FAILURE MAP
← Case archive

FA-96984 / Recipe scaling and nutrition / Member archive

Atwater energy calculator: fiber subtraction · case 04

High-fiber breads are credited 6 kcal per gram of fiber.

Member previewVariant 4 · 3 implementations · 8 checks per implementation

Case contract

Gram amounts as strings. Total carbohydrate includes fiber and polyols; available carb = max(0, carb - fiber - polyol). kcal = 4*protein + 9*fat + 4*available + 2*fiber + 7*alcohol + 2.4*polyol. Return [kcal, kJ, fat_energy_pct]: kcal half-up integer of the exact energy, kJ half-up integer of exact kcal * 4.184, fat pct = half-up of 9*fat/exact kcal*100 (0 if energy is 0).

Why this case matters

Recipe energy totals use factor systems where fiber and sugar alcohols are not full carbohydrate.

One recorded failure

Sample boundary fixture

This sample comes from the broken implementation of a controlled reproducer.

Boundary fixtureActualExpectedOutcome
sugar-free candy[135, 565, 33][131, 548, 34]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 ↗