Adding CDPSM package.
[PyCIM.git] / CIM14 / Dynamics / ExcitationSystems / ExcDC4B.py
blobd1e950b8c3866b9a3fe8d11639998d6d65948325
1 # Copyright (C) 2010 Richard Lincoln
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Lesser General Public License for more details.
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA, USA
17 from CIM14.Dynamics.ExcitationSystems.ExcitationSystem import ExcitationSystem
19 class ExcDC4B(ExcitationSystem):
20 """IEEE (2005) DC4B Model These excitation systems utilize a field-controlled dc commutator exciter with a continuously acting voltage regulator having supplies obtained from the generator or auxiliary bus. The replacement of the controls only as an upgrade (retaining the dc commutator exciter) has resulted in a new model. This excitation system typically includes a proportional, integral, and differential (PID) generator voltage regulator (AVR). An alternative rate feedback loop (<i>kf</i>, <i>tf</i>) for stabilization is also shown in the model if the AVR does not include a derivative term. If a PSS control is supplied, the appropriate model is the Type PSS2B model.
21 """
23 def __init__(self, e1=0.0, se2=0.0, tf=0.0, oelin=0.0, ki=0.0, ta=0.0, vrmax=0.0, tr=0.0, kf=0.0, vrmin=0.0, te=0.0, ka=0.0, kp=0.0, td=0.0, kd=0.0, vemin=0.0, ke=0.0, se1=0.0, e2=0.0, uelin=0.0, *args, **kw_args):
24 """Initialises a new 'ExcDC4B' instance.
26 @param e1: Field voltage value 1 (&gt; 0.)
27 @param se2: Saturation factor at e2 (&gt;= 0.)
28 @param tf: Rate feedback time constant (&gt;= 0.)
29 @param oelin: OEL input: if &lt; 2, LV gate; if = 2, subtract from error signal
30 @param ki: Integral gain (&gt;= 0.)
31 @param ta: Time constant (&gt; 0.)
32 @param vrmax: Maximum controller output
33 @param tr: Filter time constant (&gt;= 0.)
34 @param kf: Rate feedback gain (&gt;= 0.)
35 @param vrmin: Minimum controller output (&lt;= 0.)
36 @param te: Exciter time constant (&gt; 0.)
37 @param ka: Gain (&gt; 0.)
38 @param kp: Proportional gain (&gt;= 0.)
39 @param td: Derivative time constant (&gt; 0. If kd &gt; 0.)
40 @param kd: Derivative gain (&gt;= 0.)
41 @param vemin: Exciter minimum output (&lt;= 0.)
42 @param ke: Exciter field resistance line slope
43 @param se1: Saturation factor at e1 (&gt;= 0.)
44 @param e2: Field voltage value 2. (&gt; 0.)
45 @param uelin: UEL input: if &lt; 2, HV gate; if = 2, add to error signal
46 """
47 #: Field voltage value 1 (&gt; 0.)
48 self.e1 = e1
50 #: Saturation factor at e2 (&gt;= 0.)
51 self.se2 = se2
53 #: Rate feedback time constant (&gt;= 0.)
54 self.tf = tf
56 #: OEL input: if &lt; 2, LV gate; if = 2, subtract from error signal
57 self.oelin = oelin
59 #: Integral gain (&gt;= 0.)
60 self.ki = ki
62 #: Time constant (&gt; 0.)
63 self.ta = ta
65 #: Maximum controller output
66 self.vrmax = vrmax
68 #: Filter time constant (&gt;= 0.)
69 self.tr = tr
71 #: Rate feedback gain (&gt;= 0.)
72 self.kf = kf
74 #: Minimum controller output (&lt;= 0.)
75 self.vrmin = vrmin
77 #: Exciter time constant (&gt; 0.)
78 self.te = te
80 #: Gain (&gt; 0.)
81 self.ka = ka
83 #: Proportional gain (&gt;= 0.)
84 self.kp = kp
86 #: Derivative time constant (&gt; 0. If kd &gt; 0.)
87 self.td = td
89 #: Derivative gain (&gt;= 0.)
90 self.kd = kd
92 #: Exciter minimum output (&lt;= 0.)
93 self.vemin = vemin
95 #: Exciter field resistance line slope
96 self.ke = ke
98 #: Saturation factor at e1 (&gt;= 0.)
99 self.se1 = se1
101 #: Field voltage value 2. (&gt; 0.)
102 self.e2 = e2
104 #: UEL input: if &lt; 2, HV gate; if = 2, add to error signal
105 self.uelin = uelin
107 super(ExcDC4B, self).__init__(*args, **kw_args)
109 _attrs = ["e1", "se2", "tf", "oelin", "ki", "ta", "vrmax", "tr", "kf", "vrmin", "te", "ka", "kp", "td", "kd", "vemin", "ke", "se1", "e2", "uelin"]
110 _attr_types = {"e1": float, "se2": float, "tf": float, "oelin": float, "ki": float, "ta": float, "vrmax": float, "tr": float, "kf": float, "vrmin": float, "te": float, "ka": float, "kp": float, "td": float, "kd": float, "vemin": float, "ke": float, "se1": float, "e2": float, "uelin": float}
111 _defaults = {"e1": 0.0, "se2": 0.0, "tf": 0.0, "oelin": 0.0, "ki": 0.0, "ta": 0.0, "vrmax": 0.0, "tr": 0.0, "kf": 0.0, "vrmin": 0.0, "te": 0.0, "ka": 0.0, "kp": 0.0, "td": 0.0, "kd": 0.0, "vemin": 0.0, "ke": 0.0, "se1": 0.0, "e2": 0.0, "uelin": 0.0}
112 _enums = {}
113 _refs = []
114 _many_refs = []