FAILURE MAP
← Case archive

FA-5966 / Solid geometry / Open access

Spherical cap volume divided by pi · case 01

The cap cubic correction is omitted.

Verified by executionVariant 1 · 4 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The cap cubic correction is omitted.

VERIFIED REPAIR

Apply the specified mathematical contract directly, preserving all terms and boundary cases: return h*h*(R-h/3)

Unsuccessful approach: The radius term is divided by three along with the height term.

Case contract

Nonnegative integer dimensions; exact products and ordinary Python real division. Quantities named divided by pi or pi-squared deliberately omit that factor from the returned result. R>=0 and 0<=h<=2*R; the output is spherical-cap volume divided by pi. Exact operational definition: h*h*(R-h/3)

Why this case matters

Small exact fixtures expose this error without platform timing, external services, or probabilistic observations. Solid geometry results depend on the stated convention.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
import calendar
import statistics
import itertools
from fractions import Fraction
from datetime import date, datetime, timedelta, timezone
from decimal import Decimal, ROUND_HALF_UP, ROUND_DOWN, ROUND_CEILING, ROUND_FLOOR

N = 1
observations = []
def solve(R, h):
    return R*h*h
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1: (3, 3)', solve(*(3, 3)), 18)
check('fixture 2: (3, 6)', solve(*(3, 6)), 36)
check('fixture 3: (4, 0)', solve(*(4, 0)), 0)
check('fixture 4: (2, 1)', solve(*(2, 1)), 1.6666666666666667)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
fixture 1: (3, 3)2718Failed
fixture 2: (3, 6)10836Failed
fixture 3: (4, 0)00Passed
fixture 4: (2, 1)21.6666666666666667Failed

SHA-256 / 53fed256a74bb6999eb7b5e0102c78a4541d169537a6c71cab4611f1709ead9a

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
import calendar
import statistics
import itertools
from fractions import Fraction
from datetime import date, datetime, timedelta, timezone
from decimal import Decimal, ROUND_HALF_UP, ROUND_DOWN, ROUND_CEILING, ROUND_FLOOR

N = 1
observations = []
def solve(R, h):
    return h*h*(R-h)/3
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1: (3, 3)', solve(*(3, 3)), 18)
check('fixture 2: (3, 6)', solve(*(3, 6)), 36)
check('fixture 3: (4, 0)', solve(*(4, 0)), 0)
check('fixture 4: (2, 1)', solve(*(2, 1)), 1.6666666666666667)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
fixture 1: (3, 3)0.018Failed
fixture 2: (3, 6)-36.036Failed
fixture 3: (4, 0)0.00Passed
fixture 4: (2, 1)0.33333333333333331.6666666666666667Failed

SHA-256 / 8cb42e5697bfc3dfc9c1a1216c13170ff94b5f6576ce74218e2e5834d3ef9928

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json
import math
import calendar
import statistics
import itertools
from fractions import Fraction
from datetime import date, datetime, timedelta, timezone
from decimal import Decimal, ROUND_HALF_UP, ROUND_DOWN, ROUND_CEILING, ROUND_FLOOR

N = 1
observations = []
def solve(R, h):
    return h*h*(R-h/3)
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1: (3, 3)', solve(*(3, 3)), 18)
check('fixture 2: (3, 6)', solve(*(3, 6)), 36)
check('fixture 3: (4, 0)', solve(*(4, 0)), 0)
check('fixture 4: (2, 1)', solve(*(2, 1)), 1.6666666666666667)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
fixture 1: (3, 3)18.018Passed
fixture 2: (3, 6)36.036Passed
fixture 3: (4, 0)0.00Passed
fixture 4: (2, 1)1.66666666666666671.6666666666666667Passed

SHA-256 / 1196d8446a53d9f62ed0fda6473712d98b8ea884fa048d6ff67c0a81cc85377a

Verification & scope

This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.

Observations recorded using Python 3.12.14 at 2026-09-29T14:37:56.056838+00:00.

Case digest / d0a64a3c64a1a4781bfe0cbebb2d18452bb4c09b9396548cafe092f96587efdf