Decentralized and Centralized Optimal Control of HVAC Systems