Effacer les filtres
Effacer les filtres

Can manually solve system of ODEs but can't with dsolve

1 vue (au cours des 30 derniers jours)
Wesley Neill
Wesley Neill le 10 Fév 2019
Commenté : Walter Roberson le 10 Fév 2019
Good evening,
I'm using MATLAB for the first time and have been trying to apply the dsolve documentation, here.
>> syms y1(t) y2(t)
A = [0 1; -2/(t^2) 2/t];
Y = [y1; y2];
G = [t^4; t^3];
C = Y(2) == [1; 4];
odes = diff(Y) == A*Y + G;
[sol1(t), sol2(t)] = dsolve(odes, C);
I have been able to solve this by hand fairly easily. I just wanted to use it as an opportunity to start learning MATLAB. However, I get the error:
Warning: Unable to find explicit solution.
> In dsolve (line 201)
ans =
[ empty sym ]
I believe I have followed the tutorial in the documentation exactly, only changing it to match a problem in my textbook. Thanks for your help.
  4 commentaires
Wesley Neill
Wesley Neill le 10 Fév 2019
Madhan, yes that is correct.
Walter, how am I to know what this function is reasonably capable of and what it is not?
Walter Roberson
Walter Roberson le 10 Fév 2019
What I mean is that if you did a whole bunch of analysis and manipulation you just might be able to force matlab to find a solution, but it might be difficult or a nuisance to do. It might match a well known pattern but not one built in to dsolve.
The limitations of dsolve and the forms handled are not documented . The implementation is at the MuPAD level so to view the code you would need to go in at that level and use the MuPad expose() call and figure out what the code means . I do not recommend that .

Connectez-vous pour commenter.

Réponses (0)

Tags

Produits


Version

R2018b

Community Treasure Hunt

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

Start Hunting!

Translated by