Matlab ode help please?

phonewho

New member
How do you write an ode into matlab? Not sure what the best way to explain this is but here goes:

For example, the equation: m(d^2x/dt^2) + b(dx/dt) + kx = 0 is written as Xdot = [X(2);-(b/m)*X(2)-(k/m)*X(1)] in Matlab.

How would you write mL(d^2x/dt^2) + b(dx/dt) + mgsin(x) = 0?
 
Back
Top