【问题标题】:Issues with the "Chattering" example in Chapter 2 of Modelica by exampleModelica by example第2章中“Chattering”示例的问题
【发布时间】:2020-09-10 03:23:27
【问题描述】:

这里是模型的链接:https://mbe.modelica.university/behavior/discrete/decay/#chattering Dymola 2021 中以下结果的模拟结果为:

模型 WithChatter(stopTime=1.001s)

模型 WithChatter(stopTime=1.5s)

正如我们所见,noEvent 运算符确实减少了 CPUTime,但它也会导致系统僵硬,更多解释为什么 noEvent 会导致系统僵硬会更容易理解。

基于模型WithChatter的事件记录,仿真过程实际上使用了最小时间步长,因为der(x)不是一个连续函数。但是为什么这种方法不适合 WithNoEvents 模型呢?(https://mbe.modelica.university/behavior/discrete/decay/#speed-vs-accuracy)

如果 noEvent 运算符意味着直接使用积分器,它可能要求方程系统中的函数必须是连续的?那么这是否意味着 Chattering 示例中使用的模型(https://mbe.modelica.university/behavior/discrete/decay/#chattering)不合适,因为该模型中的函数不连续?

【问题讨论】:

标签: modelica dymola


【解决方案1】:

抖动示例中使用的模型不合适,因为它不连续,并且来自 dassl 的错误消息只是样板消息,因此该模型不像您发现的那样僵硬而是不连续的。

Markus A 在相关问题When to use noEvent operator in Modelica language? 中有一个很好的观点,即使用 noEvent 来避免抖动通常不是一个好主意,通常应该尝试重写模型而不是添加 noEvent。

这个特定的模型有点类似于你可能拥有的摩擦模型

der(v)=(if v>=0 then -1 else 1)+f_other/m;

摩擦的解决方案不是引入noEvent,而是像Modelica.Mechanics.Rotational.Components.BearingFriction一样添加一个卡住模式。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-05-31
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多