Skip to content
LIBRARY
Components.LEV.md

Components.LEV

Linear Electronic Expansion Valve (LEV).

m_flow > 0 means flow enters through port_a. input_position is the commanded valve position; its mapping to flow coefficient is set by the (theta, thresh) arrays (lengths NTheta, NThresh) together with the overall Cv scale ZCv.

Usage

HVACComponents.Components.LEV(medium_data, ZCv, dp_small, theta, thresh, x_t, yd0, LEV_position_start, p_a_start, m_flow_start, h_in_start, p_b_start, h_out_start, dp_start=p_a_start - p_b_start, rho_start=HVACComponents.Density_ph(p_a_start, h_in_start, medium_data), rho_a_start=HVACComponents.Density_ph(p_a_start, h_in_start, medium_data), rho_b_start=HVACComponents.Density_ph(p_b_start, h_out_start, medium_data))

Parameters:

NameDescriptionUnitsDefault value
NThetaNumber of polynomial segments in the CvLookup correlation3
NThreshNumber of breakpoints in the CvLookup correlation3
use_yd0If true, use yd0 as the regularization constant for the pressure-drop branchfalse
medium_dataRefrigerant medium properties
ZCvOverall Cv scaling factor for the valve [-]
dp_smallPressure-drop regularization scale [Pa]
thetaCvLookup polynomial coefficients keyed to valve position (length NTheta)
threshCvLookup breakpoint thresholds keyed to valve position (length NThresh)
x_tChoked-flow pressure-ratio limit used inside the orifice correlation
yd0Optional y-axis offset for the pressure-drop regularization
LEV_position_startInitial valve position [-] (solver guess)
p_a_startInitial inlet pressure [Pa] (solver guess)
m_flow_startInitial mass flow [kg/s] (solver guess)
h_in_startInitial inlet specific enthalpy [J/kg]
p_b_startInitial outlet pressure [Pa] (solver guess)
h_out_startInitial outlet specific enthalpy [J/kg]
dp_startInitial pressure drop [Pa] (= p_a_start - p_b_start)p_a_start - p_b_start
rho_startInitial upstream density [kg/m^3] (= Density_ph(p_a_start, h_in_start))HVACComponents.Density_ph(p_a_start, h_in_start, medium_data)
rho_a_startInitial port_a-side density [kg/m^3]HVACComponents.Density_ph(p_a_start, h_in_start, medium_data)
rho_b_startInitial port_b-side density [kg/m^3]HVACComponents.Density_ph(p_b_start, h_out_start, medium_data)

Connectors

  • input_position - This connector represents a real signal as an input to a component (RealInput)

  • port_a - (FluidPort)

  • port_b - (FluidPort)

Variables

NameDescriptionUnits
u_inCommanded valve position [-]
m_flowMass flow through the valve, positive into port_a [kg/s]
rhoUpstream density used by the orifice equation [kg/m^3]
rho_aDensity at port_a inflow conditions [kg/m^3]
rho_bDensity at port_b inflow conditions [kg/m^3]
dpPressure drop port_a - port_b [Pa]