Hi, I am trying to store the store the output of the inetgral of fun2 in a matrix ni. From my code, I just get the same repeating values in the matrix. Any help is appreciated.
for T1 = 173:1:1273 %loop for different temperatures
fun2 = @(E) (1.0/(2*pi^2*h^3)*(2*m)^(3/2)*sqrt(E-Ec)).*(1.0 ./(1+exp((E-Ef)/(k*T1))));n2 = integral(fun, Ec, Ec+(.3/(6.242*10^18))); ni(T1-172,:) = [T1,n2]; %store in matrix "ni"
end
Best Answer