Skip to content

Commit

Permalink
Almost automatically updated to have correct gradient.
Browse files Browse the repository at this point in the history
Note that Modelica/Electrical/Machines/Icons/(Quasi|)StaticTransformer.mo was converted to be line-based.
Closes modelica#3951
  • Loading branch information
HansOlsson committed Feb 18, 2022
1 parent 421e09e commit b1c2bf4
Show file tree
Hide file tree
Showing 15 changed files with 147 additions and 82 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,10 @@ equation
textString="A"),Rectangle(
visible=quasiStatic,
extent={{-10,90},{10,-80}},
lineColor={170,213,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={170,213,255})}), Documentation(info="<html>
fillColor={170,213,255},
pattern=LinePattern.None)}),Documentation(info="<html>
Linear model of the airgap (without saturation effects) of a DC machine, using only equations.<br>
Induced excitation voltage is calculated from der(flux), where flux is defined by excitation inductance times excitation current.
If <code>quasiStatic == false</code>, the electrical transients are neglected, i.e., the induced excitation voltage is zero.<br>
Expand Down
30 changes: 18 additions & 12 deletions Modelica/Electrical/Machines/BasicMachines/Transformers/package.mo
Original file line number Diff line number Diff line change
Expand Up @@ -102,38 +102,44 @@ even though the source's and/or load's starpoint are grounded; you may use a rea
-60,-50},{-80,-70}}),
Rectangle(
origin={10,10},
lineColor={128,0,255},
lineColor={0,0,0},
fillColor={128,0,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-88,-46},{-52,26}}),
extent={{-88,-46},{-52,26}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={0,128,255},
lineColor={0,0,0},
fillColor={0,128,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-94,-38},{-46,18}}),
extent={{-94,-38},{-46,18}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={128,0,255},
lineColor={0,0,0},
fillColor={128,0,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-28,-46},{8,26}}),
extent={{-28,-46},{8,26}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={0,128,255},
lineColor={0,0,0},
fillColor={0,128,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-34,-38},{14,18}}),
extent={{-34,-38},{14,18}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={128,0,255},
lineColor={0,0,0},
fillColor={128,0,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{32,-46},{68,26}}),
extent={{32,-46},{68,26}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={0,128,255},
lineColor={0,0,0},
fillColor={0,128,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{26,-38},{74,18}})}));
extent={{26,-38},{74,18}},
pattern=LinePattern.None)}));
end Transformers;
51 changes: 34 additions & 17 deletions Modelica/Electrical/Machines/Icons/QuasiStaticTransformer.mo
Original file line number Diff line number Diff line change
Expand Up @@ -3,46 +3,63 @@ partial model QuasiStaticTransformer
annotation (Icon(graphics={Polygon(
points={{-70,60},{-50,40},{-50,-40},{-70,-60},{-70,60}},
fillColor={135,135,135},
fillPattern=FillPattern.VerticalCylinder),Polygon(
fillPattern=FillPattern.VerticalCylinder),
Polygon(
points={{70,60},{50,40},{50,-40},{70,-60},{70,60}},
fillColor={135,135,135},
fillPattern=FillPattern.VerticalCylinder),Polygon(
fillPattern=FillPattern.VerticalCylinder),
Polygon(
points={{0,50},{-10,40},{-10,-40},{0,-50},{10,-40},{10,40},{0,
50}},
fillPattern=FillPattern.VerticalCylinder,
fillColor={135,135,135}),Polygon(
fillColor={135,135,135}),
Polygon(
points={{-70,60},{70,60},{50,40},{10,40},{0,50},{-10,40},{-50,
40},{-70,60}},
fillPattern=FillPattern.VerticalCylinder,
fillColor={135,135,135}),Polygon(
fillColor={135,135,135}),
Polygon(
points={{-70,-60},{70,-60},{50,-40},{10,-40},{0,-50},{-10,-40},
{-50,-40},{-70,-60}},
fillPattern=FillPattern.VerticalCylinder,
fillColor={135,135,135}),Rectangle(
fillColor={135,135,135}),
Rectangle(
extent={{-78,36},{-42,-36}},
lineColor={213,170,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={213,170,255}),Rectangle(
fillColor={213,170,255},
pattern=LinePattern.None),
Rectangle(
extent={{-84,28},{-36,-28}},
lineColor={170,213,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={170,213,255}),Rectangle(
fillColor={170,213,255},
pattern=LinePattern.None),
Rectangle(
extent={{-18,36},{18,-36}},
lineColor={213,170,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={213,170,255}),Rectangle(
fillColor={213,170,255},
pattern=LinePattern.None),
Rectangle(
extent={{-24,28},{24,-28}},
lineColor={170,213,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={170,213,255}),Rectangle(
fillColor={170,213,255},
pattern=LinePattern.None),
Rectangle(
extent={{42,36},{78,-36}},
lineColor={213,170,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={213,170,255}),Rectangle(
fillColor={213,170,255},
pattern=LinePattern.None),
Rectangle(
extent={{36,28},{84,-28}},
lineColor={170,213,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={170,213,255})}), Documentation(info="<html>
fillColor={170,213,255},
pattern=LinePattern.None)}),
Documentation(info="<html>
<p>
This icon is designed for a <strong>quasi-static transformer</strong> model.
</p>
Expand Down
51 changes: 34 additions & 17 deletions Modelica/Electrical/Machines/Icons/TransientTransformer.mo
Original file line number Diff line number Diff line change
Expand Up @@ -3,46 +3,63 @@ model TransientTransformer
annotation (Icon(graphics={Polygon(
points={{-70,60},{-50,40},{-50,-40},{-70,-60},{-70,60}},
fillColor={135,135,135},
fillPattern=FillPattern.VerticalCylinder),Polygon(
fillPattern=FillPattern.VerticalCylinder),
Polygon(
points={{70,60},{50,40},{50,-40},{70,-60},{70,60}},
fillColor={135,135,135},
fillPattern=FillPattern.VerticalCylinder),Polygon(
fillPattern=FillPattern.VerticalCylinder),
Polygon(
points={{0,50},{-10,40},{-10,-40},{0,-50},{10,-40},{10,40},{0,
50}},
fillPattern=FillPattern.VerticalCylinder,
fillColor={135,135,135}),Polygon(
fillColor={135,135,135}),
Polygon(
points={{-70,60},{70,60},{50,40},{10,40},{0,50},{-10,40},{-50,
40},{-70,60}},
fillPattern=FillPattern.VerticalCylinder,
fillColor={135,135,135}),Polygon(
fillColor={135,135,135}),
Polygon(
points={{-70,-60},{70,-60},{50,-40},{10,-40},{0,-50},{-10,-40},
{-50,-40},{-70,-60}},
fillPattern=FillPattern.VerticalCylinder,
fillColor={135,135,135}),Rectangle(
fillColor={135,135,135}),
Rectangle(
extent={{-78,36},{-42,-36}},
lineColor={128,0,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={128,0,255}),Rectangle(
fillColor={128,0,255},
pattern=LinePattern.None),
Rectangle(
extent={{-84,28},{-36,-28}},
lineColor={0,128,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={0,128,255}),Rectangle(
fillColor={0,128,255},
pattern=LinePattern.None),
Rectangle(
extent={{-18,36},{18,-36}},
lineColor={128,0,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={128,0,255}),Rectangle(
fillColor={128,0,255},
pattern=LinePattern.None),
Rectangle(
extent={{-24,28},{24,-28}},
lineColor={0,128,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={0,128,255}),Rectangle(
fillColor={0,128,255},
pattern=LinePattern.None),
Rectangle(
extent={{42,36},{78,-36}},
lineColor={128,0,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={128,0,255}),Rectangle(
fillColor={128,0,255},
pattern=LinePattern.None),
Rectangle(
extent={{36,28},{84,-28}},
lineColor={0,128,255},
lineColor={0,0,0},
fillPattern=FillPattern.VerticalCylinder,
fillColor={0,128,255})}), Documentation(info="<html>
fillColor={0,128,255},
pattern=LinePattern.None)}),
Documentation(info="<html>
<p>
This icon is designed for a <strong>transient transformer</strong> model.
</p>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines.Transformers;
package Dd "Transformers: primary D / secondary d"
extends Modelica.Icons.VariantsPackage;

annotation (Documentation(info="<html>
This package contains transformers primary D connected / secondary d connected in all possible vector groups.
</html>",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines.Transformers;
package Dy "Transformers: primary D / secondary y"
extends Modelica.Icons.VariantsPackage;

annotation (Documentation(info="<html>
This package contains transformers primary D connected / secondary y connected in all possible vector groups.
</html>",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines.Transformers;
package Dz "Transformers: primary D / secondary zig-zag"
extends Modelica.Icons.VariantsPackage;

annotation (Documentation(info="<html>
This package contains transformers primary D connected / secondary d connected in all possible vector groups.
</html>",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines.Transformers;
package Yd "Transformers: primary Y / secondary d"
extends Modelica.Icons.VariantsPackage;

annotation (Documentation(info="<html>
This package contains transformers primary Y connected / secondary d connected in all possible vector groups.
</html>",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines.Transformers;
package Yy "Transformers: primary Y / secondary y"
extends Modelica.Icons.VariantsPackage;

annotation (Documentation(info="<html>
This package contains transformers primary Y connected / secondary y connected in all possible vector groups.
</html>",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines.Transformers;
package Yz "Transformers: primary Y / secondary zig-zag"
extends Modelica.Icons.VariantsPackage;

annotation (Documentation(info="<html>
This package contains transformers primary Y connected / secondary zig-zag connected in all possible vector groups.
</html>",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
within Modelica.Electrical.QuasiStatic.Machines.BasicMachines;
package Transformers "Library for technical 3phase transformers"
extends Modelica.Icons.Package;

annotation (Documentation(info="<html>
This package contains components to model technical three-phase transformers:
<ul>
Expand Down Expand Up @@ -102,38 +103,44 @@ even though the source's and/or load's starpoint are grounded; you may use a rea
-60,-50},{-80,-70}}),
Rectangle(
origin={10,10},
lineColor={213,170,255},
lineColor={0,0,0},
fillColor={213,170,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-88,-46},{-52,26}}),
extent={{-88,-46},{-52,26}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={170,213,255},
lineColor={0,0,0},
fillColor={170,213,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-94,-38},{-46,18}}),
extent={{-94,-38},{-46,18}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={213,170,255},
lineColor={0,0,0},
fillColor={213,170,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-28,-46},{8,26}}),
extent={{-28,-46},{8,26}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={170,213,255},
lineColor={0,0,0},
fillColor={170,213,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{-34,-38},{14,18}}),
extent={{-34,-38},{14,18}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={213,170,255},
lineColor={0,0,0},
fillColor={213,170,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{32,-46},{68,26}}),
extent={{32,-46},{68,26}},
pattern=LinePattern.None),
Rectangle(
origin={10,10},
lineColor={170,213,255},
lineColor={0,0,0},
fillColor={170,213,255},
fillPattern=FillPattern.VerticalCylinder,
extent={{26,-38},{74,18}})}));
extent={{26,-38},{74,18}},
pattern=LinePattern.None)}));
end Transformers;
10 changes: 6 additions & 4 deletions Modelica/Fluid/Examples/AST_BatchPlant.mo
Original file line number Diff line number Diff line change
Expand Up @@ -878,9 +878,10 @@ Documentation for this example can be found on the <a href=\"modelica://Modelica
200,100}}), graphics={
Rectangle(
extent={{-200,100},{0,-100}},
lineColor={255,255,255},
lineColor={0,0,0},
fillColor={255,255,255},
fillPattern=FillPattern.VerticalCylinder),
fillPattern=FillPattern.VerticalCylinder,
pattern=LinePattern.None),
Rectangle(
extent=DynamicSelect({{-200,-100},{0,0}}, {{-200,-100},{0,(-100
+ 200*level/height)}}),
Expand Down Expand Up @@ -1683,9 +1684,10 @@ end for;
initialScale=0.2), graphics={
Rectangle(
extent={{-100,-100},{100,100}},
lineColor={255,255,255},
lineColor={0,0,0},
fillColor={255,255,255},
fillPattern=FillPattern.VerticalCylinder),
fillPattern=FillPattern.VerticalCylinder,
pattern=LinePattern.None),
Rectangle(
extent=DynamicSelect({{-100,-100},{100,0}}, {{-100,-100},{100,(-100
+ 200*level/height)}}),
Expand Down
5 changes: 3 additions & 2 deletions Modelica/Fluid/Vessels.mo
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,10 @@ initial equation
initialScale=0.2), graphics={
Rectangle(
extent={{-100,100},{100,-100}},
lineColor={255,255,255},
lineColor={0,0,0},
fillColor={255,255,255},
fillPattern=FillPattern.VerticalCylinder),
fillPattern=FillPattern.VerticalCylinder,
pattern=LinePattern.None),
Rectangle(
extent=DynamicSelect({{-100,-100},{100,10}}, {{-100,-100},{100,(-100
+ 200*level/height)}}),
Expand Down
Loading

0 comments on commit b1c2bf4

Please sign in to comment.