I am attempting to solve a double mass-spring-damper system. I already solved for single mass using ode45. However I am unable to figure out how to use this with two variables and also solve a second order differential.
The Equation I used was
The function I used is shown below.
I used this function to in ode45 as shown below
k01 = 1;
k12 = 2;
For a double mass system, I have two equations
The new constants are provided below
k23 = 3;
k34 = 1;
Any help would be greatly appreciated. If you need more information please let me know!