| 1 | within Modelica.Electrical; |
|---|
| 2 | |
|---|
| 3 | |
|---|
| 4 | package MultiPhase "Library for electrical components with 2, 3 or more phases" |
|---|
| 5 | extends Modelica.Icons.Library2; |
|---|
| 6 | annotation ( |
|---|
| 7 | version="1.3.2", versionDate="2007-08-24", |
|---|
| 8 | Documentation(info="<HTML> |
|---|
| 9 | <p> |
|---|
| 10 | This package contains packages for electrical multiphase components, based on Modelica.Electrical.Analog: |
|---|
| 11 | <ul> |
|---|
| 12 | <li>Basic: basic components (resistor, capacitor, inductor, ...)</li> |
|---|
| 13 | <li>Ideal: ideal elements (switches, diode, transformer, ...)</li> |
|---|
| 14 | <li>Sensors: sensors to measure potentials, voltages, and currents</li> |
|---|
| 15 | <li>Sources: time-dependend and controlled voltage and current sources</li> |
|---|
| 16 | </ul> |
|---|
| 17 | This package is intended to be used the same way as Modelica.Electrical.Analog |
|---|
| 18 | but to make design of multiphase models easier.<br> |
|---|
| 19 | The package is based on the plug: a composite connector containing m pins.<br> |
|---|
| 20 | It is possible to connect plugs to plugs or single pins of a plug to single pins.<br> |
|---|
| 21 | Potentials may be accessed as <tt>plug.pin[].v</tt>, currents may be accessed as <tt>plug.pin[].i</tt>. |
|---|
| 22 | </p> |
|---|
| 23 | <p> |
|---|
| 24 | Further development: |
|---|
| 25 | <ul> |
|---|
| 26 | <li>temperature-dependent resistor</li> |
|---|
| 27 | <li>lines (m-phase models)</li> |
|---|
| 28 | </ul> |
|---|
| 29 | </p> |
|---|
| 30 | <dl> |
|---|
| 31 | <p> |
|---|
| 32 | <dt><b>Main Author:</b></dt> |
|---|
| 33 | <dd> |
|---|
| 34 | <a href=\"http://www.haumer.at/\">Anton Haumer</a><br> |
|---|
| 35 | Technical Consulting & Electrical Engineering<br> |
|---|
| 36 | A-3423 St.Andrae-Woerdern<br>Austria<br> |
|---|
| 37 | email: <a href=\"mailto:a.haumer@haumer.at\">a.haumer@haumer.at</a> |
|---|
| 38 | </dd> |
|---|
| 39 | </p> |
|---|
| 40 | </dl> |
|---|
| 41 | <p> |
|---|
| 42 | Copyright © 1998-2005, Modelica Association and Anton Haumer. |
|---|
| 43 | </p> |
|---|
| 44 | <p> |
|---|
| 45 | <i>The Modelica package is <b>free</b> software; it can be redistributed and/or modified |
|---|
| 46 | under the terms of the <b>Modelica license</b>, see the license conditions |
|---|
| 47 | and the accompanying <b>disclaimer</b> |
|---|
| 48 | <a href=\"Modelica://Modelica.UsersGuide.ModelicaLicense\">here</a>.</i> |
|---|
| 49 | </p><br> |
|---|
| 50 | </HTML>", revisions="<html> |
|---|
| 51 | <ul> |
|---|
| 52 | <li>v1.0 2004/10/01 Anton Haumer</li> |
|---|
| 53 | <li>v1.1 2006/01/12 Anton Haumer<br> |
|---|
| 54 | added Sensors.PowerSensor</li> |
|---|
| 55 | <li>v1.2 2006/07/05 Anton Haumer<br> |
|---|
| 56 | removed annotation from pin of Interfaces.Plug<br> |
|---|
| 57 | corrected usage of resistance/conductance</li> |
|---|
| 58 | <li>v1.3.0 2007/01/23 Anton Haumer<br> |
|---|
| 59 | improved some icons</li> |
|---|
| 60 | <li>v1.3.1 2007/08/12 Anton Haumer<br> |
|---|
| 61 | improved documentation</li> |
|---|
| 62 | <li>v1.3.2 2007/08/24 Anton Haumer<br> |
|---|
| 63 | removed redeclare type SignalType</li> |
|---|
| 64 | </ul> |
|---|
| 65 | </html>"), |
|---|
| 66 | Icon(coordinateSystem(preserveAspectRatio=true, extent={{-100,-100},{100, |
|---|
| 67 | 100}}), graphics={ |
|---|
| 68 | Ellipse(extent={{-60,10},{40,-90}}, lineColor={0,0,255}), |
|---|
| 69 | Ellipse( |
|---|
| 70 | extent={{-40,-14},{-20,-34}}, |
|---|
| 71 | lineColor={0,0,255}, |
|---|
| 72 | fillColor={0,0,255}, |
|---|
| 73 | fillPattern=FillPattern.Solid), |
|---|
| 74 | Ellipse( |
|---|
| 75 | extent={{0,-14},{20,-34}}, |
|---|
| 76 | lineColor={0,0,255}, |
|---|
| 77 | fillColor={0,0,255}, |
|---|
| 78 | fillPattern=FillPattern.Solid), |
|---|
| 79 | Ellipse( |
|---|
| 80 | extent={{-20,-54},{0,-74}}, |
|---|
| 81 | lineColor={0,0,255}, |
|---|
| 82 | fillColor={0,0,255}, |
|---|
| 83 | fillPattern=FillPattern.Solid)})); |
|---|
| 84 | |
|---|
| 85 | package Examples "Multiphase test examples" |
|---|
| 86 | extends Modelica.Icons.Library2; |
|---|
| 87 | annotation (Documentation(info="<HTML> |
|---|
| 88 | <p> |
|---|
| 89 | This package contains test examples of analog electrical multiphase circuits. |
|---|
| 90 | </p> |
|---|
| 91 | |
|---|
| 92 | </HTML>", revisions="<html> |
|---|
| 93 | <dl> |
|---|
| 94 | <p> |
|---|
| 95 | <dt><b>Main Authors:</b></dt> |
|---|
| 96 | <dd> |
|---|
| 97 | <a href=\"http://www.haumer.at/\">Anton Haumer</a><br> |
|---|
| 98 | Technical Consulting & Electrical Engineering<br> |
|---|
| 99 | A-3423 St.Andrae-Woerdern<br>Austria<br> |
|---|
| 100 | email: <a href=\"mailto:a.haumer@haumer.at\">a.haumer@haumer.at</a> |
|---|
| 101 | </dd> |
|---|
| 102 | </p> |
|---|
| 103 | <p> |
|---|
| 104 | <dt><b>Release Notes:</b></dt> |
|---|
| 105 | <dd> |
|---|
| 106 | <ul> |
|---|
| 107 | <li> v1.0 2004/10/01 Anton Haumer</li> |
|---|
| 108 | </ul> |
|---|
| 109 | </dd> |
|---|
| 110 | <p> |
|---|
| 111 | <dt><b>Copyright:</b></dt> |
|---|
| 112 | <dd>Copyright © 1998-2006, Modelica Association and Anton Haumer.<br> |
|---|
| 113 | <i>The Modelica package is <b>free</b> software; it can be redistributed and/or modified |
|---|
| 114 | under the terms of the <b>Modelica license</b>, see the license conditions |
|---|
| 115 | and the accompanying <b>disclaimer</b> in the documentation of package |
|---|
| 116 | Modelica in file \"Modelica/package.mo\".</i></dd> |
|---|
| 117 | </p> |
|---|
| 118 | </dl> |
|---|
| 119 | </html>"), Icon(coordinateSystem(preserveAspectRatio=true, extent={{-100,-100}, |
|---|
| 120 | {100,100}}), graphics={Ellipse(extent={{-60,12},{40,-88}}, |
|---|
| 121 | lineColor={135,135,135}), Polygon( |
|---|
| 122 | points={{-30,-10},{-30,-66},{28,-38},{-30,-10}}, |
|---|
| 123 | lineColor={135,135,135}, |
|---|
| 124 | fillColor={135,135,135}, |
|---|
| 125 | fillPattern=FillPattern.Solid)})); |
|---|
| 126 | |
|---|
| 127 | model TransformerYY "Test example with multiphase components" |
|---|
| 128 | extends Modelica.Icons.Example; |
|---|
| 129 | parameter Integer m=3 "Number of phases"; |
|---|
| 130 | parameter Modelica.SIunits.Voltage V=1 "Amplitude of Star-Voltage"; |
|---|
| 131 | parameter Modelica.SIunits.Frequency f=5 "Frequency"; |
|---|
| 132 | parameter Modelica.SIunits.Inductance LT=0.003 |
|---|
| 133 | "Transformer stray inductance"; |
|---|
| 134 | parameter Modelica.SIunits.Resistance RT=0.05 "Transformer resistance"; |
|---|
| 135 | parameter Modelica.SIunits.Resistance RL=1 "Load Resistance"; |
|---|
| 136 | annotation (Documentation(info="<HTML> |
|---|
| 137 | <p> |
|---|
| 138 | Test example with multiphase components:<br> |
|---|
| 139 | Star-connected voltage source feeds via a Y-Y-transformer with internal impedance (RT, LT) a load resistor RT.<br> |
|---|
| 140 | Using f=5 Hz LT=3mH defines nominal voltage drop of approximately 10 %.<br> |
|---|
| 141 | Simulate for 1 second (2 periods) and compare voltages and currents of source, transformer and load. |
|---|
| 142 | </p> |
|---|
| 143 | </HTML>"), Diagram(graphics)); |
|---|
| 144 | Sources.SineVoltage sineVoltage( |
|---|
| 145 | V=fill(V, m), |
|---|
| 146 | freqHz=fill(f, m), |
|---|
| 147 | m=m) annotation (Placement(transformation( |
|---|
| 148 | origin={-80,20}, |
|---|
| 149 | extent={{-10,-10},{10,10}}, |
|---|
| 150 | rotation=180))); |
|---|
| 151 | Basic.Star starS(m=m) |
|---|
| 152 | annotation (Placement(transformation( |
|---|
| 153 | origin={-90,-62}, |
|---|
| 154 | extent={{-10,-10},{10,10}}, |
|---|
| 155 | rotation=270))); |
|---|
| 156 | Modelica.Electrical.Analog.Basic.Ground groundS |
|---|
| 157 | annotation (Placement(transformation(extent={{-100,-100},{-80,-80}}, |
|---|
| 158 | rotation=0))); |
|---|
| 159 | Ideal.IdealTransformer idealTransformer(m=m) |
|---|
| 160 | annotation (Placement(transformation(extent={{-40,0},{-20,20}}, |
|---|
| 161 | rotation=0))); |
|---|
| 162 | Basic.Star starT1(m=m) |
|---|
| 163 | annotation (Placement(transformation( |
|---|
| 164 | origin={-40,-62}, |
|---|
| 165 | extent={{-10,-10},{10,10}}, |
|---|
| 166 | rotation=270))); |
|---|
| 167 | Basic.Star starT2(m=m) |
|---|
| 168 | annotation (Placement(transformation( |
|---|
| 169 | origin={-20,-62}, |
|---|
| 170 | extent={{-10,-10},{10,10}}, |
|---|
| 171 | rotation=270))); |
|---|
| 172 | Modelica.Electrical.Analog.Basic.Ground groundT2 |
|---|
| 173 | annotation (Placement(transformation(extent={{-30,-100},{-10,-80}}, |
|---|
| 174 | rotation=0))); |
|---|
| 175 | Basic.Resistor transformerR(m=m, R=fill(RT, m)) |
|---|
| 176 | annotation (Placement( |
|---|
| 177 | transformation(extent={{0,10},{20,30}}, rotation=0))); |
|---|
| 178 | Basic.Inductor transformerL(m=m, L=fill(LT, m)) |
|---|
| 179 | annotation (Placement(transformation(extent={{30,10},{50,30}}, rotation= |
|---|
| 180 | 0))); |
|---|
| 181 | Basic.Resistor loadR(m=m, R=fill(RL, m)) |
|---|
| 182 | annotation (Placement(transformation(extent={{70,10},{90,30}}, rotation= |
|---|
| 183 | 0))); |
|---|
| 184 | Basic.Star starL(m=m) |
|---|
| 185 | annotation (Placement(transformation( |
|---|
| 186 | origin={90,-62}, |
|---|
| 187 | extent={{-10,-10},{10,10}}, |
|---|
| 188 | rotation=270))); |
|---|
| 189 | Modelica.Electrical.Analog.Basic.Ground groundT1 |
|---|
| 190 | annotation (Placement(transformation(extent={{-50,-100},{-30,-80}}, |
|---|
| 191 | rotation=0))); |
|---|
| 192 | equation |
|---|
| 193 | connect(starS.pin_n, groundS.p) |
|---|
| 194 | annotation (Line(points={{-90,-72},{-90,-80}}, color={0,0,255})); |
|---|
| 195 | connect(starT1.pin_n,groundT1. p) |
|---|
| 196 | annotation (Line(points={{-40,-72},{-40,-80}}, color={0,0,255})); |
|---|
| 197 | connect(starT2.pin_n,groundT2. p) |
|---|
| 198 | annotation (Line(points={{-20,-72},{-20,-80}}, color={0,0,255})); |
|---|
| 199 | connect(starS.plug_p, sineVoltage.plug_n) |
|---|
| 200 | annotation (Line(points={{-90,-52},{-90,20}}, color={0,0,255})); |
|---|
| 201 | connect(sineVoltage.plug_p, idealTransformer.plug_p1) |
|---|
| 202 | annotation (Line(points={{-70,20},{-40,20}}, color={0,0,255})); |
|---|
| 203 | connect(idealTransformer.plug_n1, starT1.plug_p) |
|---|
| 204 | annotation (Line(points={{-40,0},{-40,-52}}, color={0,0,255})); |
|---|
| 205 | connect(starT2.plug_p, idealTransformer.plug_n2) |
|---|
| 206 | annotation (Line(points={{-20,-52},{-20,0}}, color={0,0,255})); |
|---|
| 207 | connect(idealTransformer.plug_p2, transformerR.plug_p) |
|---|
| 208 | annotation (Line(points={{-20,20},{0,20}}, color={0,0,255})); |
|---|
| 209 | connect(transformerR.plug_n, transformerL.plug_p) |
|---|
| 210 | annotation (Line(points={{20,20},{30,20}}, color={0,0,255})); |
|---|
| 211 | connect(transformerL.plug_n, loadR.plug_p) |
|---|
| 212 | annotation (Line(points={{50,20},{70,20}}, color={0,0,255})); |
|---|
| 213 | connect(loadR.plug_n, starL.plug_p) |
|---|
| 214 | annotation (Line(points={{90,20},{90,-52}}, color={0,0,255})); |
|---|
| 215 | end TransformerYY; |
|---|
| 216 | |
|---|
| 217 | model TransformerYD "Test example with multiphase components" |
|---|
| 218 | extends Modelica.Icons.Example; |
|---|
| 219 | parameter Integer m=3 "Number of phases"; |
|---|
| 220 | parameter Modelica.SIunits.Voltage V=1 "Amplitude of Star-Voltage"; |
|---|
| 221 | parameter Modelica.SIunits.Frequency f=5 "Frequency"; |
|---|
| 222 | parameter Modelica.SIunits.Inductance LT=0.003 |
|---|
| 223 | "Transformer stray inductance"; |
|---|
| 224 | parameter Modelica.SIunits.Resistance RT=0.05 "Transformer resistance"; |
|---|
| 225 | parameter Modelica.SIunits.Resistance RL=1 "Load Resistance"; |
|---|
| 226 | parameter Real nT=1/sqrt((1 - Modelica.Math.cos(2*Modelica.Constants.pi/m)) |
|---|
| 227 | ^2 + (Modelica.Math.sin(2*Modelica.Constants.pi/m))^2) |
|---|
| 228 | "Transformer ratio"; |
|---|
| 229 | annotation (Documentation(info="<HTML> |
|---|
| 230 | <p> |
|---|
| 231 | Test example with multiphase components:<br> |
|---|
| 232 | Star-connected voltage source feeds via a Y-D-transformer with internal impedance (RT, LT) a load resistor RT.<br> |
|---|
| 233 | Using f=5 Hz LT=3mH defines nominal voltage drop of approximately 10 %.<br> |
|---|
| 234 | Simulate for 1 second (2 periods) and compare voltages and currents of source, transformer and load. |
|---|
| 235 | </p> |
|---|
| 236 | </HTML>"), Diagram(graphics)); |
|---|
| 237 | Sources.SineVoltage sineVoltage( |
|---|
| 238 | V=fill(V, m), |
|---|
| 239 | freqHz=fill(f, m), |
|---|
| 240 | m=m) annotation (Placement(transformation( |
|---|
| 241 | origin={-80,20}, |
|---|
| 242 | extent={{-10,-10},{10,10}}, |
|---|
| 243 | rotation=180))); |
|---|
| 244 | Basic.Star starS(m=m) |
|---|
| 245 | annotation (Placement(transformation( |
|---|
| 246 | origin={-90,-62}, |
|---|
| 247 | extent={{-10,-10},{10,10}}, |
|---|
| 248 | rotation=270))); |
|---|
| 249 | Modelica.Electrical.Analog.Basic.Ground groundS |
|---|
| 250 | annotation (Placement(transformation(extent={{-100,-100},{-80,-80}}, |
|---|
| 251 | rotation=0))); |
|---|
| 252 | Ideal.IdealTransformer idealTransformer(m=m, n=fill(nT, m)) |
|---|
| 253 | annotation (Placement(transformation(extent={{-40,0},{-20,20}}, |
|---|
| 254 | rotation=0))); |
|---|
| 255 | Basic.Star starT(m=m) |
|---|
| 256 | annotation (Placement(transformation( |
|---|
| 257 | origin={-40,-62}, |
|---|
| 258 | extent={{-10,-10},{10,10}}, |
|---|
| 259 | rotation=270))); |
|---|
| 260 | Basic.Delta deltaT2(m=m) |
|---|
| 261 | annotation (Placement(transformation( |
|---|
| 262 | origin={50,10}, |
|---|
| 263 | extent={{-10,10},{10,-10}}, |
|---|
| 264 | rotation=270))); |
|---|
| 265 | Modelica.Electrical.Analog.Basic.Ground groundT |
|---|
| 266 | annotation (Placement(transformation(extent={{-50,-100},{-30,-80}}, |
|---|
| 267 | rotation=0))); |
|---|
| 268 | Basic.Resistor transformerR(m=m, R=fill(RT/nT^2, m)) |
|---|
| 269 | annotation (Placement(transformation(extent={{-10,10},{10,30}}, |
|---|
| 270 | rotation=0))); |
|---|
| 271 | Basic.Inductor transformerL(m=m, L=fill(LT/nT^2, m)) |
|---|
| 272 | annotation (Placement(transformation(extent={{20,10},{40,30}}, rotation= |
|---|
| 273 | 0))); |
|---|
| 274 | Basic.Resistor loadR(m=m, R=fill(RL, m)) |
|---|
| 275 | annotation (Placement(transformation(extent={{70,10},{90,30}}, rotation= |
|---|
| 276 | 0))); |
|---|
| 277 | Basic.Star starL(m=m) |
|---|
| 278 | annotation (Placement(transformation( |
|---|
| 279 | origin={90,-62}, |
|---|
| 280 | extent={{-10,-10},{10,10}}, |
|---|
| 281 | rotation=270))); |
|---|
| 282 | Modelica.Electrical.Analog.Basic.Ground groundL |
|---|
| 283 | annotation (Placement(transformation(extent={{80,-100},{100,-80}}, |
|---|
| 284 | rotation=0))); |
|---|
| 285 | equation |
|---|
| 286 | connect(groundS.p, starS.pin_n) |
|---|
| 287 | annotation (Line(points={{-90,-80},{-90,-72}}, color={0,0,255})); |
|---|
| 288 | connect(groundT.p, starT.pin_n) |
|---|
| 289 | annotation (Line(points={{-40,-80},{-40,-72}}, color={0,0,255})); |
|---|
| 290 | connect(starS.plug_p, sineVoltage.plug_n) |
|---|
| 291 | annotation (Line(points={{-90,-52},{-90,20}}, color={0,0,255})); |
|---|
| 292 | connect(sineVoltage.plug_p, idealTransformer.plug_p1) |
|---|
| 293 | annotation (Line(points={{-70,20},{-40,20}}, color={0,0,255})); |
|---|
| 294 | connect(idealTransformer.plug_n1, starT.plug_p) |
|---|
| 295 | annotation (Line(points={{-40,0},{-40,-52}}, color={0,0,255})); |
|---|
| 296 | connect(idealTransformer.plug_p2, transformerR.plug_p) |
|---|
| 297 | annotation (Line(points={{-20,20},{-10,20}}, color={0,0,255})); |
|---|
| 298 | connect(transformerR.plug_n, transformerL.plug_p) |
|---|
| 299 | annotation (Line(points={{10,20},{20,20}}, color={0,0,255})); |
|---|
| 300 | connect(transformerL.plug_n, deltaT2.plug_p) |
|---|
| 301 | annotation (Line(points={{40,20},{50,20}}, color={0,0,255})); |
|---|
| 302 | connect(deltaT2.plug_n, idealTransformer.plug_n2) |
|---|
| 303 | annotation (Line(points={{50,0},{-20,0}}, color={0,0,255})); |
|---|
| 304 | connect(deltaT2.plug_p, loadR.plug_p) |
|---|
| 305 | annotation (Line(points={{50,20},{70,20}}, color={0,0,255})); |
|---|
| 306 | connect(loadR.plug_n, starL.plug_p) |
|---|
| 307 | annotation (Line(points={{90,20},{90,-52}}, color={0,0,255})); |
|---|
| 308 | connect(starL.pin_n, groundL.p) |
|---|
| 309 | annotation (Line(points={{90,-72},{90,-80}}, color={0,0,255})); |
|---|
| 310 | end TransformerYD; |
|---|
| 311 | |
|---|
| 312 | model Rectifier "Test example with multiphase components" |
|---|
| 313 | extends Modelica.Icons.Example; |
|---|
| 314 | parameter Integer m=3 "Number of phases"; |
|---|
| 315 | parameter Modelica.SIunits.Voltage V=1 "Amplitude of Star-Voltage"; |
|---|
| 316 | parameter Modelica.SIunits.Frequency f=5 "Frequency"; |
|---|
| 317 | parameter Modelica.SIunits.Inductance L=0.001 "Line Inductance"; |
|---|
| 318 | parameter Modelica.SIunits.Resistance RL=2 "Load Resistance"; |
|---|
| 319 | parameter Modelica.SIunits.Capacitance C=0.05 "Total DC-Capacitance"; |
|---|
| 320 | parameter Modelica.SIunits.Resistance RE=1E6 "Earthing Resistance"; |
|---|
| 321 | annotation (Documentation(info="<HTML> |
|---|
| 322 | <p> |
|---|
| 323 | Test example with multiphase components:<br> |
|---|
| 324 | Star-connected voltage source feeds via a line reactor a diode bridge rectifier with a DC burden.<br> |
|---|
| 325 | Using f=5 Hz, simulate for 1 second (2 periods) and compare voltages and currents of source and DC burden, |
|---|
| 326 | neglecting initial transient. |
|---|
| 327 | </p> |
|---|
| 328 | </HTML>"), Diagram(graphics)); |
|---|
| 329 | Sources.SineVoltage sineVoltage( |
|---|
| 330 | m=m, |
|---|
| 331 | V=fill(V, m), |
|---|
| 332 | freqHz=fill(f, m)) annotation (Placement(transformation(extent={{-70,10}, |
|---|
| 333 | {-90,-10}}, rotation=0))); |
|---|
| 334 | Basic.Star starS(m=m) |
|---|
| 335 | annotation (Placement(transformation( |
|---|
| 336 | origin={-90,-50}, |
|---|
| 337 | extent={{-10,-10},{10,10}}, |
|---|
| 338 | rotation=270))); |
|---|
| 339 | Basic.Inductor supplyL(m=m, L=fill(L, m)) |
|---|
| 340 | annotation (Placement(transformation(extent={{-52,-10},{-32,10}}, |
|---|
| 341 | rotation=0))); |
|---|
| 342 | Ideal.IdealDiode idealDiode1(m=m) |
|---|
| 343 | annotation (Placement(transformation( |
|---|
| 344 | origin={10,20}, |
|---|
| 345 | extent={{-10,-10},{10,10}}, |
|---|
| 346 | rotation=90))); |
|---|
| 347 | Basic.Star star1(m=m) annotation (Placement(transformation( |
|---|
| 348 | origin={10,50}, |
|---|
| 349 | extent={{-10,-10},{10,10}}, |
|---|
| 350 | rotation=90))); |
|---|
| 351 | Ideal.IdealDiode idealDiode2(m=m) |
|---|
| 352 | annotation (Placement(transformation( |
|---|
| 353 | origin={10,-20}, |
|---|
| 354 | extent={{-10,-10},{10,10}}, |
|---|
| 355 | rotation=90))); |
|---|
| 356 | Basic.Star star2(m=m) annotation (Placement(transformation( |
|---|
| 357 | origin={10,-50}, |
|---|
| 358 | extent={{-10,10},{10,-10}}, |
|---|
| 359 | rotation=270))); |
|---|
| 360 | Modelica.Electrical.Analog.Basic.Resistor loadR(R=RL) |
|---|
| 361 | annotation (Placement(transformation( |
|---|
| 362 | origin={50,0}, |
|---|
| 363 | extent={{-10,-10},{10,10}}, |
|---|
| 364 | rotation=270))); |
|---|
| 365 | Modelica.Electrical.Analog.Basic.Capacitor cDC1(C=2*C) |
|---|
| 366 | annotation (Placement(transformation( |
|---|
| 367 | origin={70,30}, |
|---|
| 368 | extent={{-10,-10},{10,10}}, |
|---|
| 369 | rotation=270))); |
|---|
| 370 | Modelica.Electrical.Analog.Basic.Capacitor cDC2(C=2*C) |
|---|
| 371 | annotation (Placement(transformation( |
|---|
| 372 | origin={70,-30}, |
|---|
| 373 | extent={{-10,-10},{10,10}}, |
|---|
| 374 | rotation=270))); |
|---|
| 375 | Modelica.Electrical.Analog.Basic.Ground groundDC |
|---|
| 376 | annotation (Placement(transformation(extent={{80,-80},{100,-60}}, |
|---|
| 377 | rotation=0))); |
|---|
| 378 | equation |
|---|
| 379 | connect(cDC1.n, cDC2.p) |
|---|
| 380 | annotation (Line(points={{70,20},{70,-20}}, color={0,0,255})); |
|---|
| 381 | connect(cDC1.n, groundDC.p) |
|---|
| 382 | annotation (Line(points={{70,20},{70,0},{90,0},{90,-60}}, color={0,0, |
|---|
| 383 | 255})); |
|---|
| 384 | connect(starS.plug_p, sineVoltage.plug_n) |
|---|
| 385 | annotation (Line(points={{-90,-40},{-90,0}}, color={0,0,255})); |
|---|
| 386 | connect(sineVoltage.plug_p, supplyL.plug_p) |
|---|
| 387 | annotation (Line(points={{-70,0},{-52,0}}, color={0,0,255})); |
|---|
| 388 | connect(idealDiode1.plug_p, supplyL.plug_n) |
|---|
| 389 | annotation (Line(points={{10,10},{10,0},{-32,0}}, color={0,0,255})); |
|---|
| 390 | connect(idealDiode2.plug_n, supplyL.plug_n) |
|---|
| 391 | annotation (Line(points={{10,-10},{10,0},{-32,0}}, color={0,0,255})); |
|---|
| 392 | connect(idealDiode1.plug_n, star1.plug_p) |
|---|
| 393 | annotation (Line(points={{10,30},{10,40}}, color={0,0,255})); |
|---|
| 394 | connect(idealDiode2.plug_p, star2.plug_p) |
|---|
| 395 | annotation (Line(points={{10,-30},{10,-40}}, color={0,0,255})); |
|---|
| 396 | connect(star2.pin_n, loadR.n) |
|---|
| 397 | annotation (Line(points={{10,-60},{50,-60},{50,-10}}, color={0,0,255})); |
|---|
| 398 | connect(star2.pin_n, cDC2.n) |
|---|
| 399 | annotation (Line(points={{10,-60},{70,-60},{70,-40}}, color={0,0,255})); |
|---|
| 400 | connect(star1.pin_n,loadR. p) |
|---|
| 401 | annotation (Line(points={{10,60},{50,60},{50,10}}, color={0,0,255})); |
|---|
| 402 | connect(star1.pin_n, cDC1.p) |
|---|
| 403 | annotation (Line(points={{10,60},{70,60},{70,40}}, color={0,0,255})); |
|---|
| 404 | end Rectifier; |
|---|
| 405 | end Examples; |
|---|
| 406 | |
|---|
| 407 | package Basic "Basic components for electrical multiphase models" |
|---|
| 408 | extends Modelica.Icons.Library2; |
|---|
| 409 | annotation (Documentation(info="<HTML> |
|---|
| 410 | <p> |
|---|
| 411 | This package contains basic analog electrical multiphase components. |
|---|
| 412 | </p> |
|---|
| 413 | |
|---|
| 414 | </HTML>", revisions="<html> |
|---|
| 415 | <dl> |
|---|
| 416 | <p> |
|---|
| 417 | <dt><b>Main Authors:</b></dt> |
|---|
| 418 | <dd> |
|---|
| 419 | <a href=\"http://www.haumer.at/\">Anton Haumer</a><br> |
|---|
| 420 | Technical Consulting & Electrical Engineering<br> |
|---|
| 421 | A-3423 St.Andrae-Woerdern<br>Austria<br> |
|---|
| 422 | email: <a href=\"mailto:a.haumer@haumer.at\">a.haumer@haumer.at</a> |
|---|
| 423 | </dd> |
|---|
| 424 | </p> |
|---|
| 425 | <p> |
|---|
| 426 | <dt><b>Release Notes:</b></dt> |
|---|
| 427 | <dd> |
|---|
| 428 | <ul> |
|---|
| 429 | <li> v1.0 2004/10/01 Anton Haumer</li> |
|---|
| 430 | </ul> |
|---|
| 431 | </dd> |
|---|
| 432 | <p> |
|---|
| 433 | <dt><b>Copyright:</b></dt> |
|---|
| 434 | <dd>Copyright © 1998-2006, Modelica Association and Anton Haumer.<br> |
|---|
| 435 | <i>The Modelica package is <b>free</b> software; it can be redistributed and/or modified |
|---|
| 436 | under the terms of the <b>Modelica license</b>, see the license conditions |
|---|
| 437 | and the accompanying <b>disclaimer</b> in the documentation of package |
|---|
| 438 | Modelica in file \"Modelica/package.mo\".</i></dd> |
|---|
| 439 | </p> |
|---|
| 440 | </dl> |
|---|
| 441 | </html>"), Icon(coordinateSystem(preserveAspectRatio=true, extent={{-100,-100}, |
|---|
| 442 | {100,100}}), graphics={ |
|---|
| 443 | Rectangle( |
|---|
| 444 | extent={{-80,-10},{60,-70}}, |
|---|
| 445 | lineColor={0,0,255}, |
|---|
| 446 | fillColor={255,255,255}, |
|---|
| 447 | fillPattern=FillPattern.Solid), |
|---|
| 448 | Line(points={{60,-40},{80,-40}}, color={0,0,255}), |
|---|
| 449 | Line(points={{-100,-40},{-80,-40}}, color={0,0,255})})); |
|---|
| 450 | |
|---|
| 451 | model Star "Star-connection" |
|---|
| 452 | parameter Integer m(final min=1) = 3 "number of phases"; |
|---|
| 453 | Interfaces.PositivePlug plug_p(final m=m) |
|---|
| 454 | annotation (Placement(transformation(extent={{-110,-10},{-90,10}}, |
|---|
| 455 | rotation=0))); |
|---|
| 456 | Modelica.Electrical.Analog.Interfaces.NegativePin pin_n |
|---|
| 457 | annotation (Placement(transformation(extent={{90,-10},{110,10}}, |
|---|
| 458 | rotation=0))); |
|---|
| 459 | annotation (Icon(graphics={ |
|---|
| 460 | Text( |
|---|
| 461 | extent={{-150,60},{150,120}}, |
|---|
| 462 | textString="%name", |
|---|
| 463 | lineColor={0,0,255}), |
|---|
| 464 | Line( |
|---|
| 465 | points={{80,0},{0,0}}, |
|---|
| 466 | thickness=0.5, |
|---|
| 467 | color={0,0,255}), |
|---|
| 468 | Line( |
|---|
| 469 | points={{0,0},{-39,68}}, |
|---|
| 470 | thickness=0.5, |
|---|
| 471 | color={0,0,255}), |
|---|
| 472 | Line( |
|---|
| 473 | points={{0,0},{-38,-69}}, |
|---|
| 474 | thickness=0.5, |
|---|
| 475 | color={0,0,255}), |
|---|
| 476 | Text( |
|---|
| 477 | extent={{-100,-110},{100,-70}}, |
|---|
| 478 | lineColor={0,0,0}, |
|---|
| 479 | textString="m=%m"), |
|---|
| 480 | Line(points={{-90,0},{-40,0}}, color={0,0,255}), |
|---|
| 481 | Line(points={{80,0},{90,0}}, color={0,0,255})}), |
|---|
| 482 | Documentation( |
|---|
| 483 | info="<HTML> |
|---|
| 484 | <p> |
|---|
| 485 | Connects all pins of plug_p to pin_n, thus establishing a so-called star-connection. |
|---|
| 486 | </p> |
|---|
| 487 | </HTML>")); |
|---|
| 488 | |
|---|
| 489 | equation |
|---|
| 490 | for j in |
|---|