Skip to main content

Dear Zemax Staff and Users,

I would like to ask if there is a possibility to parameterization of the model’s values or type equations instead of the scalar.

As an example, in this simple sequential model (figure below) I would like to perform optimization where thickness of the surfaces 2 and 3 are variables. However, I would like to keep these two values at constant level during optimization. Therefore, some kind of parameterization is needed. Moreover, is it possible to implement some equations like: “thickness surf. 2 = thickness surf 3 + 2 mm”? I would massively speed up some task in complex optical models. I didn’t find direct option to solve this problems but I was wondering maybe there is some more advanced approach like using Python. I would be pleased to get your advice on this topic.

 

Best regards,

Michal Cwikla

Hi Michal,

 

If you click on the V cell next to the Thickness value, you’ll notice different kinds of solves. One of them is called Pickup, which copies a value from another cell in the Lens Data Editor with an optional scaling factor and offset. One drawback though is that it can’t pickup a surface that is defined after the surface where the solve is applied. A workaround would be to have a dummy surface at the beginning of your file that is ignored (double-click on the surface to open the surface properties, and in the Type tab check Ignore This Surface). Then, you can have Surface 3 to pickup its Thickness from this dummy surface:

Finally, you can set another Pickup on Surface 2 from Surface 1 (which is essentially the Thickness of Surface 3) with an offset of 2.0:

While Surface 1 is ignored, you can still have its Thickness set as a variable.

Would that work for you?

As a side note, if you want to setup a more complex solve you need to look at ZPL Solve, which is a type of Solve which uses the Zemax Programming Language and would allow you to perform calculations for the Solve value.

Take care,

 

David


This is perfect, thank you David.


Reply