Formal methods in human-computer interaction