Alexander Bock
This is a work-in-progress web application for designing optical lenses consisting of sequential lens elements. It is intended to support practical design of, for example, a large aperture double Gauss lens for a full frame camera with effective control of image aberrations. Support for mirrors and the design of reflecting telescopes is planned in the future.
- Full geometrical ray tracing simulated in 3D
- Aspherical surfaces (conic constant)
- Formula support for dynamically calculated surface properties
- Incoming ray environment control
- Automatic 2D cross section viewport
- Geometric point spread function (spot diagram)
- Display of focal length, effective f-number, and numerical aperture
- Autofocus
- Optical path length and phase
- Axial and transverse chromatic aberration
- Transverse ray aberration
- Material database
- Save/load designs as local JSON files
- Import designs from ".len" files
- Light and dark UI color schemes
- Mirrors (including systems such as catadioptric telescopes)
- Design Optimization
- Generate links for sharing designs by URL
- Example designs (achromatic doublet, double Gauss, Cooke triplet, historical lenses, etc.)
- Design generators/wizards (singlet, achromatic doublet, telescope objective, spherical best form lens, etc.)
- Overall surface transmission for unpolarized light
- Field curvature
- Distortion
- Abbe sine condition
- Wavefront analysis
- Modulation transfer function graph
- Through-the-lens scene simulation (test chart, astronomical, custom photo with optional depth map)
- 3D design view
- Material browser/editor
- Export standard element drawing PDFs for manufacturing
- Even-degree polynomial terms added to aspherical surfaces
- Anti-reflective coatings
- Tolerances
Open Optical Designer supports centered, symmetrical, aspherical surfaces of revolution from curves of the form:
defined by the radius of curvature
used for more complex aspherical surfaces are
not currently supported because a more complex procedure is required to determine ray intersections in
the absence of an algebraic solution for the parameter of an intersecting line. The derivations
directory contains artifacts from the process of finding these solutions for reference.
Design parameters use generic measurement units, but designs generally follow a standard such as considering units equivalent to millimeters. Inputs and outputs that require specific units (such as the design center wavelength in micrometers) are labeled appropriately.
A surface input field value beginning with an equals sign (=
) will be interpreted
as a formula which can include numbers, arithmetic operations, and references to
the final values of other surface fields.
Supported operators: (for arbitrary operands x
and y
)
x + y
: additionx - y
: subtractionx * y
: multiplicationx / y
: divisionx ^ y
: exponentiation(x)
: parentheses-x
: negation
Supported surface variables: (where #
is the 1-based surface index)
RC#
: radius of curvatureAR#
: aperture radiusTH#
: thicknessCC#
: conic constant
Examples:
- To set the aperture radius of surface 2 to automatically update to match the aperture radius of surface 1, enter
=AR1
into the aperture radius field for surface 2. - To set the thickness of surface 1 to automatically update to be one quarter of surface 1's radius of curvature, enter
=RC1/4
into the thickness field for surface 1.
Note that the dynamic thickness of the final surface is not available for use in a formula when the "Last Surface Autofocus" setting in the "Environment Control" section is on.
The "Save JSON File" button will download the current lens design as a JSON file. Depending on your browser settings, this may prompt for a location and name to save the file or immediately save the file in your downloads directory with the default name (lens-design.json). The "Load JSON File" button can be used to load a lens design that was previously saved to a local file. JSON project files contain both the lens design and the environment settings.
The ".len" file import feature imports design surfaces and recognizes the following surface parameters:
- Radius of curvature
- Aperture radius
- Thickness
- Material
- Conic constant
This software does not utilize any external or third-party dependencies, fonts, images, packages, or frameworks. It is written in plain, modern JavaScript as a single page application using standard HTML and CSS with no build, preprocessing, generation, or transformation steps. It can be run directly in the browser locally without a web server if desired.
Open tests/test.html
in a browser to run the unit test suite.
See COPYRIGHT.txt.
See LICENSE.txt.