Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#3223 closed defect (duplicate)

Check error when using ComplexBlocks.Sources.ComplexConstant

Reported by: Christian Kral <dr.christian.kral@…> Owned by: somebody
Priority: high Milestone: never
Component: *unknown* Version: trunk
Keywords: Cc:

Description

I used an instance of ComplexBlocks.Sources.ComplexConstant in an example (see attachment) and changed the constant k to Complex(1,0). When I check the model a couple errors occur:

[/usr/lib/omlibrary/Modelica 3.2.1/ComplexBlocks.mo:2056:11-2056:79:readonly] Error: Variable const.k: Duplicate modification of element  {start  = (typed)1 DAE.PROP(Integer, C_CONST), value: 1}  and  = (typed)1.0 DAE.PROP(Real, C_CONST), value: 1.0 on component re.
[/usr/lib/omlibrary/Modelica 3.2.1/ComplexBlocks.mo:2056:11-2056:79:readonly] Error: Variable const.k: Duplicate modification of element  {start  = (typed)0 DAE.PROP(Integer, C_CONST), value: 0}  and  = (typed)0.0 DAE.PROP(Real, C_CONST), value: 0.0 on component im.
[/usr/lib/omlibrary/Modelica 3.2.1/ComplexBlocks.mo:2056:11-2056:79:readonly] Error: Variable const.k: Duplicate modification of element  {start  = (typed)1 DAE.PROP(Integer, C_CONST), value: 1}  and  = (typed)1.0 DAE.PROP(Real, C_CONST), value: 1.0 on component re.
Error: Duplicate modification of element  {start  = (typed)0 DAE.PROP(Integer, C_CONST), value: 0}  and  = (typed)0.0 DAE.PROP(Real, C_CONST), value: 0.0 on component im.

When I simulate the model, I get the same errors again:

[1] 16:29:29 Translation Error
Duplicate modification of element {start = (typed)0 DAE.PROP(Integer, C_CONST), value: 0} and = (typed)0.0 DAE.PROP(Real, C_CONST), value: 0.0 on component im.

[2] 16:29:29 Translation Error
[/usr/lib/omlibrary/Modelica 3.2.1/ComplexBlocks.mo: 2056:11-2056:79]: Variable const.k: Duplicate modification of element {start = (typed)1 DAE.PROP(Integer, C_CONST), value: 1} and = (typed)1.0 DAE.PROP(Real, C_CONST), value: 1.0 on component re.

[3] 16:29:29 Translation Error
[/usr/lib/omlibrary/Modelica 3.2.1/ComplexBlocks.mo: 2056:11-2056:79]: Variable const.k: Duplicate modification of element {start = (typed)0 DAE.PROP(Integer, C_CONST), value: 0} and = (typed)0.0 DAE.PROP(Real, C_CONST), value: 0.0 on component im.

However, the simulation works OK with no obvious problems.

Attachments (1)

ComplexBlockExample.mo (508 bytes) - added by Christian Kral <dr.christian.kral@…> 9 years ago.

Download all attachments as: .zip

Change History (4)

Changed 9 years ago by Christian Kral <dr.christian.kral@…>

comment:1 Changed 9 years ago by adrpo

This is a known bug (see #3159, #2348) but we haven't got around to fixing it.

comment:2 Changed 9 years ago by Christian Kral <dr.christian.kral@…>

  • Resolution set to duplicate
  • Status changed from new to closed

Thanks Adrian. I close the ticket.

comment:3 Changed 8 years ago by dietmarw

  • Milestone changed from Future to never

Sorting away the closed as invalid, won't fix and duplicate tickets from Future.

Note: See TracTickets for help on using tickets.