ODE Simulation

4 ビュー (過去 30 日間)
Scott
Scott 2011 年 2 月 10 日

Hi,

How would you simulate the following equation in simulink:

MA = a + b*V + c*V^2 + d*V^3

Where M, a, b, c and d are constants, A = acceleration and V = velocity. I have attached a screenshot of my attempt:

When i replace the constants with numbers I always get a singularity error that the input to my integral is Inf or Nan. Is there something fundamentally wrong with my attepmt or...

採用された回答

Guy Rouleau
Guy Rouleau 2011 年 2 月 10 日
This looks good at first look. Seth has a nice post on this topic:
http://blogs.mathworks.com/seth/2008/05/23/how-to-draw-odes-in-simulink/
I would guess that your model goes to infinity because you miss a (-) sign. Take the example of a mechanical system, the friction should be in opposite direction of the velocity. If the friction is in the same direction and proportional to the velocity, you will definitely end up accelerating infinitely fast!

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGeneral Applications についてさらに検索

タグ

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by