FAILURE MAP
← Case archive

FA-5816 / Planar geometry / Open access

Rhombus area from diagonals · case 01

Diagonal product is not halved.

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

ROOT CAUSE

Diagonal product is not halved.

VERIFIED REPAIR

Apply the specified mathematical contract directly, preserving all terms and boundary cases: return d1*d2/2

Unsuccessful approach: Averaging diagonal lengths does not compute area.

Case contract

Integer coordinates and lengths, with exact arithmetic except for indicated division results. Lengths are nonnegative. Rectangles are (xmin,ymin,xmax,ymax) with ordered bounds; coordinate vectors have matching dimensions. Rhombus area from diagonals. Exact operational definition: d1*d2/2

Why this case matters

Small exact fixtures expose this error without platform timing, external services, or probabilistic observations. Planar 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(d1, d2):
    return d1*d2
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1: (6, 8)', solve(*(6, 8)), 24)
check('fixture 2: (2, 2)', solve(*(2, 2)), 2)
check('fixture 3: (0, 7)', solve(*(0, 7)), 0)
check('fixture 4: (4, 3)', solve(*(4, 3)), 6)
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: (6, 8)4824Failed
fixture 2: (2, 2)42Failed
fixture 3: (0, 7)00Passed
fixture 4: (4, 3)126Failed

SHA-256 / 4c9b6b57224f09989f6443d63b9aedf16ed457294a9153f4490740fb2b3929a5

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(d1, d2):
    return (d1+d2)/2
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1: (6, 8)', solve(*(6, 8)), 24)
check('fixture 2: (2, 2)', solve(*(2, 2)), 2)
check('fixture 3: (0, 7)', solve(*(0, 7)), 0)
check('fixture 4: (4, 3)', solve(*(4, 3)), 6)
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: (6, 8)7.024Failed
fixture 2: (2, 2)2.02Passed
fixture 3: (0, 7)3.50Failed
fixture 4: (4, 3)3.56Failed

SHA-256 / d8cf712c6f063725829b159a8dd71e93c717946afa278d39d7f6c1b14d87c0f3

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(d1, d2):
    return d1*d2/2
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1: (6, 8)', solve(*(6, 8)), 24)
check('fixture 2: (2, 2)', solve(*(2, 2)), 2)
check('fixture 3: (0, 7)', solve(*(0, 7)), 0)
check('fixture 4: (4, 3)', solve(*(4, 3)), 6)
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: (6, 8)24.024Passed
fixture 2: (2, 2)2.02Passed
fixture 3: (0, 7)0.00Passed
fixture 4: (4, 3)6.06Passed

SHA-256 / 314bbabaa39e36daffcd4a2e5557703d52c3974a3b1baa59836bc6d90943b381

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:54.060271+00:00.

Case digest / 962ac5bde684048c4d6d39c3408caa46eac98be6725a01c798c46296d099e5c7