Error using ezplot command
10 次查看(过去 30 天)
显示 更早的评论
Adriana Castillo Castillo
2020-2-17
评论: Adriana Castillo Castillo
2020-2-22
Hi.
I´m trying to make a graph using the command "ezplot". But I get this error message: "Index exceeds the number of array elements (1)" and "error in ezplot>ezimplicit". Would you please help me to figure out what´s wrong?
This is my code:
clear all
syms x x(t) T x_0 xT
T=2;
x_0=0;
F(t)=int(x(t)-(diff(x(t))^2),t,0,T)
D=functionalDerivative(F,x)
x_sol1= dsolve(D,x(0)==x_0, x(T)==xT)
x_sol1(t)=subs(x_sol1);
figure(1);
ezplot(x_sol1(t),0,T);
0 个评论
采纳的回答
Srivardhan Gadila
2020-2-20
The correct usage ot the function is as follows:
ezplot(x_sol1(t),[0,T]);
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Numbers and Precision 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!