This example shows how the Simscape™ language can be used to define a custom thermal fluid domain.

This model uses custom blocks representing components of a rudimentary engine cooling system. A fixed displacement pump linked to a shaft drives coolant through the circuit. Heat from the engine, where pistons are cooled, is dissipated through the radiator. The system temperature is controlled by the thermostat-regulated path via the radiator. REFPROP software, developed by NIST, was used to populate the fluid property data in the table lookups in the Fluid Properties block.

In this framework, each physical component is represented by a volume of fluid for which conservation equations are written. These equations describe the dynamic evolution of the internal pressure and temperature based on boundary quantities. The domain defines two sets of Across and Through variables. The Across variables are pressure and temperature, and the Through variables are mass flow rate and power flux.

The power flux in the energy equation is described using the full-flux modeling method which provides a smooth evolution of the nodal temperature at low mass flows.

For incompressible components, the internal pressure is taken as the average of the pressure at fluid ports. In the compressible case, the conservation of mass yields a dynamic equation for the internal pressure. These cases are treated separately in different classes ('TwoPortsIncompressible' and 'TwoPortsCompressible') from which components inherit variables and equations.

Was this topic helpful?