Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#4624 closed defect (duplicate)

Huge error message when moving an object

Reported by: massimo ceraolo Owned by: Adeel Asghar
Priority: blocker Milestone: 1.13.0
Component: OMEdit Version:
Keywords: Cc: Martin Sjölund

Description (last modified by massimo ceraolo)

Very often in OMEdit, just moving an object, causes a huge red message to be displayed.
An example is in the "TestMove.mo" attached. Steps to reproduce:

  • load OMEdit
  • load TestMove.mo
  • open RL_P
  • click on pMeas to select it
  • click on the down arrow key to move the object. The following message appears, in red chararters:
[2] 00:21:27 Translation Error
[C:/dev/OpenModelica64bit/OMCompiler/Compiler/Script/CevalScriptBackend.mo: 1179:13-1179:204]: Internal error After merging the strings, the semantics changed for some reason (will simply return s2):
s1:
encapsulated package TestMove 
  import Modelica; 
  import RLCPkg; 
 
  model RL_P 
    Modelica.Electrical.Analog.Basic.Resistor resistor1(R = 1) annotation( 
      Placement(visible = true, transformation(origin = {64, 18}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
    Modelica.Electrical.Analog.Basic.Inductor inductor(L = 10e-3) annotation( 
      Placement(visible = true, transformation(origin = {64, -12}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
    Modelica.Electrical.Analog.Sensors.PowerSensor pMeas annotation( 
      Placement(visible = true, transformation(extent = {{-14, 20}, {6, 40}}, rotation = 0))); 
    Modelica.Electrical.Analog.Basic.Ground ground annotation( 
      Placement(visible = true, transformation(extent = {{-10, -66}, {10, -46}}, rotation = 0))); 
    Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation( 
      Placement(visible = true, transformation(origin = {-60, 4}, extent = {{-10, 10}, {10, -10}}, rotation = 270))); 
  equation 
    connect(pMeas.pv, pMeas.pc) annotation( 
      Line(points = {{-4, 38}, {-14, 38}, {-14, 28}}, color = {0, 0, 255})); 
    connect(sineVoltage.p, pMeas.pc) annotation( 
      Line(points = {{-60, 14}, {-60, 28}, {-14, 28}}, color = {0, 0, 255})); 
    connect(pMeas.nv, inductor.n) annotation( 
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
    connect(pMeas.nc, resistor1.p) annotation( 
      Line(points = {{6, 28}, {6, 28}, {64, 28}}, color = {0, 0, 255})); 
    connect(resistor1.n, inductor.p) annotation( 
      Line(points = {{64, 8}, {64, -2}}, color = {0, 0, 255})); 
    connect(sineVoltage.n, inductor.n) annotation( 
      Line(points = {{-60, -6}, {-60, -6}, {-60, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
    connect(ground.p, inductor.n) annotation( 
      Line(points = {{0, -46}, {0, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
    annotation( 
      experiment(StopTime = 0.1), 
      experimentSetupOutput, 
      Documentation(info = "<html> 
 <p>Misura di potenza attiva e reattiva istantanea su carico RLC</p> 
 </html>"), 
      Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)), 
      Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1))); 
  end RL_P; 
 
  package ConDiodo 
    model RLD 
      Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation( 
        Placement(visible = true, transformation(origin = {-30, 4}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
      Modelica.Electrical.Analog.Basic.Inductor inductor(L = 1e-3, i(fixed = true)) annotation( 
        Placement(visible = true, transformation(origin = {30, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
      Modelica.Electrical.Analog.Basic.Ground ground annotation( 
        Placement(visible = true, transformation(extent = {{-60, -40}, {-40, -20}}, rotation = 0))); 
      Modelica.Electrical.Analog.Basic.Resistor Rload(R = 1) annotation( 
        Placement(visible = true, transformation(origin = {30, -20}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
      Modelica.Electrical.Analog.Ideal.IdealDiode idealDiode annotation( 
        Placement(visible = true, transformation(extent = {{-10, 24}, {10, 44}}, rotation = 0))); 
      Modelica.Electrical.Analog.Basic.Resistor Rload1(R = 1e5) annotation( 
        Placement(visible = true, transformation(origin = {58, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
    equation 
      connect(Rload1.n, inductor.n) annotation( 
        Line(points = {{58, 2}, {30, 2}}, color = {0, 0, 255})); 
      connect(Rload1.p, inductor.p) annotation( 
        Line(points = {{58, 22}, {30, 22}}, color = {0, 0, 255})); 
      connect(idealDiode.p, sineVoltage.p) annotation( 
        Line(points = {{-10, 34}, {-20, 34}, {-30, 34}, {-30, 23}, {-30, 14}}, color = {0, 0, 255})); 
      connect(idealDiode.n, inductor.p) annotation( 
        Line(points = {{10, 34}, {20, 34}, {30, 34}, {30, 27}, {30, 22}}, color = {0, 0, 255})); 
      connect(Rload.n, sineVoltage.n) annotation( 
        Line(points = {{30, -30}, {30, -35}, {30, -35}, {30, -38}, {-30, -38}, {-30, -23}, {-30, -23}, {-30, -6}}, color = {0, 0, 255})); 
      connect(Rload.p, inductor.n) annotation( 
        Line(points = {{30, -10}, {30, -6}, {30, -2}, {30, 2}}, color = {0, 0, 255})); 
      connect(ground.p, sineVoltage.n) annotation( 
        Line(points = {{-50, -20}, {-50, -6}, {-30, -6}}, color = {0, 0, 255})); 
      annotation( 
        experiment(StopTime = 0.06), 
        __Dymola_experimentSetupOutput, 
        Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})), 
        Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2}))); 
    end RLD; 
  end ConDiodo; 
  annotation( 
    uses(Modelica(version = "3.2.2"))); 
end TestMove;
s2:
encapsulated package TestMove
  import Modelica;
  import RLCPkg;   model RL_P
    Modelica.Electrical.Analog.Basic.Resistor resistor1(R = 1) annotation(
      Placement(visible = true, transformation(origin = {64, 18}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    Modelica.Electrical.Analog.Basic.Inductor inductor(L = 10e-3) annotation(
      Placement(visible = true, transformation(origin = {64, -12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    Modelica.Electrical.Analog.Sensors.PowerSensor pMeas annotation(
      Placement(visible = true, transformation(extent = {{-14, 18}, {6, 38}}, rotation = 0)));
    Modelica.Electrical.Analog.Basic.Ground ground annotation(
      Placement(visible = true, transformation(extent = {{-10, -66}, {10, -46}}, rotation = 0)));
    Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation(
      Placement(visible = true, transformation(origin = {-60, 4}, extent = {{-10, 10}, {10, -10}}, rotation = 270)));
  equation
    connect(pMeas.nc, resistor1.p) annotation(
      Line(points = {{6, 28}, {6, 28}, {64, 28}}, color = {0, 0, 255}));
    connect(pMeas.nv, inductor.n) annotation(
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(sineVoltage.p, pMeas.pc) annotation(
      Line(points = {{-60, 14}, {-60, 28}, {-14, 28}}, color = {0, 0, 255}));
    connect(pMeas.pv, pMeas.pc) annotation(
      Line(points = {{-4, 38}, {-14, 38}, {-14, 28}}, color = {0, 0, 255}));
    connect(resistor1.n, inductor.p) annotation(
      Line(points = {{64, 8}, {64, -2}}, color = {0, 0, 255}));
    connect(sineVoltage.n, inductor.n) annotation(
      Line(points = {{-60, -6}, {-60, -6}, {-60, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(ground.p, inductor.n) annotation(
      Line(points = {{0, -46}, {0, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    annotation(
      experiment(StopTime = 0.1),
      experimentSetupOutput,
      Documentation(info = "<html> 
 <p>Misura di potenza attiva e reattiva istantanea su carico RLC</p> 
 </html>"),
      Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)),
      Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)));
  end RL_P;   package ConDiodo
    model RLD
      Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation(
        Placement(visible = true, transformation(origin = {-30, 4}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Basic.Inductor inductor(L = 1e-3, i(fixed = true)) annotation(
        Placement(visible = true, transformation(origin = {30, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Basic.Ground ground annotation(
        Placement(visible = true, transformation(extent = {{-60, -40}, {-40, -20}}, rotation = 0)));
      Modelica.Electrical.Analog.Basic.Resistor Rload(R = 1) annotation(
        Placement(visible = true, transformation(origin = {30, -20}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Ideal.IdealDiode idealDiode annotation(
        Placement(visible = true, transformation(extent = {{-10, 24}, {10, 44}}, rotation = 0)));
      Modelica.Electrical.Analog.Basic.Resistor Rload1(R = 1e5) annotation(
        Placement(visible = true, transformation(origin = {58, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    equation
      connect(Rload1.n, inductor.n) annotation(
        Line(points = {{58, 2}, {30, 2}}, color = {0, 0, 255}));
      connect(Rload1.p, inductor.p) annotation(
        Line(points = {{58, 22}, {30, 22}}, color = {0, 0, 255}));
      connect(idealDiode.p, sineVoltage.p) annotation(
        Line(points = {{-10, 34}, {-20, 34}, {-30, 34}, {-30, 23}, {-30, 14}}, color = {0, 0, 255}));
      connect(idealDiode.n, inductor.p) annotation(
        Line(points = {{10, 34}, {20, 34}, {30, 34}, {30, 27}, {30, 22}}, color = {0, 0, 255}));
      connect(Rload.n, sineVoltage.n) annotation(
        Line(points = {{30, -30}, {30, -35}, {30, -35}, {30, -38}, {-30, -38}, {-30, -23}, {-30, -23}, {-30, -6}}, color = {0, 0, 255}));
      connect(Rload.p, inductor.n) annotation(
        Line(points = {{30, -10}, {30, -6}, {30, -2}, {30, 2}}, color = {0, 0, 255}));
      connect(ground.p, sineVoltage.n) annotation(
        Line(points = {{-50, -20}, {-50, -6}, {-30, -6}}, color = {0, 0, 255}));
      annotation(
        experiment(StopTime = 0.06),
        __Dymola_experimentSetupOutput,
        Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})),
        Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})));
    end RLD;
  end ConDiodo;
  annotation(
    uses(Modelica(version = "3.2.2")));
end TestMove;
s3:
encapsulated package TestMove
  import Modelica;
  import RLCPkg;   model RL_P
    Modelica.Electrical.Analog.Basic.Resistor resistor1(R = 1) annotation(
      Placement(visible = true, transformation(origin = {64, 18}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    Modelica.Electrical.Analog.Basic.Inductor inductor(L = 10e-3) annotation(
      Placement(visible = true, transformation(origin = {64, -12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    Modelica.Electrical.Analog.Sensors.PowerSensor pMeas annotation(
      Placement(visible = true, transformation(extent = {{-14, 18}, {6, 38}}, rotation = 0)));
    Modelica.Electrical.Analog.Basic.Ground ground annotation(
      Placement(visible = true, transformation(extent = {{-10, -66}, {10, -46}}, rotation = 0)));
    Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation(
      Placement(visible = true, transformation(origin = {-60, 4}, extent = {{-10, 10}, {10, -10}}, rotation = 270)));
  equation
    connect(pMeas.nc, resistor1.p) annotation(
      Line(points = {{6, 28}, {6, 28}, {64, 28}}, color = {0, 0, 255}));
    connect(pMeas.nv, inductor.n) annotation(
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(sineVoltage.p, pMeas.pc) annotation(
      Line(points = {{-60, 14}, {-60, 28}, {-14, 28}}, color = {0, 0, 255}));
    connect(pMeas.pv, pMeas.pc) annotation(
      Line(points = {{-4, 38}, {-14, 38}, {-14, 28}}, color = {0, 0, 255}));
    connect(resistor1.n, inductor.p) annotation(
      Line(points = {{64, 8}, {64, -2}}, color = {0, 0, 255}));
    connect(sineVoltage.n, inductor.n) annotation(
      Line(points = {{-60, -6}, {-60, -6}, {-60, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(ground.p, inductor.n) annotation(
      Line(points = {{0, -46}, {0, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    annotation(
      experiment(StopTime = 0.1),
      experimentSetupOutput,
      Documentation(info = "<html> 
 <p>Misura di potenza attiva e reattiva istantanea su carico RLC</p> 
 </html>"),
      Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)),
      Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)));
  end RL_P;   package ConDiodo
    model RLD
      Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation(
        Placement(visible = true, transformation(origin = {-30, 4}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Basic.Inductor inductor(L = 1e-3, i(fixed = true)) annotation(
        Placement(visible = true, transformation(origin = {30, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Basic.Ground ground annotation(
        Placement(visible = true, transformation(extent = {{-60, -40}, {-40, -20}}, rotation = 0)));
      Modelica.Electrical.Analog.Basic.Resistor Rload(R = 1) annotation(
        Placement(visible = true, transformation(origin = {30, -20}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Ideal.IdealDiode idealDiode annotation(
        Placement(visible = true, transformation(extent = {{-10, 24}, {10, 44}}, rotation = 0)));
      Modelica.Electrical.Analog.Basic.Resistor Rload1(R = 1e5) annotation(
        Placement(visible = true, transformation(origin = {58, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    equation
      connect(Rload1.n, inductor.n) annotation(
        Line(points = {{58, 2}, {30, 2}}, color = {0, 0, 255}));
      connect(Rload1.p, inductor.p) annotation(
        Line(points = {{58, 22}, {30, 22}}, color = {0, 0, 255}));
      connect(idealDiode.p, sineVoltage.p) annotation(
        Line(points = {{-10, 34}, {-20, 34}, {-30, 34}, {-30, 23}, {-30, 14}}, color = {0, 0, 255}));
      connect(idealDiode.n, inductor.p) annotation(
        Line(points = {{10, 34}, {20, 34}, {30, 34}, {30, 27}, {30, 22}}, color = {0, 0, 255}));
      connect(Rload.n, sineVoltage.n) annotation(
        Line(points = {{30, -30}, {30, -35}, {30, -35}, {30, -38}, {-30, -38}, {-30, -23}, {-30, -23}, {-30, -6}}, color = {0, 0, 255}));
      connect(Rload.p, inductor.n) annotation(
        Line(points = {{30, -10}, {30, -6}, {30, -2}, {30, 2}}, color = {0, 0, 255}));
      connect(ground.p, sineVoltage.n) annotation(
        Line(points = {{-50, -20}, {-50, -6}, {-30, -6}}, color = {0, 0, 255}));
      annotation(
        experiment(StopTime = 0.06),
        __Dymola_experimentSetupOutput,
        Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})),
        Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})));
    end RLD;
  end ConDiodo;
  annotation(
    uses(Modelica(version = "3.2.2")));
end TestMove;
s4:
encapsulated package TestMove
  import Modelica;
  import RLCPkg;   model RL_P
    Modelica.Electrical.Analog.Basic.Resistor resistor1(R = 1) annotation(
      Placement(visible = true, transformation(origin = {64, 18}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    Modelica.Electrical.Analog.Basic.Inductor inductor(L = 10e-3) annotation(
      Placement(visible = true, transformation(origin = {64, -12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    Modelica.Electrical.Analog.Sensors.PowerSensor pMeas annotation(
      Placement(visible = true, transformation(extent = {{-14, 18}, {6, 38}}, rotation = 0)));
    Modelica.Electrical.Analog.Basic.Ground ground annotation(
      Placement(visible = true, transformation(extent = {{-10, -66}, {10, -46}}, rotation = 0)));
    Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation(
      Placement(visible = true, transformation(origin = {-60, 4}, extent = {{-10, 10}, {10, -10}}, rotation = 270)));
  equation
    connect(pMeas.nc, resistor1.p) annotation(
      Line(points = {{6, 28}, {6, 28}, {64, 28}}, color = {0, 0, 255}));
    connect(pMeas.nv, inductor.n) annotation(
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(pMeas.nv, inductor.n) annotation(
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(pMeas.nv, inductor.n) annotation(
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(resistor1.n, inductor.p) annotation(
      Line(points = {{64, 8}, {64, -2}}, color = {0, 0, 255}));
    connect(sineVoltage.n, inductor.n) annotation(
      Line(points = {{-60, -6}, {-60, -6}, {-60, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    connect(ground.p, inductor.n) annotation(
      Line(points = {{0, -46}, {0, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255}));
    annotation(
      experiment(StopTime = 0.1),
      experimentSetupOutput,
      Documentation(info = "<html> 
 <p>Misura di potenza attiva e reattiva istantanea su carico RLC</p> 
 </html>"),
      Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)),
      Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)));
  end RL_P;   package ConDiodo
    model RLD
      Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation(
        Placement(visible = true, transformation(origin = {-30, 4}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Basic.Inductor inductor(L = 1e-3, i(fixed = true)) annotation(
        Placement(visible = true, transformation(origin = {30, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Basic.Ground ground annotation(
        Placement(visible = true, transformation(extent = {{-60, -40}, {-40, -20}}, rotation = 0)));
      Modelica.Electrical.Analog.Basic.Resistor Rload(R = 1) annotation(
        Placement(visible = true, transformation(origin = {30, -20}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
      Modelica.Electrical.Analog.Ideal.IdealDiode idealDiode annotation(
        Placement(visible = true, transformation(extent = {{-10, 24}, {10, 44}}, rotation = 0)));
      Modelica.Electrical.Analog.Basic.Resistor Rload1(R = 1e5) annotation(
        Placement(visible = true, transformation(origin = {58, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270)));
    equation
      connect(Rload1.n, inductor.n) annotation(
        Line(points = {{58, 2}, {30, 2}}, color = {0, 0, 255}));
      connect(Rload1.p, inductor.p) annotation(
        Line(points = {{58, 22}, {30, 22}}, color = {0, 0, 255}));
      connect(idealDiode.p, sineVoltage.p) annotation(
        Line(points = {{-10, 34}, {-20, 34}, {-30, 34}, {-30, 23}, {-30, 14}}, color = {0, 0, 255}));
      connect(idealDiode.n, inductor.p) annotation(
        Line(points = {{10, 34}, {20, 34}, {30, 34}, {30, 27}, {30, 22}}, color = {0, 0, 255}));
      connect(Rload.n, sineVoltage.n) annotation(
        Line(points = {{30, -30}, {30, -35}, {30, -35}, {30, -38}, {-30, -38}, {-30, -23}, {-30, -23}, {-30, -6}}, color = {0, 0, 255}));
      connect(Rload.p, inductor.n) annotation(
        Line(points = {{30, -10}, {30, -6}, {30, -2}, {30, 2}}, color = {0, 0, 255}));
      connect(ground.p, sineVoltage.n) annotation(
        Line(points = {{-50, -20}, {-50, -6}, {-30, -6}}, color = {0, 0, 255}));
      annotation(
        experiment(StopTime = 0.06),
        __Dymola_experimentSetupOutput,
        Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})),
        Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})));
    end RLD;
  end ConDiodo;
  annotation(
    uses(Modelica(version = "3.2.2")));
end TestMove;
s5:
encapsulated package TestMove 
  import Modelica; 
  import RLCPkg; 
 
  model RL_P 
    Modelica.Electrical.Analog.Basic.Resistor resistor1(R = 1) annotation( 
      Placement(visible = true, transformation(origin = {64, 18}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
    Modelica.Electrical.Analog.Basic.Inductor inductor(L = 10e-3) annotation( 
      Placement(visible = true, transformation(origin = {64, -12}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
    Modelica.Electrical.Analog.Sensors.PowerSensor pMeas annotation( 
      Placement(visible = true, transformation(extent = {{-14, 18}, {6, 38}}, rotation = 0))); 
    Modelica.Electrical.Analog.Basic.Ground ground annotation( 
      Placement(visible = true, transformation(extent = {{-10, -66}, {10, -46}}, rotation = 0))); 
    Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation( 
      Placement(visible = true, transformation(origin = {-60, 4}, extent = {{-10, 10}, {10, -10}}, rotation = 270))); 
  equation 
    connect(pMeas.nc, resistor1.p) annotation( 
      Line(points = {{6, 28}, {6, 28}, {64, 28}}, color = {0, 0, 255})); 
  connect(pMeas.nv, inductor.n) annotation( 
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
  connect(pMeas.nv, inductor.n) annotation( 
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
  connect(pMeas.nv, inductor.n) annotation( 
      Line(points = {{-4, 18}, {-4, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
    connect(resistor1.n, inductor.p) annotation( 
      Line(points = {{64, 8}, {64, -2}}, color = {0, 0, 255})); 
    connect(sineVoltage.n, inductor.n) annotation( 
      Line(points = {{-60, -6}, {-60, -6}, {-60, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
    connect(ground.p, inductor.n) annotation( 
      Line(points = {{0, -46}, {0, -36}, {64, -36}, {64, -22}}, color = {0, 0, 255})); 
    annotation( 
      experiment(StopTime = 0.1), 
      experimentSetupOutput, 
      Documentation(info = "<html> 
 <p>Misura di potenza attiva e reattiva istantanea su carico RLC</p> 
 </html>"), 
      Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1)), 
      Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = false, initialScale = 0.1))); 
  end RL_P; 
 
  package ConDiodo 
    model RLD 
      Modelica.Electrical.Analog.Sources.SineVoltage sineVoltage(freqHz = 50, V = 100) annotation( 
        Placement(visible = true, transformation(origin = {-30, 4}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
      Modelica.Electrical.Analog.Basic.Inductor inductor(L = 1e-3, i(fixed = true)) annotation( 
        Placement(visible = true, transformation(origin = {30, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
      Modelica.Electrical.Analog.Basic.Ground ground annotation( 
        Placement(visible = true, transformation(extent = {{-60, -40}, {-40, -20}}, rotation = 0))); 
      Modelica.Electrical.Analog.Basic.Resistor Rload(R = 1) annotation( 
        Placement(visible = true, transformation(origin = {30, -20}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
      Modelica.Electrical.Analog.Ideal.IdealDiode idealDiode annotation( 
        Placement(visible = true, transformation(extent = {{-10, 24}, {10, 44}}, rotation = 0))); 
      Modelica.Electrical.Analog.Basic.Resistor Rload1(R = 1e5) annotation( 
        Placement(visible = true, transformation(origin = {58, 12}, extent = {{-10, -10}, {10, 10}}, rotation = 270))); 
    equation 
      connect(Rload1.n, inductor.n) annotation( 
        Line(points = {{58, 2}, {30, 2}}, color = {0, 0, 255})); 
      connect(Rload1.p, inductor.p) annotation( 
        Line(points = {{58, 22}, {30, 22}}, color = {0, 0, 255})); 
      connect(idealDiode.p, sineVoltage.p) annotation( 
        Line(points = {{-10, 34}, {-20, 34}, {-30, 34}, {-30, 23}, {-30, 14}}, color = {0, 0, 255})); 
      connect(idealDiode.n, inductor.p) annotation( 
        Line(points = {{10, 34}, {20, 34}, {30, 34}, {30, 27}, {30, 22}}, color = {0, 0, 255})); 
      connect(Rload.n, sineVoltage.n) annotation( 
        Line(points = {{30, -30}, {30, -35}, {30, -35}, {30, -38}, {-30, -38}, {-30, -23}, {-30, -23}, {-30, -6}}, color = {0, 0, 255})); 
      connect(Rload.p, inductor.n) annotation( 
        Line(points = {{30, -10}, {30, -6}, {30, -2}, {30, 2}}, color = {0, 0, 255})); 
      connect(ground.p, sineVoltage.n) annotation( 
        Line(points = {{-50, -20}, {-50, -6}, {-30, -6}}, color = {0, 0, 255})); 
      annotation( 
        experiment(StopTime = 0.06), 
        __Dymola_experimentSetupOutput, 
        Diagram(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2})), 
        Icon(coordinateSystem(extent = {{-80, -60}, {80, 60}}, preserveAspectRatio = true, initialScale = 0.1, grid = {2, 2}))); 
    end RLD; 
  end ConDiodo; 
  annotation( 
    uses(Modelica(version = "3.2.2"))); 
end TestMove;

Tested on OM 1.13.0-dev-215 64 bit Win version.

Attachments (1)

TestMove.mo (5.0 KB ) - added by massimo ceraolo 7 years ago.

Download all attachments as: .zip

Change History (10)

by massimo ceraolo, 7 years ago

Attachment: TestMove.mo added

comment:1 by massimo ceraolo, 7 years ago

Description: modified (diff)

comment:2 by Adeel Asghar, 7 years ago

Cc: Martin Sjölund added

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

Milestone: Future1.13.0
Priority: normalblocker

This needs to be fixed before 1.13.0 but I don't have time to look into it right now.

comment:4 by massimo ceraolo, 7 years ago

This is a strange ticket. In a sense it is not serious since it involves just a weird message.
In another is very important since it occurs frequently, even with simple models, and new OM users can be really disappointed receiving a such weird message when using very basic models.

Thank you for considering it. I hope it will be fixed by the end of this year.

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

It is serious in the sense that the formatting will get all messed up. And we have this message there so we could try to reproduce it and fix the formatter.

comment:6 by massimo ceraolo, 7 years ago

See also #4632

comment:7 by massimo ceraolo, 7 years ago

May I ask to address tickets #4632 and #4624 within 30-40 days from now?
In the beginning of next year I'm using OM for teaching and I think they have a very bad impact on newcomers.

comment:8 by Francesco Casella, 7 years ago

Resolution: duplicate
Status: newclosed

This ticket is essentially a duplicate of #4632. In this case the model is still valid after moving the compoent around because that component is in the MSL, so it is already referenced with its fully qualified path and the encapsulated syndrome of #4632 does not take place.

I am closing this ticket since the newest analysis is now in #4632.

comment:9 by massimo ceraolo, 7 years ago

This huge message is not issued if the steps in the description are made in OM 1.12.0 release (tested with Mac version)

Note: See TracTickets for help on using tickets.