How do I write a custom trim function that updates Simulink.parameters rather than inputs?

Hi, I'm trying to write a custom trim function which updates a set of Simulink.parameters such that a certain combination of the system derivatives are zero. I was trying to do this using the model([][][],'outputs') and model([],[],[],'derivs') commands, but I can't get the parameters to actually update without terminating the simulation and re-'compiling'. The parameters I'm updating are being used in "constant" blocks in my model.
Is there a good way to force Simulink to update parameters mid-simulation without re-compiling?

回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeModeling についてさらに検索

製品

タグ

質問済み:

2018 年 3 月 3 日

Community Treasure Hunt

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

Start Hunting!

Translated by