问题
I don't know how to solve this second order ODE in SIMULINK:
I rewrote it to the system of first order ODEs:
then
giving
My SIMULINK blocks are here:
giving this Scope:
This is the plot of symbolic solution from dsolve:
It looks like the functions (plots) from symbolic and SIMULINK are little similar.
回答1:
The solution was found by Phil Goddard. His answer in comments:
In Simulink you are plotting y_dot, while the symbolic solution is a plot of y.
So the problem was that Scope was plotting the y'. The correct position of Scope is here:
giving the correct plot of y:
as you can see in the plot of symbolic solution:
来源:https://stackoverflow.com/questions/30143973/solve-second-order-ode-in-matlab-simulink