Azzera filtri
Azzera filtri

Error using ==> plot Error in color/linetype argument

2 visualizzazioni (ultimi 30 giorni)

s=1.34*10^-5;
mo=1.34*10^-5;
z=16.87*10^-4;
x=2.51*10^7;
k=103;
r=linspace(0,2,50);
F=vectorize(@(r)((s/r^2)*mo*exp(z)*(exp(-x*r^2))*(4*k*r*cosh(4*k*r)-sinh(4*k*r))));
plot(r,F)
??? Error using ==> plot
Error in color/linetype argument

Risposte (1)

KALYAN ACHARJYA
KALYAN ACHARJYA il 8 Giu 2023
s=1.34*10^-5;
mo=1.34*10^-5;
z=16.87*10^-4;
x=2.51*10^7;
k=103;
r=linspace(0,2,50);
F=(s./r.^2)*mo*exp(z).*(exp(-x*r.^2)).*(exp(-x*r.^2)).*(4*k*r.*(cosh(4*k*r))-sinh(4*k*r));
plot(r,F)
Above code most values are zero, please check the typical values of the parameters again or expression?
Are you looking for fplot (function plot) with function handle, see detail
HTH

Categorie

Scopri di più su 2-D and 3-D Plots in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by