See the retroactive interest a no-interest-if-paid-in-full store card promotion charges when a balance is left, and the payment that avoids it.
Model and assumptions. During the promotion, interest accrues in the background each month at the standard rate on the balance left after your last payment, but is not charged. If the purchase is paid in full by the end, none of it is charged. If any balance remains, all the accrued interest is added at once. The payment that avoids interest is the purchase divided by the promotion months, rounded up to the cent. The model uses monthly steps and simple monthly interest on the declining balance, whereas issuers use the daily balance, and it ignores new purchases and late payments, which can end a promotion early.