need help on trouble shooting my Simulink controller model

1 回表示 (過去 30 日間)
Randy Chen
Randy Chen 2021 年 10 月 10 日
編集済み: Aniket 2025 年 1 月 30 日
I have created a simulink model for an inverted airfoil mounted on a moving cart (very similar to the inverted cart-pendulum). I created a subsystem from my plant model and then added a PID control loop around it. However, I'm getting this error:
I tried reducing the strep size in Solver under Configuration Parameters, but it did not work. Attached here is my model, could someone please give me some suggestions?
I also attached a PDF file that includes my derivation of equations of motion and the numerical values for each parameter I've used
  2 件のコメント
Salman Ahmed
Salman Ahmed 2021 年 10 月 14 日
Hi,
Could you share the related parameter values loaded in your MATLAB workspace like m, l, g?
Randy Chen
Randy Chen 2021 年 10 月 15 日
yes I have all the constants defined in the PDF

サインインしてコメントする。

回答 (1 件)

Aniket
Aniket 2025 年 1 月 30 日
編集済み: Aniket 2025 年 1 月 30 日
I am assuming the derivations mentioned in attached PDF are correct and have verified that the model is in line with the derivations. When I tried reproducing the issue, I received the same error message. As stated in Diagnostic viewer, the value of "theta_dot" seems to grow exponentially to cross infinity, and hence MATLAB outputs NaN after 18 time steps. I also logged other signals, and found similar issues with "x_dot". Because of this, the "Force_x" also explodes after certain time steps (See below attached screenshots for reference).
At time step: 8
At time step: 9
I suggest debugging your model step-by-step using "Step Forward" simulation and verifying the cause of this exponential increase in signal values. Also check the derivations for any errors.
Additionally, kindly ensure that initial conditions for Unit Delay and Integrator blocks (default: 0) are set appropriately.
I hope this helps resolve the issue!

カテゴリ

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

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by