  We present SaSTL -- a novel Spatial Aggregation Signal Temporal Logic -- for
the efficient runtime monitoring of safety and performance requirements in
smart cities. We first describe a study of over 1,000 smart city requirements,
some of which can not be specified using existing logic such as Signal Temporal
Logic (STL) and its variants. To tackle this limitation, we develop two new
logical operators in SaSTL to augment STL for expressing spatial aggregation
and spatial counting characteristics that are commonly found in real city
requirements. We also develop efficient monitoring algorithms that can check a
SaSTL requirement in parallel over multiple data streams (e.g., generated by
multiple sensors distributed spatially in a city). We evaluate our SaSTL
monitor by applying to two case studies with large-scale real city sensing data
(e.g., up to 10,000 sensors in one requirement). The results show that SaSTL
has a much higher coverage expressiveness than other spatial-temporal logics,
and with a significant reduction of computation time for monitoring
requirements. We also demonstrate that the SaSTL monitor can help improve the
safety and performance of smart cities via simulated experiments.
