{
  "schemaVersion": 1,
  "slug": "snow-removal-cost-calculator",
  "category": "household",
  "kind": "implementation",
  "independentValidation": false,
  "implementationHash": "3568b68086540e5a0c91198735c01a78b83af4062079fa53396e163bb355e5f4",
  "provenance": "Generated from the calculation contract used by the published page. Publication is not external validation.",
  "sourceFiles": [
    "data/calculators/snow-removal-cost-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": "k = max(1, ⌈d÷6⌉); C = r×k×t×(1 + L×W÷6000); C_s = C×n×5",
    "vars": [
      [
        "L",
        "Length (ft)"
      ],
      [
        "W",
        "Width (ft)"
      ],
      [
        "d",
        "Snow depth (in)"
      ],
      [
        "r",
        "Rate per push ($)"
      ],
      [
        "t",
        "Snow-type factor"
      ],
      [
        "n",
        "Storms per month"
      ],
      [
        "k",
        "Pushes per storm"
      ],
      [
        "C",
        "Cost per storm ($)"
      ],
      [
        "C_s",
        "Seasonal cost ($)"
      ]
    ],
    "note": "Scenario cost applies assumed depth-based pushes, a snow-type multiplier and an area adjustment to the entered rate; monthly/seasonal totals assume five months. Factors are not market prices."
  },
  "externalEvidence": null,
  "contract": {
    "compute": "const T = { powder:0.8, average:1, wet:1.3, ice:1.6 }; const area = length*width; const pushesPerStorm = Math.max(1, Math.ceil(snowDepth/6)); const costPerStorm = ratePerPush*pushesPerStorm*(T[snowType] || 1)*(1+area/6000); return { area, pushesPerStorm, costPerStorm, monthlyCost: costPerStorm*stormsPerMonth, seasonalCost: costPerStorm*stormsPerMonth*5 };",
    "inputs": [
      {
        "name": "length",
        "type": "number",
        "default": 40,
        "min": 1,
        "max": 2000,
        "step": 1,
        "slider": true
      },
      {
        "name": "width",
        "type": "number",
        "default": 12,
        "min": 1,
        "max": 200,
        "step": 0.5,
        "slider": true
      },
      {
        "name": "snowDepth",
        "type": "number",
        "default": 6,
        "min": 0.5,
        "max": 36,
        "step": 0.5,
        "slider": true
      },
      {
        "name": "stormsPerMonth",
        "type": "number",
        "default": 4,
        "min": 0,
        "max": 31,
        "step": 1,
        "slider": true
      },
      {
        "name": "ratePerPush",
        "type": "number",
        "default": 50,
        "min": 0,
        "max": 1000,
        "step": 5,
        "slider": true
      },
      {
        "name": "snowType",
        "type": "select",
        "default": "average",
        "options": [
          {
            "value": "powder"
          },
          {
            "value": "average"
          },
          {
            "value": "wet"
          },
          {
            "value": "ice"
          }
        ]
      }
    ],
    "outputs": [
      {
        "name": "area",
        "precision": 0,
        "unit": "sq ft"
      },
      {
        "name": "pushesPerStorm",
        "precision": 0,
        "unit": ""
      },
      {
        "name": "costPerStorm",
        "precision": 2,
        "unit": "$"
      },
      {
        "name": "monthlyCost",
        "precision": 2,
        "unit": "$"
      },
      {
        "name": "seasonalCost",
        "precision": 0,
        "unit": "$"
      }
    ],
    "interpret": null
  }
}
