Plot an going down exponential curve by using values only
Ältere Kommentare anzeigen
Why I can't plot a graph using the coding below. I wanna plot a Vout againt i, for getting the trendline.
clear
clc
Vin=10;
Vs=5;
Vd=0.7;
R1=2200;
R2=3300;
R3=linspace(0,1e5);
x=R2/R1;
for m=1:100
i=R3(1,m)/R1;
Vout=(x*Vin+x*i*Vs+i*(1+x)*Vd)/(x+i+x*i)
end
figure;
plot(i,Vout)
Antworten (1)
clear
clc
Vin=10;
Vs=5;
Vd=0.7;
R1=2200;
R2=3300;
R3=linspace(0,1e5);
x=R2/R1;
for m=1:100
I(m)=R3(1,m)/R1;
Vout(m)=(x*Vin+x*I(m)*Vs+I(m)*(1+x)*Vd)/(x+I(m)+x*I(m));
end
figure;
plot(I,Vout)
Kategorien
Mehr zu Mathematics finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
