FAILURE MAP
← Case archive

FA-71686 / Seismic magnitude estimation / Open access

Brune source radius and stress drop: circular crack constant · case 01

Every stress drop is exactly zero.

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

ROOT CAUSE

Integer floor division turns 7/16 into 0.

VERIFIED REPAIR

Use 7.0/16.0.

Unsuccessful approach: The inverted constant 16/7 inflates stress drops fivefold.

Case contract

Seismic moment N*m, corner frequency Hz, shear velocity km/s; non-positive input returns None. r = 2.34 beta / (2 pi fc) in m; stress drop = 7/16 M0 / r^3 Pa. Return [r rounded 0.1 m, stress drop in MPa rounded 0.001].

Why this case matters

Stress drop characterises source physics and ground-motion scaling.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(m0_nm, fc_hz, beta_kms):
    if min(m0_nm, fc_hz, beta_kms) <= 0:
        return None
    r = 2.34 * beta_kms * 1000.0 / (2 * math.pi * fc_hz)
    ds = 7 // 16 * m0_nm / r ** 3
    return [round(r, 1), round(ds / 1e6, 3)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['M0 1.0e+12 fc 0.5 beta 3.2', [1000000000000.0, 0.5, 3.2], [2383.5, 0.0]], ['M0 1.0e+12 fc 0.5 beta 3.5', [1000000000000.0, 0.5, 3.5], [2607.0, 0.0]], ['M0 1.0e+12 fc 2.0 beta 3.2', [1000000000000.0, 2.0, 3.2], [595.9, 0.002]], ['M0 1.0e+12 fc 2.0 beta 3.5', [1000000000000.0, 2.0, 3.5], [651.7, 0.002]], ['M0 1.0e+12 fc 10.0 beta 3.2', [1000000000000.0, 10.0, 3.2], [119.2, 0.258]], ['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.2', [350000000000000.0, 0.5, 3.2], [2383.5, 0.011]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]]], [['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 3.5e+14 fc 2.0 beta 3.5', [350000000000000.0, 2.0, 3.5], [651.7, 0.553]], ['M0 3.5e+14 fc 10.0 beta 3.2', [350000000000000.0, 10.0, 3.2], [119.2, 90.467]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]], ['M0 2.0e+17 fc 0.5 beta 3.2', [2e+17, 0.5, 3.2], [2383.5, 6.462]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]]], [['M0 1.0e+12 fc 0.5 beta 3.2', [1000000000000.0, 0.5, 3.2], [2383.5, 0.0]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]], ['M0 2.0e+17 fc 2.0 beta 3.2', [2e+17, 2.0, 3.2], [595.9, 413.562]], ['M0 2.0e+17 fc 2.0 beta 3.5', [2e+17, 2.0, 3.5], [651.7, 316.072]], ['M0 2.0e+17 fc 10.0 beta 3.2', [2e+17, 10.0, 3.2], [119.2, 51695.192]], ['M0 2.0e+17 fc 10.0 beta 3.5', [2e+17, 10.0, 3.5], [130.3, 39508.992]], ['zero corner', [100000000000000.0, 0, 3.5], None]], [['M0 1.0e+12 fc 2.0 beta 3.2', [1000000000000.0, 2.0, 3.2], [595.9, 0.002]], ['M0 1.0e+12 fc 2.0 beta 3.5', [1000000000000.0, 2.0, 3.5], [651.7, 0.002]], ['M0 1.0e+12 fc 10.0 beta 3.2', [1000000000000.0, 10.0, 3.2], [119.2, 0.258]], ['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.2', [350000000000000.0, 0.5, 3.2], [2383.5, 0.011]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]]], [['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.5', [350000000000000.0, 2.0, 3.5], [651.7, 0.553]], ['M0 3.5e+14 fc 10.0 beta 3.2', [350000000000000.0, 10.0, 3.2], [119.2, 90.467]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]], ['M0 2.0e+17 fc 0.5 beta 3.2', [2e+17, 0.5, 3.2], [2383.5, 6.462]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]], ['M0 2.0e+17 fc 2.0 beta 3.2', [2e+17, 2.0, 3.2], [595.9, 413.562]], ['M0 2.0e+17 fc 2.0 beta 3.5', [2e+17, 2.0, 3.5], [651.7, 316.072]]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
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
M0 1.0e+12 fc 0.5 beta 3.2[2383.5, 0.0][2383.5, 0.0]Passed
M0 1.0e+12 fc 0.5 beta 3.5[2607.0, 0.0][2607.0, 0.0]Passed
M0 1.0e+12 fc 2.0 beta 3.2[595.9, 0.0][595.9, 0.002]Failed
M0 1.0e+12 fc 2.0 beta 3.5[651.7, 0.0][651.7, 0.002]Failed
M0 1.0e+12 fc 10.0 beta 3.2[119.2, 0.0][119.2, 0.258]Failed
M0 1.0e+12 fc 10.0 beta 3.5[130.3, 0.0][130.3, 0.198]Failed
M0 3.5e+14 fc 0.5 beta 3.2[2383.5, 0.0][2383.5, 0.011]Failed
M0 3.5e+14 fc 0.5 beta 3.5[2607.0, 0.0][2607.0, 0.009]Failed

SHA-256 / ac017247730d74cec609b225196f3e8a13bd3ce044a409b050e6739db873859d

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(m0_nm, fc_hz, beta_kms):
    if min(m0_nm, fc_hz, beta_kms) <= 0:
        return None
    r = 2.34 * beta_kms * 1000.0 / (2 * math.pi * fc_hz)
    ds = 16.0 / 7.0 * m0_nm / r ** 3
    return [round(r, 1), round(ds / 1e6, 3)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['M0 1.0e+12 fc 0.5 beta 3.2', [1000000000000.0, 0.5, 3.2], [2383.5, 0.0]], ['M0 1.0e+12 fc 0.5 beta 3.5', [1000000000000.0, 0.5, 3.5], [2607.0, 0.0]], ['M0 1.0e+12 fc 2.0 beta 3.2', [1000000000000.0, 2.0, 3.2], [595.9, 0.002]], ['M0 1.0e+12 fc 2.0 beta 3.5', [1000000000000.0, 2.0, 3.5], [651.7, 0.002]], ['M0 1.0e+12 fc 10.0 beta 3.2', [1000000000000.0, 10.0, 3.2], [119.2, 0.258]], ['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.2', [350000000000000.0, 0.5, 3.2], [2383.5, 0.011]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]]], [['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 3.5e+14 fc 2.0 beta 3.5', [350000000000000.0, 2.0, 3.5], [651.7, 0.553]], ['M0 3.5e+14 fc 10.0 beta 3.2', [350000000000000.0, 10.0, 3.2], [119.2, 90.467]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]], ['M0 2.0e+17 fc 0.5 beta 3.2', [2e+17, 0.5, 3.2], [2383.5, 6.462]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]]], [['M0 1.0e+12 fc 0.5 beta 3.2', [1000000000000.0, 0.5, 3.2], [2383.5, 0.0]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]], ['M0 2.0e+17 fc 2.0 beta 3.2', [2e+17, 2.0, 3.2], [595.9, 413.562]], ['M0 2.0e+17 fc 2.0 beta 3.5', [2e+17, 2.0, 3.5], [651.7, 316.072]], ['M0 2.0e+17 fc 10.0 beta 3.2', [2e+17, 10.0, 3.2], [119.2, 51695.192]], ['M0 2.0e+17 fc 10.0 beta 3.5', [2e+17, 10.0, 3.5], [130.3, 39508.992]], ['zero corner', [100000000000000.0, 0, 3.5], None]], [['M0 1.0e+12 fc 2.0 beta 3.2', [1000000000000.0, 2.0, 3.2], [595.9, 0.002]], ['M0 1.0e+12 fc 2.0 beta 3.5', [1000000000000.0, 2.0, 3.5], [651.7, 0.002]], ['M0 1.0e+12 fc 10.0 beta 3.2', [1000000000000.0, 10.0, 3.2], [119.2, 0.258]], ['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.2', [350000000000000.0, 0.5, 3.2], [2383.5, 0.011]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]]], [['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.5', [350000000000000.0, 2.0, 3.5], [651.7, 0.553]], ['M0 3.5e+14 fc 10.0 beta 3.2', [350000000000000.0, 10.0, 3.2], [119.2, 90.467]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]], ['M0 2.0e+17 fc 0.5 beta 3.2', [2e+17, 0.5, 3.2], [2383.5, 6.462]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]], ['M0 2.0e+17 fc 2.0 beta 3.2', [2e+17, 2.0, 3.2], [595.9, 413.562]], ['M0 2.0e+17 fc 2.0 beta 3.5', [2e+17, 2.0, 3.5], [651.7, 316.072]]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
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
M0 1.0e+12 fc 0.5 beta 3.2[2383.5, 0.0][2383.5, 0.0]Passed
M0 1.0e+12 fc 0.5 beta 3.5[2607.0, 0.0][2607.0, 0.0]Passed
M0 1.0e+12 fc 2.0 beta 3.2[595.9, 0.011][595.9, 0.002]Failed
M0 1.0e+12 fc 2.0 beta 3.5[651.7, 0.008][651.7, 0.002]Failed
M0 1.0e+12 fc 10.0 beta 3.2[119.2, 1.35][119.2, 0.258]Failed
M0 1.0e+12 fc 10.0 beta 3.5[130.3, 1.032][130.3, 0.198]Failed
M0 3.5e+14 fc 0.5 beta 3.2[2383.5, 0.059][2383.5, 0.011]Failed
M0 3.5e+14 fc 0.5 beta 3.5[2607.0, 0.045][2607.0, 0.009]Failed

SHA-256 / fc7ef544362b5f90833f2e9a14839aa8d6f6a6d310ab2d661a501fd1441f987d

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(m0_nm, fc_hz, beta_kms):
    if min(m0_nm, fc_hz, beta_kms) <= 0:
        return None
    r = 2.34 * beta_kms * 1000.0 / (2 * math.pi * fc_hz)
    ds = 7.0 / 16.0 * m0_nm / r ** 3
    return [round(r, 1), round(ds / 1e6, 3)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['M0 1.0e+12 fc 0.5 beta 3.2', [1000000000000.0, 0.5, 3.2], [2383.5, 0.0]], ['M0 1.0e+12 fc 0.5 beta 3.5', [1000000000000.0, 0.5, 3.5], [2607.0, 0.0]], ['M0 1.0e+12 fc 2.0 beta 3.2', [1000000000000.0, 2.0, 3.2], [595.9, 0.002]], ['M0 1.0e+12 fc 2.0 beta 3.5', [1000000000000.0, 2.0, 3.5], [651.7, 0.002]], ['M0 1.0e+12 fc 10.0 beta 3.2', [1000000000000.0, 10.0, 3.2], [119.2, 0.258]], ['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.2', [350000000000000.0, 0.5, 3.2], [2383.5, 0.011]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]]], [['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 3.5e+14 fc 2.0 beta 3.5', [350000000000000.0, 2.0, 3.5], [651.7, 0.553]], ['M0 3.5e+14 fc 10.0 beta 3.2', [350000000000000.0, 10.0, 3.2], [119.2, 90.467]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]], ['M0 2.0e+17 fc 0.5 beta 3.2', [2e+17, 0.5, 3.2], [2383.5, 6.462]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]]], [['M0 1.0e+12 fc 0.5 beta 3.2', [1000000000000.0, 0.5, 3.2], [2383.5, 0.0]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]], ['M0 2.0e+17 fc 2.0 beta 3.2', [2e+17, 2.0, 3.2], [595.9, 413.562]], ['M0 2.0e+17 fc 2.0 beta 3.5', [2e+17, 2.0, 3.5], [651.7, 316.072]], ['M0 2.0e+17 fc 10.0 beta 3.2', [2e+17, 10.0, 3.2], [119.2, 51695.192]], ['M0 2.0e+17 fc 10.0 beta 3.5', [2e+17, 10.0, 3.5], [130.3, 39508.992]], ['zero corner', [100000000000000.0, 0, 3.5], None]], [['M0 1.0e+12 fc 2.0 beta 3.2', [1000000000000.0, 2.0, 3.2], [595.9, 0.002]], ['M0 1.0e+12 fc 2.0 beta 3.5', [1000000000000.0, 2.0, 3.5], [651.7, 0.002]], ['M0 1.0e+12 fc 10.0 beta 3.2', [1000000000000.0, 10.0, 3.2], [119.2, 0.258]], ['M0 1.0e+12 fc 10.0 beta 3.5', [1000000000000.0, 10.0, 3.5], [130.3, 0.198]], ['M0 3.5e+14 fc 0.5 beta 3.2', [350000000000000.0, 0.5, 3.2], [2383.5, 0.011]], ['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.2', [350000000000000.0, 2.0, 3.2], [595.9, 0.724]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]]], [['M0 3.5e+14 fc 0.5 beta 3.5', [350000000000000.0, 0.5, 3.5], [2607.0, 0.009]], ['M0 3.5e+14 fc 2.0 beta 3.5', [350000000000000.0, 2.0, 3.5], [651.7, 0.553]], ['M0 3.5e+14 fc 10.0 beta 3.2', [350000000000000.0, 10.0, 3.2], [119.2, 90.467]], ['M0 3.5e+14 fc 10.0 beta 3.5', [350000000000000.0, 10.0, 3.5], [130.3, 69.141]], ['M0 2.0e+17 fc 0.5 beta 3.2', [2e+17, 0.5, 3.2], [2383.5, 6.462]], ['M0 2.0e+17 fc 0.5 beta 3.5', [2e+17, 0.5, 3.5], [2607.0, 4.939]], ['M0 2.0e+17 fc 2.0 beta 3.2', [2e+17, 2.0, 3.2], [595.9, 413.562]], ['M0 2.0e+17 fc 2.0 beta 3.5', [2e+17, 2.0, 3.5], [651.7, 316.072]]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
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
M0 1.0e+12 fc 0.5 beta 3.2[2383.5, 0.0][2383.5, 0.0]Passed
M0 1.0e+12 fc 0.5 beta 3.5[2607.0, 0.0][2607.0, 0.0]Passed
M0 1.0e+12 fc 2.0 beta 3.2[595.9, 0.002][595.9, 0.002]Passed
M0 1.0e+12 fc 2.0 beta 3.5[651.7, 0.002][651.7, 0.002]Passed
M0 1.0e+12 fc 10.0 beta 3.2[119.2, 0.258][119.2, 0.258]Passed
M0 1.0e+12 fc 10.0 beta 3.5[130.3, 0.198][130.3, 0.198]Passed
M0 3.5e+14 fc 0.5 beta 3.2[2383.5, 0.011][2383.5, 0.011]Passed
M0 3.5e+14 fc 0.5 beta 3.5[2607.0, 0.009][2607.0, 0.009]Passed

SHA-256 / 66130856701193ce2a367d18c2264c7edb6e9505f5d2f2cc3e4832363e8e220f

Verification & scope

Stipulated deterministic teaching model of a seismological magnitude procedure; constants and tables are fixed by the contract and no claim of agency or standards conformance is made. 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:48:31.812497+00:00.

Case digest / 4876747f185758a8bf09ec02e7070f3ba08850a94c7101c0b7b396deef3ed25a