functionpolynomialABCinverse

calculates the solution of x = f(y,z) defined by polynomial function z = c[1]*x^2 + c[2]*xy + c[3]*y^2

Extends from Modelica.Icons.Function.

Information

This function is used in the Zugabe.Fluid.Movers.Pump model. It depends on the correct order of the coefficients in c and the respective assignment of y and z. For the computation of n = f(Q,H), for example z must be assigned H and y = Q in m3/h. The result will be the pump speed in revolutions/min.

Be aware that the function will not check if the result is a positive number. Negative results have no sensible physical meaning in this case. There are two solutions of quadratic polynomial that can be calculated with the so-called p-q-formula. The function will take the larger value of the two soutions as a result.

Inputs

TypeNameDefaultDescription
Realccoefficient vector
Realyvariable 2
Realzvariable 3

Outputs

TypeNameDefaultDescription
Realxresult

Revisions

  • 2017-11-16 by Peter Matthes:
    Implemented