Problem in ezplot with simple equation

13 Ansichten (letzte 30 Tage)
Camilo Sánchez
Camilo Sánchez am 23 Apr. 2018
Kommentiert: Star Strider am 23 Apr. 2018
s=dsolve ('Dy=(t+y)^(1/2)','y(0.4)=0.41')
ezplot(s,[0.4,10])
Whats wrong???

Akzeptierte Antwort

Star Strider
Star Strider am 23 Apr. 2018
Not all differential equations have analytical solutions. Fortunately, ode45 will integrate this without problems:
DE = @(t,y) (t+y)^(1/2);
[T,Y]= ode45(DE, [0.4 10], 0.41);
figure(1)
plot(T,Y)
grid
  2 Kommentare
Camilo Sánchez
Camilo Sánchez am 23 Apr. 2018
Thanks
Star Strider
Star Strider am 23 Apr. 2018
As always, my pleasure.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Numerical Integration and Differential Equations finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by