{
  "schemaVersion": 1,
  "slug": "pizza-dough-calculator",
  "category": "cooking",
  "kind": "implementation",
  "independentValidation": false,
  "implementationHash": "6b4bbc64ed245cf00304b50ef9bececca7034fd54d73f8fc15871f44929c98a2",
  "provenance": "Generated from the calculation contract used by the published page. Publication is not external validation.",
  "sourceFiles": [
    "data/calculators/pizza-dough-calculator.json",
    "src/engine.js"
  ],
  "runtimeSource": "/sources/engine.txt",
  "runtimeHash": "5c888d8898afbdee36267bb9977829e1e2ac568f6677c8ee87469c139864645c",
  "scope": "The compute function records implemented equations, constants, lookup tables and custom rules. Inputs record defaults and allowed values; outputs record precision and units. Defaults are examples, not recommendations. General background references are not evidence for this specific algorithm.",
  "publishedFormula": {
    "formula": "M = π × (d ÷ 2)^2 × F × n; flour = M ÷ 1.65",
    "vars": [
      [
        "M",
        "Total dough (g)"
      ],
      [
        "d",
        "Diameter (in)"
      ],
      [
        "F",
        "Thickness factor"
      ],
      [
        "n",
        "Number of pizzas"
      ],
      [
        "flour",
        "Flour amount (g)"
      ]
    ],
    "note": "F from table: 1.8/2.2/2.8; water/yeast/salt = flour × 0.62/0.005/0.025."
  },
  "externalEvidence": null,
  "contract": {
    "compute": "const F = { thin:1.8, standard:2.2, thick:2.8 }; const area = Math.PI*Math.pow(diameter/2,2); const perPizza = area*(F[style]||2.2); const total = perPizza*pizzas; const flour = total/1.65; return { doughGrams: perPizza, totalDough: total, flourGrams: flour, waterGrams: flour*0.62, yeastGrams: flour*0.005, saltGrams: flour*0.025 };",
    "inputs": [
      {
        "name": "pizzas",
        "type": "number",
        "default": 4,
        "min": 1,
        "max": 200,
        "step": 1,
        "slider": true
      },
      {
        "name": "diameter",
        "type": "number",
        "default": 12,
        "min": 6,
        "max": 30,
        "step": 0.5,
        "slider": true
      },
      {
        "name": "style",
        "type": "select",
        "default": "standard",
        "options": [
          {
            "value": "thin"
          },
          {
            "value": "standard"
          },
          {
            "value": "thick"
          }
        ]
      }
    ],
    "outputs": [
      {
        "name": "doughGrams",
        "precision": 0,
        "unit": "g"
      },
      {
        "name": "totalDough",
        "precision": 0,
        "unit": "g"
      },
      {
        "name": "flourGrams",
        "precision": 0,
        "unit": "g"
      },
      {
        "name": "waterGrams",
        "precision": 0,
        "unit": "g"
      },
      {
        "name": "yeastGrams",
        "precision": 1,
        "unit": "g"
      },
      {
        "name": "saltGrams",
        "precision": 1,
        "unit": "g"
      }
    ],
    "interpret": null
  }
}
