Template:Convert/Mach/sandbox

The Template:Convert/Mach converts speeds in Mach number with other units, where the optional parameter 4 can be the altitude in feet. Some examples are shown below.
 * Usage: {&#123;convert|1|Mach/s}} &rarr; Mach 1 (761 mph; 1,225 km/h)
 * {&#123;convert|2.0|Mach/s}} &rarr; 2.0 Mach/sandbox
 * {&#123;convert|3.3|Mach/s}} &rarr; 3.3 Mach/sandbox
 * {&#123;convert|3.3|Mach/s|90,000}}      &rarr; 3.3 Mach/sandbox
 * {&#123;convert|3.3|Mach/s|90,000|sigfig=6}} &rarr; 3.3 Mach/sandbox
 * {&#123;convert|810|mph|Mach/s}}      &rarr; 810 mph
 * {&#123;convert|810|mph|Mach|sigfig=4}} &rarr; 810 mph

The conversion depends on the altitude, passed as parameter 4 measured in feet (default: 0), and the temperature (ignored), where the temperature at higher altitudes is likely to be fairly constant. Hence, only the altitude is an optional parameter, when converting from Mach number into other speed units. The altitude cannot be specified in reverse conversions, to Mach number, from other units, and the altitude is only accepted as feet, not metres.

Note that the speed of sound alternately decreases then increases, and again decreases then increases, at successively higher altitudes in the Earth's atmosphere. From sea level, in the troposphere, the speed decreases with rising altitude until the tropopause, at 40,000 ft, where Mach 1 is 660.1 mph, for most commercial jet airliners. However, the speed increases (as a reverse change) in the stratosphere, reaching 737.7 mph at altitude 160,000 ft. Then, the speed re-reverses to again decrease in the mesosphere, down to 613.2 mph at altitude 285,000 ft. However, in the thermosphere, the speed of sound re-re-reverses to increase (as in the stratosphere), and reaches 688.9 mph at altitude 400,000 ft. The highest speeds are below sea level, as in low-lying canyon areas, and the template allows a lowest altitude of -15,000 (feet) in parameter 4.