poppy icon indicating copy to clipboard operation
poppy copied to clipboard

Consider refactoring plane types from OpticalElements to OpticalSystems

Open mperrin opened this issue 8 years ago • 1 comments

Promoted to its own issue from a comment on #151 :

Something to consider for eventual API larger overhaul. In retrospect I don't think that I should have made planetype a property of an optic itself. Rather it is a property of the ordering of planes that makes up an optical system. The OpticalSystem should maintain the list of plane types along with the list of plane objects themselves. (And the list of distances between planes, in the case of the FresnelOpticalSystem.)

Back story: When this was just a Fraunhofer domain code, there was a clear distinction between pupil plane optics specified with linear physical units (meters) and image plane optics with angular units (arcseconds). In the more general Fresnel domain, a given optic described in linear physical units can be located at any plane. It's not a property of the optic itself, it's a property of where it is in the optical system as a whole. (and Wavefronts do have a well defined plane type at each stage of propagation through that system). It may be cleaner and more self-consistent to remove having plane type as a property of the optical element classes.

mperrin avatar Feb 10 '16 23:02 mperrin

Not going to happen any time soon - seems to be limited return on investment for refactoring this. Removing the milestone tag.

mperrin avatar Sep 26 '16 17:09 mperrin