The variance was three-tenths of a cent. It took eleven days to find.
A reconciliation analyst sat with three monitors showing the legacy ledger, the new cloud-native accounting engine, and the global custodian’s statement. The trade counts matched. The unit balances matched. The exchange rates matched. But the cash settlement was off by a fraction of a minor unit.
Every system that moves money rounds. Every rounding rule is a decision. Most of those decisions were made by someone who left the company a decade ago, and they are embedded in a compiler default.
Month three of a ledger migration parallel run. The steering committee looks at a 99.6 percent match rate. The migration cannot go live until the match rate hits 100 percent or the breaks are fully explained. The remaining 0.4 percent consists entirely of sub-unit discrepancies on cross-border transactions.
The project team assumes a data mapping error. They check the incoming feeds, the reference data, and the trade state. The data is perfect. The discrepancy is baked into the math library.
The legacy mainframe rounds half-up. Two and a half becomes three. The new microservice uses a standard floating-point library that defaults to half-even, also known as banker’s rounding. Two and a half becomes two. Three and a half becomes four.
Banker’s rounding is not more correct. It is less biased over large volumes. But those are different things, and the custodian’s mainframe does not care about statistical bias. It cares about the posted amount.
Rounding answers one question about a midpoint. It does not describe the calculation. Systems do not disagree on the math. They disagree on the sequence of the math.
Consider a foreign exchange translation. A fund buys equities in a foreign market. System A multiplies the quantity by the share price, rounds the result to two decimal places, and then multiplies by the FX rate before rounding again. System B multiplies the quantity, the share price, and the FX rate together, carrying eight decimal places of intermediate precision, and rounds only at the final step.
Both calculations are mathematically defensible. Both will fail the counterparty matching process at the clearinghouse.
The same friction applies to aggregation. A fee engine calculates an allocation of 1.145 per lot across a block of one hundred lots. Rounding at the lot level yields 1.15 per lot, totaling 115. Aggregating the unrounded fee yields 114.5, which rounds to 114 or 115 depending on the rule, but rarely matches the lot-level total.
The difference is the residual. The residual has to land somewhere. The question is whether the business decided where it lands, or whether a developer decided by choosing a standard library function.
A posted amount is not the same thing as a reproducible amount. Teams discover the difference when they move a ledger to a new platform.
The custodian’s posted amount is a contractual fact for reconciliation. An internal system might produce a different, more precise calculation, but the cash account must reconcile to the custodian’s statement. You cannot patch a custodian bank’s mainframe to match your new microservice. If a reversal recalculates from the underlying precision rather than reversing the posted entries, it will leave a balance behind.
This reality rarely makes it into the requirements. Nobody puts rounding rules in the RFP. They ask about cloud hosting, API gateways, and high-availability failover.
During a data contract negotiation, a vendor’s integration lead says the platform rounds to two decimals. The enterprise architect asks if that happens before or after aggregation. Nobody in the room knows. If the rounding rule is not in the data contract, it is in the vendor’s code, and the client does not have access to the vendor’s code.
Sometimes the rule is documented. A custodian’s technical specification might run to eight hundred pages. The rounding methodology is on page 847, footnote 3. It contradicts the rounding rule stated on page 47.
Migration test plans routinely miss these boundaries. A test suite might contain four thousand cases, but none of them have a transaction amount that ends in exactly half a cent. The exact midpoint never appears in the test files.
When the production cutover happens, the daily accrual is wrong by a fraction that compounds. A migration test that validates end-state balances to the cent will pass. The intermediate calculations will still be wrong. Precision is not accuracy. Carrying eight decimal places through a calculation that should have been rounded at step two does not make the result more correct.
Faced with thousands of tiny breaks, the temptation is to widen the reconciliation tolerance. Set the auto-match threshold to five cents. The exceptions disappear from the dashboard. The steering committee signs off.
But systematic rounding differences are directional. If the new system rounds half-to-even and the counterparty rounds half-up, the variances will not cancel out. They will accumulate. Tolerance thresholds are not a solution. They are a decision to stop looking at the problem. The automated matching engine does not care that the difference is mathematically insignificant. A break is a break, and the monthly balancing entry grows.
A field called “amount” in an API payload settles none of these questions. A complete data contract must specify whether the field carries an unrounded calculation, a rounded payable amount, or an amount already posted externally. It must name the calculation basis, the decimal precision at each step, the rounding mode, the rounding stage, and the treatment of negative values.
The useful migration artifact is a worked calculation that starts with source inputs and ends with the amount the next party actually receives. Historical postings should not be silently recalculated on import. A new engine may produce a different valid number from the same inputs, leaving the migration team with an unexplained difference against the statement everyone is trying to match.
You only control internal systems. You do not control the market infrastructure, external asset managers, global custodians, or tax authorities. Internal systems must be capable of adopting multiple rounding rules depending on the counterparty or jurisdiction. Identifying the immutable systems in the architecture early is the only way to know which external math the internal systems must mimic.
The residual will land in a ledger account eventually. The business must decide which one before the migration starts.
