Name | Description |
---|---|
baseFlow | Base class for pump flow characteristics |
basePower | Base class for pump power consumption characteristics |
baseEfficiency | Base class for efficiency characteristics |
linearFlow | Linear flow characteristic |
quadraticFlow | Quadratic flow characteristic |
polynomialFlow | Polynomial flow characteristic |
constantEfficiency | Constant efficiency characteristic |
linearPower | Linear power consumption characteristic |
quadraticPower | Quadratic power consumption characteristic |
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] |
Type | Name | Description |
---|---|---|
Height | head | Pump head [m] |
partial function baseFlow "Base class for pump flow characteristics" extends Modelica.Icons.Function; input SI.VolumeFlowRate V_flow "Volumetric flow rate"; output SI.Height head "Pump head"; end baseFlow;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] |
Type | Name | Description |
---|---|---|
Power | consumption | Power consumption [W] |
partial function basePower "Base class for pump power consumption characteristics" extends Modelica.Icons.Function; input SI.VolumeFlowRate V_flow "Volumetric flow rate"; output SI.Power consumption "Power consumption"; end basePower;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] |
Type | Name | Description |
---|---|---|
Real | eta | Efficiency |
partial function baseEfficiency "Base class for efficiency characteristics" extends Modelica.Icons.Function; input SI.VolumeFlowRate V_flow "Volumetric flow rate"; output Real eta "Efficiency"; end baseEfficiency;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] | |
VolumeFlowRate | V_flow_nominal[2] | Volume flow rate for two operating points (single pump) [m3/s] | |
Height | head_nominal[2] | Pump head for two operating points [m] |
Type | Name | Description |
---|---|---|
Height | head | Pump head [m] |
function linearFlow "Linear flow characteristic" extends baseFlow; input SI.VolumeFlowRate V_flow_nominal[2] "Volume flow rate for two operating points (single pump)"; input SI.Height head_nominal[2] "Pump head for two operating points"; /* Linear system to determine the coefficients: head_nominal[1] = c[1] + V_flow_nominal[1]*c[2]; head_nominal[2] = c[1] + V_flow_nominal[2]*c[2]; */ protected Real c[2] = Modelica.Math.Matrices.solve([ones(2),V_flow_nominal],head_nominal) "Coefficients of linear head curve"; algorithm // Flow equation: head = q*c[1] + c[2]; head := c[1] + V_flow*c[2]; end linearFlow;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] | |
VolumeFlowRate | V_flow_nominal[3] | Volume flow rate for three operating points (single pump) [m3/s] | |
Height | head_nominal[3] | Pump head for three operating points [m] |
Type | Name | Description |
---|---|---|
Height | head | Pump head [m] |
function quadraticFlow "Quadratic flow characteristic" extends baseFlow; input SI.VolumeFlowRate V_flow_nominal[3] "Volume flow rate for three operating points (single pump)"; input SI.Height head_nominal[3] "Pump head for three operating points"; protected Real V_flow_nominal2[3] = {V_flow_nominal[1]^2,V_flow_nominal[2]^2, V_flow_nominal[3]^2} "Squared nominal flow rates"; /* Linear system to determine the coefficients: head_nominal[1] = c[1] + V_flow_nominal[1]*c[2] + V_flow_nominal[1]^2*c[3]; head_nominal[2] = c[1] + V_flow_nominal[2]*c[2] + V_flow_nominal[2]^2*c[3]; head_nominal[3] = c[1] + V_flow_nominal[3]*c[2] + V_flow_nominal[3]^2*c[3]; */ Real c[3] = Modelica.Math.Matrices.solve([ones(3), V_flow_nominal, V_flow_nominal2],head_nominal) "Coefficients of quadratic head curve"; algorithm // Flow equation: head = c[1] + V_flow*c[2] + V_flow^2*c[3]; head := c[1] + V_flow*c[2] + V_flow^2*c[3]; end quadraticFlow;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] | |
VolumeFlowRate | V_flow_nominal[:] | Volume flow rate for N operating points (single pump) [m3/s] | |
Height | head_nominal[:] | Pump head for N operating points [m] |
Type | Name | Description |
---|---|---|
Height | head | Pump head [m] |
function polynomialFlow "Polynomial flow characteristic" extends baseFlow; input SI.VolumeFlowRate V_flow_nominal[:] "Volume flow rate for N operating points (single pump)"; input SI.Height head_nominal[:] "Pump head for N operating points"; protected Integer N = size(V_flow_nominal,1) "Number of nominal operating points"; Real V_flow_nominal_pow[N,N] = {{V_flow_nominal[i]^(j-1) for j in 1:N} for i in 1:N} "Rows: different operating points; columns: increasing powers"; /* Linear system to determine the coefficients (example N=3): head_nominal[1] = c[1] + V_flow_nominal[1]*c[2] + V_flow_nominal[1]^2*c[3]; head_nominal[2] = c[1] + V_flow_nominal[2]*c[2] + V_flow_nominal[2]^2*c[3]; head_nominal[3] = c[1] + V_flow_nominal[3]*c[2] + V_flow_nominal[3]^2*c[3]; */ Real c[N] = Modelica.Math.Matrices.solve(V_flow_nominal_pow,head_nominal) "Coefficients of polynomial head curve"; algorithm // Flow equation (example N=3): head = c[1] + V_flow*c[2] + V_flow^2*c[3]; // Note: the implementation is numerically efficient only for low values of Na head := sum(V_flow^(i-1)*c[i] for i in 1:N); end polynomialFlow;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] | |
Real | eta_nominal | Nominal efficiency |
Type | Name | Description |
---|---|---|
Real | eta | Efficiency |
function constantEfficiency "Constant efficiency characteristic" extends baseEfficiency; input Real eta_nominal "Nominal efficiency"; algorithm eta := eta_nominal; end constantEfficiency;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] | |
VolumeFlowRate | V_flow_nominal[2] | Volume flow rate for two operating points (single pump) [m3/s] | |
Power | W_nominal[2] | Power consumption for two operating points [W] |
Type | Name | Description |
---|---|---|
Power | consumption | Power consumption [W] |
function linearPower "Linear power consumption characteristic" extends basePower; input SI.VolumeFlowRate V_flow_nominal[2] "Volume flow rate for two operating points (single pump)"; input SI.Power W_nominal[2] "Power consumption for two operating points"; /* Linear system to determine the coefficients: W_nominal[1] = c[1] + V_flow_nominal[1]*c[2]; W_nominal[2] = c[1] + V_flow_nominal[2]*c[2]; */ protected Real c[2] = Modelica.Math.Matrices.solve([ones(3),V_flow_nominal],W_nominal) "Coefficients of linear power consumption curve"; algorithm consumption := c[1] + V_flow*c[2]; end linearPower;
Type | Name | Default | Description |
---|---|---|---|
VolumeFlowRate | V_flow | Volumetric flow rate [m3/s] | |
VolumeFlowRate | V_flow_nominal[3] | Volume flow rate for three operating points (single pump) [m3/s] | |
Power | W_nominal[3] | Power consumption for three operating points [W] |
Type | Name | Description |
---|---|---|
Power | consumption | Power consumption [W] |
function quadraticPower "Quadratic power consumption characteristic" extends basePower; input SI.VolumeFlowRate V_flow_nominal[3] "Volume flow rate for three operating points (single pump)"; input SI.Power W_nominal[3] "Power consumption for three operating points"; protected Real V_flow_nominal2[3] = {V_flow_nominal[1]^2,V_flow_nominal[2]^2, V_flow_nominal[3]^2} "Squared nominal flow rates"; /* Linear system to determine the coefficients: W_nominal[1] = c[1] + V_flow_nominal[1]*c[2] + V_flow_nominal[1]^2*c[3]; W_nominal[2] = c[1] + V_flow_nominal[2]*c[2] + V_flow_nominal[2]^2*c[3]; W_nominal[3] = c[1] + V_flow_nominal[3]*c[2] + V_flow_nominal[3]^2*c[3]; */ Real c[3] = Modelica.Math.Matrices.solve([ones(3),V_flow_nominal,V_flow_nominal2],W_nominal) "Coefficients of quadratic power consumption curve"; algorithm consumption := c[1] + V_flow*c[2] + V_flow^2*c[3]; end quadraticPower;