  We consider the problem of determining the optimal aggregate power
consumption of a population of thermostatically controlled loads. This is
motivated by the problem of synthesizing the demand response for a load serving
entity (LSE) serving a population of such customers. We show how the LSE can
opportunistically design the aggregate reference consumption to minimize its
energy procurement cost, given day-ahead price, load and ambient temperature
forecasts, while respecting each individual load's comfort range constraints.
The resulting synthesis problem is shown to be amenable to optimal control
techniques, but computationally difficult otherwise. Numerical simulations
elucidate how the LSE can use the optimal aggregate power consumption
trajectory thus computed, for the purpose of demand response.
