modelGenericDistributed_HX_Rwall
A (i.e., no inlet/outlet plenum considerations, etc.) generic heat exchanger with discritized fluid and wall volumes where concurrent/counter flow is specified mass flow direction.
Extends from TRANSFORM.Utilities.Visualizers.IconColorMap.
Information
A generic heat exchanger for any relatively simple general purpose heat transfer process.
- Currently the nodes on the shell and tube side must be equal. The lengths do not however there are no geometry checks to ensure reasonable user input.
- The wall is currently fixed as a 2D cylinder but may be generalized in the future to allow user to select wall geometry. The 2D cyclinder though does not require the tubes/shell to be cylinders but will potentially impact the results depending on what thermal resistance dominates.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Real | nParallel | 1 | # of identical parallel HXs |
| Boolean | counterCurrent | true | Swap shell side temperature and flux vector order |
| Shell Initialization › Start Value: Absolute Pressure | |||
| SI.AbsolutePressure | ps_start_shell | linspace_1D(p_a_start_shell, p_b_start_shell, geometry.nV) | Pressure |
| SI.AbsolutePressure | p_a_start_shell | Medium_shell.p_default | Pressure at port a |
| SI.AbsolutePressure | p_b_start_shell | p_a_start_shell + (if m_flow_a_start_shell > 0 then -1e3 elseif m_flow_a_start_shell < 0 then -1e3 else 0) | Pressure at port b |
| Shell Initialization › Start Value: Temperature | |||
| Boolean | use_Ts_start_shell | true | Use T_start if true, otherwise h_start |
| SI.Temperature[geometry.nV] | Ts_start_shell | linspace_1D(T_a_start_shell, T_b_start_shell, geometry.nV) | Temperature |
| SI.Temperature | T_a_start_shell | Medium_shell.T_default | Temperature at port a |
| SI.Temperature | T_b_start_shell | T_a_start_shell | Temperature at port b |
| Shell Initialization › Start Value: Specific Enthalpy | |||
| SI.SpecificEnthalpy | hs_start_shell | if not use_Ts_start_shell then linspace_1D(h_a_start_shell, h_b_start_shell, geometry.nV) else {Medium_shell.specificEnthalpy_pTX(ps_start_shell[i], Ts_start_shell[i], Xs_start_shell[i, 1:Medium_shell.nX]) for i in 1:geometry.nV} | Specific enthalpy |
| SI.SpecificEnthalpy | h_a_start_shell | Medium_shell.specificEnthalpy_pTX(p_a_start_shell, T_a_start_shell, X_a_start_shell) | Specific enthalpy at port a |
| SI.SpecificEnthalpy | h_b_start_shell | Medium_shell.specificEnthalpy_pTX(p_b_start_shell, T_b_start_shell, X_b_start_shell) | Specific enthalpy at port b |
| Shell Initialization › Start Value: Species Mass Fraction | |||
| SI.MassFraction[geometry.nV,Medium_shell.nX] | Xs_start_shell | linspaceRepeat_1D(X_a_start_shell, X_b_start_shell, geometry.nV) | Mass fraction |
| SI.MassFraction[Medium_shell.nX] | X_a_start_shell | Medium_shell.X_default | Mass fraction at port a |
| SI.MassFraction[Medium_shell.nX] | X_b_start_shell | X_a_start_shell | Mass fraction at port b |
| Shell Initialization › Start Value: Trace Substances | |||
| SIadd.ExtraProperty[geometry.nV,Medium_shell.nC] | Cs_start_shell | linspaceRepeat_1D(C_a_start_shell, C_b_start_shell, geometry.nV) | Mass-Specific value |
| SIadd.ExtraProperty[Medium_shell.nC] | C_a_start_shell | fill(0, Medium_shell.nC) | Mass-Specific value at port a |
| SIadd.ExtraProperty[Medium_shell.nC] | C_b_start_shell | C_a_start_shell | Mass-Specific value at port b |
| Shell Initialization › Start Value: Mass Flow Rate | |||
| SI.MassFlowRate | m_flows_start_shell | linspace(m_flow_a_start_shell, -m_flow_b_start_shell, geometry.nV + 1) | Mass flow rates |
| SI.MassFlowRate | m_flow_a_start_shell | 0 | Mass flow rate at port_a |
| SI.MassFlowRate | m_flow_b_start_shell | -m_flow_a_start_shell | Mass flow rate at port_b |
| Tube Initialization › Start Value: Absolute Pressure | |||
| SI.AbsolutePressure | ps_start_tube | linspace_1D(p_a_start_tube, p_b_start_tube, geometry.nV) | Pressure |
| SI.AbsolutePressure | p_a_start_tube | Medium_tube.p_default | Pressure at port a |
| SI.AbsolutePressure | p_b_start_tube | p_a_start_tube + (if m_flow_a_start_tube > 0 then -1e3 elseif m_flow_a_start_tube < 0 then -1e3 else 0) | Pressure at port b |
| Tube Initialization › Start Value: Temperature | |||
| Boolean | use_Ts_start_tube | true | Use T_start if true, otherwise h_start |
| SI.Temperature[geometry.nV] | Ts_start_tube | linspace_1D(T_a_start_tube, T_b_start_tube, geometry.nV) | Temperature |
| SI.Temperature | T_a_start_tube | Medium_tube.T_default | Temperature at port a |
| SI.Temperature | T_b_start_tube | T_a_start_tube | Temperature at port b |
| Tube Initialization › Start Value: Specific Enthalpy | |||
| SI.SpecificEnthalpy | hs_start_tube | if not use_Ts_start_tube then linspace_1D(h_a_start_tube, h_b_start_tube, geometry.nV) else {Medium_tube.specificEnthalpy_pTX(ps_start_tube[i], Ts_start_tube[i], Xs_start_tube[i, 1:Medium_tube.nX]) for i in 1:geometry.nV} | Specific enthalpy |
| SI.SpecificEnthalpy | h_a_start_tube | Medium_tube.specificEnthalpy_pTX(p_a_start_tube, T_a_start_tube, X_a_start_tube) | Specific enthalpy at port a |
| SI.SpecificEnthalpy | h_b_start_tube | Medium_tube.specificEnthalpy_pTX(p_b_start_tube, T_b_start_tube, X_b_start_tube) | Specific enthalpy at port b |
| Tube Initialization › Start Value: Species Mass Fraction | |||
| SI.MassFraction[geometry.nV,Medium_tube.nX] | Xs_start_tube | linspaceRepeat_1D(X_a_start_tube, X_b_start_tube, geometry.nV) | Mass fraction |
| SI.MassFraction[Medium_tube.nX] | X_a_start_tube | Medium_tube.X_default | Mass fraction at port a |
| SI.MassFraction[Medium_tube.nX] | X_b_start_tube | X_a_start_tube | Mass fraction at port b |
| Tube Initialization › Start Value: Trace Substances | |||
| SIadd.ExtraProperty[geometry.nV,Medium_tube.nC] | Cs_start_tube | linspaceRepeat_1D(C_a_start_tube, C_b_start_tube, geometry.nV) | Mass-Specific value |
| SIadd.ExtraProperty[Medium_tube.nC] | C_a_start_tube | fill(0, Medium_tube.nC) | Mass-Specific value at port a |
| SIadd.ExtraProperty[Medium_tube.nC] | C_b_start_tube | C_a_start_tube | Mass-Specific value at port b |
| Tube Initialization › Start Value: Mass Flow Rate | |||
| SI.MassFlowRate | m_flows_start_tube | linspace(m_flow_a_start_tube, -m_flow_b_start_tube, geometry.nV + 1) | Mass flow rates |
| SI.MassFlowRate | m_flow_a_start_tube | 0 | Mass flow rate at port_a |
| SI.MassFlowRate | m_flow_b_start_tube | -m_flow_a_start_tube | Mass flow rate at port_b |
| Wall Initialization › Start Value: Temperature | |||
| SI.Temperature[geometry.nR,geometry.nV] | Ts_wall_start | linspaceRepeat_1D(Ts_wall_start_tubeSide, if counterCurrent then Modelica.Math.Vectors.reverse(Ts_wall_start_shellSide) else Ts_wall_start_shellSide, geometry.nR) | Tube wall temperature |
| SI.Temperature[geometry.nV] | Ts_wall_start_tubeSide | Medium_tube.temperature_phX(ps_start_tube, hs_start_tube, Xs_start_tube) | Tube side wall temperature |
| SI.Temperature[geometry.nV] | Ts_wall_start_shellSide | Medium_shell.temperature_phX(ps_start_shell, hs_start_shell, Xs_start_shell) | Shell side wall temperature |
| Advanced › Dynamics | |||
| Modelica.Fluid.Types.Dynamics[3] | energyDynamics | {Dynamics.DynamicFreeInitial, Dynamics.DynamicFreeInitial, Dynamics.DynamicFreeInitial} | Formulation of energy balances {shell,tube,tubeWall} |
| Modelica.Fluid.Types.Dynamics[2] | massDynamics | energyDynamics[1:2] | Formulation of mass balances {shell,tube} |
| Dynamics[2] | traceDynamics | massDynamics | Formulation of trace substance balances {shell,tube} |
| Modelica.Fluid.Types.Dynamics[2] | momentumDynamics | {Dynamics.SteadyState, Dynamics.SteadyState} | Formulation of momentum balances {shell,tube} |
| Advanced › Shell Side | |||
| Boolean | allowFlowReversal_shell | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
| Boolean | exposeState_a_shell | true | =true, p is calculated at port_a else m_flow |
| Boolean | exposeState_b_shell | false | =true, p is calculated at port_b else m_flow |
| Boolean | useLumpedPressure_shell | false | =true to lump pressure states together |
| LumpedLocation | lumpPressureAt_shell | LumpedLocation.port_a | Location of pressure for flow calculations |
| Boolean | useInnerPortProperties_shell | false | =true to take port properties for flow models from internal control volumes |
| Advanced › Tube Side | |||
| Boolean | allowFlowReversal_tube | true | = true to allow flow reversal, false restricts to design direction (port_a -> port_b) |
| Boolean | exposeState_a_tube | true | =true, p is calculated at port_a else m_flow |
| Boolean | exposeState_b_tube | false | =true, p is calculated at port_b else m_flow |
| Boolean | useLumpedPressure_tube | false | =true to lump pressure states together |
| LumpedLocation | lumpPressureAt_tube | LumpedLocation.port_a | Location of pressure for flow calculations |
| Boolean | useInnerPortProperties_tube | false | =true to take port properties for flow models from internal control volumes |
| Advanced › Tube Wall | |||
| Boolean[2] | adiabaticDims | {false, false} | =true, toggle off conduction heat transfer in dimension {1,2} |
| Visualization › Color Coding | |||
| Boolean | showColors (from IconColorMap) | false | Toggle dynamic color display |
| Integer | n_colors (from IconColorMap) | 64 | Number of colors in the colorMap, multiples of 4 is best |
Connectors
| Type | Name | Default | Description |
|---|---|---|---|
| TRANSFORM.Fluid.Interfaces.FluidPort_Flow | port_a_tube | ||
| TRANSFORM.Fluid.Interfaces.FluidPort_Flow | port_b_tube | ||
| TRANSFORM.Fluid.Interfaces.FluidPort_Flow | port_a_shell | ||
| TRANSFORM.Fluid.Interfaces.FluidPort_Flow | port_b_shell |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| TRANSFORM.Fluid.SystemTF | systemTF | ||
| Geometry | geometry | ||
| TRANSFORM.HeatAndMassTransfer.BoundaryConditions.Heat.CounterFlow | counterFlow | ||
| Fluid.Pipes.GenericPipe_MultiTransferSurface | shell | ||
| Fluid.Pipes.GenericPipe_MultiTransferSurface | tube | ||
| HeatAndMassTransfer.Resistances.Heat.Specified_Resistance[geometry.nV] | tubeWall | ||
| TRANSFORM.HeatExchangers.BaseClasses.Summary | summary | ||
| Real | val (from IconColorMap) | Color map input variable | |
| Real | val_min (from IconColorMap) | val <= val_min is mapped to colorMap[1,:] | |
| Real | val_max (from IconColorMap) | val >= val_max is mapped to colorMap[end,:] | |
| Real[3] | dynColor (from IconColorMap) | Modelica.Mechanics.MultiBody.Visualizers.Colors.scalarToColor(val, val_min, val_max, colorMap(n_colors)) | |
| Real[3] | dynColor_tube | Modelica.Mechanics.MultiBody.Visualizers.Colors.scalarToColor(tube.summary.T_effective, val_min, val_max, colorMap(n_colors)) | |
| HeatAndMassTransfer.BoundaryConditions.Heat.ParallelFlow[geometry.nV] | nFlow_tubeTowall | ||
| HeatAndMassTransfer.BoundaryConditions.Heat.ParallelFlow[geometry.nV] | nFlow_wallToshell | ||
| SI.ThermalConductivity[geometry.nV] | lambdas_tubeWall | {if counterCurrent then Material_tubeWall.thermalConductivity_T(0.5*(tube.mediums[i].T + tube.mediums[geometry.nV - i + 1].T)) else Material_tubeWall.thermalConductivity_T(0.5*(tube.mediums[i].T + tube.mediums[geometry.nV - i + 1].T)) for i in 1:geometry.nV} | Average thermal conductivity per wall node |
| SI.ThermalResistance[geometry.nV] | R_tubeWall | {log(geometry.dimensions_tube_outer[i]/geometry.dimensions_tube[i])/(2*Modelica.Constants.pi*geometry.dlengths_tube[i]*lambdas_tubeWall[i]) for i in 1:geometry.nV} | Thermal resistance of wall |
Contents
| Name | Description |
|---|---|
| Shell side medium | |
| Tube side medium | |
| Tube wall material | |