FA-65984 / Aviation weight and balance / Member archive
Already-at-target request reported as a direction error · case 04
Asking to reach the CG the aircraft already has returns ERR_DIRECTION for aft station moves.
Case contract
Input [total lb, current CG, target CG, from-station arm, to-station arm]. Weight to move = W*dCG/dArm, rounded UP to a whole pound after clearing float noise at 6 decimals. Same station -> 'ERR_SAME_STATION'; zero dCG -> 0; a move that shifts CG the wrong way -> 'ERR_DIRECTION'.
Why this case matters
The weight-shift formula moves existing load between stations without changing total weight; the answer must be conservative (rounded up).
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| already at target | "ERR_DIRECTION" | 0 | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗