Syntax error in Simulink Fcn

6 ビュー (過去 30 日間)
Moritz Schmetzer
Moritz Schmetzer 2019 年 8 月 5 日
回答済み: Kaashyap Pappu 2019 年 8 月 8 日
Hello all,
unfortunately I am getting a syntax error in Simulink in two Fcn blocks:
1) c1*(1-exp(-c2*u))-c3*u
2) cw*A*rho/2*u^2
I really can't find the problem in this so a little help is appreciated.
Many thanks in advace!
  1 件のコメント
Walter Roberson
Walter Roberson 2019 年 8 月 5 日
Please show the complete error message.

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

回答 (1 件)

Kaashyap Pappu
Kaashyap Pappu 2019 年 8 月 8 日
Make sure the variables “c1”, “c2”, “u”, “c3”, “cw”, “A” and “rho” are defined in the MATLAB workspace or in one of the callbacks of the Simulink Model. The syntax for both equations is correct.
Furthermore, the denominator of equation 2 has a squaring operation, therefore care should be taken if “u” is a vector.

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by