{
  "schemaVersion": 1,
  "slug": "rabbit-hutch-size-calculator",
  "category": "pets",
  "kind": "implementation",
  "independentValidation": false,
  "implementationHash": "0d3fd7f57f444e8764862840c6fee52a78c3131648713a2c23194cc212de8024",
  "provenance": "Generated from the calculation contract used by the published page. Publication is not external validation.",
  "sourceFiles": [
    "data/calculators/rabbit-hutch-size-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 = 64.6 ft² × ceil(rabbits ÷ 2); shelter reference = 6 × 2 × 2 ft per pair",
    "vars": [
      [
        "N",
        "Number of rabbits"
      ],
      [
        "k",
        "Size factor"
      ],
      [
        "b",
        "Run bonus"
      ],
      [
        "h",
        "Confinement factor"
      ],
      [
        "L",
        "Hutch length (ft)"
      ],
      [
        "R",
        "Run area (ft²)"
      ],
      [
        "D",
        "Hutch depth (ft)"
      ]
    ],
    "note": "For two medium rabbits, total living area reference = 3 m × 2 m = 6 m² (64.6 sq ft) with 1 m height, including shelter and exercise. Shelter/run split and scaling for additional pairs are illustrative, not official minimums; larger breeds and groups may require more. Reference: RSPCA UK."
  },
  "externalEvidence": {
    "reviewedAt": "2026-09-26",
    "sources": [
      {
        "name": "RSPCA UK — Rabbit Living Space",
        "url": "https://www.rspca.org.uk/adviceandwelfare/pets/rabbits/environment"
      },
      {
        "name": "RSPCA UK — Rabbit Adoption",
        "url": "https://www.rspca.org.uk/findapet/adopt/rabbit"
      }
    ]
  },
  "contract": {
    "compute": "const pairs=Math.max(1,Math.ceil(rabbits/2)),scale=Math.sqrt(pairs),hutchLength=6.56*scale,hutchDepth=3.28*scale,hutchHeight=2.46,runArea=Math.max(0,64.6*pairs-hutchLength*hutchDepth);return{hutchLength,hutchDepth,hutchHeight,runArea,totalLivingArea:64.6*pairs};",
    "inputs": [
      {
        "name": "rabbits",
        "type": "number",
        "default": 2,
        "min": 1,
        "max": 10,
        "step": 1
      }
    ],
    "outputs": [
      {
        "name": "hutchLength",
        "precision": 1,
        "unit": "ft"
      },
      {
        "name": "hutchDepth",
        "precision": 1,
        "unit": "ft"
      },
      {
        "name": "hutchHeight",
        "precision": 1,
        "unit": "ft"
      },
      {
        "name": "runArea",
        "precision": 0,
        "unit": "sq ft"
      },
      {
        "name": "totalLivingArea",
        "precision": 1,
        "unit": "sq ft"
      }
    ],
    "interpret": null
  }
}
