Parameters Sometimes Not Editable in Dymola Simulation Tab and FMU

大兔子大兔子 提交于 2019-12-10 22:47:47

问题


Example:

You create a model with 9 parameters you expect to be editable in the Simulation tab and user-settable in the FMU.

However,

  1. Only 5 parameters appear to be editable from the Simulation tab.
  2. Likewise, FMU has only 5 user-settable parameters.

回答1:


Solution:

To generate more efficient code, Dymola sometimes "evaluates" parameters.

annotation(Evaluate=false) tells Dymola a parameter should not be evaluated.

Example:

parameter Real theAnswer = 42.0 "The answer to life,…" annotation(Evaluate=false);

Dymola will now allow theAnswer to be edited in the Simulation tab and be user-settable in the FMU.



来源:https://stackoverflow.com/questions/37571451/parameters-sometimes-not-editable-in-dymola-simulation-tab-and-fmu

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!