where:

n = number of payment periods to be amortized.

INTj = amount of PMT applied to interest in period j.

PRNj = amount of PMT applied to principal in period j.

PVj = present value (balance) of loan after payment in period j.

j = period number.

INT1 = {0 if n = 0 and payment mode is set to Begin.

|PV0 × i|RND (sign of PMT)

PRN1 = PMT – INT1

PV1 = PV0 + PRN1

INTj = |PVj –1 × i|RND × (sign of PMT) for j > 1.

PRNj = PMT – INTj

PVj = PVj –1 + PRNj