Fixing website and API documentation links
[PyCIM.git] / CIM14 / ENTSOE / Equipment / Generation / Production / GeneratingUnit.py
blob730b711991204f8b406c3254cb1b7b536cca5bbd
1 # Copyright (C) 2010-2011 Richard Lincoln
3 # Permission is hereby granted, free of charge, to any person obtaining a copy
4 # of this software and associated documentation files (the "Software"), to
5 # deal in the Software without restriction, including without limitation the
6 # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
7 # sell copies of the Software, and to permit persons to whom the Software is
8 # furnished to do so, subject to the following conditions:
10 # The above copyright notice and this permission notice shall be included in
11 # all copies or substantial portions of the Software.
13 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
18 # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
19 # IN THE SOFTWARE.
21 from CIM14.ENTSOE.Equipment.Core.Equipment import Equipment
23 class GeneratingUnit(Equipment):
24 """A single or set of synchronous machines for converting mechanical power into alternating-current power. For example, individual machines within a set may be defined for scheduling purposes while a single control signal is derived for the set. In this case there would be a GeneratingUnit for each member of the set and an additional GeneratingUnit corresponding to the set.For the 2010 ENTSOE IOP, this is required for Synchronous Machine. - To define a GeneratingUnit requires defining the initial real power injection, net real power limits, and the status of the unit. The initial injection is defined using the attribute “initialP”. - The net real power limits can be defined in three ways; 1) with the attributes “maxOperatingP” and “minOperatingP”, or 2) with the attribute “ratedNetMaxP” or 3) with the attributes “ratedGrossMinP” and “ratedGrossMaxP” used in conjunction with an associated GrossToNetActivePowerCurve. - The control status of the unit is defined with the attribute “genControlSource”, but it is not required. The participation factor attributes “longPF”, “normalPF”, and “shortPF” are not required. - The GeneratingUnit class should only be used in cases where the more specific classes, HydroGeneratingUnit and ThermalGeneratingUnit, do not apply. - The attributes governorSCD, maximumAllowableSpinningReserve, nominalP, startupCost, and variableCost are not required.
25 """
27 def __init__(self, maxOperatingP=0.0, ratedGrossMaxP=0.0, variableCost=0.0, minOperatingP=0.0, ratedGrossMinP=0.0, shortPF=0.0, ratedNetMaxP=0.0, longPF=0.0, startupCost=0.0, genControlSource="onAGC", nominalP=0.0, governorSCD=0.0, maximumAllowableSpinningReserve=0.0, initialP=0.0, normalPF=0.0, SynchronousMachines=None, ControlAreaGeneratingUnit=None, *args, **kw_args):
28 """Initialises a new 'GeneratingUnit' instance.
30 @param maxOperatingP: This is the maximum operating active power limit the dispatcher can enter for this unit
31 @param ratedGrossMaxP: The unit's gross rated maximum capacity (Book Value).
32 @param variableCost: The variable cost component of production per unit of ActivePower.
33 @param minOperatingP: This is the minimum operating active power limit the dispatcher can enter for this unit.
34 @param ratedGrossMinP: The gross rated minimum generation level which the unit can safely operate at while delivering power to the transmission grid
35 @param shortPF: Generating unit economic participation factor
36 @param ratedNetMaxP: The net rated maximum capacity determined by subtracting the auxiliary power used to operate the internal plant machinery from the rated gross maximum capacity
37 @param longPF: Generating unit economic participation factor
38 @param startupCost: The initial startup cost incurred for each start of the GeneratingUnit.
39 @param genControlSource: The source of controls for a generating unit. Values are: "onAGC", "unavailable", "plantControl", "offAGC"
40 @param nominalP: The nominal power of the generating unit. Used to give precise meaning to percentage based attributes such as the govenor speed change droop (govenorSCD attribute).Should not be null or zero.
41 @param governorSCD: Governor Speed Changer Droop. This is the change in generator power output divided by the change in frequency normalized by the nominal power of the generator and the nominal frequency and expressed in percent and negated. A positive value of speed change droop provides additional generator output upon a drop in frequency.
42 @param maximumAllowableSpinningReserve: Maximum allowable spinning reserve. Spinning reserve will never be considered greater than this value regardless of the current operating point.
43 @param initialP: Default Initial active power which is used to store a powerflow result for the initial active power for this unit in this network configuration
44 @param normalPF: Generating unit economic participation factor
45 @param SynchronousMachines: A synchronous machine may operate as a generator and as such becomes a member of a generating unit
46 @param ControlAreaGeneratingUnit: ControlArea specifications for this generating unit.
47 """
48 #: This is the maximum operating active power limit the dispatcher can enter for this unit
49 self.maxOperatingP = maxOperatingP
51 #: The unit's gross rated maximum capacity (Book Value).
52 self.ratedGrossMaxP = ratedGrossMaxP
54 #: The variable cost component of production per unit of ActivePower.
55 self.variableCost = variableCost
57 #: This is the minimum operating active power limit the dispatcher can enter for this unit.
58 self.minOperatingP = minOperatingP
60 #: The gross rated minimum generation level which the unit can safely operate at while delivering power to the transmission grid
61 self.ratedGrossMinP = ratedGrossMinP
63 #: Generating unit economic participation factor
64 self.shortPF = shortPF
66 #: The net rated maximum capacity determined by subtracting the auxiliary power used to operate the internal plant machinery from the rated gross maximum capacity
67 self.ratedNetMaxP = ratedNetMaxP
69 #: Generating unit economic participation factor
70 self.longPF = longPF
72 #: The initial startup cost incurred for each start of the GeneratingUnit.
73 self.startupCost = startupCost
75 #: The source of controls for a generating unit. Values are: "onAGC", "unavailable", "plantControl", "offAGC"
76 self.genControlSource = genControlSource
78 #: The nominal power of the generating unit. Used to give precise meaning to percentage based attributes such as the govenor speed change droop (govenorSCD attribute).Should not be null or zero.
79 self.nominalP = nominalP
81 #: Governor Speed Changer Droop. This is the change in generator power output divided by the change in frequency normalized by the nominal power of the generator and the nominal frequency and expressed in percent and negated. A positive value of speed change droop provides additional generator output upon a drop in frequency.
82 self.governorSCD = governorSCD
84 #: Maximum allowable spinning reserve. Spinning reserve will never be considered greater than this value regardless of the current operating point.
85 self.maximumAllowableSpinningReserve = maximumAllowableSpinningReserve
87 #: Default Initial active power which is used to store a powerflow result for the initial active power for this unit in this network configuration
88 self.initialP = initialP
90 #: Generating unit economic participation factor
91 self.normalPF = normalPF
93 self._SynchronousMachines = []
94 self.SynchronousMachines = [] if SynchronousMachines is None else SynchronousMachines
96 self._ControlAreaGeneratingUnit = []
97 self.ControlAreaGeneratingUnit = [] if ControlAreaGeneratingUnit is None else ControlAreaGeneratingUnit
99 super(GeneratingUnit, self).__init__(*args, **kw_args)
101 _attrs = ["maxOperatingP", "ratedGrossMaxP", "variableCost", "minOperatingP", "ratedGrossMinP", "shortPF", "ratedNetMaxP", "longPF", "startupCost", "genControlSource", "nominalP", "governorSCD", "maximumAllowableSpinningReserve", "initialP", "normalPF"]
102 _attr_types = {"maxOperatingP": float, "ratedGrossMaxP": float, "variableCost": float, "minOperatingP": float, "ratedGrossMinP": float, "shortPF": float, "ratedNetMaxP": float, "longPF": float, "startupCost": float, "genControlSource": str, "nominalP": float, "governorSCD": float, "maximumAllowableSpinningReserve": float, "initialP": float, "normalPF": float}
103 _defaults = {"maxOperatingP": 0.0, "ratedGrossMaxP": 0.0, "variableCost": 0.0, "minOperatingP": 0.0, "ratedGrossMinP": 0.0, "shortPF": 0.0, "ratedNetMaxP": 0.0, "longPF": 0.0, "startupCost": 0.0, "genControlSource": "onAGC", "nominalP": 0.0, "governorSCD": 0.0, "maximumAllowableSpinningReserve": 0.0, "initialP": 0.0, "normalPF": 0.0}
104 _enums = {"genControlSource": "GeneratorControlSource"}
105 _refs = ["SynchronousMachines", "ControlAreaGeneratingUnit"]
106 _many_refs = ["SynchronousMachines", "ControlAreaGeneratingUnit"]
108 def getSynchronousMachines(self):
109 """A synchronous machine may operate as a generator and as such becomes a member of a generating unit
111 return self._SynchronousMachines
113 def setSynchronousMachines(self, value):
114 for x in self._SynchronousMachines:
115 x.GeneratingUnit = None
116 for y in value:
117 y._GeneratingUnit = self
118 self._SynchronousMachines = value
120 SynchronousMachines = property(getSynchronousMachines, setSynchronousMachines)
122 def addSynchronousMachines(self, *SynchronousMachines):
123 for obj in SynchronousMachines:
124 obj.GeneratingUnit = self
126 def removeSynchronousMachines(self, *SynchronousMachines):
127 for obj in SynchronousMachines:
128 obj.GeneratingUnit = None
130 def getControlAreaGeneratingUnit(self):
131 """ControlArea specifications for this generating unit.
133 return self._ControlAreaGeneratingUnit
135 def setControlAreaGeneratingUnit(self, value):
136 for x in self._ControlAreaGeneratingUnit:
137 x.GeneratingUnit = None
138 for y in value:
139 y._GeneratingUnit = self
140 self._ControlAreaGeneratingUnit = value
142 ControlAreaGeneratingUnit = property(getControlAreaGeneratingUnit, setControlAreaGeneratingUnit)
144 def addControlAreaGeneratingUnit(self, *ControlAreaGeneratingUnit):
145 for obj in ControlAreaGeneratingUnit:
146 obj.GeneratingUnit = self
148 def removeControlAreaGeneratingUnit(self, *ControlAreaGeneratingUnit):
149 for obj in ControlAreaGeneratingUnit:
150 obj.GeneratingUnit = None