UK weather: Why do trains get cancelled when there's a heatwave?

Network Rail has revealed how abnormally high temperatures across the UK can cause steel rails across the network to buckle.