@@ -40,7 +40,8 @@ model TransformerYY "Test example with polyphase components"
40
40
transformation(extent={{-30,-100},{-10,-80}})));
41
41
Basic.Resistor transformerR(m= m, R= fill (RT, m)) annotation (Placement(
42
42
transformation(extent={{0,10},{20,30}})));
43
- Basic.Inductor transformerL(m= m, L= fill (LT, m)) annotation (Placement(
43
+ Basic.Inductor transformerL(m= m, L= fill (LT, m),
44
+ iL(start= zeros (m), fixed= cat(1 ,fill (true ,m- 1 ),{false }))) annotation (Placement(
44
45
transformation(extent={{30,10},{50,30}})));
45
46
Basic.Resistor loadR(m= m, R= fill (RL, m)) annotation (Placement(
46
47
transformation(extent={{70,10},{90,30}})));
@@ -50,9 +51,6 @@ model TransformerYY "Test example with polyphase components"
50
51
rotation=270)));
51
52
Modelica.Electrical.Analog.Basic.Ground groundT1 annotation (Placement(
52
53
transformation(extent={{-50,-100},{-30,-80}})));
53
- initial equation
54
- transformerL.i[1 :m - 1 ] = zeros (m - 1 ) "Y-connection" ;
55
-
56
54
equation
57
55
connect (starS.pin_n, groundS.p)
58
56
annotation (Line(points={{-90,-72},{-90,-80}}, color={0,0,255}));
@@ -77,12 +75,32 @@ equation
77
75
connect (loadR.plug_n, starL.plug_p)
78
76
annotation (Line(points={{90,20},{90,-52}}, color={0,0,255}));
79
77
annotation (Documentation(info="<html>
78
+ <p>Test example with polyphase components:</p>
79
+ <p>Star-connected voltage source feeds via a Y-Y-transformer with internal impedance (RT, LT) a load resistor RT.</p>
80
+ <p>Using f=5 Hz LT=3mH defines nominal voltage drop of approximately 10 %.</p>
81
+ <p>Simulate for 1 second (2 periods) and compare voltages and currents of source, transformer and load. </p>
82
+ <h4>Note</h4>
80
83
<p>
81
- Test example with polyphase components:<br>
82
- Star-connected voltage source feeds via a Y-Y-transformer with internal impedance (RT, LT) a load resistor RT.<br>
83
- Using f=5 Hz LT=3mH defines nominal voltage drop of approximately 10 %.<br>
84
- Simulate for 1 second (2 periods) and compare voltages and currents of source, transformer and load.
84
+ From the <code>m</code> currents <code>m-1</code> have to be initialized with fixed = true, one of the <code>m</code> currents with fixed = false,
85
+ due to the fact that the star connection enforces sum of the currents = 0.
86
+ </p>
87
+ <p>
88
+ Tools are expected to present a proper initialization section of the menu of <code>transformerL</code> which allows
89
+ to set the start values of the <code>m</code> currents and the fixed attributes individually, i.e. as an array.
90
+ Especially, a checkbox for the fixed attributes should be avoided.
91
+ </p>
92
+ <p>
93
+ If this is not the case, you have to write the code manually:
94
+ </p>
95
+ <p><code>
96
+ Modelica.Electrical.PolyPhase.Basic.Inductor transformerL(m=m, L=fill(LT, m),
97
+ <strong>iL(start=zeros(m), fixed=cat(1,fill(true,m-1),{false}))</strong>);</code>
85
98
</p>
86
99
</html>" ),
87
- experiment(StopTime=1.0, Interval=0.001));
100
+ experiment(StopTime=1.0, Interval=0.001),
101
+ Diagram(graphics={Text(
102
+ extent={{0,60},{80,40}},
103
+ textColor={28,108,200},
104
+ textString="Regarding initialization:
105
+ see Documentation" )}));
88
106
end TransformerYY;
0 commit comments