The installment plan is calculated to contain the same installment amounts as the ones calculated using installment daily accrual done by TM smart contract. The EMI is calculated using the formula and the interest amount is recalculated using the actual number of days in a month. The last installment is modified to repay the whole loan.

Note: The prepayments are handled separately and they do not modify the installment plan at all.

First repayment date

The repayment day is the number between 1 and 28. The first repayment date is the first possible date where the difference between loan disbursement and it is greater or equal to one month and it is on the selected day.

EMI calculation

The EMI is calculated using the following formula:

A = P * (r(1+r)^n) / ((1+r)^n - 1)

Where:

  • A - EMI

  • P - principal amount

  • r - monthly interest rate (interest rate / 12)

  • n - tenor (number of installments)

The result is rounded to two decimal places.

Monthly installment amount calculation

All the installments except the last one are calculated using the same formula. For all the cases the interest is calculated using the number of days and the daily interest rate.

The daily interest is calculated using:

Id = p * (y/365)

where:

  • Id - daily interest

  • p - remaining principal / outstanding balance

  • y - yearly interest rate

The daily interest is rounded to five decimal places.

The daily interest rate (y/365) is rounded to ten decimal placese.

The interest for a given date period is calculated using:

Ip = d * Id

where:

  • Ip - interest for given date period

  • d - number of days

  • Id - daily interest

The interest is rounded to two decimal places.

Installment amount calculation

The installment amount for all the installments except the last one is equal to EMI. The interest is calculated using the formula above where the number of days is the difference between the current and the previous repayment date (using the actual number of days). In the first installment calculation the loan origin date is used instead of the previous repayment date. The principal is calculated as a difference between EMI and the interest calculated.

EMI = E
Interest = Ip
Principal = EMI - Ip

Where:

  • E - originally calculated EMI

  • Ip - interest for last repayment period

Last installment amount calculation

The EMI of the last installment is not fixed and it is calculated as a sum of the interest of the last period and the remaining principal.

Interest = Ip
Principal = Pr
EMI = Ip + Pr

Where:

  • Ip - interest for last repayment period

  • Pr - remaining principal of the loan

TM interest accruing and due/overdue day movements

Daily accrual

Every day at 0:00:01 starting the day after loan disbursement the interest is accrued. The daily interest is calculated using the formula above and the money is moved from ACCRUED_INTEREST address to INTERNAL_CONTRA of the loan account. This creates the debt at ACCRUED_INTEREST of the size of daily accrued interest.

The same as above the calculations are rounded to five decimal places.

Due day movements

Every repayment date at 0:01:00 the money is moved from INTEREST_DUE to ACCRUED_INTEREST. The amount is determined by the rounded balance of ACCRUED_INTEREST to two decimal places. The rounding remainder is sent to/from back to the INTERNAL_CONTRA address. After these operations the ACCRUED_INTEREST address is cleared and the INTEREST_DUE address contains the rounded due interest amount.

The next step is sending money from PRINCIPAL_DUE address to PRINCIPAL address of the account. The calculation is different for the last installment and all the others. Normally, the amount is calculated as EMI-INTEREST_DUE. For the last installment the remaining PRINCIPAL is used.

Overdue day movements

Every repayment date at 23:59:00 all the money is moved from INTEREST_OVERDUE to INTEREST_DUE and from PRINCIPAL_OVERDUE to PRINCIPAL_DUE.

Early repayment calculation

Note: the early repayments can be performed only on the account with no outstanding payments.

Full loan repayment

The full repayment amount is calculated using:

R = I + P

Where:

  • R - full repayment amount

  • I - daily accrued interest since the last repayment date (or the loan origin if no repayment date happened)

Partial loan repayment

When the customer does an overpayment and requests the installment plan recalculation, the overpayment is used to repay the current daily accrued interest and the part of the remaining principal.

This is done by inserting a new installment with the current date and with the amount of the overpayment. The interest amount is the interest accrued since last repayment date and the principal amount is the difference between the overpayment amount and the accrued interest amount.

The new remaining principal amount is then calculated using:

N = P - (O - I)

Where:

  • N - remaining principal after overpayment

  • P - remaining principal before overpayment

  • O - overpayment

  • I - daily accrued interest since the last repayment date (or the loan origin if no repayment date happened)

This new remaining principal amount is used for recalculation of the following installments. The normal installment plan calculator is used. The opening date is set to the current date and the first installment date is set to the next installment date as it was planned before. The resulting installment plan is concatenation of the previous installments, overpayment installment and the future installments calculated by the calculator. The exact calculation depends if the customer wants to decrease the EMI or the number of the installments.

Decreasing EMI

If the customer wants to decrease the EMI, the new installment plan is calculated together with the new EMI calculation. The number of the installments is set to the number of previously planned future installments and the new principal is used. All the other parameters remain the same as set up on loan opening.

Decreasing number of installments

When decreasing the number of installments, the installment plan is recalculated using the old EMI. The number of installment is decreased since the empty installments are dropped. The last non empty installment is recalculated using the same approach as the last installment during normal installment calculation.

Attachments:

Repayment plan calculation SaFi Loans.xlsx (application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
Partial Early Repayments examples.xlsx (application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
Partial Early Repayments examples_Kobe_20220920.xlsx (application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
Partial Early Repayments examples_Kobe_20220930.xlsx (application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)