Posts

Showing posts with the label involve

Systems of Equations

PROFESSOR: Many mathematical models involve high order derivatives. But the MATLAB ODE solvers only work with systems of first order ordinary differential equations. So we have to rewrite the models to just involve first order derivatives. Let's see how to do that with a very simple model, the harmonic oscillator. x double prime plus x equals 0. This involves a second order derivative. So to write it as a first order system, we introduced the vector y. This is a vector with two components, x, and the derivative of x. We're just changing notation to let y have two components, x and x prime. Then the derivative of y is the vector with x and x double prime. So the differential equation now becomes y2 prime plus y1 equals zero. Do you see how we've just rewritten this differential equation. so y2 prime is playing of x double prime? Once you've done that, everything else is easy. The vector system is now y1, y2 prime is y2 minus y1. The first components says y1...