From 5b3d75cc0da9d3e80cba2dc180d9e4c1e3e63da6 Mon Sep 17 00:00:00 2001 From: Lew Rossman Date: Tue, 16 Aug 2022 13:13:39 -0400 Subject: [PATCH] Updated language binding files added. --- doc/input-file.dox | 5 +++-- include/epanet.cs | 5 +++++ include/epanet2.bas | 5 ++++- include/epanet2.pas | 7 +++++-- include/epanet2.vb | 5 ++++- 5 files changed, 21 insertions(+), 6 deletions(-) diff --git a/doc/input-file.dox b/doc/input-file.dox index c0b69f5..f4d36ce 100644 --- a/doc/input-file.dox +++ b/doc/input-file.dox @@ -1045,8 +1045,9 @@ __Remarks:__ |GPV (general purpose valve) | ID of head loss curve | 2. Shutoff valves and check valves are considered to be part of a pipe, not a separate control valve component (see @ref PipesPage). 3. The loss coefficient setting for a TCV should not be less than its fully open loss coefficient. -4. The characteristic curve for a PCV relates the valve's fraction of fully open flow to the fraction open. -5. The head loss curve for a GPV relates head loss across the valve to the flow rate through it. +4. The characteristic curve for a PCV relates the valve's fraction of fully open flow to the fraction open. If not supplied then a linear curve is assumed. +5. The partially opened loss coefficient for a PCV is the inverse of the squared value from its characteristic curve times the fully open loss coefficient. +6. The head loss curve for a GPV relates head loss across the valve to the flow rate through it. */ /** diff --git a/include/epanet.cs b/include/epanet.cs index 2cec376..68489e6 100644 --- a/include/epanet.cs +++ b/include/epanet.cs @@ -73,6 +73,9 @@ namespace EpanetCSharpLibrary public const int EN_PUMP_ECURVE = 20; public const int EN_PUMP_ECOST = 21; public const int EN_PUMP_EPAT = 22; + public const int EN_LINK_INCONTROL = 23; + public const int EN_GPV_CURVE = 24; + public const int EN_PCV_CURVE = 25; public const int EN_DURATION = 0; //Time parameters public const int EN_HYDSTEP = 1; @@ -126,6 +129,7 @@ namespace EpanetCSharpLibrary public const int EN_FCV = 6; public const int EN_TCV = 7; public const int EN_GPV = 8; + public const int EN_PCV = 9; public const int EN_NONE = 0; //Quality analysis types public const int EN_CHEM = 1; @@ -209,6 +213,7 @@ namespace EpanetCSharpLibrary public const int EN_EFFIC_CURVE = 2; //Efficiency curve public const int EN_HLOSS_CURVE = 3; //Head loss curve public const int EN_GENERIC_CURVE = 4; //Generic curve + public const int EN_VALVE_CURVE = 5; //Valve position curve public const int EN_UNCONDITIONAL = 0; //Unconditional object deletion public const int EN_CONDITIONAL = 1; //Conditional object deletion diff --git a/include/epanet2.bas b/include/epanet2.bas index c38003e..bc2ce1e 100644 --- a/include/epanet2.bas +++ b/include/epanet2.bas @@ -5,7 +5,7 @@ Attribute VB_Name = "Module1" 'Declarations of functions in the EPANET PROGRAMMERs TOOLKIT '(EPANET2.DLL) -'Last updated on 02/01/2020 +'Last updated on 07/28/2022 ' These are codes used by the DLL functions Public Const EN_ELEVATION = 0 ' Node parameters @@ -63,6 +63,7 @@ Public Const EN_PUMP_ECOST = 21 Public Const EN_PUMP_EPAT = 22 Public Const EN_LINK_INCONTROL = 23 Public Const EN_GPV_CURVE = 24 +Public Const EN_PCV_CURVE= 25 Public Const EN_DURATION = 0 ' Time parameters Public Const EN_HYDSTEP = 1 @@ -117,6 +118,7 @@ Public Const EN_PBV = 5 Public Const EN_FCV = 6 Public Const EN_TCV = 7 Public Const EN_GPV = 8 +Public Const EN_PCV = 9 Public Const EN_CLOSED = 0 ' Link status types Public Const EN_OPEN = 1 @@ -209,6 +211,7 @@ Public Const EN_PUMP_CURVE = 1 ' Pump curve Public Const EN_EFFIC_CURVE = 2 ' Efficiency curve Public Const EN_HLOSS_CURVE = 3 ' Head loss curve Public Const EN_GENERIC_CURVE = 4 ' Generic curve +Public Const EN_VALVE_CURVE = 5 ' Valve position curve Public Const EN_UNCONDITIONAL = 0 ' Unconditional object deletion Public Const EN_CONDITIONAL = 1 ' Conditional object deletion diff --git a/include/epanet2.pas b/include/epanet2.pas index cbba41e..fba8147 100644 --- a/include/epanet2.pas +++ b/include/epanet2.pas @@ -3,7 +3,7 @@ unit epanet2; { Declarations of imported procedures from the EPANET PROGRAMMERs TOOLKIT } { (EPANET2.DLL) } -{Last updated on 02/01/2020} +{Last updated on 07/28/2022} interface @@ -69,6 +69,7 @@ const EN_PUMP_EPAT = 22; EN_LINK_INCONTROL = 23; EN_GPV_CURVE = 24; + EN_PCV_CURVE = 25; EN_DURATION = 0; { Time parameters } EN_HYDSTEP = 1; @@ -123,6 +124,7 @@ const EN_FCV = 6; EN_TCV = 7; EN_GPV = 8; + EN_PCV = 9; EN_CLOSED = 0; { Link status types } EN_OPEN = 1; @@ -214,7 +216,8 @@ const EN_PUMP_CURVE = 1; EN_EFFIC_CURVE = 2; EN_HLOSS_CURVE = 3; - EN_GENERIC_CURVE = 4; + EN_GENERIC_CURVE = 4; + EN_VALVE_CURVE = 5; EN_UNCONDITIONAL = 0; { Deletion action codes } EN_CONDITIONAL = 1; diff --git a/include/epanet2.vb b/include/epanet2.vb index bbd365e..7c283f0 100644 --- a/include/epanet2.vb +++ b/include/epanet2.vb @@ -4,7 +4,7 @@ 'Declarations of functions in the EPANET PROGRAMMERs TOOLKIT '(EPANET2.DLL) for use with VB.Net. -'Last updated on 02/01/2020 +'Last updated on 07/28/2022 Imports System.Runtime.InteropServices Imports System.Text @@ -67,6 +67,7 @@ Public Const EN_PUMP_ECOST = 21 Public Const EN_PUMP_EPAT = 22 Public Const EN_LINK_INCONTROL = 23 Public Const EN_GPV_CURVE = 24 +Public Const EN_PCV_CURVE = 25 Public Const EN_DURATION = 0 ' Time parameters Public Const EN_HYDSTEP = 1 @@ -120,6 +121,7 @@ Public Const EN_PBV = 5 Public Const EN_FCV = 6 Public Const EN_TCV = 7 Public Const EN_GPV = 8 +Public Const EN_PCV = 9 Public Const EN_NONE = 0 ' Quality analysis types Public Const EN_CHEM = 1 @@ -203,6 +205,7 @@ Public Const EN_PUMP_CURVE = 1 ' Pump curve Public Const EN_EFFIC_CURVE = 2 ' Efficiency curve Public Const EN_HLOSS_CURVE = 3 ' Head loss curve Public Const EN_GENERIC_CURVE = 4 ' Generic curve +Public Const EN_VALVE_CURVE = 5 ' Valve position curve Public Const EN_UNCONDITIONAL = 0 ' Unconditional object deletion Public Const EN_CONDITIONAL = 1 ' Conditional object deletion