Compact focusing grating couplers TM mode simulation divering


I’m trying to run a modified version of the example for focusing grating coupler provided here, but changing it to have elliptical gratings. I made some simulations for TE mode, and worked fine using anti-symmetric boundary layers for ymin. When I simulated for TM changing the source port 1 (fiber) to TM mode and port 2 (GC waveguide) as well, and using symmetric boundary layer this time, I get a message at the end that the simulation diverged. I also tried removing the symmetry and got the same result. I used both mesh accuracy of 3 and 4, getting the same result. Do you have any recommendations on how to troubleshoot this issue? Thank you.


sorry for the unexpectedly slow response. There could be many possible reasons that may lead to a diverging simulation. We have some troubleshooting steps here on this page, FYI. I would suggest following the instructions there and see if you can narrowdown the issue a little bit. We are happy to take a look at your simulation file if you run into trouble.

I tried following the steps to troubleshoot finding that the root was the boundary conditions. I did what they recommend in that page, which is to set the BC to PML stabilized, however, I found that this distorted the transmission spectrum while using a Gaussian source, compared to the 2DFDTD results. Maybe due to how close the source is to the boundary (my best guess). However I didn’t want to increase the simulation area too much. GC_3DFDTD_TM1550T_total_Tout_beamsource_monitor

I also tried setting the PML profile to “custom” and increasing “alpha” to 0.1, and I think the result was closer to the one I got with the 2D simulation, but I’m still not sure if it is correct. Because the transmission is lower.


switching to Stablized PML is one possible way to solve the divergence issue (if the divergence is coming from PML). However, convergence testing should be still required. It is possible that you may need to test the convergence against parameters like mesh, boundary proximity, etc.

You mentioned that 2D and 3D data are different. Can you elaborate a little more or upload the file here that we can take a look at.

Thanks for replying. I attach the file for the 2D and 3D simulation for TM mode. For the 3D file I modified the example provided on the Lumerical website and changed the circular gratings for elliptical ones. Also in my case the fiber angle is 10 degrees. I also used a beam source, a DFT monitor and its Mode Expansion Monitor. As it is, the 3D simulation should diverge.

grating_coupler_2D_startdesignTM1550nm10deg.fsp (1.4 MB)

Sorry, this page does not allow me to upload the 3D file (maybe due to the size). I uploaded it here:

Hi, thanks for providing additional information to us.

My understanding is that the 3D and 2D results will not be exactly the same, including the peak transmission and the peak wavelength, see the results in the last section on this page (

Testing the results convergence is a reasonable step. However, i would probably not recommend changing the PML profile to custom and adjust the PML parameters, such as alpha. Instead, you should probably first stick with Stabilized PML if it fixes the divergence issue. If you would like to test the results convergence against PML, then the PML proximity and layers should be tested before other PML parameters. See our convergence testing article for more information