The following figure shows the statechart of the Room in the HomeHeatingSystem example.

From the lifeline of the Room in the SomeoneEntersTheRoom sequence diagram, you can see that the Room polls its occupancy attribute to see whether it is occupied. If it is, it sends the required heat to the Furnace once the inhabitant has set a wanted temperature on the thermostat. Once the Room receives a message from the Furnace saying that it has started, the Room sends a message to the Valve telling it to open. When the room is warm enough, the Room tells the Furnace to stop generating heat, and then closes the Valve. Finally, the Room receives an acknowledgment from the Furnace letting it know that the Furnace has stopped.
From this sequence of events, you can see that the Room has four regions of responsibility, or concurrent states:
| Region | Responsibility |
|---|---|
| mode | Determine the working temperature based on the occupancy. |
| heatMode | Determine the need for heat. |
| FurnaceMode | Monitor the state of the Furnace. |
| sampling | Periodically sample the heat and occupancy sensors. |