Complexity of Safety and coSafety Fragments of Linear Temporal Logic