Issue
The accrue action will cause precision loss
,testCase "multiple times on diff dates" $
assertEqual "accrue int on bond multiple times on diff dates"
(B.bndDueInt (B.accrueInt (L.toDate "20210103") b1))
(B.bndDueInt (B.accrueInt (L.toDate "20210103") (B.accrueInt (L.toDate "20210102") b1)))
A bond accrue from Sep 1 -> Sep 4 is different with accrue from Sep 1 -> Sep 2 , Sep 2 -> Sep 4 .
Because in each rounding , it will do rounding to make it like "balance with 2 decimal "
Goal
The goal is use Rational to represent accrued balance
And the the representation of Rational with 6 digits instead of form of ( x % y )
Scope
All type under Accrual class will be affected