This function computes the volume flow rate V_flow supplied by a pump at a given head from the roots of the polynom that fits the pump curve. This function is mainly used as inverse of the polynomialFlow function when the head is known but not the volume flow rate.
If the pump curve of the pressure as a function of the volume flow rate is not monotonically decreasing with increasing V_flow_nominal, severals solution for the flow rate are possible for a polynom higher than the first order. However, a pumping system is designed to work only in the monotonically decreasing part of the pump curve. Therefore, among the mulitiples roots, the most reasonable one is the higher value of roots.
The fitting is carried out from nominal inputs of the volume flow rate and the head (V_flow_nominal and head_nominal) via the least squares method. The order of the polynom that fits the curve is settable via the input OrderPolyFitting but cannot go over the third order.
function polynomialFlow_inv import Modelica.Math.Vectors; extends Modelica.Icons.Function; input Modelica.SIunits.Position head "Pump head"; input Modelica.SIunits.VolumeFlowRate V_flow_nominal[:] "Volume flow rate for N operating points (single pump)" annotation( Dialog); input Modelica.SIunits.Position head_nominal[:] "Pump head for N operating points" annotation( Dialog); input Integer OrderPolyFitting(min = 1) = 3 "Order of the polynom that fits the fan curve"; output Modelica.SIunits.VolumeFlowRate V_flow "Volumetric flow rate"; end polynomialFlow_inv;