loglog plot command not working,gives linear plot. I need help to make it work
古いコメントを表示
% plot of radius of critical nucleus against temperature
Lf = 10.9375e8;
Gma = 0.176;
Teq = 1235;
nstep = 125;
del_T=1100;
storage = zeros(nstep,2);
for i=1:nstep
r = -(2*Gma*Teq)/(Lf*-del_T);
storage(i,:) = [del_T, r];
del_T = del_T + 1;
end
history = zeros(nstep,2);
q = storage(:,2);
del_T=1100;
for j = 1:nstep
Del_G = (4*pi*((q(j)^2)*Gma) + ((4/3)*pi*(q(j))^3)*((Lf*-del_T)/Teq));
history(j,:) = [del_T, Del_G];
del_T = del_T + 1;
end
figure(1); clf;
loglog((storage(:,1)),(storage(:,2)),'r-', 'linewidth',2)
xlabel('Temperature (K)');
ylabel('Critical Radius (m)');
title('Plot of Critical Radius vs. Temperature Q2a');
string = ' r* = -2*Gma*Teq/Lf*-del_T;';
text (200, 2.2e-10,string)
figure(2); clf;
loglog((history(:,1)),(history(:,2)),'r-', 'linewidth',2)
xlabel('Temperature (K)');
ylabel('Activation Free Energy (J)');
title('Plot of Activation Free Energy vs. Temperature Q2b');
string = ' Del G = 4*pi*((q(j)^2)*Gma + (4/3)*pi*(q(j))^3)*((Lf*-del_T)/Teq)';
text (-1500, 2.7e-10,string);
x = history(:,1);
y = history(:,2);
figure(3 ); clf;
loglog(x, (y*0.15625),'r-', 'linewidth',2)
xlabel('Temperature (K)');
ylabel('Heterogenous Nucleation');
title('Plot of Heterogenous Nucleation vs. Temperature Q2c');
grid on
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で 2-D and 3-D Plots についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!