News for hackers. Stuff that matters.
Re:64-Bit Bank Balances ‘Ought to Be Enough for Anybody’? by seanhunter on Tuesday September 19, 2023 @10:03AM (#37570091)
That is absolutely not how it works. Rounding is exactly specified in the underlying contract always and you need to implement the correct rounding. For example, here is the rounding table for compounding calculations in the ISDA definitions (these are very standard for a wide range of contracts, but this particular table is for various overnight swap rates used in interest rate derivatives)[1].

[1] https://globalmarkets.cib.bnpparibas/app/uploads/sites/4/202...

Re:64-Bit Bank Balances ‘Ought to Be Enough for Anybody’? by prometheus76 on Tuesday September 19, 2023 @10:36AM (#37570595)
Interesting side note:ASME also has a standard for rounding on engineering drawings. A few years back I had to build a custom function I. Excel to match the standard, because our calcs weren't matching the customer's calcs.
Re:64-Bit Bank Balances ‘Ought to Be Enough for Anybody’? by cornstalks on Tuesday September 19, 2023 @10:26AM (#37570442)
And how do they round ties? Does 0.00005% round to 0.0001%? Is tie breaking usually included in such contracts?
Re:64-Bit Bank Balances ‘Ought to Be Enough for Anybody’? by RandomLensman on Tuesday September 19, 2023 @10:31AM (#37570514)
For these benchmarks, yes, that is defined.

Where issues could come in is when these things are multiplied with a bunch of other numbers (each number with defined rounding but not after each operation) and then have some defined rounding at the end. There different computer numerics could in give slightly different results, but those can easily be resolved on settlement (for small stuff that stays well within the back offices - at least that is how I remember it).

Also, not totally unusual for one or both participants to forget about some rounding they might have agreed bilaterally if it was some one off etc.