How to solve some "tricky" differential equations
Show older comments
I'm a Mathematica user who is starting to learn MATLAB. My professor told me that if I want to do something serious, nothing is better than MATLAB. So, I have several DEs problems to solve.
First problem:

In Mathematica, I use this code for the solution of above equation

Second problem:

The Mathematica code

Third problem:

The code

I have consulted to MATLAB documentations how to solve above differential equations but I couldn't find the answer. Any help would be appreciated. Thank you.
Answers (1)
Torsten
on 22 Jun 2015
It should be possible to solve the first problem with MATLAB's "dsolve". Otherwise, rewrite you 3rd order ODE as a system of three first-order ODEs
y1'=y2
y2'=y3
y3'=y1+1
and use ODE45 to solve.
For the second and third problem, use DDE23.
Best wishes
Torsten.
2 Comments
Deco Sukan
on 22 Jun 2015
Edited: Deco Sukan
on 22 Jun 2015
Torsten
on 22 Jun 2015
Using dsolve, you should have no trouble to insert boundary conditions at three different points. Using a numerical solver, try BVP4C and look at the example "threebvp".
For the second and third problem: DDE23 deals with non-identical (constant) delays.
Invest a little time - nothing is for free.
Best wishes
Torsten.
Categories
Find more on Programming in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!