SPDC

class spdcalc.spdcalc.SPDC

Bases: object

SPDC configuration object

This is the primary object that is used to hold the configuration of the SPDC process. There are two main ways to create an instance of this object:

1. By using the default constructor SPDC.default() which creates an instance with default values. These can then be modified as needed.

  1. By using the SPDC.from_yaml(yaml: str) or SPDC.from_json(json: str)

Attributes Summary

apodization

The apodization

counter_propagation

Whether or not counter-propagation is used

crystal_kind

The type of crystal used in the SPDC process

crystal_length_um

The crystal length in micrometers

crystal_phi_deg

The crystal polar angle in degrees

crystal_pm_type

The phasematching type used in the SPDC process

crystal_temperature_c

The crystal temperature in degrees Celsius

crystal_theta_deg

The crystal azimuthal angle in degrees

deff_pm_per_volt

The effective nonlinear coefficient in pm/V

idler_frequency_rad_per_s

The idler frequency in radians per second

idler_phi_deg

The idler polar angle in degrees

idler_theta_deg

The idler (internal) azimuthal angle in degrees

idler_theta_external_deg

The idler external azimuthal angle in degrees

idler_waist_position_um

The idler waist position in micrometers

idler_waist_um

The idler waist in nanometers

idler_wavelength_nm

The idler wavelength in nanometers

poling_period_um

The poling period in micrometers

pump_average_power_mw

The pump average power in milliwatts

pump_bandwidth_nm

The pump spectral bandwidth in nanometers

pump_frequency_rad_per_s

The pump frequency in radians per second

pump_spectrum_threshold

The pump spectrum threshold

pump_waist_nm

The pump waist in nanometers

pump_wavelength_nm

The pump wavelength in nanometers

signal_frequency_rad_per_s

The signal frequency in radians per second

signal_phi_deg

The signal polar angle in degrees

signal_theta_deg

The signal (internal) azimuthal angle in degrees

signal_theta_external_deg

The signal external azimuthal angle in degrees

signal_waist_position_um

The signal waist position in micrometers

signal_waist_um

The signal waist in nanometers (x, y)

signal_wavelength_nm

The signal wavelength in nanometers

Methods Summary

counts_coincidences(si_range[, integrator])

Calculate the coincidence counts

counts_singles_idler(si_range[, integrator])

Calculate the singles rate for the idler

counts_singles_signal(si_range[, integrator])

Calculate the singles rate for the signal

default()

Create a new SPDC object with default values

delta_k(signal_frequency_rad_per_s, ...)

Compute delta_k vector

efficiencies(si_range[, integrator])

Calculate the efficiencies (symmetric, signal, idler)

from_json(json)

Create a new SPDC object from a JSON string

from_yaml(yaml)

Create a new SPDC object from a YAML string

hom_rate_series(time_delays, si_range[, ...])

Calculate the Hong-Ou-Mandel rate for different time delays

hom_two_source_rate_series(time_delays, si_range)

Calculate the two-source Hong-Ou-Mandel rate series

hom_two_source_visibilities(si_range[, ...])

Calculate the two-source Hong-Ou-Mandel visibilities

hom_visibility(si_range[, integrator])

Calculate the Hong-Ou-Mandel visibility

joint_spectrum([integrator])

Calculate the joint spectrum

optimum_crystal_theta()

Get the optimum crystal theta

optimum_range(n)

Get the optimum range in frequency space

poling_domain_lengths_m()

Get the poling domains as lengths in meters

poling_domains()

Get the poling domains

to_json()

Convert the SPDC object to a JSON string

to_optimum()

Convert this setup to an optimum setup

to_yaml()

Convert the SPDC object to a YAML string

with_optimum_crystal_theta()

Convert this setup to one with an optimum crystal theta

with_optimum_idler()

Convert this setup to one with an optimum idler

with_optimum_periodic_poling()

Convert this setup to one with an optimum periodic poling

with_swapped_signal_idler()

Swap the signal and idler

Attributes Documentation

apodization

The apodization

This is a dictionary with the following keys: - kind: the kind of apodization - parameter: the parameter depending on the kind

The kind can be one of the following: - off: no apodization - gaussian: Gaussian function (parameter: { fwhm_nm: float }) - bartlett: Bartlett function (parameter: float) - blackman: Blackman function (parameter: float) - connes: Connes function (parameter: float) - cosine: Cosine function (parameter: float) - hamming: Hamming function (parameter: float) - welch: Welch function (parameter: float) - interpolate: Interpolated evenly spaced points (parameter: list of floats)

counter_propagation

Whether or not counter-propagation is used

crystal_kind

The type of crystal used in the SPDC process

The values can be seen by looking at the id feilds from get_all_crystal_meta()

crystal_length_um

The crystal length in micrometers

crystal_phi_deg

The crystal polar angle in degrees

crystal_pm_type

The phasematching type used in the SPDC process

The format for setting this is flexible. The following are all valid: - “ooo” - “o-oo” - “Type2 e eo” - “type 2 e->eo”

crystal_temperature_c

The crystal temperature in degrees Celsius

crystal_theta_deg

The crystal azimuthal angle in degrees

deff_pm_per_volt

The effective nonlinear coefficient in pm/V

idler_frequency_rad_per_s

The idler frequency in radians per second

idler_phi_deg

The idler polar angle in degrees

idler_theta_deg

The idler (internal) azimuthal angle in degrees

idler_theta_external_deg

The idler external azimuthal angle in degrees

idler_waist_position_um

The idler waist position in micrometers

idler_waist_um

The idler waist in nanometers

idler_wavelength_nm

The idler wavelength in nanometers

poling_period_um

The poling period in micrometers

pump_average_power_mw

The pump average power in milliwatts

pump_bandwidth_nm

The pump spectral bandwidth in nanometers

pump_frequency_rad_per_s

The pump frequency in radians per second

pump_spectrum_threshold

The pump spectrum threshold

Values below this threshold are considered to be zero

pump_waist_nm

The pump waist in nanometers

pump_wavelength_nm

The pump wavelength in nanometers

signal_frequency_rad_per_s

The signal frequency in radians per second

signal_phi_deg

The signal polar angle in degrees

signal_theta_deg

The signal (internal) azimuthal angle in degrees

signal_theta_external_deg

The signal external azimuthal angle in degrees

signal_waist_position_um

The signal waist position in micrometers

signal_waist_um

The signal waist in nanometers (x, y)

signal_wavelength_nm

The signal wavelength in nanometers

Methods Documentation

counts_coincidences(si_range, integrator=None)

Calculate the coincidence counts

Parameters

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

float

The coincidence counts

counts_singles_idler(si_range, integrator=None)

Calculate the singles rate for the idler

Parameters

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

float

The singles rate for the idler

counts_singles_signal(si_range, integrator=None)

Calculate the singles rate for the signal

Parameters

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

float

The singles rate for the signal

static default()

Create a new SPDC object with default values

delta_k(signal_frequency_rad_per_s, idler_frequency_rad_per_s)

Compute delta_k vector

Parameters

signal_frequency_rad_per_sfloat

The signal frequency in rad/s

idler_frequency_rad_per_sfloat

The idler frequency in rad/s

Returns

tuple of float

efficiencies(si_range, integrator=None)

Calculate the efficiencies (symmetric, signal, idler)

Parameters

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

dict

The efficiencies (symmetric, signal, idler), and rates (coincidences, singles signal, singles idler)

static from_json(json)

Create a new SPDC object from a JSON string

static from_yaml(yaml)

Create a new SPDC object from a YAML string

hom_rate_series(time_delays, si_range, integrator=None)

Calculate the Hong-Ou-Mandel rate for different time delays

Parameters

time_delayslist of floats

The time delays in seconds

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

list of float

The Hong-Ou-Mandel rate for different time delays

hom_two_source_rate_series(time_delays, si_range, integrator=None)

Calculate the two-source Hong-Ou-Mandel rate series

Parameters

time_delayslist of floats

The time delays in seconds

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

dict

The two-source Hong-Ou-Mandel rate series

hom_two_source_visibilities(si_range, integrator=None)

Calculate the two-source Hong-Ou-Mandel visibilities

Parameters

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

dict

The two-source Hong-Ou-Mandel visibilities

hom_visibility(si_range, integrator=None)

Calculate the Hong-Ou-Mandel visibility

Parameters

si_rangeSIRange

Range of signal and idler frequencies

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

dict

The Hong-Ou-Mandel visibility

joint_spectrum(integrator=None)

Calculate the joint spectrum

Parameters

integratorIntegrator, optional

The integrator to use, which defaults to a simple Simpson’s rule

Returns

JointSpectrum

The joint spectrum object

optimum_crystal_theta()

Get the optimum crystal theta

optimum_range(n)

Get the optimum range in frequency space

poling_domain_lengths_m()

Get the poling domains as lengths in meters

Returns

List[Tuple[float, float]]

poling_domains()

Get the poling domains

They are a list of fractions of poling period

Returns

List[Tuple[float, float]]

to_json()

Convert the SPDC object to a JSON string

to_optimum()

Convert this setup to an optimum setup

to_yaml()

Convert the SPDC object to a YAML string

with_optimum_crystal_theta()

Convert this setup to one with an optimum crystal theta

with_optimum_idler()

Convert this setup to one with an optimum idler

with_optimum_periodic_poling()

Convert this setup to one with an optimum periodic poling

with_swapped_signal_idler()

Swap the signal and idler