The house keeps its indoor setpoint at 21°C. Heat constantly leaks out through the walls, roof and windows at a rate set by the building envelope's overall heat-transfer coefficient — better insulation (higher R-value) and a smaller glazing ratio both shrink that leak, since single-pane-like windows lose heat roughly three times faster than an insulated wall of the same area. The escaping heat is drawn as glowing particles drifting outward through the walls, thicker and faster when the loss rate is high. Meanwhile the sun arcs across the sky; roof-mounted solar panels only generate power while the sun is above the horizon, and their output scales with how directly the sunlight hits them (steepest near solar noon) and with how many panels are installed.
Q_loss = U_wall·A_wall·ΔT + U_glass·A_glass·ΔT (ΔT = T_in − T_out)
P_solar = n_panels · P_rated · max(0, sin(elevation))
Net = P_solar − Q_loss
- Wall insulation (R-value) — higher values mean thicker/better insulation; heat-transfer coefficient U = 1/R, so loss drops as R climbs.
- Window / glazing ratio — the share of exterior wall area replaced by glass; glass loses heat much faster than insulated wall, so a large ratio raises total heat loss even at high R-value.
- Roof solar panels — how many panels sit on the south-facing roof slope; each contributes its own share of peak power at solar noon.
- Outdoor temperature — colder outside air widens ΔT against the fixed 21°C indoor setpoint, driving heat loss up.
- Day speed — how fast the simulated day cycles, so you can watch the solar generation curve rise and fall without waiting for real time.
Real-world relevance: this is exactly the trade-off a green-building retrofit balances — spend on insulation and glazing to shrink the loss term, then spend on solar to offset what's left, aiming for a net energy figure at or below zero across the day.