Skip to content
LIBRARY
HeatTransfer.PartialTwoPhaseHeatTransfer.md

HeatTransfer.PartialTwoPhaseHeatTransfer

Partial base class for an N-cell two-phase convective heat-transfer model.

Provides the per-cell heat balance Q = alpha * A * (T_wall - T_fluid), the linkage to a HeatPort array, the per-cell thermodynamic states, and the geometry/state-derived variables (Ts, ds, m_flows, ...). The cell-side flow state must be driven externally — typically the parent distributed-volume component binds states[i].p / states[i].h and the cell velocities vs[i]. Extending components must supply the alphas[i] closure (e.g. ConstantPhasic selects phase-specific values from vapor quality xs[i]). Sign convention: Q_flows[i] = heatPorts[i].Q_flow, so positive Q_flow means heat into the fluid.

Usage

HVACComponents.HeatTransfer.PartialTwoPhaseHeatTransfer(medium_data, surfaceAreas, lengths, dimensions, roughnesses, diameters=missing, As=missing, alpha0, ps_start, hs_start)

Parameters:

NameDescriptionUnitsDefault value
NNumber of heat-transfer control volumes
medium_dataRefrigerant medium properties
surfaceAreasPer-cell heat-transfer surface area [m^2] (length N)
lengthsPer-cell axial length [m] (length N)
dimensionsPer-cell characteristic dimension (hydraulic diameter) [m] (length N)
roughnessesPer-cell wall roughness [m] (length N)
alpha0Nominal heat-transfer coefficient used as the solver guess for alphas [W/(m^2.K)]
ps_startInitial pressure profile across the cells [Pa] (length N)Pa
hs_startInitial specific-enthalpy profile across the cells [J/kg] (length N)J/kg

Connectors

  • heatPorts - This connector represents a thermal port with temperature and heat flow as the potential and flow variables, respectively. (HeatPort)

Variables

NameDescriptionUnits
vsPer-cell mean velocity [m/s] (length N); typically bound externally
TsPer-cell fluid temperature [K] (length N)K
dsPer-cell fluid density [kg/m^3] (length N)
m_flowsPer-cell mass flow rate [kg/s] (length N; = ds * vs * As)kg/s
alphasPer-cell heat-transfer coefficient [W/(m^2.K)] (length N); extender supplies
xsPer-cell vapor quality [-] (length N); typically bound externally
Q_flowsPer-cell heat flow into the fluid [W] (length N; = heatPorts[i].Q_flow)W