Calculate Monthly Loan Payments (Amortization)

From HotDocs Wiki

Jump to: navigation, search

HotDocs can perform complicated mathematical calculations, such as those required to determine the monthly payment for a loan. The following computation is based on the basic formula that uses three variables to determine the monthly payment (PMT): the interest rate (R), number of payments (N), and the amount of the loan (M).

The scripts below show two ways to calculate monthly loan payments. The first version is broken up into several small calculations, and the second version has everything on one line. Often, it is easier to write and maintain computation scripts if they are broken up into smaller segments like the first version.

In this formula, R is the annual percentage rate (APR) divided by 100, which is then divided by the number of payments per year. Thus, for 12 payments per year, R is the APR divided by 1200.


//Example 1: Broken up into several small calculations. 
POWER( 1 + (Rate / 1200 ), Payments ) 
 ( Rate / 1200 ) / RESULT 
 ( Rate / 1200 ) + RESULT 
RESULT * Loan Amount ROUND( RESULT, 2 ) 
//Example 2: Entire calculation on one line. 
ROUND( ( ( ( Rate / 1200 ) + ( Rate / 1200 ) / ( POWER( 1 + ( Rate / 1200 ), Payments ) - 1 ) ) * Loan Amount ), 2 )

Rate The annual percentage rate. The computation divides this number by 1200 to calculate the value for R in the formula.
Payments The number of payments (N). In this example, this is the number of months because payments are made every month.
Loan Amount The initial amount of the loan (M).