ningshuxia
2024-03-20 785c92f5078cb7aeb05b13f6da627defb6525b36
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
using IStation.Epanet.Enums;
 
namespace IStation.Epanet.Network.Structures
{
 
    public class Reservoir : Node
    {
        public Reservoir(string name) : base(name) { }
 
        public override void ConvertUnits(Network nw)
        {
            // FIXME:Tanks and reservoirs here?
 
            FieldsMap fMap = nw.FieldsMap;
 
            // ... convert from user to internal units
            double ucfLength = fMap.GetUnits(FieldType.ELEV);
            Elevation /= ucfLength;
            Head = Elevation + Head / ucfLength;
        }
 
        public override NodeType NodeType => NodeType.Reservoir;
 
 
        ///<summary>基准</summary>
        public double Head { get; set; }
 
        ///<summary>Fixed grade time pattern.</summary>
        public Pattern Pattern { get; set; }
    }
 
}