Closed MaximilianHoffmann closed 8 years ago
Do you have example code that shows this? propagate(clip=True)
should invalidate out-of-area rays.
What do you think about this example?
import rayopt as ro
import warnings
import numpy as np
%matplotlib inline
# ignore matplotlib and numpy warning each other
warnings.simplefilter("ignore", FutureWarning)
# ignore floating point exceptions
np.seterr(divide="ignore", invalid="ignore")
# by default only print 4 significant digits
np.set_printoptions(precision=4)
t='''
{"wavelengths": [7e-07, 8e-07], "scale": 0.001, "description": "", "solves": [], "validators": [], "pickups": [],
"image": {"radius": Infinity, "type": "finite",
"pupil": {"distance": 42816.23751102979, "radius": -1415.9501091620718, "refractive_index": 1.0002758044985038, "update_radius": true}},
"object": {"angle": 0.017453292519943295,
"pupil": {"distance": 151.0, "radius": 10.0, "refractive_index": 1.0002758044985038}},
"stop": 2,
"elements": [{"material": "basic/air"},
{"distance": 1.0, "material": "basic/air"},
{"distance": 150.0, "material": "basic/mirror", "radius": 5.0, "angles": [-0.20943951023931956, 0.0, 0.0]},
{"distance": 150.0, "direction": [0.0, 0.40673664307580026, -0.913545457642601], "material": "SCHOTT/N-LAK22", "radius": 25.4, "curvature": 0.0089118616879066},
{"distance": 8.2, "direction": [0.0, 0.40673664307580026, -0.913545457642601], "material": "SCHOTT/N-SF6HT", "radius": 25.4, "curvature": -0.0104231811548885},
{"distance": 5.0, "direction": [0.0, 0.40673664307580026, -0.913545457642601], "material": "basic/air", "radius": 25.4, "curvature": -0.0030759766225777},
{"distance": 144.9494222095487, "direction": [0.0, 0.40673664307580026, -0.913545457642601], "material": "basic/air", "radius": 40.0}]}
'''
s=ro.system_from_json(t)
ro.Analysis(s)
It seem like rays of a parallel ray bundle reflect at the continuation of a mirror surface, even if the radius is smaller than the bundle diameter?