Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

Management of arrays of components in OMEdit - an issue?

Management of arrays of components in OMEdit - an issue?

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

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". This is not good.

Maybe some modifications to OMEdit to allow better management of arrays of model is needed?

Edited by: ceraolo - Nov-25-14 10:28:10

Re: Management of arrays of components in OMEdit - an issue?

This should be trac ticket instead of forum post.

Adeel.

Re: Management of arrays of components in OMEdit - an issue?

Sure.
I just wanted first to be sure that it was a real issue and not a fault of mine.
I will post the ticket today.

MC

There are 0 guests and 0 other users also viewing this topic
You are here: