fouriax.KSpacePropagator#
- class KSpacePropagator(distance_um=None, refractive_index=1.0, na_limit=None, include_evanescent=False, precomputed_transfer_stack=None)#
Bases:
OpticalLayerDiagonal k-space propagator using the angular-spectrum phase advance.
Requires k-space-domain input. Multiplies each frequency component by
exp(j * kz * distance_um)where kz is derived from the dispersion relation. Supports scalar and Jones fields.All length quantities are in micrometers.
- Parameters:
distance_um (float | None) – Propagation distance in micrometers.
refractive_index (float) – Refractive index of the medium.
na_limit (float | None) – Optional numerical aperture cutoff applied as a hard k-space mask.
include_evanescent (bool) – If
True, evanescent modes are included (complex kz). IfFalse(default), evanescent modes are zeroed out.precomputed_transfer_stack (Array | None)
- __init__(distance_um=None, refractive_index=1.0, na_limit=None, include_evanescent=False, precomputed_transfer_stack=None)#
- Parameters:
distance_um (float | None)
refractive_index (float)
na_limit (float | None)
include_evanescent (bool)
precomputed_transfer_stack (Array | None)
- Return type:
None
Methods
__init__([distance_um, refractive_index, ...])forward(field)Propagate a k-space field by diagonal transfer multiplication.
Return trainable parameters exposed by this layer.
transfer_function(field, wavelength_um, ...)Build the diagonal k-space transfer function for one wavelength.
validate_for(field)Check that field is compatible with this layer.
Attributes
- distance_um: float | None = None#
- refractive_index: float = 1.0#
- na_limit: float | None = None#
- include_evanescent: bool = False#
- precomputed_transfer_stack: Array | None = None#
- transfer_function(field, wavelength_um, distance_um)#
Build the diagonal k-space transfer function for one wavelength.
- Parameters:
field (Field) – K-space field whose grid defines the sampled frequency axes.
wavelength_um (float) – Wavelength to propagate in micrometers.
distance_um (float) – Propagation distance in micrometers.
- Returns:
Complex array with shape
(ny, nx)matching the sampled k-space grid.- Raises:
ValueError – If the distance, refractive index, or NA limit is invalid.
- Return type:
Array
- parameters()#
Return trainable parameters exposed by this layer.
- Return type:
dict[str, Array]
- forward(field)#
Propagate a k-space field by diagonal transfer multiplication.