TAGGED: Lumerical-FDTD, metalens
-
-
February 25, 2023 at 6:11 pmA.Abdur Rahman AkibSubscriber
Hello, I was trying to design a metalens using P-B phase by rotating nanofins to get the 2pi phase change and I was using https://optics.ansys.com/hc/en-us/articles/360042097313-Metalens this design as my base, here I replaced the pillar by the nano fin. But I am not getting proper phase vs rotation, I am getting results just the screenshot uploaded.
P.S. I haven't change anything apart from the pillar, all other parameters and designs same as it is as the example. I really need help!Do i need to change something in the S parameter I am really lost.
-
March 1, 2023 at 12:23 amGuilin SunAnsys Employee
It seems the interpolation might have errors, as the phase cannot be that large.
Please first test the example, make sure everything is duplicated. then change the unit cell to your own, plot the rotaion vs phase again.
Since the source and the monitors are in the same analysis group, make sure their locations are proper.You can also check if the transmission is correct.
-
March 1, 2023 at 1:30 amA.Abdur Rahman AkibSubscriber
To achieve berry phase I needed to use circularly polarized light, from a post in the forum I've came to know that lumerical can not calculate circularly polarized lights phase directly.
Therefore first I ran the simulation for polarization angle 0 then 90 degree then took the phase difference of S.S21_Gn from angle 0 - angle 90
Is this the right approach? But I am still not getting proper results.
-
March 1, 2023 at 4:59 pmGuilin SunAnsys Employee
“To achieve berry phase I needed to use circularly polarized light, from a post in the forum I've came to know that lumerical can not calculate circularly polarized lights phase directly. ”
I do not think there is anything to prevent you calculating the phase of the phase of circularly polarized light. What you need to calculate is: get the complex ampltude of the decomposed cp light. It needs a little math.eg, the total fields are A*RCP+B*LCP.
-
March 1, 2023 at 7:14 pmA.Abdur Rahman AkibSubscriber
clear;
load("unit_cell.fsp");
period = getnamed("::model","period");
# get data from sweep
sname= "radius";
radius = getsweepdata(sname,"radius");
height = getsweepdata(sname,"height");
S = getsweepresult(sname,"S");
phase = pinch(angle(S.S21_Gn),1,1); # the dimension of S21_Gn is [frequency,radius,height]
phase = pinch(unwrap(phase)) - phase(1);
height = height(1);
E = getsweepresult(sname,"E");
H = getsweepresult(sname,"H");
wavelength = E.lambda;
matlabsave("EH_and_phase_vs_radius_fdtd",wavelength,height,period,phase,radius,E,H);
#############################################################
# interpolate radius and fields on a denser phase data points
#############################################################
phase_interp = linspace(0,2*pi,361); # limit the phase range to 0 - 2*pi
radius_interp = spline(radius,phase,phase_interp); # phase sampled at an interval of 1 degree.
plot(phase_interp*180/pi,radius_interp*1e9,"phase (degree)","radius (nm)","","linewidth=2");
holdon;
plot(phase*180/pi,radius*1e9,"phase (degree)","radius (nm)","","plot type = point,marker type=x, color=red");
legend("radius_interpolated","radius from sweep");
holdoff;
E = getsweepresult(sname,"E");
Ex = pinch(E.Ex); Hx = pinch(H.Hx);
Ey = pinch(E.Ey); Hy = pinch(H.Hy);
Ez = pinch(E.Ez); Hz = pinch(H.Hz);
x = E.x;
y = E.y;
z = E.z;
f = E.f;
wavlength = c/f;
# interpolate over radius
Ex = interp(Ex,x,y,radius,x,y,radius_interp);
Ey = interp(Ey,x,y,radius,x,y,radius_interp);
Ez = interp(Ez,x,y,radius,x,y,radius_interp);
Hx = interp(Hx,x,y,radius,x,y,radius_interp);
Hy = interp(Hy,x,y,radius,x,y,radius_interp);
Hz = interp(Hz,x,y,radius,x,y,radius_interp);
# spatial sampling
######################
do_sampling = true;
ns = 3; # sampling per period
if (do_sampling) {
xs = linspace(min(x),max(x),ns);
ys = linspace(min(y),max(y),ns);
Ex = interp(Ex,x,y,radius_interp,xs,ys,radius_interp);
Ey = interp(Ey,x,y,radius_interp,xs,ys,radius_interp);
Ez = interp(Ez,x,y,radius_interp,xs,ys,radius_interp);
Hx = interp(Hx,x,y,radius_interp,xs,ys,radius_interp);
Hy = interp(Hy,x,y,radius_interp,xs,ys,radius_interp);
Hz = interp(Hz,x,y,radius_interp,xs,ys,radius_interp);
Ex = reshape(Ex,[ns,ns,1,1,length(phase_interp)]);
Ey = reshape(Ey,[ns,ns,1,1,length(phase_interp)]);
Ez = reshape(Ez,[ns,ns,1,1,length(phase_interp)]);
Hx = reshape(Hx,[ns,ns,1,1,length(phase_interp)]);
Hy = reshape(Hy,[ns,ns,1,1,length(phase_interp)]);
Hz = reshape(Hz,[ns,ns,1,1,length(phase_interp)]);
E = rectilineardataset("E",xs,ys,z);
E.addparameter("f",f);
E.addparameter("radius",radius_interp);
E.addattribute("E",Ex,Ey,Ez);
H = rectilineardataset("H",xs,ys,z);
H.addparameter("f",f);
H.addparameter("radius",radius_interp);
H.addattribute("H",Hx,Hy,Hz);
phase = phase_interp;
radius = radius_interp;
}
mat_pillar = getnamed("pillar","material");
index_pillar = getindex("pillar",c/wavelength);
mat_sub = getnamed("substrate","material");
index_sub = getnamed("substrate","index");
matlabsave("EH_and_phase_vs_radius_interp_fdtd",wavelength,height,period,mat_pillar,index_pillar,mat_sub,index_sub,phase,radius,E,H);
visualize(E);
-
March 1, 2023 at 7:15 pmA.Abdur Rahman AkibSubscriber
I am using the uloaded code for phase calculation, is this code alright???
-
-
March 1, 2023 at 8:14 pm
-
- The topic ‘P-B phase metalens phase library creation’ is closed to new replies.
- Difference between answers in version 2024 and 2017 lumerical mode solution
- Errors Running Ring Modulator Example on Cluster
- INTERCONNECT – No results unless rerun simulation until it gives any
- Import material .txt file with script
- Trapezoidal ring
- Help for qINTERCONNECT
- Issues with getting result from interconnent analysis script
- Absorption cross-section of AuNR excited by prism-based TIR
- How to measure transmission coefficients on a given plane .
- Topology Optimization Error
-
1406
-
599
-
591
-
555
-
366
© 2025 Copyright ANSYS, Inc. All rights reserved.