epyt-flow 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (131) hide show
  1. epyt_flow/EPANET/EPANET/SRC_engines/AUTHORS +28 -0
  2. epyt_flow/EPANET/EPANET/SRC_engines/LICENSE +21 -0
  3. epyt_flow/EPANET/EPANET/SRC_engines/Readme_SRC_Engines.txt +18 -0
  4. epyt_flow/EPANET/EPANET/SRC_engines/enumstxt.h +134 -0
  5. epyt_flow/EPANET/EPANET/SRC_engines/epanet.c +5578 -0
  6. epyt_flow/EPANET/EPANET/SRC_engines/epanet2.c +865 -0
  7. epyt_flow/EPANET/EPANET/SRC_engines/epanet2.def +131 -0
  8. epyt_flow/EPANET/EPANET/SRC_engines/errors.dat +73 -0
  9. epyt_flow/EPANET/EPANET/SRC_engines/funcs.h +193 -0
  10. epyt_flow/EPANET/EPANET/SRC_engines/genmmd.c +1000 -0
  11. epyt_flow/EPANET/EPANET/SRC_engines/hash.c +177 -0
  12. epyt_flow/EPANET/EPANET/SRC_engines/hash.h +28 -0
  13. epyt_flow/EPANET/EPANET/SRC_engines/hydcoeffs.c +1151 -0
  14. epyt_flow/EPANET/EPANET/SRC_engines/hydraul.c +1117 -0
  15. epyt_flow/EPANET/EPANET/SRC_engines/hydsolver.c +720 -0
  16. epyt_flow/EPANET/EPANET/SRC_engines/hydstatus.c +476 -0
  17. epyt_flow/EPANET/EPANET/SRC_engines/include/epanet2.h +431 -0
  18. epyt_flow/EPANET/EPANET/SRC_engines/include/epanet2_2.h +1786 -0
  19. epyt_flow/EPANET/EPANET/SRC_engines/include/epanet2_enums.h +468 -0
  20. epyt_flow/EPANET/EPANET/SRC_engines/inpfile.c +810 -0
  21. epyt_flow/EPANET/EPANET/SRC_engines/input1.c +707 -0
  22. epyt_flow/EPANET/EPANET/SRC_engines/input2.c +864 -0
  23. epyt_flow/EPANET/EPANET/SRC_engines/input3.c +2170 -0
  24. epyt_flow/EPANET/EPANET/SRC_engines/main.c +93 -0
  25. epyt_flow/EPANET/EPANET/SRC_engines/mempool.c +142 -0
  26. epyt_flow/EPANET/EPANET/SRC_engines/mempool.h +24 -0
  27. epyt_flow/EPANET/EPANET/SRC_engines/output.c +852 -0
  28. epyt_flow/EPANET/EPANET/SRC_engines/project.c +1359 -0
  29. epyt_flow/EPANET/EPANET/SRC_engines/quality.c +685 -0
  30. epyt_flow/EPANET/EPANET/SRC_engines/qualreact.c +743 -0
  31. epyt_flow/EPANET/EPANET/SRC_engines/qualroute.c +694 -0
  32. epyt_flow/EPANET/EPANET/SRC_engines/report.c +1489 -0
  33. epyt_flow/EPANET/EPANET/SRC_engines/rules.c +1362 -0
  34. epyt_flow/EPANET/EPANET/SRC_engines/smatrix.c +871 -0
  35. epyt_flow/EPANET/EPANET/SRC_engines/text.h +497 -0
  36. epyt_flow/EPANET/EPANET/SRC_engines/types.h +874 -0
  37. epyt_flow/EPANET/EPANET-MSX/MSX_Updates.txt +53 -0
  38. epyt_flow/EPANET/EPANET-MSX/Src/dispersion.h +27 -0
  39. epyt_flow/EPANET/EPANET-MSX/Src/hash.c +107 -0
  40. epyt_flow/EPANET/EPANET-MSX/Src/hash.h +28 -0
  41. epyt_flow/EPANET/EPANET-MSX/Src/include/epanetmsx.h +102 -0
  42. epyt_flow/EPANET/EPANET-MSX/Src/include/epanetmsx_export.h +42 -0
  43. epyt_flow/EPANET/EPANET-MSX/Src/mathexpr.c +937 -0
  44. epyt_flow/EPANET/EPANET-MSX/Src/mathexpr.h +39 -0
  45. epyt_flow/EPANET/EPANET-MSX/Src/mempool.c +204 -0
  46. epyt_flow/EPANET/EPANET-MSX/Src/mempool.h +24 -0
  47. epyt_flow/EPANET/EPANET-MSX/Src/msxchem.c +1285 -0
  48. epyt_flow/EPANET/EPANET-MSX/Src/msxcompiler.c +368 -0
  49. epyt_flow/EPANET/EPANET-MSX/Src/msxdict.h +42 -0
  50. epyt_flow/EPANET/EPANET-MSX/Src/msxdispersion.c +586 -0
  51. epyt_flow/EPANET/EPANET-MSX/Src/msxerr.c +116 -0
  52. epyt_flow/EPANET/EPANET-MSX/Src/msxfile.c +260 -0
  53. epyt_flow/EPANET/EPANET-MSX/Src/msxfuncs.c +175 -0
  54. epyt_flow/EPANET/EPANET-MSX/Src/msxfuncs.h +35 -0
  55. epyt_flow/EPANET/EPANET-MSX/Src/msxinp.c +1504 -0
  56. epyt_flow/EPANET/EPANET-MSX/Src/msxout.c +401 -0
  57. epyt_flow/EPANET/EPANET-MSX/Src/msxproj.c +791 -0
  58. epyt_flow/EPANET/EPANET-MSX/Src/msxqual.c +2010 -0
  59. epyt_flow/EPANET/EPANET-MSX/Src/msxrpt.c +400 -0
  60. epyt_flow/EPANET/EPANET-MSX/Src/msxtank.c +422 -0
  61. epyt_flow/EPANET/EPANET-MSX/Src/msxtoolkit.c +1164 -0
  62. epyt_flow/EPANET/EPANET-MSX/Src/msxtypes.h +551 -0
  63. epyt_flow/EPANET/EPANET-MSX/Src/msxutils.c +524 -0
  64. epyt_flow/EPANET/EPANET-MSX/Src/msxutils.h +56 -0
  65. epyt_flow/EPANET/EPANET-MSX/Src/newton.c +158 -0
  66. epyt_flow/EPANET/EPANET-MSX/Src/newton.h +34 -0
  67. epyt_flow/EPANET/EPANET-MSX/Src/rk5.c +287 -0
  68. epyt_flow/EPANET/EPANET-MSX/Src/rk5.h +39 -0
  69. epyt_flow/EPANET/EPANET-MSX/Src/ros2.c +293 -0
  70. epyt_flow/EPANET/EPANET-MSX/Src/ros2.h +35 -0
  71. epyt_flow/EPANET/EPANET-MSX/Src/smatrix.c +816 -0
  72. epyt_flow/EPANET/EPANET-MSX/Src/smatrix.h +29 -0
  73. epyt_flow/EPANET/EPANET-MSX/readme.txt +14 -0
  74. epyt_flow/EPANET/compile.sh +4 -0
  75. epyt_flow/VERSION +1 -0
  76. epyt_flow/__init__.py +24 -0
  77. epyt_flow/data/__init__.py +0 -0
  78. epyt_flow/data/benchmarks/__init__.py +11 -0
  79. epyt_flow/data/benchmarks/batadal.py +257 -0
  80. epyt_flow/data/benchmarks/batadal_data.py +28 -0
  81. epyt_flow/data/benchmarks/battledim.py +473 -0
  82. epyt_flow/data/benchmarks/battledim_data.py +51 -0
  83. epyt_flow/data/benchmarks/gecco_water_quality.py +267 -0
  84. epyt_flow/data/benchmarks/leakdb.py +592 -0
  85. epyt_flow/data/benchmarks/leakdb_data.py +18923 -0
  86. epyt_flow/data/benchmarks/water_usage.py +123 -0
  87. epyt_flow/data/networks.py +650 -0
  88. epyt_flow/gym/__init__.py +4 -0
  89. epyt_flow/gym/control_gyms.py +47 -0
  90. epyt_flow/gym/scenario_control_env.py +101 -0
  91. epyt_flow/metrics.py +404 -0
  92. epyt_flow/models/__init__.py +2 -0
  93. epyt_flow/models/event_detector.py +31 -0
  94. epyt_flow/models/sensor_interpolation_detector.py +118 -0
  95. epyt_flow/rest_api/__init__.py +4 -0
  96. epyt_flow/rest_api/base_handler.py +70 -0
  97. epyt_flow/rest_api/res_manager.py +95 -0
  98. epyt_flow/rest_api/scada_data_handler.py +476 -0
  99. epyt_flow/rest_api/scenario_handler.py +352 -0
  100. epyt_flow/rest_api/server.py +106 -0
  101. epyt_flow/serialization.py +438 -0
  102. epyt_flow/simulation/__init__.py +5 -0
  103. epyt_flow/simulation/events/__init__.py +6 -0
  104. epyt_flow/simulation/events/actuator_events.py +259 -0
  105. epyt_flow/simulation/events/event.py +81 -0
  106. epyt_flow/simulation/events/leakages.py +404 -0
  107. epyt_flow/simulation/events/sensor_faults.py +267 -0
  108. epyt_flow/simulation/events/sensor_reading_attack.py +185 -0
  109. epyt_flow/simulation/events/sensor_reading_event.py +170 -0
  110. epyt_flow/simulation/events/system_event.py +88 -0
  111. epyt_flow/simulation/parallel_simulation.py +147 -0
  112. epyt_flow/simulation/scada/__init__.py +3 -0
  113. epyt_flow/simulation/scada/advanced_control.py +134 -0
  114. epyt_flow/simulation/scada/scada_data.py +1589 -0
  115. epyt_flow/simulation/scada/scada_data_export.py +255 -0
  116. epyt_flow/simulation/scenario_config.py +608 -0
  117. epyt_flow/simulation/scenario_simulator.py +1897 -0
  118. epyt_flow/simulation/scenario_visualizer.py +61 -0
  119. epyt_flow/simulation/sensor_config.py +1289 -0
  120. epyt_flow/topology.py +290 -0
  121. epyt_flow/uncertainty/__init__.py +3 -0
  122. epyt_flow/uncertainty/model_uncertainty.py +302 -0
  123. epyt_flow/uncertainty/sensor_noise.py +73 -0
  124. epyt_flow/uncertainty/uncertainties.py +555 -0
  125. epyt_flow/uncertainty/utils.py +206 -0
  126. epyt_flow/utils.py +306 -0
  127. epyt_flow-0.1.0.dist-info/LICENSE +21 -0
  128. epyt_flow-0.1.0.dist-info/METADATA +139 -0
  129. epyt_flow-0.1.0.dist-info/RECORD +131 -0
  130. epyt_flow-0.1.0.dist-info/WHEEL +5 -0
  131. epyt_flow-0.1.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,131 @@
1
+ LIBRARY EPANET2.DLL
2
+
3
+ EXPORTS
4
+ ENaddcontrol = _ENaddcontrol@24
5
+ ENaddcurve = _ENaddcurve@4
6
+ ENaddlink = _ENaddlink@20
7
+ ENaddnode = _ENaddnode@12
8
+ ENadddemand = _ENadddemand@16
9
+ ENaddpattern = _ENaddpattern@4
10
+ ENaddrule = _ENaddrule@4
11
+ ENclearreport = _ENclearreport@0
12
+ ENclose = _ENclose@0
13
+ ENcloseH = _ENcloseH@0
14
+ ENcloseQ = _ENcloseQ@0
15
+ ENcopyreport = _ENcopyreport@4
16
+ ENdeletecontrol = _ENdeletecontrol@4
17
+ ENdeletecurve = _ENdeletecurve@4
18
+ ENdeletedemand = _ENdeletedemand@8
19
+ ENdeletelink = _ENdeletelink@8
20
+ ENdeletenode = _ENdeletenode@8
21
+ ENdeletepattern = _ENdeletepattern@4
22
+ ENdeleterule = _ENdeleterule@4
23
+ ENepanet = _ENepanet@16
24
+ ENgetaveragepatternvalue = _ENgetaveragepatternvalue@8
25
+ ENgetbasedemand = _ENgetbasedemand@12
26
+ ENgetcomment = _ENgetcomment@12
27
+ ENgetcontrol = _ENgetcontrol@24
28
+ ENgetcoord = _ENgetcoord@12
29
+ ENgetcount = _ENgetcount@8
30
+ ENgetcurve = _ENgetcurve@20
31
+ ENgetcurveid = _ENgetcurveid@8
32
+ ENgetcurveindex = _ENgetcurveindex@8
33
+ ENgetcurvelen = _ENgetcurvelen@8
34
+ ENgetcurvetype = _ENgetcurvetype@8
35
+ ENgetcurvevalue = _ENgetcurvevalue@16
36
+ ENgetdemandindex = _ENgetdemandindex@12
37
+ ENgetdemandmodel = _ENgetdemandmodel@16
38
+ ENgetdemandname = _ENgetdemandname@12
39
+ ENgetdemandpattern = _ENgetdemandpattern@12
40
+ ENgetelseaction = _ENgetelseaction@20
41
+ ENgeterror = _ENgeterror@12
42
+ ENgetflowunits = _ENgetflowunits@4
43
+ ENgetheadcurveindex = _ENgetheadcurveindex@8
44
+ ENgetlinkid = _ENgetlinkid@8
45
+ ENgetlinkindex = _ENgetlinkindex@8
46
+ ENgetlinknodes = _ENgetlinknodes@12
47
+ ENsetlinknodes = _ENsetlinknodes@12
48
+ ENgetlinktype = _ENgetlinktype@8
49
+ ENgetlinkvalue = _ENgetlinkvalue@12
50
+ ENgetnodeid = _ENgetnodeid@8
51
+ ENgetnodeindex = _ENgetnodeindex@8
52
+ ENgetnodetype = _ENgetnodetype@8
53
+ ENgetnodevalue = _ENgetnodevalue@12
54
+ ENgetnumdemands = _ENgetnumdemands@8
55
+ ENgetoption = _ENgetoption@8
56
+ ENgetpatternid = _ENgetpatternid@8
57
+ ENgetpatternindex = _ENgetpatternindex@8
58
+ ENgetpatternlen = _ENgetpatternlen@8
59
+ ENgetpatternvalue = _ENgetpatternvalue@12
60
+ ENgetpremise = _ENgetpremise@36
61
+ ENgetpumptype = _ENgetpumptype@8
62
+ ENgetqualinfo = _ENgetqualinfo@16
63
+ ENgetqualtype = _ENgetqualtype@8
64
+ ENgetresultindex = _ENgetresultindex@12
65
+ ENgetrule = _ENgetrule@20
66
+ ENgetruleID = _ENgetruleID@8
67
+ ENgetstatistic = _ENgetstatistic@8
68
+ ENgetthenaction = _ENgetthenaction@20
69
+ ENgettimeparam = _ENgettimeparam@8
70
+ ENgettitle = _ENgettitle@12
71
+ ENgetversion = _ENgetversion@4
72
+ ENgetvertex = _ENgetvertex@16
73
+ ENgetvertexcount = _ENgetvertexcount@8
74
+ ENinit = _ENinit@16
75
+ ENinitH = _ENinitH@4
76
+ ENinitQ = _ENinitQ@4
77
+ ENnextH = _ENnextH@4
78
+ ENnextQ = _ENnextQ@4
79
+ ENopen = _ENopen@12
80
+ ENopenH = _ENopenH@0
81
+ ENopenQ = _ENopenQ@0
82
+ ENreport = _ENreport@0
83
+ ENresetreport = _ENresetreport@0
84
+ ENrunH = _ENrunH@4
85
+ ENrunQ = _ENrunQ@4
86
+ ENsaveH = _ENsaveH@0
87
+ ENsavehydfile = _ENsavehydfile@4
88
+ ENsaveinpfile = _ENsaveinpfile@4
89
+ ENsetbasedemand = _ENsetbasedemand@12
90
+ ENsetcomment = _ENsetcomment@12
91
+ ENsetcontrol = _ENsetcontrol@24
92
+ ENsetcoord = _ENsetcoord@20
93
+ ENsetcurve = _ENsetcurve@16
94
+ ENsetcurveid = _ENsetcurveid@8
95
+ ENsetcurvevalue = _ENsetcurvevalue@16
96
+ ENsetdemandmodel = _ENsetdemandmodel@16
97
+ ENsetdemandname = _ENsetdemandname@12
98
+ ENsetdemandpattern = _ENsetdemandpattern@12
99
+ ENsetelseaction = _ENsetelseaction@20
100
+ ENsetflowunits = _ENsetflowunits@4
101
+ ENsetheadcurveindex = _ENsetheadcurveindex@8
102
+ ENsetjuncdata = _ENsetjuncdata@16
103
+ ENsetlinkid = _ENsetlinkid@8
104
+ ENsetlinknodes = _ENsetlinknodes@12
105
+ ENsetlinktype = _ENsetlinktype@12
106
+ ENsetlinkvalue = _ENsetlinkvalue@12
107
+ ENsetnodeid = _ENsetnodeid@8
108
+ ENsetnodevalue = _ENsetnodevalue@12
109
+ ENsetoption = _ENsetoption@8
110
+ ENsetpattern = _ENsetpattern@12
111
+ ENsetpatternid = _ENsetpatternid@8
112
+ ENsetpatternvalue = _ENsetpatternvalue@12
113
+ ENsetpipedata = _ENsetpipedata@20
114
+ ENsetpremise = _ENsetpremise@36
115
+ ENsetpremiseindex = _ENsetpremiseindex@12
116
+ ENsetpremisestatus = _ENsetpremisestatus@12
117
+ ENsetpremisevalue = _ENsetpremisevalue@12
118
+ ENsetqualtype = _ENsetqualtype@16
119
+ ENsetreport = _ENsetreport@4
120
+ ENsetrulepriority = _ENsetrulepriority@8
121
+ ENsetstatusreport = _ENsetstatusreport@4
122
+ ENsettankdata = _ENsettankdata@32
123
+ ENsetthenaction = _ENsetthenaction@20
124
+ ENsettimeparam = _ENsettimeparam@8
125
+ ENsettitle = _ENsettitle@12
126
+ ENsetvertices = _ENsetvertices@16
127
+ ENsolveH = _ENsolveH@0
128
+ ENsolveQ = _ENsolveQ@0
129
+ ENstepQ = _ENstepQ@4
130
+ ENusehydfile = _ENusehydfile@4
131
+ ENwriteline = _ENwriteline@4
@@ -0,0 +1,73 @@
1
+ //EPANET 2 Error Messages
2
+ DAT(0,"ok")
3
+ DAT(101,"insufficient memory available")
4
+ DAT(102,"no network data available")
5
+ DAT(103,"hydraulic solver not opened")
6
+ DAT(104,"no hydraulics for water quality analysis")
7
+ DAT(105,"water quality solver not opened")
8
+ DAT(106,"no results saved to report on")
9
+ DAT(107,"hydraulics supplied from external file")
10
+ DAT(108,"cannot use external file while hydraulics solver is active")
11
+ DAT(110,"cannot solve network hydraulic equations")
12
+ DAT(120,"cannot solve water quality transport equations")
13
+
14
+ // These errors apply only to an input file
15
+ DAT(200,"one or more errors in input file")
16
+ DAT(201,"syntax error")
17
+
18
+ // These errors apply to both an input file and to API functions
19
+ DAT(202,"illegal numeric value")
20
+ DAT(203,"undefined node")
21
+ DAT(204,"undefined link")
22
+ DAT(205,"undefined time pattern")
23
+ DAT(206,"undefined curve")
24
+ DAT(207,"attempt to control CV/GPV link")
25
+ DAT(208,"illegal PDA pressure limits")
26
+ DAT(209,"illegal node property value")
27
+ DAT(211,"illegal link property value")
28
+ DAT(212,"undefined trace node")
29
+ DAT(213,"invalid option value")
30
+ DAT(214,"too many characters in input line")
31
+ DAT(215,"duplicate ID label")
32
+ DAT(216,"reference to undefined pump")
33
+ DAT(217,"invalid pump energy data")
34
+ DAT(219,"illegal valve connection to tank node")
35
+ DAT(220,"illegal valve connection to another valve")
36
+ DAT(221,"mis-placed rule clause in rule-based control")
37
+ DAT(222,"same start and end nodes for link")
38
+
39
+ // These errors apply to network consistency check
40
+ DAT(223,"not enough nodes in network")
41
+ DAT(224,"no tanks or reservoirs in network")
42
+ DAT(225,"invalid lower/upper levels for tank")
43
+ DAT(226,"no head curve or power rating for pump")
44
+ DAT(227,"invalid head curve for pump")
45
+ DAT(230,"nonincreasing x-values for curve")
46
+ DAT(233,"network has unconnected node")
47
+
48
+ // These errors apply only to API functions
49
+ DAT(240,"nonexistent source")
50
+ DAT(241,"nonexistent control")
51
+ DAT(250,"invalid format")
52
+ DAT(251,"invalid parameter code")
53
+ DAT(252,"invalid ID name")
54
+ DAT(253,"nonexistent demand category")
55
+ DAT(254,"node with no coordinates")
56
+ DAT(255,"invalid link vertex")
57
+ DAT(257,"nonexistent rule")
58
+ DAT(258,"nonexistent rule clause")
59
+ DAT(259,"attempt to delete a node that still has links connected to it")
60
+ DAT(260,"attempt to delete node assigned as a Trace Node")
61
+ DAT(261,"attempt to delete a node or link contained in a control")
62
+ DAT(262,"attempt to modify network structure while solver is active")
63
+
64
+ // File errors
65
+ DAT(301,"identical file names")
66
+ DAT(302,"cannot open input file")
67
+ DAT(303,"cannot open report file")
68
+ DAT(304,"cannot open binary output file")
69
+ DAT(305,"cannot open hydraulics file")
70
+ DAT(306,"hydraulics file does not match network data")
71
+ DAT(307,"cannot read hydraulics file")
72
+ DAT(308,"cannot save results to file")
73
+ DAT(309,"cannot save results to report file")
@@ -0,0 +1,193 @@
1
+ /*
2
+ ******************************************************************************
3
+ Project: OWA EPANET
4
+ Version: 2.2
5
+ Module: funcs.h
6
+ Description: prototypes of external functions called by various modules
7
+ Authors: see AUTHORS
8
+ Copyright: see AUTHORS
9
+ License: see LICENSE
10
+ Last Updated: 11/15/2019
11
+ ******************************************************************************
12
+ */
13
+ #ifndef FUNCS_H
14
+ #define FUNCS_H
15
+
16
+ // ------- PROJECT.C ------------
17
+
18
+ void initpointers(Project *);
19
+ int allocdata(Project *);
20
+ void freedata(Project *);
21
+
22
+ int openfiles(Project *, const char *, const char *,const char *);
23
+ int openhydfile(Project *);
24
+ int openoutfile(Project *);
25
+ void closeoutfile(Project *);
26
+
27
+ int buildadjlists(Network *);
28
+ void freeadjlists(Network *);
29
+
30
+ int incontrols(Project *, int, int);
31
+ int valvecheck(Project *, int, int, int, int);
32
+ int findnode(Network *, char *);
33
+ int findlink(Network *, char *);
34
+ int findtank(Network *, int);
35
+ int findvalve(Network *, int);
36
+ int findpump(Network *, int);
37
+ int findpattern(Network *, char *);
38
+ int findcurve(Network *, char *);
39
+
40
+ Pdemand finddemand(Pdemand, int);
41
+ int adddemand(Snode *, double, int, char *);
42
+ void freedemands(Snode *);
43
+
44
+ int addlinkvertex(Slink *, double, double);
45
+ void freelinkvertices(Slink *);
46
+
47
+ void adjustpatterns(Network *, int);
48
+ void adjustcurves(Network *, int);
49
+ int adjustpumpparams(Project *, int);
50
+ int resizecurve(Scurve *, int);
51
+
52
+ int getcomment(Network *, int, int, char *);
53
+ int setcomment(Network *, int, int, const char *);
54
+
55
+ int namevalid(const char *);
56
+ void getTmpName(char *);
57
+ char *xstrcpy(char **, const char *, const size_t n);
58
+ int strcomp(const char *, const char *);
59
+ double interp(int, double [], double [], double);
60
+ char *geterrmsg(int, char *);
61
+ void errmsg(Project *, int);
62
+ void writewin(void (*vp)(char *), char *);
63
+
64
+ // ------- INPUT1.C ----------------
65
+
66
+ int getdata(Project *);
67
+ void setdefaults(Project *);
68
+ void initreport(Report *);
69
+ void adjustdata(Project *);
70
+ int inittanks(Project *);
71
+ void initunits(Project *);
72
+ void convertunits(Project *);
73
+
74
+ //-------- INPUT2.C -----------------
75
+
76
+ int netsize(Project *);
77
+ int readdata(Project *);
78
+ int updatepumpparams(Project *, int);
79
+ int findmatch(char *, char *[]);
80
+ int match(const char *, const char *);
81
+ int gettokens(char *, char **, int, char *);
82
+ int getfloat(char *, double *);
83
+ double hour(char *, char *);
84
+ int setreport(Project *, char *);
85
+
86
+ // ------- INPUT3.C -----------------
87
+
88
+ int juncdata(Project *);
89
+ int tankdata(Project *);
90
+ int pipedata(Project *);
91
+ int pumpdata(Project *);
92
+ int valvedata(Project *);
93
+ int patterndata(Project *);
94
+ int curvedata(Project *);
95
+ int coordata(Project *);
96
+ int demanddata(Project *);
97
+ int controldata(Project *);
98
+ int energydata(Project *);
99
+ int sourcedata(Project *);
100
+ int emitterdata(Project *);
101
+ int qualdata(Project *);
102
+ int reactdata(Project *);
103
+ int mixingdata(Project *);
104
+ int statusdata(Project *);
105
+ int reportdata(Project *);
106
+ int timedata(Project *);
107
+ int optiondata(Project *);
108
+ int vertexdata(Project *);
109
+
110
+ // ------- RULES.C ------------------
111
+
112
+ void initrules(Project *);
113
+ void addrule(Parser *, char *);
114
+ void deleterule(Project *, int);
115
+ int allocrules(Project *);
116
+ void freerules(Project *);
117
+ int ruledata(Project *);
118
+ void ruleerrmsg(Project *);
119
+ void adjustrules(Project *, int, int);
120
+ void adjusttankrules(Project *);
121
+ Spremise *getpremise(Spremise *, int);
122
+ Saction *getaction(Saction *, int);
123
+ int writerule(Project *, FILE *, int);
124
+ int checkrules(Project *, long);
125
+
126
+ // ------- REPORT.C -----------------
127
+
128
+ int clearreport(Project *);
129
+ int copyreport(Project *, char *);
130
+ int writereport(Project *);
131
+ void writelogo(Project *);
132
+ void writesummary(Project *);
133
+ void writehydstat(Project *, int, double);
134
+ void writeheader(Project *, int,int);
135
+ void writeline(Project *, char *);
136
+ void writerelerr(Project *, int, double);
137
+ void writestatchange(Project *, int,char,char);
138
+ void writecontrolaction(Project *, int, int);
139
+ void writeruleaction(Project *, int, char *);
140
+ int writehydwarn(Project *, int,double);
141
+ void writehyderr(Project *, int);
142
+ void writemassbalance(Project *);
143
+ void writetime(Project *, char *);
144
+ char *clocktime(char *, long);
145
+
146
+ // ------- HYDRAUL.C -----------------
147
+
148
+ int openhyd(Project *);
149
+ void inithyd(Project *, int initFlags);
150
+ int runhyd(Project *, long *);
151
+ int nexthyd(Project *, long *);
152
+ void closehyd(Project *);
153
+ void setlinkstatus(Project *, int, char, StatusType *, double *);
154
+ void setlinksetting(Project *, int, double, StatusType *, double *);
155
+ int tanktimestep(Project *, long *);
156
+ void getenergy(Project *, int, double *, double *);
157
+ double tankvolume(Project *, int, double);
158
+ double tankgrade(Project *, int, double);
159
+
160
+ // ------- HYDCOEFFS.C -----------------
161
+
162
+ void resistcoeff(Project *, int);
163
+ void headlosscoeffs(Project *);
164
+ void matrixcoeffs(Project *);
165
+ void emitterheadloss(Project *, int, double *, double *);
166
+ void demandheadloss(Project *, int, double, double, double *, double *);
167
+
168
+ // ------- QUALITY.C --------------------
169
+
170
+ int openqual(Project *);
171
+ int initqual(Project *);
172
+ int runqual(Project *, long *);
173
+ int nextqual(Project *, long *);
174
+ int stepqual(Project *, long *);
175
+ int closequal(Project *);
176
+ double avgqual(Project *, int);
177
+
178
+ // ------- OUTPUT.C ---------------------
179
+
180
+ int savenetdata(Project *);
181
+ int savehyd(Project *, long *);
182
+ int savehydstep(Project *, long *);
183
+ int saveenergy(Project *);
184
+ int readhyd(Project *, long *);
185
+ int readhydstep(Project *, long *);
186
+ int saveoutput(Project *);
187
+ int savefinaloutput(Project *);
188
+
189
+ // ------- INPFILE.C --------------------
190
+
191
+ int saveinpfile(Project *, const char *);
192
+
193
+ #endif