#################################################### # microstrip_convergence.lsf # # This file is meant to be used with microstrip.lms # It runs a parameter sweep which sweeps the mesh step # size and collects the characteristic impedance of the # microstrip mode, then fits the data and extrapolates the # values at the intercept with dx=0 # # Copyright 2016 Lumerical Solutions Inc ##################################################### # run the parameter sweep runsweep; # get sweep parameters and results dx = getsweepdata("mesh_sweep","dx"); dy = getsweepdata("mesh_sweep","dy"); Z0 = getsweepdata("mesh_sweep","Z0"); # generate a linear fit to the sweep results p_Z0 = polyfit(dx,Z0,1); # calculate intercept result at dx = 0 ?Z0_intercept = p_Z0(1);