Explicit invented inputs
Currency is USD; price is 19.99 per pack; each pack contains 12 items; the order quantity is three whole packs. The example rounds a displayed per-item price half-up to cents. Tax, freight, discounts, variable pack sizes and foreign exchange are excluded. This is arithmetic, not an invoice, purchase recommendation or accounting rule.
If the matrix is wider than the box, scroll horizontally to read every column. Keyboard: focus the matrix and use Left/Right.
items ordered = 12 items/pack × 3 packs = 36 items
pack-based amount = USD 19.99/pack × 3 packs = USD 59.97
unrounded item price = USD 19.99 ÷ 12 = USD 1.665833…
displayed item price, half-up = USD 1.67
wrong display-based total = USD 1.67 × 36 = USD 60.12
difference = USD 0.15The expected assertions
Assert 36 items and 5,997 cents as separate results. Assert that the 167-cent display value is not used to derive the amount. The local synthetic model uses exact integer-cent arithmetic for these nonnegative inputs; it is not a general decimal library or an implemented supplier importer.
- Unknown, zero, negative or fractional pack sizes are held under this example's whole-pack policy.
- Confirm whether the real supplier quotes per item, per pack or by weight before comparing.
- A real rounding policy must be chosen by the authorised business owner, not copied from this example.
What this evidence cannot establish
No supplier order, application preview or payment was executed. These checks cannot establish taxes, freight, legal invoice amounts or product equivalence. The correct arithmetic still produces a misleading comparison if the source's units or currency were mapped incorrectly.
- Keep quantity conversion and monetary basis visible in the acceptance request.
- Real documents and customer records are unnecessary for the initial reproduction.
Priced enquiry and non-fit
One existing-code calculation defect with an owner-approved unit and rounding rule may fit fix-one-bug-with-regression-test, from £295 after bounded synthetic reproduction and a fixed repair quote. Accounting policy, schema changes, landed-cost modelling and correction of real orders are not included. Send invented inputs, the stated basis and the expected results initially, not code or private financial documents. The price is untested and payment follows agreed passing checks and sign-off.
Sources and limits
- Python decimal: fixed-exponent quantize and rounding modes Checked 2026-10-11.
- quantize rounds to a fixed exponent; rounding policy must be selected explicitly.
- W3C tabular model: units need metadata Checked 2026-10-11.
- Units are not a built-in interpretation of numeric table values.
- Current local regression-test repair Checked 2026-10-11.