Symbolically eliminating variables from a set of 1st order ODEs to obtain a single higher order ODE
1 view (last 30 days)
Show older comments
I wonder if it is possible in MATLAB to symbolically eliminate variables from a set of first order ODEs in order to obtain a higher-order ODE for a single variable. So not actually solving for the variable, but just constructing the single equation.
For example, take the simple serial RLC circuit connected to a voltage source. One could write a set of equations like this:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335250/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335253/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335256/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335259/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335262/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335265/image.png)
When eliminating variables from the set of these equations, one could write a single 2nd order differential equation for a selected variable, e.g.:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/335268/image.png)
So is it possible to come to this final equation directly using MATLAB from the set of the equations written above?
Thank you!
1 Comment
David Goodmanson
on 22 Jul 2020
Hi LIpa,
In a set of linear equations (fixed R,L,C, op amp gain, etc.) the answer is yes, although the answers get increasingly complicated. In that case you can replace each nth derivative with (iw)^n or(jw)^n depending on your background, then come up with a large polynomial, then take all the resulting (iw)^n back to derivatives. That is doable, but with, say, the Lagrange equations for several variables in spherical coordinates, reducing the equation to a high order differential equation in one variable quickly leads to a total morass. It's not worth it. Anyway, if you want to solve the equations, the practical method is in the other direction, to convert all the higher order equatiions down to a set of first order differential equations.
Answers (1)
Ahmed Rehan
on 22 Jul 2020
It seems doable using Laplace transform. But the final equation might need to be converted back using symbolic conversions.
0 Comments
See Also
Categories
Find more on Symbolic Math Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!