# Contents of the Domain Theory

We have looked at some of the logical underpinnings of CML and the thermal domain theory. Now we turn to the domain theory itself.

The domain theory contains definitions for 123 entities and model fragments and over 200 quantity, attribute, and participant functions.

The domain theory contains definitions for numerous components in the such as a turbine, heat-exchanger, pump, subsystems such as a boiler-system, or steam generator with reheat system, as well as the conceptual entities that are used to model them. The primary conceptual objects include the control-volume, stream, its specialization, the two dimensional stream (2d-stream), and the steady-state steady-flow process, which establishes the first law equations.

Dimensions may be defined in CML:

```(defDimension entropy-dimension
:= (/ energy-dimension temperature-dimension))

(defDimension specific-entropy-dimension
:= (/ entropy-dimension mass-dimension))
```

A common object in this domain is the heat exchanger. There are several heat exchanger definitions in the domain theory that are subclasses of this one. It establishes the quantities that are important for modeling heat exchangers. The equations that relate these quantities are established by the thermodyanmic laws.

```(defEntity Heat-exchanger
:documentation "a device that transfer energy between fluids at different temperatures"
:subclass-of (Thermal-component)
:quantities
((area :dimension area-dimension
:documentation "the surface area through heat is exchanged"
:the-*-the-object ("heat exchange surface area" "of")
:abbreviation "a")
(overall-heat-transfer-coefficient
:dimension dimensionless
:documentation "the overall heat transfer coefficient of the heat exchanger"
:the-*-the-object ("net het transfer coefficient" "of")
:abbreviation "h") ; some complex dimension
(heat-transfer-rate :dimension power-dimension
:documentation "the rate at which heat is transfered inside the heat exchanger"
:the-*-the-object ("heat transfer rate" "of")
:abbreviation "Q'")
(max-pressure :dimension pressure-dimension
:documentation "the maximum pressure inside the heat exchanger"
:the-*-the-object ("maximum pressure" "in")
:abbreviation "pmax")
(max-temperature :dimension temperature-dimension
:documentation "the maximum temperature inside the heat exchanger"
:the-*-the-object ("maximum temperature" "in")
:abbreviation "tmax")
(max-heat-rate :dimension power-dimension
:documentation "the maximum heat transfer rate"
:the-*-the-object ("maximum heat transfer rate" "of")
:abbreviation "Q'max")
(ideal-heat-rate :dimension power-dimension
:documentation "the ideal heat transfer rate"
:the-*-the-object ("ideal heat transfer rate" "of")
:abbreviation "Q'ideal")
)
)
```