I just discovered:
From the manual:
OpticalRayTracer is a free (GPL) cross-platform application that
analyzes systems of lenses and mirrors. It uses optical principles and
a virtual optical bench to predict the behavior of many kinds of
ordinary and exotic lens types as well as flat and curved mirrors.
OpticalRayTracer includes an advanced, easy-to-use interface that
allows the user to rearrange the optical configuration by dragging
objects around using the mouse.
OpticalRayTracer fully analyzes lens optical properties, incuding
refraction and dispersion. The dispersion display uses color-coded
light beams to simplify interpretation of the results.
Recent OpticalRayTracer versions allow the creation of mirrors, flat
and curved. In modern optical designs, mirrors often produce better
results than lenses, for example in astronomical instruments. Such
instruments can be roughed out in OpticalRayTracer's virtual
workbench.
This is in french, but seems to fit some my requirements.
Both seem to be nice 2d tools, both are in the ubuntu repositories.
From the manual:
OpenRayTrace is an optical lens design software that performs ray
tracing. It is built using python, wxPython, and PyOpenGL. It should
run on any platform that python, wxPython and PyOpenGL run on.
So it should in principle run on a linux box but I didn't manage to do so yet.
Here is a newer fork of the project: https://github.com/BenFrantzDale/OpenRayTrace
It also seems to support 3D ray tracing.
pyOpTools is a set of packages that allow the simulation of optical
systems by raytracing as well as some calculations involving
wavefronts, currently under development. It is written in Python and
Cython, and is being developed by the technological development group
of Combustión Ingenieros S.A.S, and the applied optics group of the
Universidad Nacional de Colombia.
A nice video of how it works can be found on youtube: https://www.youtube.com/watch?v=DB8sfm7pVPI
From the README:
Geometric optics raytracing in python for education and small-project
design.
From the documentation:
geoptics propagates light rays in 2D, in the geometrical optics
approximation.
Modifying objects should be easy, with a live update of the rays
propagation. The intent being to give a fun experience with optics.
That being said, physical precision is kept, so geoptics might
interest engineers or physicists looking for a quick way to test
ideas.
Still in alpha stage.