A model for the fragile-to-strong transition in water