Opened 5 years ago
Closed 5 years ago
#6299 closed defect (duplicate)
Multiple extends does not work in GUI
| Reported by: | Owned by: | Adeel Asghar | |
|---|---|---|---|
| Priority: | high | Milestone: | 1.16.2 |
| Component: | OMEdit | Version: | v1.17.0-dev |
| Keywords: | Cc: |
Description
Consider the following attached example:
package Extending
model Model1
Modelica.Electrical.Analog.Basic.Ground ground annotation(
Placement(visible = true, transformation(origin = {0, -30}, extent = {{-10, -10}, {10, 10}}, rotation = 0)));
Modelica.Electrical.Analog.Sources.ConstantVoltage constantVoltage annotation(
Placement(visible = true, transformation(origin = {0, 0}, extent = {{-10, -10}, {10, 10}}, rotation = -90)));
equation
connect(constantVoltage.n, ground.p) annotation(
Line(points = {{0, -10}, {0, -20}}, color = {0, 0, 255}));
end Model1;
model Model2
extends Extending.Model1(constantVoltage.V = 10);
equation
end Model2;
model Model3
extends Extending.Model2;
equation
end Model3;
annotation(
uses(Modelica(version = "3.2.3")));
end Extending;
Apply the following action in the Diagram view:
- Make a double click on the voltage model of
Model2. Change parameterV. The changed parameter is stored in the model as one can check in the Text view.
- Make a double check on the voltage model of
Model3. Change parameterV. The changed parameter is NOT stored in the model as one can check in the Text view:
model Model3 extends Extending.Model2; equation end Model3;
Attachments (1)
Change History (4)
by , 5 years ago
| Attachment: | Extending.mo added |
|---|
comment:1 by , 5 years ago
Yes, it seems setExtendsModifierValue has some bugs in it. I also discovered this while trying to make an example for #6291.
comment:2 by , 5 years ago
This is a duplicate of #4809.
We should at least figure out if it's a simple bug to fix, as ticket:4809#comment:2 seemed to imply, and then just do it in 1.17.0, or if it is something more involved.
comment:3 by , 5 years ago
| Resolution: | → duplicate |
|---|---|
| Status: | new → closed |
Note:
See TracTickets
for help on using tickets.

Modelica package to demonstrate problem of parameter changes in extended models