LensHH-LT Optical Design
LocalAbout LensHH-LT Optical Design
LensHH-LT is a sequential optical-design tool for designers working on refractive and reflective imaging systems. It combines optical analyses and merit-function optimization with a desktop app, C# API, CLI, and MCP access.
Key features
- 01Import lens designs in multiple formats
- 02Run polychromatic optical analyses
- 03Optimize with merit functions
- 04Replace glass and reshape designs
- 05Desktop app, C# API, and CLI
Use cases
- 01Analyze lens MTF and aberrations
- 02Optimize an existing lens design
- 03Search and substitute catalog glass
- 04Let an LLM agent operate the design engine
MCP support
The MCP server exposes the design engine to LLM agents for analysis and optimization, including stock-lens workflows.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMELensHH-LT — Optical Lens Design
LensHH-LT is a sequential optical-design tool for refractive and reflective imaging systems — triplets, Petzvals, double Gauss, Schmidt-Cassegrain and Maksutov telescopes, and similar designs.
Load a starting design from ZEMAX (.zmx), OSLO (.len), Optalix
(.otx), Code V (.seq), Optiland (.json), or LensHH-LT's native
.lhlt; explore it
through a full set of polychromatic analyses (spot, MTF, wavefront,
ray and OPD fans, Seidel, Zernike, distortion, field curvature,
relative illumination, chromatic focal shift); and refine it with
merit-function-driven optimization (Levenberg-Marquardt, multistart,
basin hopping) plus design-shape operators (split-element,
SPC synthesis) and per-element glass substitution.
The same engine is reachable from a C# API, an interactive CLI, and an MCP server for LLM agents (Claude Code, Cursor, etc.). The desktop app runs on Windows, macOS, and Linux.
This guide walks through the GUI, every analysis panel, every merit-function operand, the optimizers, the glass-catalog system, and the programmatic interfaces.
Pages
- Getting Started — install, open a sample lens, run a first analysis, run a first optimization.
- Analyses Reference — every analysis panel (spot, MTF, wavefront, ray fans, Seidel, Zernike, etc.) with inputs and interpretation tips.
- Merit Function Reference — every merit function operand with its inputs, meaning, and typical usage.
- Optimization — the optimizers (Local LM, Random Start, Multistart, Basin Hopping and the global modes), the searches for a new form or real glasses (Sign-Pattern Search, Replace Model Glass), the design-shape operators (split-element, SPC synthesis), and when to use each.
- Semi-Diameter as an Optimization Variable — make a Fixed-aperture surface's clear-aperture semi-diameter a variable and let the optimizer size the aperture directly; worked Cooke-triplet-with-vignetting case study.
- Automatic Vignetting Factors — sample the vignetted pupil correctly for off-axis fields in analysis and optimization; recalculated automatically as the apertures change.
- GPU Acceleration — configure the GPU options in Preferences and confirm they're running with the live GPU status chip; which optimizers use the GPU and which don't.
- Glass Catalogs — AGF format, the five shipping catalogs, preference order, custom catalogs via GlassCatalogGenerator, and glass substitution during optimization.
- API, CLI, and MCP — programmatic access: embed the C# API in your own .NET code, drive the engine from the interactive CLI, or expose it to Claude/Cursor/other MCP hosts.
- Agent Workflow — Stock-Lens-Based Design —
recipe for an LLM agent to chain
search_stock_lenses→insert_stock_lens→ analyze →reverse_lens→ optimize against the bundled 7,600-part Edmund + Thorlabs + Ross Optical catalog. - Sasian Design — Stock-Lens Triplet Pipeline —
end-to-end MCP orchestrator (
sasian_design_start/_status/_cancel/_discard) that builds a Cooke-triplet skeleton, free-optimizes with glass substitution, then walks element-by-element replacing each free-form singlet with the best matching catalog stock part. Phase 2 entry for doublet retrofits. - Building from Source — optional on every platform (Windows installer, pre-signed macOS zip package, Linux AppImage all ship with each release); for users tracking main.
Scope
LensHH-LT supports the common workflow of a general-purpose lens designer:
- Loading lens files from ZEMAX (
.zmx), OSLO (.len), Optalix (.otx), Code V (.seq), Optiland (.json), or LensHH-LT's native.lhlt. - Standard and Even Asphere surfaces.
- EPD or F/# apertures, object-angle or object-height fields.
- Polychromatic spot, PSF, and MTF analyses (wavefront, OPD, Zernike, and Seidel are evaluated one wavelength at a time).
- Merit-function-driven optimization with variables and pickups.
- Glass catalogs in AGF format (five catalogs ship with the installer).
It does not handle configurations, coatings, thermal/environmental effects, tolerancing data, tilts and decenters, folds, or non-standard surface types. For those, see the full LensHH product.
Feedback
File issues or suggestions at the project's GitHub repository.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.