pyoptools.raytrace.surface.aspherical module

Module that defines support for Aspherical optical surfaces

class pyoptools.raytrace.surface.aspherical.Aspherical

Bases: Surface

Class representing a high-order aspherical optical surface.

An aspherical surface is defined by the equation:

Z = (Ax*x**2 + Ay*y**2) /

(1 + sqrt(1 - (1+Kx)*Ax**2*x**2 - (1+Ky)*Ay**2*y**2)) + Poly2D(x, y)

The aspherical surface combines a base aspheric shape with an additional polynomial deformation term defined by Function2D.

Parameters:
  • shape (Shape object) – The shape of the aspherical surface.

  • Ax (float, optional) – X-axis curvature coefficient. Default is 0.

  • Ay (float, optional) – Y-axis curvature coefficient. Default is 0.

  • Kx (float, optional) – X-axis conic constant. Default is 0.

  • Ky (float, optional) – Y-axis conic constant. Default is 0.

  • poly (Poly2D, optional) – Polynomial surface deformation term. If None, a zero-order polynomial is used (no deformation).

  • *args – Additional arguments passed to the parent Surface class.

  • **kwargs – Additional arguments passed to the parent Surface class.

xmin, xmax

Bounds of the surface in the x direction.

Type:

float

ymin, ymax

Bounds of the surface in the y direction.

Type:

float

zmin, zmax

Bounds of the surface in the z direction.

Type:

float

DX, DY

Partial derivatives of the polynomial deformation term.

Type:

Poly2D

Examples

>>> from pyoptools.raytrace.surface import Aspherical
>>> from pyoptools.raytrace.shape import Rectangle
>>> from pyoptools.misc.function_2d.poly_2d.poly_2d import Poly2D
>>> surface = Aspherical(
...     shape=Rectangle(size=(5,5)),
...     Ax=0.5,
...     Ay=0.3,
...     Kx=0.1,
...     Ky=0.1,
...     poly=Poly2D((0,1,1))
... )

Notes

The surface shape is determined by the combination of the base aspherical equation and the polynomial deformation term. The polynomial term allows for modeling complex surface irregularities or corrections.

Ax
Ay
DX
DY
Kx
Ky
poly
xmax
xmin
ymax
ymin
zmax
zmin