TAGGED: plasmonics
-
-
September 21, 2022 at 2:35 pmAMaitySubscriber
Hello,
I was wondering if someone can lead me to get all these spectra wrt wavelengths. https://optics.ansys.com/hc/en-us/articles/360042160993Â
######################################################
## Script: plasmon_mode_excitation_scattering_linear.lsf
## this script will plot the results from the parameter
## sweep.
##
## Variables:
## run_sim: 0, do not run any simulation (load results from file)
## 1, run simulations (parameter sweep)
##
## Copyright 2019 Lumerical Inc.
#######################################################
clear;
sweep_name = "sweep_polarization";
Â
run_sim = 1; # 0, do not run any simulation
# 1, run sweep
Â
if (run_sim) {
runsweep(sweep_name);
}
Â
scat = getsweepresult(sweep_name, "scat");
total = getsweepresult(sweep_name, "total");
Â
energy = scat.energy;
scat = scat.sigma;
total = -total.sigma;
ext = scat + total;
Â
#######################################################
# Linear x
plot(energy, pinch(scat, 2, 1), pinch(total, 2, 1), pinch(ext, 2, 1),
"energy (eV)", "cross section (m^2)", "Linear x polarization");
setplot("x min", 2);
setplot("x max", 3.2);
legend("Scattering", "Absorption", "Extinction");
Â
#######################################################
# Linear y
plot(energy, pinch(scat, 2, 2), pinch(total, 2, 2), pinch(ext, 2, 2),
"energy (eV)", "cross section (m^2)", "Linear y polarization");
setplot("x min", 2);
setplot("x max", 3.2);
legend("Scattering", "Absorption", "Extinction");
-
September 21, 2022 at 5:27 pmGuilin SunAnsys Employee
You want to know how to convert wavelength to energy? it is inside the analysis group:
sigma.addparameter("lambda",c/f,"f",f, "energy", h*f/e);
where e and h are reserved constants in Lumerical:
e is the charge;
h is the Plank constant.
Â
energy=f*h/e=(c/lambda)*h/e
Â
-
September 21, 2022 at 6:35 pmAMaitySubscriber
Hi Guilin,
Thanks for your prompt reply. So far I got the impression that if I make the following changes, it will work:plot(lambda, pinch(scat, 2, 1), pinch(total, 2, 1), pinch(ext, 2, 1),
"lambda(nm)", "cross section (m^2)", "Linear x polarization");
setplot("x min", 500);
setplot("x max", 650);
legend("Scattering", "Absorption", "Extinction");
Let me know what you think.
Regards
Achyut
-
September 22, 2022 at 3:47 pmGuilin SunAnsys Employee
It is roughly ok. What the unit you use for the wavelength? it seems in nanometer, which is ok.
setplot("x min", 500);
setplot("x max", 650);
Â
This indicates they are in nanometers.
-
September 22, 2022 at 4:09 pmAMaitySubscriber
The following errors are coming up:
Error: C:/Users/3055376/Downloads/Plasmon mode excitation/plasmon_mode_excitation_linear.lsf line 32: lambda is not a valid function or variable name
Error: C:/Users/3055376/Downloads/Plasmon mode excitation/plasmon_mode_excitation_linear.lsf line 32: could not create a figure windowÂ
It does not seem to be working
-
September 22, 2022 at 5:32 pmGuilin SunAnsys Employee
Please modify the analysis script in the group, as the origingal dataset does not have "lambda". Instead, it uses "energy". Please modify it.General description about dataset can be found here: https://optics.ansys.com/hc/en-us/articles/360034409554-Introduction-to-Lumerical-datasets
-
- The topic ‘How to convert energy in terms of wavelength’ is closed to new replies.
- INTERCONNECT – No results unless rerun simulation until it gives any
- Errors Running Ring Modulator Example on Cluster
- Difference between answers in version 2024 and 2017 lumerical mode solution
- Import material .txt file with script
- Calculation of correlation values in laser modulation bandwidth simulation
- Trapezoidal ring
- Help for qINTERCONNECT
- Issues with getting result from interconnent analysis script
- Topology Optimization Error
- Edge Coupler EME Example Issue
-
1131
-
468
-
466
-
225
-
201
© 2024 Copyright ANSYS, Inc. All rights reserved.