# Overflowing Bathtub Model

Moore and Derry's (1995) Coleman cooler/bathtub example provides a nice entry into numerical modeling for beginners. Students start with a physical model of a bathtub with an inflow of water from a faucet and an outflow through a drain. Instructors can lead students through the identification of reservoirs (the tub itself) and fluxes (the inflow and outflow) and discuss conservation of mass. They can introduce the idea of boundary conditions by asking students to think about the physical dimensions of the tub and what would happen if the drain were plugged while the tap ran freely. Getting students to observe the state of the tub before the inflow or outflow fluxes are employed introduces the idea of initial conditions.

Based on the physical model, the class can move on to develop a numerical model of the system. This numerical model can start with a logic diagram and progress to a box-modeling software package such as STELLA. Fig. 1 shows a very simple STELLA representation of the bathtub system. Values of inflow, outflow, and the initial volume of the bathtub are specified in dialog boxes that appear when double clicking on each model element, and the instructor can ask students to predict what kind of behavior the system should exhibit given different combinations of inflow and outflow. STELLA's included graphing tool can be used to display the results of different model runs (Fig. 1).

As students work with the STELLA model they realize that the simulation deviates from the physical model of a real bathtub. For example, bathtubs in real life cannot fill forever: they eventually overflow, hopefully through an emergency overflow drain (the boundary conditions), but the STELLA model shown in Fig. 1 does not incorporate this reality and will fill forever since the inflow exceeds the outflow. This means that the model is missing an essential component of the physics of the real system, a fact that the instructor can use to teach students to evaluate modeling results critically, along with the assumptions underlying the models.

In the case of the bathtub example, the behavior of the real system prompts a revision to the STELLA model to ensure that the tub volume does not exceed the dimensions of the tub, which allows the introduction of if-then-else logical statements (Fig. 2).

Another issue not included in the models in Fig. 1 or 2 is the fact that as water depth increases in a tub, water pressure increases the outflow from the drain. In STELLA, this can be represented by including a pink linking arrow that shows the dependency between the outflow from the drain and the bathtub volume (Fig. 3). As in the case of Fig. 2, a steady state between inflow and outflow is eventually reached, leading to a steady state volume for the bathtub. Instructors can use this opportunity to discuss transient versus steady state behavior.

Once students master the basic concepts illustrated by the bathtub system, it is relatively straightforward to move on to systems that behave in similar ways, such as Earth's radiative equilibrium with the sun, crustal heat flow and the geothermal gradient, and radioactive decay.