{
  "version": 1,
  "topic": "DC11",
  "title": "Why monthly rate samples do not exactly equal analytical cumulative",
  "createdAt": "2026-10-24",
  "case": {
    "title": "Sampling error against an analytical integral",
    "premise": "Exponential qi = 1,000 STB/day, D = 0.001/day, 365-day horizon. Divide the interval into n equal widths.",
    "formula": "left = Σq(ti)Δt; right = Σq(ti+1)Δt; trapezoid = (left+right)/2",
    "variables": "These are instantaneous rate samples. The exact integral is the independent reference for quadrature error.",
    "steps": [
      {
        "label": "Define the baseline",
        "calculation": "Equal intervals n = 12",
        "explanation": "Exponential qi = 1,000 STB/day, D = 0.001/day, 365-day horizon. Divide the interval into n equal widths."
      },
      {
        "label": "Select the relation",
        "calculation": "left = Σq(ti)Δt; right = Σq(ti+1)Δt; trapezoid = (left+right)/2",
        "explanation": "These are instantaneous rate samples. The exact integral is the independent reference for quadrature error."
      },
      {
        "label": "Substitute the values",
        "calculation": "For n = 12, Δt = 365/12 days; sum the twelve left and twelve right endpoint rectangles and average them for trapezoids",
        "explanation": "Retain intermediate precision. The displayed values are rounded only after evaluation."
      },
      {
        "label": "Read the result",
        "calculation": "Left sum (STB) = 310477.685; Right sum (STB) = 301176.166; Trapezoid sum (STB) = 305826.926; Exact integral (STB) = 305803.349",
        "explanation": "For this decreasing curve, left sums are high and right sums low; refinement reduces the numerical integration gap."
      }
    ],
    "result": "Left sum (STB) = 310477.685; Right sum (STB) = 301176.166; Trapezoid sum (STB) = 305826.926; Exact integral (STB) = 305803.349",
    "interpretation": "For this decreasing curve, left sums are high and right sums low; refinement reduces the numerical integration gap.",
    "control": "Equal intervals n",
    "columns": [
      "Equal intervals n",
      "Left sum (STB)",
      "Right sum (STB)",
      "Trapezoid sum (STB)",
      "Exact integral (STB)"
    ],
    "rows": [
      [
        4,
        319967.78837613587,
        292063.23276875145,
        306015.51057244366,
        305803.3491220212
      ],
      [
        12,
        310477.68479211634,
        301176.16625632154,
        305826.92552421894,
        305803.3491220212
      ],
      [
        24,
        308134.6229246818,
        303483.8636567844,
        305809.2432907331,
        305803.3491220212
      ],
      [
        52,
        306877.85682714154,
        304731.3525496505,
        305804.604688396,
        305803.3491220212
      ],
      [
        365,
        305956.27628019423,
        305650.4729310723,
        305803.37460563326,
        305803.3491220212
      ]
    ],
    "baseline": 1,
    "rowNotes": [
      "Equal intervals n = 4. Left sum (STB): 319967.788; Right sum (STB): 292063.233; Trapezoid sum (STB): 306015.511; Exact integral (STB): 305803.349.",
      "Equal intervals n = 12. Left sum (STB): 310477.685; Right sum (STB): 301176.166; Trapezoid sum (STB): 305826.926; Exact integral (STB): 305803.349.",
      "Equal intervals n = 24. Left sum (STB): 308134.623; Right sum (STB): 303483.864; Trapezoid sum (STB): 305809.243; Exact integral (STB): 305803.349.",
      "Equal intervals n = 52. Left sum (STB): 306877.857; Right sum (STB): 304731.353; Trapezoid sum (STB): 305804.605; Exact integral (STB): 305803.349.",
      "Equal intervals n = 365. Left sum (STB): 305956.276; Right sum (STB): 305650.473; Trapezoid sum (STB): 305803.375; Exact integral (STB): 305803.349."
    ],
    "provenance": "Original synthetic teaching calculation. Equations and fixed controls are stated here; these are not field measurements.",
    "questions": [
      {
        "question": "Reproduce the baseline Left sum (STB) without rounding intermediate values.",
        "answer": "For n = 12, Δt = 365/12 days; sum the twelve left and twelve right endpoint rectangles and average them for trapezoids. Left sum (STB) = 310477.685. For this decreasing curve, left sums are high and right sums low; refinement reduces the numerical integration gap."
      },
      {
        "question": "Compare the first and last recorded scenarios. Which input changes?",
        "answer": "Equal intervals n changes from 4 to 365. Other controls remain as stated in the premise. Left sum (STB) changes from 319967.788 to 305956.276."
      },
      {
        "question": "What would be needed to apply this example to a different physical system?",
        "answer": "Replace the synthetic controls with compatible documented inputs and check the relation's assumptions. These are instantaneous rate samples. The exact integral is the independent reference for quadrature error. For this decreasing curve, left sums are high and right sums low; refinement reduces the numerical integration gap."
      }
    ]
  },
  "recorded": null
}
