This is a simple model of hydraulic valve. The model can use a constant efficiency or varying efficiency from a lookup-table.
This model is based on the energy balance of a valve. The valve
capacity can either be specified directly by the user by specifying
C_v or it will be calculated from the nominal head
H_n and nominal flow rate Vdot_n.
The valve efficiency is in per-unit values from 0 to 1, where 1 means that there are no losses in the valve. The valve power is defined as the product of the valve power and valve efficiency.
Besides hydraulic input and output, there is an input
u for controlling the valve opening.