Sound travels faster in warm air than cold. So when the air is layered by temperature, sound RAYS bend — and that’s why a far-off train is loud at night and faint by day. By day the ground is warm, sound bends UP and away (a shadow); by night the ground is cool, sound bends back DOWN and carries for miles. Slide day to night and watch the rays curve.
The speed of sound rises with temperature: c = 20.05·√T (T in kelvin) — ~349 m/s at 30°C, ~337 at 10°C. Where c varies with height, Snell’s law (sinθ/c = const) bends rays toward the SLOWER (cooler) air. By day the ground is hot, so c is higher near the ground and rays curve UPWARD, leaving an acoustic shadow; by night the ground is cool (a temperature inversion), c is lower near the ground and rays curve back DOWN, so sound ducts along the surface and carries far. A fail-loud self-check throws unless warm air is faster than cool. ◆ real atmospheric acoustics, node-verified.
A two-layer / linear-gradient ray-bending picture (Snell on a continuous profile); real profiles add wind shear (which also refracts sound, louder downwind) — the c(T) law and the day-up / night-down bending are exact.