Time Value of Money in one screen
The TVM equation links five variables — PV, FV, PMT, N and Rate. Given any four you can solve for the fifth, which is exactly how financial calculators like the HP-12C work.
This calculator handles ordinary annuities and annuities due, uses bisection to solve numerically for N and Rate, and works for any consistent payment frequency (we use months as the period for clarity).