HP-12C Reference the 1981 financial Voyager · 92 functions, with procedures for the financial ones

Five registers solve any compound-interest problem; six more keys handle uneven cash flows, bonds and depreciation. The guide gives the keystroke procedure for each financial calculation — loan payments and terms, savings, leases in BEGIN mode, effective rates and APR, amortisation, NPV and IRR, bond price and yield, depreciation — then programming, and an index of every function with its handbook page. Every figure was computed and checked against the user's guide. Gold f and blue g prefixes are written as the keyboard prints them.

f gold, above the key g blue, on the key
Sources: HP 12c user's guide, Edition 5 (HP, 2008) for behaviour and page numbers; the HP-12C Owner's Handbook and Problem-Solving Guide, Edition 2 (HP, 1992) for the keyboard diagram; the HP 12c Solutions Handbook for worked practice.
Colour keythe machineentry, stack & displayprogrammingmathematicssymbolic, solvers & financeinput, output & interfacereference & system

The Keyboard

39 keys · drawn to the proportions of the machine · the small grey number on each key is its keycode — row, then column
1,234.56
hp12C
BOND
DEPRECIATION
CLEAR
AMORTn12×11
INTi12÷12
NPVPVCF013
RNDPMTCFj14
IRRFVNj15
CHSDATE16
7BEG7
8END8
9MEM9
÷ 10
PRICEyx√x̄21
YTM1/xex22
SL%TLN23
SOYDΔ%FRAC24
DB%INTG25
EEXΔDYS26
4D.MY4
5M.DY5
6x̄w6
× 20
P/RR/SPSE31
ΣSSTBST32
PRGMR↓GTO33
FINx≷yx≤y34
REGCLxx=035
PREFIXENTERLST x36
1x̂,r1
2ŷ,r2
3n!3
 30
ON  
f 42
g 43
STO 44
RCL 45
00
·s48
Σ+Σ−49
+ 40
gold, reached with f — printed on the case above the keyblue, reached with g — printed on the key itselfkeycode as a program line shows it

HP-12C Guide

procedures for the financial calculations, then programming

Anatomy four things the keyboard does not tell you

The sign convention

Cash paid out is negative; cash received is positive. The TVM keys solve an equation that balances the two, so every problem needs at least one flow of each sign. Flows all of one sign have no solution — that is Error 5.

PV
50,000 in
0  
  1PMT
  2PMT
  3PMT
  PMT
  nPMT

From the borrower's seat the 50,000 arrives (positive PV) and the payments leave (negative PMT). From the lender's seat every sign flips and the answer is unchanged. Key a payment you make with CHS, and expect a solved PMT to come back negative.

Five registers, any four

Compound interest is one equation in five terms. Store any four and press the fifth key to solve for it; order does not matter.

fill any four, press the fifthniPVPMTFVperiodsratenoweach periodat the end

n and i are per period. A 25-year mortgage paid monthly is n = 300 and i = 13.25 ÷ 12. Key the years and press g 12×; key the annual rate and press g 12÷. Each stores its result directly.

Press f CLEAR FIN between problems; a value left in an unused register is used silently. A non-integer n puts the machine in Odd-Period mode (see the card).

One pool: registers, cash flows, program

Data registers and program lines share one memory: 8 lines and 20 registers at power-up, and every seven further instructions convert one register, from R.9 downward. Cash flows are held in registers, so a long program and a long cash-flow series compete for space.

at power-up8 lines20 registers — R0…R9, R.0…R.9
fully expanded99 program linesR0…R613 registers converted, seven lines eachleft for data
lines usedregisters freeP-08r-20g MEM

99 = 8 + 13 × 7. The thirteen converted registers are R.9 down to R.0, then R9, R8, R7, leaving R0–R6. Data in a converted register is lost.

Cash flows: CF₀ plus up to 20 flows, fewer while a program is stored. At the maximum the last flow is held in FV.

User's guide pp. 94–95 and 60.

No labels, only line numbers

A program is a numbered list of keystrokes. There is no LBL and no subroutine: g GTO takes a two-digit line number, and the two conditionals skip one line when false.

01- 11digits record as themselves
03- 42 11f AMORT42 is the f prefix, 11 is the key at row 1, column 1
07- 45 13RCL PVRCL at row 4 col 5, PV at row 1 col 3
09- 43,33 01g GTO 01a whole keystroke sequence merged into one line

Inserting a line renumbers everything after it, so every GTO aimed past the insertion now lands one line early. Check each branch after an edit, or leave g GTO 00 lines as spare slots.

g x≤y and g x=0: true executes the next line, false skips it. The line after a test is normally the GTO.

The machine

Introduced in 1981, still in production, and still the standard instrument in finance. A Voyager: the same body and four-level RPN stack as the HP-15C, with financial functions in place of scientific ones.

RPN, 4-level stackno parentheses, no equals keyfive TVM registersn, i, PV, PMT, FV — store four, solve the fifth20 registers / 99 program linessharing one poolCF₀ + 20 cash flowsfor NPV and IRRbonds and depreciationin firmwareContinuous Memoryeverything survives switch-off

Permitted in the CFP and CFA exams. The 12C Platinum adds algebraic entry, 400 program lines and undo; this sheet covers the standard 12C.

Reading the keyboard

Three legends per key: white on the key, gold above it via f, blue on the lower face via g.

f AMORTgold — printed above the n keyg 12÷blue — printed on the i key itselff CLEAR FINthe CLEAR bracket spans five keys on row 3f PREFIXcancels a prefix pressed by mistake

The four gold labels under the CLEAR bracket — Σ, PRGM, FIN, REG — are written here as CLEAR Σ, CLEAR FIN and so on. f CLEAR FIN clears only the five financial registers; f CLEAR REG also clears the storage registers and with them the cash flows.

TVM: the procedure

Every compound-interest problem is the same six steps. Whichever key you press last is the unknown.

f CLEAR FINzero the five registersg END or g BEGpayment timing — END for loans, BEG for leases and rentyears g 12×stores n in monthsannual rate g 12÷stores i per monthamount PV, CHS PMT, FVthe known amounts; money paid out is negativepress the unknownthe answer is displayed and stored in that register

Any register not used in the problem must hold zero, which is what f CLEAR FIN is for. Quarterly or annual payments: key n and i directly instead of using the 12× and 12÷ keys.

A solved n is rounded up to the next whole payment; the final payment is then smaller than PMT. User's guide p. 39.

Loans

Payment. £250,000 over 25 years at 5.4% nominal, monthly in arrears:

f CLEAR FIN g END25 g 12×n = 3005.4 g 12÷i = 0.45250000 PVthe advance, receivedPMT−1,520.32

Term. How long to clear £10,000 at 5.4% paying £300 a month:

f CLEAR FIN5.4 g 12÷ 10000 PV300 CHS PMTn37 — 36.2 rounded up; the 37th payment is partial

Rate. Key n, PV and PMT (with its sign) and press i; multiply by 12 for the nominal annual rate.

Savings and balloons

Future value. £500 a month at 6% for ten years, deposited at month end:

f CLEAR FIN g END10 g 12×n = 1206 g 12÷i = 0.5500 CHS PMTpaid in, so negativeFV81,939.67g BEG FV82,349.37 if deposits are made at the start of the month

Balloon. A balloon is a non-zero FV. For a loan with a lump sum due at the end, key the balloon as a negative FV before solving for PMT; the payment falls because part of the principal is deferred. A target sum to accumulate is a positive FV: key it, then solve PMT for the required deposit.

Leases: BEGIN mode

Payments due in advance shift every flow one period earlier: press g BEG. Leases, rent and insurance premiums are paid in advance; loans in arrears. The BEGIN annunciator is the only indication of the mode.

Lessor's view: equipment costing 30,000, 36 monthly payments in advance, 8% nominal, residual value 10,000 at the end:

f CLEAR FIN g BEG36 n8 g 12÷i = 0.666730000 CHS PVthe asset, paid out10000 FVthe residual, receivedPMT688.80

The same lease in arrears solves to 693.39. The two differ by exactly one month's interest, and the mode persists until changed.

Nominal, effective and APR

nominalthe quoted annual rate — 12% "compounded monthly"periodicnominal ÷ periods — 1% a month; what goes in ieffectivethe annual rate after compounding within the yearAPRthe rate on the net proceeds after fees — the comparable figure

Nominal to effective. 12% compounded monthly:

f CLEAR FIN12 n 1 itwelve periods at the periodic rate100 CHS PVFV112.68100 12.68% effective

APR with fees. The loan on the Loans card with a 2% arrangement fee (5,000). Solve PMT on the full amount, then:

245000 PVthe net amount actually advancedi0.4673 per month12 ×5.61% APR against 5.4% quoted

User's guide Section 12, p. 124.

Amortisation

f AMORT splits a run of payments into interest and principal. Set up the loan (n, i, PV, PMT, END mode) and set the display to two decimals with f 2, then:

12 f AMORTinterest in the next twelve paymentsx≷yprincipal repaid in the same twelveRCL PVbalance outstandingRCL npayments amortised so far

Each call continues from the last, so repeating 12 f AMORT gives the next year. To restart, re-enter the original PV and press 0 n. Amounts are rounded to the displayed decimals, so set them first or the schedule will not tie out.

User's guide pp. 54–56. Programmed version in the worked example below.

Uneven cash flows: entry

PMT assumes level payments. For anything else, enter the flows in time order with the cash-flow keys, then press f NPV or f IRR.

f CLEAR REGclear old flows firstg CF₀the flow at time zero — the outlay, negativeg CFⱼeach later flow, in orderg Nⱼrepeat count for the flow just entered, 1–990 g CFⱼa period with no flow — never skippedRCL nhow many flows have been entered

Flow j is held in register j. To correct one, key the new amount and STO j; to change its Nⱼ, store j in n, key the count and press g Nⱼ. Both NPV and IRR read the same set.

User's guide pp. 57–66.

NPV

Net present value discounts every flow at the rate in i and nets the total against CF₀. Accept when NPV > 0 at your hurdle rate.

Outlay 100,000; returns 35,000 a year for four years; cost of capital 10%:

f CLEAR REG100000 CHS g CF₀35000 g CFⱼ 4 g Nⱼfour equal annual flows10 ithe hurdle rate, per periodf NPV10,945.29 — acceptf IRR14.96% on the same flows

NPV is in currency and adds across projects, so it ranks projects of different sizes correctly. The result is also left in PV. Note that f IRR overwrites i; re-key the rate before a second NPV.

IRR

Internal rate of return is the discount rate at which NPV is zero.

needs a sign changeflows all one way have no rateseveral sign changespossibly several IRRs, or noneError 3no unique solution found — supply an estimate in i and RCL g R/SError 7no sign change among the flows

IRR ignores scale, so a small short project can out-rank a larger one worth more, and it assumes interim flows are reinvested at the IRR itself. Use NPV to rank and IRR to report. Modified IRR, which discounts at a stated reinvestment rate, is worked in the user's guide Section 13, p. 148; the Error 3 procedure is in Appendix B, p. 182.

Bonds

f PRICE and f YTM assume semiannual coupons on an actual/actual basis (US Treasury practice), par = 100. Dates go in the stack: settlement ENTER maturity.

Price from yield. 5% coupon, matures 1 June 2036, settles 1 June 2026, yield 6%:

g M.DY f CLEAR FIN6 iyield to maturity5 PMTannual coupon rate6.012026 ENTER 6.012036settlement, maturityf PRICE92.56 per 100 of parx≷yaccrued interest — 0.00 here, settlement is a coupon date

Yield from price. Same entries, price in PV instead of i, then f YTM.

Municipal and corporate bonds use a 30/360 basis and annual-coupon bonds are not covered by the built-in keys; both need the programs in Section 16, p. 163.

Depreciation

f SLstraight line — equal every yearf SOYDsum-of-the-years'-digits — acceleratedf DBdeclining balance — a fixed percentage of book value200 ithe DB factor: 200 = double-declining, 150 = one-and-a-half

Cost in PV, salvage in FV, life in n, the year number in X, then the method key. Cost 10,000, salvage 1,000, five years, year 1:

f CLEAR FIN10000 PV 1000 FV 5 n1 f SL1,800.001 f SOYD3,000.00200 i 1 f DB4,000.00x≷yremaining depreciable value after that year

Key 2 and the method key for year 2. Accelerated methods front-load the deduction, which is worth more in present value; declining balance never reaches salvage, so schedules cross over to straight line. Partial first years and crossover are in Section 13.

Odd periods and the C flag

A non-integer n means the first period is short: the integer part is the whole periods, the fraction is the stub as a fraction of one period.

n = 300.5three hundred full months and half a month of stubg ΔDYScount the odd days, then divide by 30 or by 365/12STO EEXtoggles the C indicator — compound interest over the stubC unlitsimple interest over the stub, the default

The stub cannot exceed one period, STO EEX is not programmable, and after solving in Odd-Period mode do not go on to solve for n: the machine leaves the mode and answers a different question.

Percentages and dates

The three percent keys leave the base in Y so the calculation can continue.

1250 ENTER 8 %100.00 — then + gives 1,350.00120 ENTER 150 Δ%25.00 — percent change from 120 to 150500 ENTER 125 %T25.00 — 125 as a percent of 5006.012026 ENTER 12.312026 g ΔDYS213 actual days; x≷y for the 30-day count6.012026 ENTER 90 g DATEthe date 90 days on, with the weekday digitg D.MY / g M.DYdate entry order — a persistent mode

Check the D.MY annunciator before keying a date with a day above twelve.

Writing a program

The 12C records keystrokes. Branching is to a line number; there are no labels or subroutines.

f P/Rtoggle Program and Run modeg GTO 00in Run mode, rewind to the startg GTO 01as a program line, branch to line 1R/Srun; as a line, stop and show Xg PSEshow X for a second and carry onSST / g BSTstep forward and backf CLEAR PRGMin Program mode, erase everything

g x≤y and g x=0 skip the next line when false, so the line after a test is the branch. Inserting a line shifts every line after it and every GTO aimed past the insertion.

Errors

An error shows Error and a digit; any key clears it.

0mathematics division by zero, or an impossible argument
1overflow a magnitude too large for a register
2statistics too few data points
3IRR no unique rate found — see the IRR card
4program over 99 lines, or a GTO to a line that is not there
5compound interest no solution — usually PV, PMT and FV all one sign
6registers a register that is now program memory
7IRR no sign change among the cash flows
8calendar an impossible or out-of-range date

Appendix B, pp. 181–183.

Further reading

user's guidethe machine end to end, with worked examples — 213 pp.Solutions Handbookproblems by industry: lending, leasing, savings, bondsSections 12–16real estate, investment analysis, leasing, savings, bondsAppendix Dthe formulas behind every financial key

Appendix D prints the equations, which is what makes any result on this sheet checkable.

Function Index

92 entries · hover for the full description and its handbook page

Time Value of Money

13
nnumber of periods
iinterest per period
PVpresent value
PMTthe periodic payment
FVfuture value
g 12×multiply by 12 and store in n
g 12÷divide by 12 and store in i
g BEGpayments at period start
g ENDpayments at period end
f CLEAR FINclear the five TVM registers
f AMORTsplit n payments into interest and principal
f INTsimple interest
STO EEXtoggle the C indicator

Cash Flows: NPV & IRR

7
g CF₀the initial cash flow
g CFⱼthe next cash flow
g Nⱼrepeat the last flow
f NPVnet present value
f IRRinternal rate of return
RCL nhow many flows are stored
f CLEAR REGclear the cash-flow registers

Bonds

3
f PRICEbond price per 100 of par
f YTMyield to maturity
conventionssemiannual coupon, actual/actual

Depreciation

4
f SLstraight line
f SOYDsum-of-the-years'-digits
f DBdeclining balance
partial yearsand the crossover

Percentages

3
%x percent of y
Δ%percent change from y to x
%Tx as a percent of the total y

Calendar

4
g DATEdate arithmetic
g ΔDYSdays between two dates
g D.MYday-month-year input
g M.DYmonth-day-year input

Stack, Storage & Display

11
ENTERcopy x into y
x≷yexchange x and y
R↓roll the stack down
g LST xthe previous x
CLxclear x
STO n · RCL nstore and recall
STO + − × ÷ nregister arithmetic
f 0–9display decimal places
g RNDround x to the display
f CLEAR REGclear the storage registers
g MEMshow the memory split

Maths

11
+ − × ÷two-number arithmetic
g √x̄square root
y^xy to the power x
g 1/xreciprocal
g LNnatural log
g e^xe to the x
g n!factorial
g FRACfractional part
g INTGinteger part
CHSchange sign
EEXexponent entry

Statistics

8
Σ+accumulate a data pair
g Σ−remove a data pair
gmeans of x and y
g ssample standard deviations
g x̂,restimate x, and the correlation
g ŷ,restimate y, and the correlation
g x̄wweighted mean
f CLEAR Σclear R1–R6 and the stack

Programming

10
f P/Rtoggle Program and Run mode
f CLEAR PRGMerase program memory
R/Srun / stop
g GTO nnbranch to a line number
SSTsingle step
g BSTback step
g PSEpause about a second
g x≤yskip the next line if false
g x=0skip the next line if false
g MEMlines used, registers left

Keycodes

7
42 · 43the f and g prefixes
row · columnhow a keycode reads
25row 2, key 5
40row 4, key 10
0 – 9digits record as themselves
43,33 00g GTO 00
44 40 1STO + 1

Error Codes

11
Error 0mathematics
Error 1storage register overflow
Error 2statistics
Error 3IRR
Error 4program memory
Error 5compound interest
Error 6storage registers
Error 7IRR
Error 8calendar
Error 9service
Pr Errorpower interrupted

Worked Example — an amortisation schedule

nine program lines, year by year
01- 11
02- 22twelve payments — one year at a time
03- 42 11f AMORTsplits them: interest into X, principal into Y
04- 31R/Sstop, showing the year's interest
05- 34x≷ybring the principal down
06- 31R/Sstop, showing the year's principal
07- 45 13RCL PVwhat is still owed
08- 31R/Sstop, showing the balance
09- 43,33 01g GTO 01round again for the next year

Keycodes as the calculator displays them, checked against the listings in HP's user's guide.

Nine lines print a year-by-year amortisation schedule. It is that short because f AMORT is stateful: each call continues from where the last one stopped.

Set up the loan in Run mode. £250,000 over 25 years at 5.4% nominal, paid monthly in arrears:

f CLEAR FINclear the financial registersf 2two decimals — AMORT rounds to the display25 g 12×n = 3005.4 g 12÷i = 0.45250000 PVthe advance, receivedg ENDpayments in arrearsPMT−1,520.32

Run it. g GTO 00, then R/S, and R/S again at each stop. Year one:

R/S−13,380.82 interest paid in year 1R/S−4,863.02 principal repaid in year 1R/S245,136.98 balance outstanding

Of £18,244 paid in the first year, £4,863 reduced the debt. Each further R/S cycle gives the next year, and the ratio inverts over the term.

Why the lines are what they are. 1 and 2 are separate lines because each digit records individually. f AMORT leaves interest in X and principal in Y, so x≷y reaches the second result. g GTO 01 branches to a line number; insert a line above it and the branch points at the wrong instruction.

Method from the user's guide, p. 54 (amortisation) and pp. 88–104 (programming and branching); keycodes cross-checked against its program listings. Figures above were computed with the machine's own rounding rule — each period's interest rounded to the display format — a model checked against the handbook's published example on p. 55, which it reproduces exactly.