[comp.sys.handhelds] TVM Menu for the HP-48SX

fin@norge.unet.umn.edu (Craig A. Finseth) (05/07/90)

For those of you who want a simple, straightforward set of TVM functions...

When: 10 Apr 1990
What: Time Value of Money Functions

How to use these functions:

	1) Change to the TVM directory.

	2) Press CST.

CLR	Clear the variables (set End mode, store 12 to PYR, store 0 to rest)
TSTO	Store and display with tag
TRCL	Display with tag
TVM	TVM solver
TVMEQ	TVM equation
CST	Custom menu definition

  --variables--
n	Number of payments
I	Interest per period
PV	Present Value
PMT	Payment
FV	Future Value
PYR	Payments per YeaR
PMF	Payment Factor (0 = End mode, 1 = Begin mode)

------------------------------------------------------------
Custom Menu

	n	Store PYR * <value> into n
	<\n	Solve for n
	\>n	Recall n
	I	Store <value> / PYR into I
	<\I	Solve for I
	\>I	Recall I
	PV	Store <value> into PV
	<\PV	Solve for PV
	\>PV	Recall PV
	PMT	Store <value> into PMT
	<\PMT	Solve for PMT
	\>PMT	Recall PMT
	FV	<value> into FV
	<\FV	Solve for FV
	\>FV	Recall FV
	PYR	Store <value> into PYR
	\>PRY	Recall PYR

	BEGIN	Set Begin mode
	END	Set End mode
	?	Display mode
	CLEAR	Clear values


Checksum: #25276d
Size: 1392
------------------------------------------------------------
%%HP: T(3)A(D)F(.);
DIR
  CLR
    \<< 0 'n' STO 0
'I' STO 0 'PV' STO
0 'PMT' STO 0 'FV'
STO 12 'PYR' STO 0
'PMF' STO
    \>>
  TSTO
    \<< \-> v x
      \<< v x STO x
TRCL
      \>>
    \>>
  TRCL
    \<< \-> x
      \<< x RCL x
\->TAG
      \>>
    \>>
  TVM
    \<< \-> x
      \<< 'TVMEQ' x 1
ROOT x \->TAG
      \>>
    \>>
  TVMEQ '0=PV+(1+I*
PMF/100)*PMT*((1-(1
+I/100)^-n)/(I/100)
)+FV*(1+I/100)^-n'
  CST { { "n" {
    \<< PYR * 'n'
TSTO
    \>>
    \<< 'n' TVM
    \>>
    \<< 'n' TRCL
    \>> } } { "I" {
    \<< PYR / 'I'
TSTO
    \>>
    \<< 'I' TVM
    \>>
    \<< 'I' TRCL
    \>> } } { "PV" {
    \<< 'PV' TSTO
    \>>
    \<< 'PV' TVM
    \>>
    \<< 'PV' TRCL
    \>> } } { "PMT" {
    \<< 'PMT' TSTO
    \>>
    \<< 'PMT' TVM
    \>>
    \<< 'PMT' TRCL
    \>> } } { "FV" {
    \<< 'FV' TSTO
    \>>
    \<< 'FV' TVM
    \>>
    \<< 'FV' TRCL
    \>> } } { "PYR" {
    \<< 'PYR' TSTO
    \>>
    \<<
    \>>
    \<< 'PYR' TRCL
    \>> } } { "BEGIN"
    \<< 1 'PMF' STO
    \>> } { "END"
    \<< 0 'PMF' STO
    \>> } { "?"
    \<< "" 6 DISP
      IF PMF
      THEN "Begin"
      ELSE "End"
      END 7 DISP 1
WAIT
    \>> } { "CLEAR"
CLR } }
  n 0
  I 0
  PV 0
  PMT 0
  FV 0
  PYR 12
  PMF 0
END

Craig A. Finseth			fin@unet.umn.edu [CAF13]
University Networking Services		+1 612 624 3375 desk
University of Minnesota			+1 612 626 1002 FAX
130 Lind Hall, 207 Church St SE, Minneapolis MN 55455-0134, U.S.A.