Info
Cette question est clôturée. Rouvrir pour modifier ou répondre.
Help in solving Differential Equations
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi I have a few differential equations of the following form.. Is there anyone that can enlighten me in solving them in beginners terms? Thanks a lot.
A simplified example is as follow:
y(1)' = y(1) + y(2)'
y(2)' = y(1)' + y(2)' + y(3)'
y(3)' = y(3) + y(2) + 3*y(1)'
Thanks, this is just a simplified version and I don't think I could modify the equations such that all the y' are on one side :(
Thanks again1
0 commentaires
Réponses (1)
Sathish Kumar
le 12 Avr 2013
The set od equations you are trying to solve COUPLED set of ODEs. It is actually very easy to do in matlab using ODE45. You need the initial conditions of all the y's in your equation. I believe you know some linear algebra. Take Y=[y1 y2 y3] as the vector you want to find. Let Y0=[y10 y20 y30] be the IC(you should put the values of y10 y20 y30). Define the range of independant variable for which you need the solution. x=xmin:xmax; call [xout,Yout]=ode45(@yourfxn,x,Y0); xout is the range of independant variable numerically used. First column of Y is y1 and so on; define yourfxn as a function. function Y'=yourfxn(x,Y); define what is your function doing. Y'=AY, where A is the coeffienct matrix.
Hope this helps!!!! Lot of solutions and examples can be found online for this
0 commentaires
Cette question est clôturée.
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!