{
  "id": "normal-shock",
  "version": "6ebec366d8b2",
  "status": "published",
  "name": "Normal Shock Calculator",
  "question": "What changes in a normal shock?",
  "summary": "Normal shock relations for a perfect gas: from the upstream Mach number (or M₂, or p₂/p₁) and γ, the downstream Mach number and the pressure, density, temperature, velocity and total pressure ratios.",
  "category": "physics",
  "subcategory": "mechanics",
  "url": "https://www.acalculator.org/physics/normal-shock-calculator",
  "markdown": "https://www.acalculator.org/physics/normal-shock-calculator.md",
  "kind": "function",
  "method": "M₂² = [(γ − 1)M₁² + 2] ÷ [2γM₁² − (γ − 1)]; p₂/p₁ = [2γM₁² − (γ − 1)] ÷ (γ + 1); ρ₂/ρ₁ = (γ + 1)M₁² ÷ [(γ − 1)M₁² + 2]; T₂/T₁ = (p₂/p₁) ÷ (ρ₂/ρ₁); p₀₂/p₀₁ = (ρ₂/ρ₁)^(γ/(γ − 1)) × (p₁/p₂)^(1/(γ − 1)).",
  "assumptions": [
    "A perfect gas with constant γ, in steady one-dimensional flow with no heat added and no friction (NASA).",
    "The shock is normal: at a right angle to the flow.",
    "Typed numbers are read as exact decimals; M₂ is a root rounded once; the total pressure ratios are 64-bit floats."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "by": {
        "title": "I know",
        "description": "The upstream Mach number M₁, the downstream Mach number M₂, or the static pressure ratio p₂/p₁.",
        "type": "string",
        "enum": [
          "m1",
          "m2",
          "p"
        ]
      },
      "M1": {
        "title": "Upstream Mach number (M₁)",
        "description": "The Mach number of the flow before the shock: 1 or more.",
        "type": "number",
        "minimum": 1,
        "maximum": 100
      },
      "M2": {
        "title": "Downstream Mach number (M₂)",
        "description": "The Mach number of the flow after the shock: above 0 and at most 1.",
        "type": "number",
        "exclusiveMinimum": 0,
        "maximum": 1
      },
      "p": {
        "title": "Static pressure ratio (p₂/p₁)",
        "description": "The static pressure after the shock divided by the pressure before it: 1 or more.",
        "type": "number",
        "minimum": 1,
        "maximum": 10000
      },
      "g": {
        "title": "Ratio of specific heats (γ)",
        "description": "γ = cp ÷ cv of the gas: 1.4 for air, 1.67 for helium or argon, 1.3 for steam or carbon dioxide.",
        "type": "number",
        "minimum": 1.05,
        "maximum": 1.7
      }
    }
  },
  "outputs": {
    "result": {
      "label": "Mach number found",
      "description": "M₂ when M₁ is typed; otherwise M₁, to 6 significant figures.",
      "format": "text"
    },
    "M1": {
      "label": "Upstream Mach number (M₁)",
      "description": "The Mach number before the shock.",
      "format": "number"
    },
    "M2": {
      "label": "Downstream Mach number (M₂)",
      "description": "The Mach number after the shock: below 1 for M₁ above 1.",
      "format": "number"
    },
    "p": {
      "label": "Static pressure ratio (p₂/p₁)",
      "description": "The static pressure after the shock over the pressure before it.",
      "format": "number"
    },
    "rho": {
      "label": "Density ratio (ρ₂/ρ₁)",
      "description": "The density after the shock over the density before it.",
      "format": "number"
    },
    "T": {
      "label": "Static temperature ratio (T₂/T₁)",
      "description": "The static temperature after the shock over the temperature before it.",
      "format": "number"
    },
    "u": {
      "label": "Velocity ratio (u₂/u₁)",
      "description": "The flow speed after the shock over the speed before it: ρ₁/ρ₂.",
      "format": "number"
    },
    "pt": {
      "label": "Total pressure ratio (p₀₂/p₀₁)",
      "description": "The stagnation pressure after the shock over the stagnation pressure before it.",
      "format": "number"
    },
    "pitot": {
      "label": "Pitot pressure ratio (p₀₂/p₁)",
      "description": "The stagnation pressure behind the shock over the static pressure before it.",
      "format": "number"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "by": "m1",
      "M1": 2,
      "M2": 0.5,
      "p": 4.5,
      "g": 1.4
    },
    "outputs": {
      "result": "M₂ = 0.57735",
      "M1": 2,
      "M2": 0.5773502691896257,
      "p": 4.5,
      "rho": 2.6666666666666665,
      "T": 1.6875,
      "u": 0.375,
      "pt": 0.720873861484745,
      "pitot": 5.640440812823316
    },
    "text": "For M₁ = 2 and γ = 1.4, the flow leaves the shock at M₂ = 0.57735 with p₂/p₁ = 4.5."
  },
  "examples": [
    {
      "given": {
        "by": "m1",
        "M1": 2,
        "g": 1.4
      },
      "expect": {
        "M2": 0.5773502691896257,
        "p": 4.5,
        "rho": 2.6666666666666665,
        "T": 1.6875,
        "u": 0.375,
        "pt": 0.7208738614847453,
        "pitot": 5.640440812823317,
        "result": "M₂ = 0.57735"
      },
      "source": "NASA Glenn Research Center, Normal Shock Wave Equations (M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)]; T₁/T₀ = [2γM² − (γ − 1)][(γ − 1)M² + 2] ÷ [(γ + 1)²M²]; p₁/p₀ = [2γM² − (γ − 1)] ÷ (γ + 1); r₁/r₀ = (γ + 1)M² ÷ [(γ − 1)M² + 2]; pt₁/pt₀ = {(γ + 1)M² ÷ [(γ − 1)M² + 2]}^[γ/(γ − 1)] × {(γ + 1) ÷ [2γM² − (γ − 1)]}^[1/(γ − 1)]; Tt₁/Tt₀ = 1), https://www.grc.nasa.gov/www/k-12/airplane/normal.html (retrieved 2026-10-19); NASA Glenn Research Center, Isentropic Flow Equations (Eq. 6: p/pt = [1 + M²(γ − 1)/2]^−[γ/(γ − 1)]), https://www.grc.nasa.gov/www/k-12/airplane/isentrop.html (retrieved 2026-10-19); hand calculation in content.mdx",
      "tolerance": 1e-14
    },
    {
      "given": {
        "by": "m1",
        "M1": 3,
        "g": 1.4
      },
      "expect": {
        "M2": 0.47519096331149147,
        "p": 10.333333333333334,
        "rho": 3.857142857142857,
        "T": 2.6790123456790123,
        "pt": 0.32834388819073695,
        "pitot": 12.060964701266622
      },
      "source": "NASA Glenn Research Center, Normal Shock Wave Equations (M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)]; T₁/T₀ = [2γM² − (γ − 1)][(γ − 1)M² + 2] ÷ [(γ + 1)²M²]; p₁/p₀ = [2γM² − (γ − 1)] ÷ (γ + 1); r₁/r₀ = (γ + 1)M² ÷ [(γ − 1)M² + 2]; pt₁/pt₀ = {(γ + 1)M² ÷ [(γ − 1)M² + 2]}^[γ/(γ − 1)] × {(γ + 1) ÷ [2γM² − (γ − 1)]}^[1/(γ − 1)]; Tt₁/Tt₀ = 1), https://www.grc.nasa.gov/www/k-12/airplane/normal.html (retrieved 2026-10-19); NASA Glenn Research Center, Isentropic Flow Equations (Eq. 6: p/pt = [1 + M²(γ − 1)/2]^−[γ/(γ − 1)]), https://www.grc.nasa.gov/www/k-12/airplane/isentrop.html (retrieved 2026-10-19); hand calculation in content.mdx",
      "tolerance": 1e-14
    },
    {
      "given": {
        "by": "m1",
        "M1": 1,
        "g": 1.4
      },
      "expect": {
        "M2": 1,
        "p": 1,
        "rho": 1,
        "T": 1,
        "pt": 1,
        "pitot": 1.892929158737854
      },
      "source": "NASA Glenn Research Center, Normal Shock Wave Equations (M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)]; T₁/T₀ = [2γM² − (γ − 1)][(γ − 1)M² + 2] ÷ [(γ + 1)²M²]; p₁/p₀ = [2γM² − (γ − 1)] ÷ (γ + 1); r₁/r₀ = (γ + 1)M² ÷ [(γ − 1)M² + 2]; pt₁/pt₀ = {(γ + 1)M² ÷ [(γ − 1)M² + 2]}^[γ/(γ − 1)] × {(γ + 1) ÷ [2γM² − (γ − 1)]}^[1/(γ − 1)]; Tt₁/Tt₀ = 1), https://www.grc.nasa.gov/www/k-12/airplane/normal.html (retrieved 2026-10-19); NASA Glenn Research Center, Isentropic Flow Equations (Eq. 6: p/pt = [1 + M²(γ − 1)/2]^−[γ/(γ − 1)]), https://www.grc.nasa.gov/www/k-12/airplane/isentrop.html (retrieved 2026-10-19); hand calculation in content.mdx: p₀₁/p₁ = 1.2^3.5",
      "tolerance": 1e-14
    },
    {
      "given": {
        "by": "m2",
        "M2": 0.5,
        "g": 1.4
      },
      "expect": {
        "M1": 2.6457513110645907,
        "p": 8,
        "rho": 3.5,
        "pt": 0.4431116697730247,
        "result": "M₁ = 2.64575"
      },
      "source": "NASA Glenn Research Center, Normal Shock Wave Equations (M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)]; T₁/T₀ = [2γM² − (γ − 1)][(γ − 1)M² + 2] ÷ [(γ + 1)²M²]; p₁/p₀ = [2γM² − (γ − 1)] ÷ (γ + 1); r₁/r₀ = (γ + 1)M² ÷ [(γ − 1)M² + 2]; pt₁/pt₀ = {(γ + 1)M² ÷ [(γ − 1)M² + 2]}^[γ/(γ − 1)] × {(γ + 1) ÷ [2γM² − (γ − 1)]}^[1/(γ − 1)]; Tt₁/Tt₀ = 1), https://www.grc.nasa.gov/www/k-12/airplane/normal.html (retrieved 2026-10-19); hand calculation in content.mdx: M₁² = (0.4 × 0.25 + 2) ÷ (2.8 × 0.25 − 0.4) = 2.1 ÷ 0.3 = 7",
      "tolerance": 1e-14
    },
    {
      "given": {
        "by": "p",
        "p": 4.5,
        "g": 1.4
      },
      "expect": {
        "M1": 2,
        "M2": 0.5773502691896257,
        "result": "M₁ = 2"
      },
      "source": "NASA Glenn Research Center, Normal Shock Wave Equations (M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)]; T₁/T₀ = [2γM² − (γ − 1)][(γ − 1)M² + 2] ÷ [(γ + 1)²M²]; p₁/p₀ = [2γM² − (γ − 1)] ÷ (γ + 1); r₁/r₀ = (γ + 1)M² ÷ [(γ − 1)M² + 2]; pt₁/pt₀ = {(γ + 1)M² ÷ [(γ − 1)M² + 2]}^[γ/(γ − 1)] × {(γ + 1) ÷ [2γM² − (γ − 1)]}^[1/(γ − 1)]; Tt₁/Tt₀ = 1), https://www.grc.nasa.gov/www/k-12/airplane/normal.html (retrieved 2026-10-19); hand calculation in content.mdx: M₁² = (2.4 × 4.5 + 0.4) ÷ 2.8 = 4"
    },
    {
      "given": {
        "by": "m1",
        "M1": 1.5,
        "g": 1.3
      },
      "expect": {
        "M2": 0.6942492218086974,
        "p": 2.4130434782608696,
        "T": 1.247321991178324,
        "pt": 0.9261001829450125
      },
      "source": "NASA Glenn Research Center, Normal Shock Wave Equations (M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)]; T₁/T₀ = [2γM² − (γ − 1)][(γ − 1)M² + 2] ÷ [(γ + 1)²M²]; p₁/p₀ = [2γM² − (γ − 1)] ÷ (γ + 1); r₁/r₀ = (γ + 1)M² ÷ [(γ − 1)M² + 2]; pt₁/pt₀ = {(γ + 1)M² ÷ [(γ − 1)M² + 2]}^[γ/(γ − 1)] × {(γ + 1) ÷ [2γM² − (γ − 1)]}^[1/(γ − 1)]; Tt₁/Tt₀ = 1), https://www.grc.nasa.gov/www/k-12/airplane/normal.html (retrieved 2026-10-19); hand calculation in content.mdx",
      "tolerance": 1e-14
    }
  ],
  "sources": [
    "NASA Glenn Research Center, Normal Shock Wave Equations (last updated May 13 2021): M₁² = [(γ − 1)M² + 2] ÷ [2γM² − (γ − 1)], the static temperature, static pressure, density and total pressure ratios, and Tt₁/Tt₀ = 1, for a compressible gas with no viscous effects in one-dimensional flow without heat addition, retrieved 2026-10-19. https://www.grc.nasa.gov/www/k-12/airplane/normal.html",
    "NASA Glenn Research Center, Isentropic Flow Equations (last updated May 13 2021): Eq. 6, p/pt = [1 + M²(γ − 1)/2]^−[γ/(γ − 1)], retrieved 2026-10-19. https://www.grc.nasa.gov/www/k-12/airplane/isentrop.html"
  ],
  "related": [
    "true-airspeed",
    "speed",
    "pressure",
    "density-altitude"
  ],
  "changelog": []
}
