  This paper puts forth a mathematical framework for Buildings-to-Grid (BtG)
integration in smart cities. The framework explicitly couples power grid and
building's control actions and operational decisions, and can be utilized by
buildings and power grids operators to simultaneously optimize their
performance. Simplified dynamics of building clusters and building-integrated
power networks with algebraic equations are presented---both operating at
different time-scales. A model predictive control (MPC)-based algorithm that
formulates the BtG integration and accounts for the time-scale discrepancy is
developed. The formulation captures dynamic and algebraic power flow
constraints of power networks and is shown to be numerically advantageous. The
paper analytically establishes that the BtG integration yields a reduced total
system cost in comparison with decoupled designs where grid and building
operators determine their controls separately. The developed framework is
tested on standard power networks that include thousands of buildings modeled
using industrial data. Case studies demonstrate building energy savings and
significant frequency regulation, while these findings carry over in network
simulations with nonlinear power flows and mismatch in building model
parameters. Finally, simulations indicate that the performance does not
significantly worsen when there is uncertainty in the forecasted weather and
base load conditions.
