Defocus#

class deeptrack.aberrations.Defocus(*args: tuple[Any, ...], coefficient: PropertyLike[float | list[float]] = 1, **kwargs: dict[str, Any])#

Bases: Zernike

Zernike polynomial with n=2, m=0.

This class represents the Zernike polynomial for defocus aberration, characterized by a radial index of n=2 and an azimuthal index of m=0. It describes phase aberrations that result in a uniform spherical defocus across the optical system.

Parameters#

coefficient: PropertyLike[float or list of floats], optional

The coefficient of the polynomial. Default is 1.

Attributes#

n: int

The radial index of the Zernike polynomial (always 2 for Defocus).

m: int

The azimuthal index of the Zernike polynomial (always 0 for Defocus).

coefficient: PropertyLike[float or list of floats]

The coefficient of the polynomial.

Examples#

Apply a Defocus Zernike phase aberration (n=2, m=0) to a simulated fluorescence image:

>>> import deeptrack as dt
>>> particle = dt.PointParticle(z=0 * dt.units.micrometer)
>>> defocus_aberration = dt.Defocus(coefficient= 1.5)
>>> aberrated_optics = dt.Fluorescence(
>>>     pupil=defocus_aberration,
>>> )
>>> aberrated_particle = aberrated_optics(particle)
>>> aberrated_particle.plot(cmap="gray")