-
Notifications
You must be signed in to change notification settings - Fork 5
/
SystemParticipantTestData.groovy
362 lines (337 loc) · 11.2 KB
/
SystemParticipantTestData.groovy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
/*
* © 2021. TU Dortmund University,
* Institute of Energy Systems, Energy Efficiency and Energy Economics,
* Research group Distribution grid planning and operation
*/
package edu.ie3.test.common
import static edu.ie3.datamodel.models.StandardUnits.*
import edu.ie3.datamodel.models.OperationTime
import edu.ie3.datamodel.models.input.EmInput
import edu.ie3.datamodel.models.input.NodeInput
import edu.ie3.datamodel.models.input.OperatorInput
import edu.ie3.datamodel.models.input.container.SystemParticipants
import edu.ie3.datamodel.models.input.system.*
import edu.ie3.datamodel.models.input.system.characteristic.CosPhiFixed
import edu.ie3.datamodel.models.input.system.characteristic.CosPhiP
import edu.ie3.datamodel.models.input.system.characteristic.QV
import edu.ie3.datamodel.models.input.system.characteristic.WecCharacteristicInput
import edu.ie3.datamodel.models.input.system.type.*
import edu.ie3.datamodel.models.input.system.type.chargingpoint.ChargingPointTypeUtils
import edu.ie3.datamodel.models.input.system.type.evcslocation.EvcsLocationType
import edu.ie3.datamodel.models.input.thermal.CylindricalStorageInput
import edu.ie3.datamodel.models.input.thermal.ThermalBusInput
import edu.ie3.datamodel.models.input.thermal.ThermalStorageInput
import edu.ie3.datamodel.models.profile.BdewStandardLoadProfile
import edu.ie3.datamodel.models.profile.StandardLoadProfile
import edu.ie3.util.TimeUtil
import edu.ie3.util.quantities.interfaces.*
import tech.units.indriya.ComparableQuantity
import tech.units.indriya.quantity.Quantities
import javax.measure.quantity.*
class SystemParticipantTestData {
// general participant data
static final OperationTime operationTime = OperationTime.builder()
.withStart(TimeUtil.withDefaults.toZonedDateTime("2020-03-24 15:11:31"))
.withEnd(TimeUtil.withDefaults.toZonedDateTime("2020-03-25 15:11:31")).build()
static final OperatorInput operator = new OperatorInput(
UUID.fromString("8f9682df-0744-4b58-a122-f0dc730f6510"), "TestOperator")
public static final NodeInput participantNode = GridTestData.nodeA
// general type data
static final CosPhiFixed cosPhiFixed = new CosPhiFixed("cosPhiFixed:{(0.0,0.95)}")
private static final CosPhiP cosPhiP = new CosPhiP("cosPhiP:{(0.0,1.0),(0.9,1.0),(1.2,-0.3)}")
private static final QV qV = new QV("qV:{(0.9,-0.3),(0.95,0.0),(1.05,0.0),(1.1,0.3)}")
public static final String cosPhiFixedSerialized = "cosPhiFixed:{(0.0,0.95)}"
public static final String cosPhiPSerialized = "cosPhiP:{(0.0,1.0),(0.9,1.0),(1.2,-0.3)}"
public static final String qVSerialized = "qV:{(0.9,-0.3),(0.95,0.0),(1.05,0.0),(1.1,0.3)}"
static final ComparableQuantity<Power> sRated = Quantities.getQuantity(25d, ACTIVE_POWER_IN)
static final double cosPhiRated = 0.95
private static final UUID typeUuid = UUID.fromString("5ebd8f7e-dedb-4017-bb86-6373c4b68eb8")
private static final ComparableQuantity<Currency> capex = Quantities.getQuantity(100d, CAPEX)
private static final ComparableQuantity<EnergyPrice> opex = Quantities.getQuantity(50d, ENERGY_PRICE)
static final ComparableQuantity<Dimensionless> etaConv = Quantities.getQuantity(98d, EFFICIENCY)
// EmInput
public static final String emControlStrategy = "self_optimization"
public static final EmInput parentEm = new EmInput(
UUID.fromString("897bfc17-8e54-43d0-8d98-740786fd94dd"),
"test_parentEmInput",
SystemParticipantTestData.operator,
SystemParticipantTestData.operationTime,
emControlStrategy,
null
)
public static final EmInput emInput = new EmInput(
UUID.fromString("977157f4-25e5-4c72-bf34-440edc778792"),
"test_emInput",
SystemParticipantTestData.operator,
SystemParticipantTestData.operationTime,
emControlStrategy,
parentEm
)
// FixedFeedInput
public static final FixedFeedInInput fixedFeedInInput = new FixedFeedInInput(
UUID.fromString("717af017-cc69-406f-b452-e022d7fb516a"),
"test_fixedFeedInInput",
operator,
operationTime,
participantNode,
cosPhiFixed,
emInput,
sRated,
cosPhiRated
)
// PV
static final double albedo = 0.20000000298023224d
static final ComparableQuantity<Angle> azimuth = Quantities.getQuantity(-8.926613807678223d, AZIMUTH)
static final ComparableQuantity<Angle> elevationAngle = Quantities.getQuantity(41.01871871948242d, SOLAR_ELEVATION_ANGLE)
static double kT = 1d
static double kG = 0.8999999761581421d
public static final PvInput pvInput = new PvInput(
UUID.fromString("d56f15b7-8293-4b98-b5bd-58f6273ce229"),
"test_pvInput",
operator,
operationTime,
participantNode,
cosPhiFixed,
emInput,
albedo,
azimuth,
etaConv,
elevationAngle,
kG,
kT,
false,
sRated,
cosPhiRated
)
// WEC
private static final WecCharacteristicInput wecCharacteristic = new WecCharacteristicInput("cP:{(10.00,0.05),(15.00,0.10),(20.00,0.20)}")
private static final ComparableQuantity<Area> rotorArea = Quantities.getQuantity(20, ROTOR_AREA)
private static final ComparableQuantity<Length> hubHeight = Quantities.getQuantity(200, HUB_HEIGHT)
public static final WecTypeInput wecType = new WecTypeInput(
typeUuid,
"test_wecType",
capex,
opex,
sRated,
cosPhiRated,
wecCharacteristic,
etaConv,
rotorArea,
hubHeight
)
public static final WecInput wecInput = new WecInput(
UUID.fromString("ee7e2e37-a5ad-4def-a832-26a317567ca1"),
"test_wecInput",
operator,
operationTime,
participantNode,
cosPhiP,
emInput,
wecType,
false
)
// CHP
private static final ComparableQuantity<Dimensionless> etaEl = Quantities.getQuantity(19, EFFICIENCY)
private static final ComparableQuantity<Dimensionless> etaThermal = Quantities.getQuantity(76, EFFICIENCY)
private static final ComparableQuantity<Power> pOwn = Quantities.getQuantity(0, ACTIVE_POWER_IN)
private static final ComparableQuantity<Power> pThermal = Quantities.getQuantity(9, ACTIVE_POWER_IN)
public static final ChpTypeInput chpTypeInput = new ChpTypeInput(
typeUuid,
"test_chpType",
capex,
opex,
etaEl,
etaThermal,
sRated,
cosPhiRated,
pThermal,
pOwn
)
public static final ThermalBusInput thermalBus = new ThermalBusInput(
UUID.fromString("0d95d7f2-49fb-4d49-8636-383a5220384e"),
"test_thermalBusInput",
operator,
operationTime
)
public static final ComparableQuantity<Volume> storageVolumeLvl = Quantities.getQuantity(1.039154027, VOLUME)
public static final ComparableQuantity<Volume> storageVolumeLvlMin = Quantities.getQuantity(0.3, VOLUME)
public static final ComparableQuantity<Temperature> inletTemp = Quantities.getQuantity(110, TEMPERATURE)
public static final ComparableQuantity<Temperature> returnTemp = Quantities.getQuantity(80, TEMPERATURE)
public static final ComparableQuantity<SpecificHeatCapacity> c = Quantities.getQuantity(
1, SPECIFIC_HEAT_CAPACITY)
public static final ThermalStorageInput thermalStorage = new CylindricalStorageInput(
UUID.fromString("8851813b-3a7d-4fee-874b-4df9d724e4b3"),
"test_cylindricThermalStorage",
GridTestData.profBroccoli,
OperationTime.notLimited(),
thermalBus,
storageVolumeLvl,
storageVolumeLvlMin,
inletTemp,
returnTemp,
c
)
public static final ChpInput chpInput = new ChpInput(
UUID.fromString("9981b4d7-5a8e-4909-9602-e2e7ef4fca5c"),
"test_chpInput",
operator,
operationTime,
participantNode,
thermalBus,
cosPhiFixed,
emInput,
chpTypeInput,
thermalStorage,
false
)
// BM
private static final ComparableQuantity<DimensionlessRate> loadGradient = Quantities.getQuantity(25, ACTIVE_POWER_GRADIENT)
public static final BmTypeInput bmTypeInput = new BmTypeInput(
typeUuid,
"test_bmTypeInput",
capex,
opex,
loadGradient,
sRated,
cosPhiRated,
etaConv
)
private static final ComparableQuantity<EnergyPrice> feedInTarif = Quantities.getQuantity(10, ENERGY_PRICE)
public static final BmInput bmInput = new BmInput(
UUID.fromString("d06e5bb7-a3c7-4749-bdd1-4581ff2f6f4d"),
"test_bmInput",
operator,
operationTime,
participantNode,
qV,
emInput,
bmTypeInput,
false,
false,
feedInTarif
)
// EV
private static final ComparableQuantity<Energy> eStorage = Quantities.getQuantity(100, ENERGY_IN)
private static final ComparableQuantity<SpecificEnergy> eCons = Quantities.getQuantity(5, ENERGY_PER_DISTANCE)
private static final ComparableQuantity<Power> sRatedAC = Quantities.getQuantity(20,S_RATED )
private static final ComparableQuantity<Power> sRatedDC = Quantities.getQuantity(20,S_RATED )
public static final EvTypeInput evTypeInput = new EvTypeInput(
typeUuid,
"test_evTypeInput",
capex,
opex,
eStorage,
eCons,
sRated,
cosPhiRated,
sRatedAC,
sRatedDC)
public static final EvInput evInput = new EvInput(
UUID.fromString("a17be20f-c7a7-471d-8ffe-015487c9d022"),
"test_evInput",
operator,
operationTime,
participantNode,
cosPhiFixed,
emInput,
evTypeInput
)
// Load
protected static final ComparableQuantity<Energy> eConsAnnual = Quantities.getQuantity(4000, ENERGY_IN)
protected static final StandardLoadProfile standardLoadProfile = BdewStandardLoadProfile.H0
public static final LoadInput loadInput = new LoadInput(
UUID.fromString("eaf77f7e-9001-479f-94ca-7fb657766f5f"),
"test_loadInput",
operator,
operationTime,
participantNode,
cosPhiFixed,
emInput,
standardLoadProfile,
false,
eConsAnnual,
sRated,
cosPhiRated
)
// Storage
private static final ComparableQuantity<Power> pMax = Quantities.getQuantity(15, ACTIVE_POWER_IN)
private static final ComparableQuantity<Dimensionless> eta = Quantities.getQuantity(95, EFFICIENCY)
private static final ComparableQuantity<Dimensionless> dod = Quantities.getQuantity(10, EFFICIENCY)
private static final ComparableQuantity<DimensionlessRate> cpRate = Quantities.getQuantity(100, ACTIVE_POWER_GRADIENT)
private static final ComparableQuantity<Time> lifeTime = Quantities.getQuantity(175316.4, LIFE_TIME)
private static final int lifeCycle = 100
public static final StorageTypeInput storageTypeInput = new StorageTypeInput(
typeUuid,
"test_storageTypeInput",
capex,
opex,
eStorage,
sRated,
cosPhiRated,
pMax,
cpRate,
eta,
dod,
lifeTime,
lifeCycle
)
public static final StorageInput storageInput = new StorageInput(
UUID.fromString("06b58276-8350-40fb-86c0-2414aa4a0452"),
"test_storageInput",
operator,
operationTime,
participantNode,
cosPhiFixed,
emInput,
storageTypeInput
)
// HP
public static final HpTypeInput hpTypeInput = new HpTypeInput(
typeUuid,
"test_hpTypeInput",
capex,
opex,
sRated,
cosPhiRated,
pThermal
)
public static final HpInput hpInput = new HpInput(
UUID.fromString("798028b5-caff-4da7-bcd9-1750fdd8742b"),
"test_hpInput",
operator,
operationTime,
participantNode,
thermalBus,
cosPhiFixed,
emInput,
hpTypeInput
)
// charging station
public static final boolean v2gSupport = false
public static final evcsInput = new EvcsInput(
UUID.fromString("798028b5-caff-4da7-bcd9-1750fdd8742c"),
"test_csInput",
operator,
operationTime,
participantNode,
cosPhiFixed,
emInput,
ChargingPointTypeUtils.HouseholdSocket,
4,
cosPhiRated,
EvcsLocationType.HOME,
v2gSupport
)
public static SystemParticipants emptySystemParticipants =
new SystemParticipants(
[] as Set,
[] as Set,
[] as Set,
[] as Set,
[] as Set,
[] as Set,
[] as Set,
[] as Set,
[] as Set,
[] as Set)
}