Intelligent buildings are responsible for ensuring indoor air quality for their occupants under normal operation as well as under possibly harmful contaminant events. An emerging environmental application involves the monitoring of intelligent buildings against harmful events by incorporating various sensing technologies and using sophisticated algorithms to detect and isolate such events. In this context, both centralized and distributed approaches have been proposed, with the latter having significant benefits in terms of complexity, scalability, reliability and performance. This paper considers the automatic partitioning of the building into subsystems, which enables the distributed simulation, modeling, analysis and management of the intelligent building while ensuring the effective detection and isolation of contaminants in the building interior. Specifically, we develop both a high-quality heuristic algorithm and an optimal Mixed Integer Linear Programming (MILP) formulation for the building partitioning problem. The MILP formulation is based on graph partitioning techniques, while the heuristic is based on matrix clustering techniques. Both approaches partition the building into subsystems while ensuring (i) maximum decoupling between the various subsystems, (ii) strong connectivity between the zones of each subsystem and (iii) control of the size of the subsystems with respect to the number of allocated zones. A combination of the two approaches is also proposed for reconfiguring an initial partitioning composition in real time in order to accommodate partitioning needs that arise from dynamic system changes. . His research focuses on the modeling and system-wide solution of problems in complex and uncertain environments that require real-time and close to optimal decisions by developing optimisation, machine learning and computational intelligence techniques. Application areas of his work include intelligent transportation systems, communication systems, and smart buildings.Michalis P. Michaelides (S'04-M'9) is a tenuretrack Lecturer with the