]> git.somenet.org - pub/jan/ewbs-dlv.git/blob - c.test7.dl
c updates
[pub/jan/ewbs-dlv.git] / c.test7.dl
1 % testing a control center
2 % noop
3 % In case that L cur < L demand, the control station uses plants with the following priority with respect to their maximal capacity C x with x 2 fpsh; w; fg:
4 %   1. windmill w,
5 %   2. pumped-storage hydropower plant psh, and
6 %   3. fossil-fuel power station f.
7 % The pumped-storage hydropower plant psh can only be used if its storage (indicated via the input i3) is not empty.
8 % The windmill w can only be used under certain circumstances; namely, when the wind speed (which is received on input i4) is between 5 and 40.
9
10 % our plant's types
11 caloric_plant(f). windmill(w). storage_plant(psh).
12
13 % our plant's max values: min + max wind hardcoded (5-40)
14 c_max(f,60). c_max(w,15). c_max(psh,20). charge_max(psh,30).
15
16 control(c).
17
18 % define control i1/L_cur to 10KW
19 c(c,i1,10).
20
21 % define control i2/L_demand to 10KW
22 c(c,i2,10).
23
24 % define control i3/Sstorage to empty
25 c(c,i3,empty).
26
27 % define control i4/Swind to 0
28 c(c,i4,0).
29
30
31 % test definition.
32 % expecting i1 to be 0
33 expect_c(c,i1,0).
34
35 % expecting i2 to be 0
36 expect_c(c,i2,0).
37
38 % expecting i3 to be empty
39 expect_c(c,i3,empty).
40
41 % expecting i4 to be 0
42 expect_c(c,i4,0).
43
44 % and request 0KW
45 expect_p(c,o1,0).
46
47 % and request 0KW
48 expect_p(c,o2,0).
49
50 % and request 0KW
51 expect_p(c,o3,0).
52
53 % do we enable the switching station?
54 expect_p(c,o4,0).
55
56 % and we charge out pumpspeicherkraftwerk with 0KW
57 expect_p(c,o5,0).
58