AbstractFieldStop#

class esis.optics.abc.AbstractFieldStop[source]#

Bases: Printable, Replaceable, Rollable, Translatable

An interface describing the field stop of the instrument.

Attributes

num_folds

The order of the rotational symmetry of the optical system.

num_sides

The number of sides of the field stop's aperture.

radius_clear

The distance from the center to a vertex of the clear aperture.

radius_mechanical

The radius of the exterior edge of the field stop.

roll

roll angle of this object

surface

Represent this object as an optika surface.

transformation

the coordinate transformation between the global coordinate system and this object's local coordinate system

translation

translate the coordinate system

width_clear

The width of the clear aperture from edge to edge.

Methods

__init__()

replace(**changes)

A copy of this object with the given fields replaced.

to_string([prefix])

Public-facing version of the __repr__ method that allows for defining a prefix string, which can be used to calculate how much whitespace to add to the beginning of each line of the result.

Inheritance Diagram

Inheritance diagram of esis.optics.abc.AbstractFieldStop
replace(**changes)#

A copy of this object with the given fields replaced.

A method version of dataclasses.replace(), matching named_arrays.AbstractArray.replace(), so that a nested change reads the same at every level:

system.replace(
    surface=system.surface.replace(
        sag=system.surface.sag.replace(radius=r),
    ),
)

The copy is shallow, as dataclasses.replace() is: every field which is not named is shared with the original, and mutating one through the copy is mutating it in both. Take copy.deepcopy() of the result where that matters.

Parameters:

changes – The fields to overwrite in the copy.

Return type:

Self

to_string(prefix=None)#

Public-facing version of the __repr__ method that allows for defining a prefix string, which can be used to calculate how much whitespace to add to the beginning of each line of the result.

Parameters:

prefix (None | str) – an optional string, the length of which is used to calculate how much whitespace to add to the result.

Return type:

str

abstract property num_folds: int#

The order of the rotational symmetry of the optical system.

property num_sides: int#

The number of sides of the field stop’s aperture.

abstract property radius_clear: Quantity | AbstractScalar#

The distance from the center to a vertex of the clear aperture.

abstract property radius_mechanical: Quantity | AbstractScalar#

The radius of the exterior edge of the field stop.

abstract property roll: Quantity | int | float | complex | ndarray | AbstractScalar#

roll angle of this object

property surface: Surface#

Represent this object as an optika surface.

property transformation: AbstractTransformation#

the coordinate transformation between the global coordinate system and this object’s local coordinate system

abstract property translation: Quantity | AbstractScalar | AbstractVectorArray#

translate the coordinate system

property width_clear: Quantity#

The width of the clear aperture from edge to edge.