comnum.Photodiode#
- class comnum.Photodiode(*, responsivity=Ellipsis, temperature_k=Ellipsis, dark_current_a=Ellipsis, load_ohm=Ellipsis, bandwidth_hz=Ellipsis, n_taps=Ellipsis, filter_kind=Ellipsis, shot_noise=Ellipsis, thermal_noise=Ellipsis, bandwidth_limitation=Ellipsis, ideal=Ellipsis)#
A PIN photodiode (OptiCommPy
photodiode): responsivity, shot noise2q(I + I_d)B, thermal noise4k_BTB/R_L, and a low-pass FIR of bandwidthB.Every attribute is readable and writable;
ideal=TruegivesR|E|²without noise nor filter.- Parameters:
responsivity (float) – responsivity (A/W).
temperature_k (float) – temperature (K).
dark_current_a (float) – dark current (A).
load_ohm (float) – load resistance (Ω).
bandwidth_hz (float) – electrical bandwidth
B(Hz).n_taps (int) – taps of the bandwidth-limiting filter (made odd).
filter_kind (str) – the filter,
"rect"or"gauss"(seelow_pass_fir).shot_noise (bool) – add shot noise.
thermal_noise (bool) – add thermal noise.
bandwidth_limitation (bool) – filter to the bandwidth.
ideal (bool) – ideal square-law detection (overrides the three flags above).
- Raises:
ValueError – for an invalid parameter (the message names it).
- detect(e, fs, rng)#
Photocurrent of an optical field (one polarisation).
- Parameters:
- Returns:
the photocurrent (A, float64).
- Return type:
- Raises:
ValueError – if the detector is not ideal and
fs < 2B.
- detect_power(p, fs, rng)#
Photocurrent of an optical power.
- Parameters:
- Returns:
the photocurrent (A, float64).
- Return type:
- Raises:
ValueError – for an invalid parameter or input (the message names it).
- filter_kind#
The filter,
"rect"or"gauss"(read and write; a name is checked when it is assigned).- Type: