This is a model of an Ember coffee mug -- a battery-powered, state-of-the-art beverage container that controls the temperature of your beverage to keep it at the setpoint you specify for a couple of hours.
This model simulates the process of filling the mug with a hot liquid and maintaining it at the setpoint until the battery is exhausted.
This model includes modeling of the PCM (Phase Change Material). From the measurements used to characterize the actual device, it appears that the PCM contains multiple melting-point materials (see experimental results here: https://www.systemvision.com/design/ember-coffee-mug-2-pcm-experimental-...), thus two were included –at melting points of 47C and 52C respectively. The thermal mass of the liquid is modeled by the block with a “coffee cup” symbol. The feedback control is simple proportional gain. The battery is Li-Ion chemistry with a capacity calibrated from measurements on the real-life temperature profile over time – estimated as 5 cells in series (total ~17 V), since the charger voltage was just under 20 V, with 130 milliamp-hour capacity each, for a total of 650 milliamp-hours capacity.
The red wires are thermal, with temperature as the across variable and heat flow as the conserved through variable. Black wires are electrical, with voltage as the across variable and current as the conserved through variable. The green wires are directional control signals (modeling the control system variables).
The block labeled “Temp” models the temperature sensor, feeding back the temperature to the proportional controller. The block on the far-left in the setpoint, with a step-input from ambient to the desired beverage temperature.