Opened 10 years ago

Closed 9 years ago

#3001 closed defect (duplicate)

Difficulties in managing arrays of components in OMEDIT

Reported by: ceraolo Owned by: adeas31
Priority: high Milestone: 1.9.3
Component: OMEdit Version: trunk
Keywords: Cc:

Description

I want to use arrays of blocks in a model. Consider for instance the following code:

model a
  Modelica.Blocks.Sources.Constant const[3];
  Modelica.Blocks.Math.Gain gain[3];
equation 
  connect(gain.u, const.y) ;
end a;

It looks like it is impossible to create such code graphically in OMEdit.

I tried dragging & dropping "const" and "gain" from Modelica library, and then making the blocks become arrays changing their names, i.e. "const" into "const[3]" and "gain" into "gain[3]" . But this did not work.

Indeed, changing "const" into "const[3]" directly in the diagram view perspective causes a strange behaviour: the name visualised in the diagram view is "const[3]", while the code still reads "const".

Some modifications to OMEdit to allow better management of arrays of model is needed, I suppose?

Change History (2)

comment:1 Changed 9 years ago by sjoelund.se

  • Milestone changed from 1.9.2 to 1.9.3

Milestone changed to 1.9.3 since 1.9.2 was released.

comment:2 Changed 9 years ago by adeas31

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

Similar to #3196.

Note: See TracTickets for help on using tickets.