% Units bar = 1e5 ; % [Pa] kJ = 1000 ; % [J] min = 60 ; % [s] m = 1 ; % [m] g = 0.001 ; % [kg] TT = 273.15 ; % [K] % Quantities for mix enthalpy cp_as = 1.005 * kJ ; % [kJ/(kg K)] cp_vap = 1.875 * kJ ; % [kJ/(kg K)] h_lv = 2501 * kJ ; % [kJ/(kg)] % Dry air ideal gas constants R_bar = 8.314 ; % [J/(mol K)] M_as = 29 * g ; % [kg/mol] R_as = R_bar / M_as % Functions for saturation, absolute humidity, mix enthalpy p_sat = @(t) 610.5 * exp( 17.269*t / (237.3+t) ) ; % [Pa] t_sat = @(p) 237.3 / ( 17.269/log(p/610.5)-1 ) ; % [°C] w = @(p_vap, p) 0.622 * p_vap / (p-p_vap) ; % [kg_vap/kg_as] p_vap = @(w, p) p / ( 0.622 / w + 1 ) ; % [Pa] J = @(t, w) cp_as * t + w * ( h_lv + cp_vap*t ) ; % [J/kg_as] % Common pressure p = 1 * bar ; % Flow 1 Vp1 = 142 * m^3 / min ; t1 = 5 ; % [°C] w1 = 0.002 ; % [kg_vap/kg_as] % Flow 2 Vp2 = 425 * m^3 / min ; t2 = 24 ; % [°C] phi2 = 0.50 ; % [-] p_vap2 = phi2 * p_sat(t2) w2 = w(p_vap2, p) % Mass flow rates T1 = t1 + TT ; mp_as1 = Vp1 * p / ( R_as * T1 ) T2 = t2 + TT ; mp_as2 = Vp2 * p / ( R_as * T2 ) % Mix absolute humidity w3 = ( mp_as1 * w1 + mp_as2 * w2 ) / (mp_as1 + mp_as2) % Mix enthalpies J1 = J(t1, w1) J2 = J(t2, w2) J3 = ( mp_as1 * J1 + mp_as2 * J2 ) / (mp_as1 + mp_as2) t3 = ( J3 - w3*h_lv ) / ( cp_as + w3*cp_vap ) p_vap3 = p_vap(w3, p) p_sat3 = p_sat(t3) phi_3 = p_vap3 / p_sat3