Can anyone please help me in correcting the code for ns vs thickness AlN

조회 수: 1 (최근 30일)
I want to plot sheet charge density 'ns' vs AlN spacer thickness 'tAlN ' using eq. 9 but I am not getting correct results as I should get the plot which I have attached . Please check my code and modify it so that I can understand my mistakes. As in this eqn 'tAlN ' will vary but here used tAlN for 'detaEceff' and ns both.
clear all;
q=1.6e-19;
E0=8.85e-12;
Ealgan=10.31;
Ealn=10.78;
fib=(5.1*1.6e-19);
sigmaaln=3.38e17;
sigmaalgan=1.3e17;
detaec=(0.862*1.6e-19);
talgan=23e-9;
d0=26e-9;
p=(q^2/Ealn*E0);
taln=0:0.1:2.5;
m=length(taln);
for i=1:m
detaec2(i)=[detaec+(p*sigmaaln*taln(i))];
end
ns(i)=(sigmaaln*taln-(Ealgan*E0*fib/q)+(Ealn*E0*detaec2(i)/q^2))/(talgan+taln+d0);
plot(taln, ns)

채택된 답변

Abderrahim. B
Abderrahim. B 2022년 7월 25일
Hi!
Please learn how to use for loops ...
doc for
The code below plots a graph similar to the one you attached, bmaybe still need some to be reviewed.
clear;
q=1.6e-19;
E0=8.85e-12;
Ealgan=10.31;
Ealn=10.78;
fib=(5.1*1.6e-19);
sigmaaln=3.38e17;
sigmaalgan=1.3e17;
detaec=(0.862*1.6e-19);
talgan=23e-9;
d0=26e-9;
p=((q^2)/Ealn)*E0;
taln=10:10:100;
m=length(taln);
for i=1:m
detaec2 = detaec + (p*sigmaaln*taln(i));
ns(i) = ((sigmaaln*taln(i) - (Ealgan*E0)*(fib/q) + ((Ealn*E0*detaec2)/(q^2)) ))/(talgan +taln(i) +d0);
end
plot(taln, ns, 'k-o')
  댓글 수: 4
Nudrat Sufiyan
Nudrat Sufiyan 2022년 7월 25일
Thankyou sir. This is really helpful for me.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Scripts에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by