-
Notifications
You must be signed in to change notification settings - Fork 44
Closed
Labels
clarificationSpecification of feature is unclear, but not incorrectSpecification of feature is unclear, but not incorrectworksforme
Milestone
Description
Section 3.7.5, operator 3.24 states
The first value of pre(y) is determined in the initialization phase.
Section 8.6 then states that it is possible to add the equation pre(vc) = startExpression to the initialization problem by setting vc(start = startExpression, fixed = true)
What is not 100% clear to me is whether it is really necessary to do so in case vc is completely determined as a function of time. Consider this MWE:
model TestInitDiscrete
Boolean b;
Boolean b1(start = true);
Boolean bs(start = false, fixed = true);
equation
b = if time < 0.5 then false else true;
b1 = b;
when pre(b1) and pre(bs)==false then
bs = true;
end when;
end TestInitDiscrete;Both Dymola and OpenModelica automatically add fixed = true to b1, which makes pre(b1) = true at initialization. This seems a bit odd to me, given that b1 is always false for time < 0.5.
Is this the intended behaviour? If so, maybe we should clarify it more explicitly, perhaps in a non-normative section of the text.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
clarificationSpecification of feature is unclear, but not incorrectSpecification of feature is unclear, but not incorrectworksforme