FAILURE MAP
← Case archive

FA-93636 / Solar tracker geometry / Open access

Cross-axis slope aware backtracking: limit applied after backtracking · case 01

Backtracked angles are computed from a pre-clamped ideal angle.

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

ROOT CAUSE

The rotation limit is applied to the ideal angle before backtracking instead of to the result.

THE FAILURE

The rotation limit is applied to the ideal angle before backtracking instead of to the result.

Unsuccessful approach: Clamping only the positive side lets eastern angles pass the stop.

Case contract

Rows on terrain with cross-axis slope cross_tilt degrees. dist = 1/(gcr*cos(cross_tilt)); temp = dist*cos(ideal - cross_tilt). When temp < 1 the angle becomes ideal - sign(ideal)*acos(max(temp, -1)) degrees, else ideal. The result is then clamped to +-max_angle. Return the angle rounded to 3.

Why this case matters

Single-axis and dual-axis solar trackers turn a sun direction into actuator commands; a sign, frame or limit mistake points a whole plant away from the sun or into a mechanical stop.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(ideal, gcr, cross_tilt, max_angle):
    ideal = max(-max_angle, min(max_angle, ideal))
    dist = 1 / (gcr * math.cos(math.radians(cross_tilt)))
    temp = dist * math.cos(math.radians(ideal - cross_tilt))
    if temp < 1:
        theta = ideal - math.copysign(math.degrees(math.acos(max(temp, -1.0))), ideal)
    else:
        theta = ideal
    return round(theta, 3)
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-80, 0.5, 0, 75], -10.322],
  ['regression: limit applied after backtracking (partial repair)', [-60, 0.3, 10, 50], -50],
  ['control 1', [-45, 0.5, -5, 50], -45], ['control 2', [-60, 0.3, 0, 60], -60]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [60, 0.5, -5, 55], 28.045],
  ['regression: limit applied after backtracking (partial repair)', [-70, 0.3, -5, 60], -60],
  ['control 1', [80, 0.4, 0, 60], 15.729], ['control 2', [-80, 0.4, 15, 75], 23.037]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-70, 0.3, 15, 60], 2.496],
  ['regression: limit applied after backtracking (partial repair)', [-70, 0.3, -5, 50], -50],
  ['control 1', [0, 0.4, -5, 55], 0], ['control 2', [70, 0.4, -5, 75], 20.505]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-80, 0.4, -10, 75], -50.255],
  ['regression: limit applied after backtracking (partial repair)', [-60, 0.5, 0, 50], -50],
  ['control 1', [-60, 0.4, -5, 50], -50], ['control 2', [0, 0.4, -5, 60], 0]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-80, 0.4, 0, 75], -15.729],
  ['regression: limit applied after backtracking (partial repair)', [-70, 0.3, -5, 60], -60],
  ['control 1', [-80, 0.5, 0, 75], -10.322], ['control 2', [-45, 0.4, 15, 50], -45]]]
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
normal: flat terrain matches plain backtracking-60-38.765Failed
boundary: slope-facing noon00Passed
boundary: clamp after backtracking50-10.0Failed
regression: limit applied after backtracking-16.174-10.322Failed
regression: limit applied after backtracking (partial repair)-50-50Passed
control 1-45-45Passed
control 2-60-60Passed

SHA-256 / da3f210b9bc8561c24bb682685ec3d7572ee5c9089b199cfecd3359d427a1033

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
N = 1
observations = []
def solve(ideal, gcr, cross_tilt, max_angle):
    dist = 1 / (gcr * math.cos(math.radians(cross_tilt)))
    temp = dist * math.cos(math.radians(ideal - cross_tilt))
    if temp < 1:
        theta = ideal - math.copysign(math.degrees(math.acos(max(temp, -1.0))), ideal)
    else:
        theta = ideal
    theta = min(max_angle, theta)
    return round(theta, 3)
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-80, 0.5, 0, 75], -10.322],
  ['regression: limit applied after backtracking (partial repair)', [-60, 0.3, 10, 50], -50],
  ['control 1', [-45, 0.5, -5, 50], -45], ['control 2', [-60, 0.3, 0, 60], -60]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [60, 0.5, -5, 55], 28.045],
  ['regression: limit applied after backtracking (partial repair)', [-70, 0.3, -5, 60], -60],
  ['control 1', [80, 0.4, 0, 60], 15.729], ['control 2', [-80, 0.4, 15, 75], 23.037]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-70, 0.3, 15, 60], 2.496],
  ['regression: limit applied after backtracking (partial repair)', [-70, 0.3, -5, 50], -50],
  ['control 1', [0, 0.4, -5, 55], 0], ['control 2', [70, 0.4, -5, 75], 20.505]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-80, 0.4, -10, 75], -50.255],
  ['regression: limit applied after backtracking (partial repair)', [-60, 0.5, 0, 50], -50],
  ['control 1', [-60, 0.4, -5, 50], -50], ['control 2', [0, 0.4, -5, 60], 0]],
 [['normal: flat terrain matches plain backtracking', [-70, 0.4, 0, 60], -38.765],
  ['boundary: slope-facing noon', [0, 0.4, 10, 60], 0],
  ['boundary: clamp after backtracking', [80, 0.3, -10, 50], -10.0],
  ['regression: limit applied after backtracking', [-80, 0.4, 0, 75], -15.729],
  ['regression: limit applied after backtracking (partial repair)', [-70, 0.3, -5, 60], -60],
  ['control 1', [-80, 0.5, 0, 75], -10.322], ['control 2', [-45, 0.4, 15, 50], -45]]]
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
normal: flat terrain matches plain backtracking-38.765-38.765Passed
boundary: slope-facing noon00Passed
boundary: clamp after backtracking-10.0-10.0Passed
regression: limit applied after backtracking-10.322-10.322Passed
regression: limit applied after backtracking (partial repair)-60-50Failed
control 1-45-45Passed
control 2-60-60Passed

SHA-256 / 7c014ece79e313c22ca19571b101b6d3d6d2785792c8739a89aee60d0593fc87

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 7 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.

Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.

Member access is invitation-based. Sign in with your invited account to inspect the repair.

Sign in to the archive ↗

Verification & scope

Deterministic stipulated toy contract for teaching; no claim of conformance with any standard, vendor protocol or production controller. 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:51:56.910169+00:00.

Case digest / 3b9d6b5c13482456176e82f9f82b980adee6ff57e1bd8ffe3e0d8d915deddeff