Code:-
go atlas
mesh auto
#==================================================================
x.mesh loc=0 s=1
x.mesh loc=400 s=1
#==================================================================
y.mesh loc=0 s=.1
y.mesh loc=0.5 s=.1
y.mesh loc=1.5 s=.1
y.mesh loc=2.0 s=.1
y.mesh loc=2.3 s=.1
#==================================================================
region num=1 material=Si x.min=0 x.max=400 y.min=0 y.max=0.5 acceptor=5e18
region num=2 material=Si x.min=0 x.max=400 y.min=.5 y.max=1.5
region num=3 material=Si x.min=0 x.max=400 y.min=1.50 y.max=2.0 donor=5e18
region num=4 material=Si x.min=0 x.max=400 y.min=2.0 y.max=2.3 donor=5e18
#==================================================================
electrode name=anode top
electrode name=cathode bottom
#==================================================================
material material=Si EG300=1.1 PERMITTIVITY=11.8 AFFINITY=4.07 MUN=1000 MUP=500 NC300=2.8e19 taun0=1e-6 taup0=1e-6 NV300=1.04e19 sopra=Si111.nk
#==========================================================================================================
doping n.type uniform region=4 resisti=0.05
#==================================================================
save outf=usPIN.str
tonyplot usPIN.str
beam num=1 x.o=100 y.o=-2 angle=90 power.file=C:/sedatools/examples/solar/solarex01.spec
output opt.int
#==================================================================
models conmob fermi optr consrh print
method newton autonr trap maxtrap=10
#==================================================================
contact name=anode
contact name=cathode
#==================================================================
#
solve init
solve prev
solve b1=1e-02
solve b1=1e-01
solve b1=1
#==================================================================
log outf=IsPIN.log
solve vanode=0 name=anode vstep=0.3 vfinal=0.6
tonyplot IsPIN.log
#==================================================================
extract init inf="IsPIN.log"
extract name="Jsc" max(curve(v."anode", i."cathode"))
extract name="JscmAcm2" $Jsc*1e08*1e03
extract name="Voc" x.val from curve(v."anode",i."cathode") where y.val=0.0
extract name="Pm" max(curve(v."anode",(v."anode" *i."cathode")))
extract name="Vm" x.val from curve(v."anode",(v."anode"*i."cathode") ) where y.val=$"Pm"
extract name="Im" $"Pm"/$"Vm"
extract name="FF" ($"Pm"/($"Jsc"*$"Voc"))*100
extract name="Eff" (1e8*$Pm/$Opt_int)*100
extract name="Power" curve(v."anode", (v."anode" * i."anode" *(-1))) outf="Power_a.dat"
tonyplot Power_a.dat
solve init
solve prev
solve prev b1=0
log outf=solar_0.log
solve b1=1 beam=1 lambda=0.2 wstep=0.02 wfinal=2.0
extract init inf="solar_0.log"
extract name="EQE1" curve(elect."optical wavelength", -(i."anode")/elect."source photo current") outf="EQE1.dat"
tonyplot EQE1.dat
quit
Result:-