Extracting Huygens PSF and FFT PSF function

  • 3 January 2023
  • 1 reply



I want to extract PSFs of our company lens by macro of the optics studio.


The lens is not suitable for the FFT PSF, so I have to extract Huygens PSF.


I am interesting in spatial variant PSFs


I need a macro code for the Huygens PSF so that I can extract PSF from the various points on the image space.


Is there anyone who can show some examples codes for the Hugens PSF?


Thank you and Happy new year!


Best answer by Ethan 13 January 2023, 04:55

View original

1 reply

Userlevel 2
Badge +2

Hi @sh0815kang,

Your only option for extracting Huygen’s PSF data is through the ZPL GETTEXTFILE command (See the Help File: The Programming Tab > About the ZPL > KEYWORDS (about the zpl) > GETTEXTFILE). This command can be used to save the text file from any analysis in OpticStudio, and then you can manually parse the file for the data that you need.

However, there are additional methods and functionality in the ZOS API if you are interested in using that as an alternative. To get started with the API, please see this Knowledgebase article: Basic method of performing system analysis in ZOS-API – Knowledgebase (