Opened 10 years ago

Closed 10 years ago

Last modified 7 years ago

#3014 closed defect (fixed)

known vars break initialization

Reported by: Lennart Ochel Owned by: Lennart Ochel
Priority: high Milestone: 1.9.4
Component: Backend Version: trunk
Keywords: Cc: Willi Braun

Description

The initialization depends on known variables, but they are calculated after the actual initialization. Hence, the initialization is wrong for certain cases.

The following example can be used as test case:

model foo
  Real a "= -1";
  Real b "= -2";
  Real x(start=1) "= -2";
initial equation
  a = x+1;
  x = 2*a;
  b = 2*a;
equation
  der(x) = 1;
  der(a) = sin(time);
  der(b) = cos(time);
end foo;

Change History (5)

comment:1 by Lennart Ochel, 10 years ago

Status: newaccepted

I have already a patch for this issue. I just need a stable internet connection to push it in (DB has no free wifi yet).

comment:2 by Willi Braun, 10 years ago

Cc: Willi Braun added

comment:3 by Lennart Ochel, 10 years ago

Resolution: fixed
Status: acceptedclosed

fixed in r23666

comment:4 by Dietmar Winkler, 9 years ago

Milestone: Futurepre1.9.4

It doesn't make sense to keep closed ticket in the "Future" milestone that were simply forgotten to assign to the correct milestone in the past.

comment:5 by Martin Sjölund, 7 years ago

Milestone: pre1.9.41.9.4

Removing the pre1.9.4 milestone in favor of 1.9.4.

Note: See TracTickets for help on using tickets.