-
Hello, First, thank you so much for creating Ray-optics! I am currently using it in a project where I have to read a CodeV .seq file into python and modify some parameters of the surfaces. For instance, I would like to change the curvature, thickness, glass and asphere coefficients of a particular surface in the optical model and then update the optical model. I am currently using the following: opm = open_model(current_working_directory+"\dblgauss.seq") For updating the curvature I am using: For updating the thickness I am using For updating glass: I haven't discovered how to update the asphere coefficients so far. May I kindly ask you please to tell me if what I did is the right way of changing the parameters? It is working but I am not sure if this is the intended way. Also it would be great if you can tell me how to update the asphere coefficeints? Many thanks in advance and sorry if this is too basic. Best Regards, |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hello, Actually I was going through the different Q&As and I found the answer to my question. Below is a copy of what I was looking for. sm.gaps[5].medium = create_glass('N-SK16', 'Schott') |
Beta Was this translation helpful? Give feedback.
Hello,
Actually I was going through the different Q&As and I found the answer to my question. Below is a copy of what I was looking for.
sm.gaps[5].medium = create_glass('N-SK16', 'Schott')
sm.gaps[5].thi = 1.2
sm.ifcs[7].profile.cv = -.12
sm.ifcs[sm.cur_surface].profile = EvenPolynomial(r=63.00, cc=0,
coefs=[0.0,-4.662529E-6,8.0842E-09,0.0,0.0,0.0])
opm.update_model()
opm.rebuild_from_seq()