The attached are two files that shows how to simulate CMOS diffraction using the static link in OpticStudio.
More information about using static link can be found in the following article:
How to load grating data from Lumerical into OpticStudio – Ansys Optics
When the files are opened, it might look as below.
![](https://uploads-us-west-2.insided.com/zemax-en/attachment/8ffa7990-1a57-4924-9812-3168fed93255.png)
It’s not difficult to find object 21 is set up with the static link, which is supposed to simulate how CMOS can diffract lights and cause straylight when it comes back.
![](https://uploads-us-west-2.insided.com/zemax-en/attachment/23fce171-7664-44b1-b84b-d5702fb479d5.png)
The Stochastic mode is turn on because rays will revisit the CMOS many times and generate so many calculations.
The Test Mode is set to 9 for a special handling to the grating data. Normally, when light hits CMOS, most of the power is absorbed and converted to electric power in the pixels. And only a certain ratio of power is diffracted in the reflection direction. If the grating data is generated from Lumerical, there will be only reflection diffraction and no any transmission order. The trick of Test Mode = 9 is it calculates total reflection diffraction power in R and put all the (1-R) power to the transmission order (0,0). In this way, we can easily check the absorbed power by placing a detector after the grating.
![](https://uploads-us-west-2.insided.com/zemax-en/attachment/1d3c1013-8e61-4600-943a-759c38830639.png)
By setting a larger Layout Rays #, we can observe how the system looks like.
![](https://uploads-us-west-2.insided.com/zemax-en/attachment/7707e756-6554-4fab-910a-63d2742033a1.png)
And the simulation results are as below for 1 um and 4 um CMOS.
![](https://uploads-us-west-2.insided.com/zemax-en/attachment/71e95f55-5fe6-47fd-9890-4e9a57d079fe.png)
![](https://uploads-us-west-2.insided.com/zemax-en/attachment/5603bd3e-2471-4499-a2df-84b591e8c120.png)