Photonics

Photonics

Topics related to Lumerical and more.

optimization with feasible region

    • SAURAV GAUTAM
      Subscriber

      Hi, I want to get feasible results of transmittance spectra(all parameter within 10% of transmittance) from different constraint sweeps like angle, thickness, material. Is there any sample script for this?

      I found particle swarm optimization but that's for single minima and just one constraint.

      thank you

    • Amrita Pati
      Ansys Employee

      Hi Saurav,

      With Lumerical’s in-built Optimization tool (which uses PSO), you can have different constraints. For ex. screenshot of a multi-constraint optimization that I was working on a while ago is shown:

      But the PSO can maximize/minimize a single objective function. In terms of the objective function there can be two variations:

      1. First one is that if you have a single objective function but you are looking at it’s multiple values. For ex., the transmission spectrum that you mentioned here. In those cases what is typically done is you have to come up with a different figure of merit that manages to quantify a series of Ts over wavelength into a single value. For this, what you have to do is add “T” to the Figure of Merit. But at the same time, you have to enable the “Use figure of merit script” in the Advanced Tab and then you have to decide what this FOM can be (in the section for code) for transmission across a range of wavelengths. For ex. something like fom = integrate(T^2,1,f); What this does is takes the multiple values of T in a range of frequecies, integrates them over the frequency, which converts it into a single value that can be minimized or maximized. So, this takes into consideration not just a single value of T, but the values of T over the entire spectrum.


      2. The second consideration is a multi-objective optimization. Which is when you are looking at different objective functions. For ex. along with T if you are looking at some other result. In those cases there can be two approaches. The first is, you either have to find a way to combine multiple objective functions into a single function. There are many papers on that. One approach is that, you simply add all the objective functions, and assign each term a weight to decide the priority of each objective. In that case, you can use the inbuilt PSO and add the FOM like I mentioned before. But in general I have seen that PSO is not very effective at multi-objective optimization.

      The second approach is to use a different algorithm altogether which can be done from the user defined algorithm section as shown below:

      Please let me know if you have any questions.

      Reagrds,
      Amrita

       

    • SAURAV GAUTAM
      Subscriber

      thanks a lot amrita,

      i want to find the angles, depths for transmisiion more 10%, so i am considering using nested sweep with for loop and if else condition to get the values.

    • SAURAV GAUTAM
      Subscriber

      https://optics.ansys.com/hc/en-us/articles/360034922913

      i found this example,

      how to write code for set or range of angle , depth that will give  reflection higher than sepoint at given wavelength?

    • Amrita Pati
      Ansys Employee

      Hi Saurav,

      You are welcome! I had a quick look at the example you mentioned. I would just like to point out that it calculates the mean of R and T in the sweep and optimizes the thickness of the structure for the maximum mean (single value) of R over a set of angles (rather than maximizing the value of R at each angle). 

      For setting up sweeps using code, please refer to the following link:Creating parameter sweeps using a script 

      For setting up optimization task using code, please refer to the following:Creating optimization tasks using a script

      I did a quick search and didn't find any published code for nested sweeps, here is a simple example code, but you can combine it with the resources above.

      addsweep(0);
      setsweep("sweep","name","A");
      insertsweep("A");
      setsweep("sweep","name","B");

      This creates a nested loop as shown:

      Regards,
      Amrita

    • SAURAV GAUTAM
      Subscriber

      thank you for the help and support

Viewing 5 reply threads
  • The topic ‘optimization with feasible region’ is closed to new replies.