{
  "schemaVersion": 1,
  "slug": "square-footage-calculator",
  "category": "construction",
  "kind": "implementation",
  "independentValidation": false,
  "implementationHash": "5f1d3c617213b8c24f6b46a0443d539ab2020dfb39dd7d852901b2acee329012",
  "provenance": "Generated from the calculation contract used by the published page. Publication is not external validation.",
  "sourceFiles": [
    "data/calculators/square-footage-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": "A = L × W × n; sq yd = A÷9; m² = A×0.09290304; acres = A÷43560",
    "vars": [
      [
        "L",
        "Length (ft)"
      ],
      [
        "W",
        "Width (ft)"
      ],
      [
        "n",
        "Number of rooms"
      ]
    ],
    "note": "Total value = A × price per sq ft, when a price is entered."
  },
  "externalEvidence": null,
  "contract": {
    "compute": "const sqft = length*width*rooms; return { sqft, sqyd: sqft/9, sqm: sqft*0.09290304, acres: sqft/43560, totalValue: sqft*pricePerSqft };",
    "inputs": [
      {
        "name": "length",
        "type": "number",
        "default": 20,
        "min": 0,
        "max": 10000,
        "step": 0.25
      },
      {
        "name": "width",
        "type": "number",
        "default": 15,
        "min": 0,
        "max": 10000,
        "step": 0.25
      },
      {
        "name": "rooms",
        "type": "number",
        "default": 1,
        "min": 1,
        "max": 500,
        "step": 1,
        "slider": true
      },
      {
        "name": "pricePerSqft",
        "type": "number",
        "default": 0,
        "min": 0,
        "max": 5000,
        "step": 1,
        "slider": true
      }
    ],
    "outputs": [
      {
        "name": "sqft",
        "precision": 2,
        "unit": "sq ft"
      },
      {
        "name": "sqyd",
        "precision": 2,
        "unit": "sq yd"
      },
      {
        "name": "sqm",
        "precision": 2,
        "unit": "m²"
      },
      {
        "name": "acres",
        "precision": 4,
        "unit": "acres"
      },
      {
        "name": "totalValue",
        "precision": 0,
        "unit": "$"
      }
    ],
    "interpret": null
  }
}
