Post Reply 
(17B/19B) GPM: initial payment
05-25-2024, 08:40 PM (This post was last modified: 05-29-2024 10:28 PM by Albert Chan.)
Post: #8
RE: (17B/19B) GPM: initial payment
Look at Graduated Payment Problem in time reversed order, this is simple, without needing a solver.

Let dn = i/((1+i)^n-1), cn = dn + i

Year 6 to Year 30: 25*12 = 300 months

c300 * pv6 + d300 * (fv=0) + pmt*s^5 = 0      → pv6/pmt = -s^5 / c300

pv6 is previous year future value (signed flipped, to honor sign convention)
All we need is to calculate pv(k)/pmt ratio, until reached pv1 --> pmt = pv1 / ratio

Code:
c12 * pv5 + d12 * -pv6 + pmt*s^4 = 0
c12 * pv4 + d12 * -pv5 + pmt*s^3 = 0
c12 * pv3 + d12 * -pv4 + pmt*s^2 = 0
c12 * pv2 + d12 * -pv3 + pmt*s^1 = 0
c12 * pv1 + d12 * -pv2 + pmt     = 0

lua> s, i, pv = 1.075, 0.01, 6e4
lua> d12 = i / expm1(log1p(i)*12)
lua> c12 = d12 + i
lua> c300 = i / expm1(log1p(i)*300) + i

lua> r = -s^5 / c300 -- = pv6/pmt
lua> for p=4,0,-1 do r = (d12*r - s^p) / c12 end
lua> pmt = pv / r
lua> pmt
-474.82512976281373

Another way is let r = pv(k) / pmt(k), eliminated the need for s^p

lua> r = -1 / c300 -- = pv6/pmt6
lua> for loops=1,5 do r = (d12*r*s - 1) / c12 end
lua> pv / r -- = pmt
-474.82512976281373

Equivalently, with USPV(i,n) = 1 / cn

lua> USPV = fn'i,n: -expm1(log1p(i)*-n)/i'
lua> k = -USPV(i,12)
lua> r = -USPV(i,300)
lua> for loops=1,5 do r=r*s; r=r+k*(1+r*i) end
lua> pv/r -- = pmt
-474.82512976281384


This is a dangerous setup, with initial payments not even cover interest!
First 5 years, we owe more and more to the bank.

lua> tvm(12, i, pv, pmt, nil) -- year 1
-61587.530668959655
lua> tvm(12, i, -_, pmt*s, nil) -- year 2
-62924.75212742366
lua> tvm(12, i, -_, pmt*s^2, nil) -- year 3
-63946.045314571944
lua> tvm(12, i, -_, pmt*s^3, nil) -- year 4
-64574.92851114446
lua> tvm(12, i, -_, pmt*s^4, nil) -- year 5
-64722.489143526655
lua> tvm(300, i, -_, pmt*s^5, nil) -- year 6 to 30
-3.4924596548080444e-10
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
(17B/19B) GPM: initial payment - SlideRule - 05-22-2024, 11:39 AM
RE: (17B/19B) GPM: initial payment - Gil - 05-25-2024, 04:05 PM
RE: (17B/19B) GPM: initial payment - Gil - 05-25-2024, 08:22 PM
RE: (17B/19B) GPM: initial payment - Albert Chan - 05-25-2024 08:40 PM
RE: (17B/19B) GPM: initial payment - Gil - 05-25-2024, 09:12 PM
RE: (17B/19B) GPM: initial payment - Gil - 05-25-2024, 11:52 PM
RE: (17B/19B) GPM: initial payment - Gil - 05-29-2024, 07:08 PM
RE: (17B/19B) GPM: initial payment - Gil - 05-30-2024, 01:08 AM
RE: (17B/19B) GPM: initial payment - Gil - 05-30-2024, 03:14 AM
RE: (17B/19B) GPM: initial payment - Gil - 06-01-2024, 10:43 AM
RE: (17B/19B) GPM: initial payment - Gil - 06-01-2024, 11:57 AM
RE: (17B/19B) GPM: initial payment - Gil - 06-17-2024, 08:32 PM
RE: (17B/19B) GPM: initial payment - Gil - 06-18-2024, 08:03 AM
RE: (17B/19B) GPM: initial payment - Gil - 06-20-2024, 01:28 PM



User(s) browsing this thread: 3 Guest(s)