Multiple Period Percentage Change Program for the 30b



#2

Hello everyone,

Previously, I posted a program that add a top-level shifted percentage change function to the 30b while using the RPN stack.

I decided that this was not enough. If amounts change over multiple periods, discounting or compounding take place. The best way to solve this dilemma is to incorporate this into a brand new program.

Here it goes:


SH% (put this on line zero to assign the program to this key combination)

STO 1

Roll down

swap

/

RCL 1

1/x

y^X

1

-

100

*

(you can add a message like delta (the symbol) % or Pct chng here if you want)

The way this program works is such:

Say you had $50 two years ago and you have $90 today. You want to know what the percentage increase is over these two years:

50 input 90 input 2
SH% (SH is shift hold)

You should get an answer of 34.16

Now say you have the opposite situation and want to know the percentage decrease.

90 input 50 input 2
SH%

You should get an answer of -25.46440

Keep in mind that if you have only one period, you MUST enter a 1 for the third argument - otherwise you will get an error. This program requires three arguments to work.

(Now, if your logic works such that you prefer to have the new amount first, then get rid of the swap command and then enter the new first, old second, and # periods third.)

Hope this helps anyone who doesn't like going through the %Calc menu to get to this function.

If any of you have questions regarding this program, please feel free to ask.

Regards,

Mark


Edited: 24 May 2011, 1:56 a.m.


Possibly Related Threads...
Thread Author Replies Views Last Post
  17BII & 17BII+ Discounted Payback Period Revisited Tom Neudorfl 8 1,021 11-25-2013, 10:28 AM
Last Post: Don Shepherd
  HP Prime: run a program in another program Davi Ribeiro de Oliveira 6 762 11-11-2013, 08:28 PM
Last Post: Davi Ribeiro de Oliveira
  Program to change entry mode on Prime Michael de Estrada 3 553 10-28-2013, 10:13 AM
Last Post: Han
  HP PRIME: How to change the column headers and reset data Joseph Ec 5 694 10-18-2013, 02:26 PM
Last Post: Joseph Ec
  Leading 0 change? Tim Wessman 12 1,052 10-07-2013, 12:11 PM
Last Post: Katie Wasserman
  Does Prime Have a Multiple Equation Solver? Norman Dziedzic 2 403 09-20-2013, 09:43 AM
Last Post: Norman Dziedzic
  Flashing cable for HP 20 / 30B Stefan Koenig 3 605 09-19-2013, 05:53 AM
Last Post: Marcus von Cube, Germany
  Any 30b cables left? patryk 7 807 09-16-2013, 02:54 PM
Last Post: Marcus von Cube, Germany
  HP-30B (WP-34S) Technical Documentation Barry Mead 3 561 09-09-2013, 03:07 PM
Last Post: Harald
  HP's thinking behind the 20b/30b? John Ioannidis 3 515 09-07-2013, 10:21 AM
Last Post: Tim Wessman

Forum Jump: