# A Great RPN Calculator

We were having company for supper last night.

To make it special for the little ones, we decided to serve Kentucky Friend Chicken.  Now, there hasn’t been a store in Amherstburg in years so guess who got to drive into Windsor to get it?

As I stared at the menus, I remembered the good old days when they served chicken and cole slaw.  Things really have changed.  The menus are huge.  So, I’m standing there doing a little, actually a lot, of mental math to try to determine what the best value would be.  I selected and ordered.  There would be a fifteen minute wait while they cooked the chicken!  I looked at the clock – it wasn’t anywhere near one o’clock, the traditional end of the lunch hour!  How could they be out?  <grin>

Well, we wanted to do it so I decided to order and wait.  To kill some time, I pulled out my phone and started doing some math with the pricing on the menus.  It wasn’t a horrific task; there were math questions all over the place.  What’s the best value?  Is the price of a bowl of cole slaw the same with every order?  What’s the best value for pop that’s available in three sizes? As my kids would point out, these are the reasons I sit alone in public places.

There were so many things to calculate, I soon find that I’m doing the math on the standard calculator that comes on my Android and realize that it wasn’t efficient use of my time.  Then, I clued in.  I was using an algebraic calculator.  I could be much more efficient with an RPN Calculator.  You may recall that I’ve blogged about this before and before.  I thank my university statistics professor for recommending my original HP21 calculator.

Chicken isn’t cooked so I’m off to the Google Play store to look for an RPN Calculator to download.

It turns out there were a LOT of them.  One in particular caught my eye because it was the spitting image of the HP products that I was so fond of.

I became really engrossed with this program.  It’s such a nice and faithful copy of the original – even to the LED display that couldn’t be read in bright sunlight!

Other than just using the calculator, the whole experience brought back a few problems from my computer science classroom.  First, you have to teach students just what RPN is and then have them write the code.  The HP 21 had a nice rolling stack of 4 which led right into another sort of topic that you’ll only find in a computer science classroom.  And, the nice thing about writing your own calculator program is that you can add feature after feature, including printing graphs.  Function keys extend the function of any of the buttons.  It’s just a shame that we had to use a mouse to press the buttons at the time.

Well, the moment has passed but I’ve been inspired to get the application and play with it.  Who says mathematics can’t be fun?

The content of this blog is generated by whatever strikes my fancy at any given point. It might be computers, weather, political, or something else in nature. I experiment and comment a lot on things so don't take anything here too seriously; I might change my mind a day later but what you read is my thought and opinion at the time I wrote it! My personal website is at: http://www.dougpeterson.ca Follow me on Twitter: http://www.twitter.com/dougpete I'm bookmarking things at: http://www.diigo.com/user/dougpete

## 3 thoughts on “A Great RPN Calculator”

1. I missed reading this when you wrote it, but I was just thinking today about giving my CS students a calculator-writing assignment, and RPN crossed my mind. Then Steve Gibson talking about them (https://www.grc.com/sn/sn-332.htm) and a prof I had saying that Yoda spoke in RPN.

I’m sure my students aren’t ready for a complex calculator, but maybe something small, or maybe an optional enrichment task…

Like

1. Until I took statistics and this one prof, I had no idea that RPN existed. She convinced me to spend a lot of money on that. I seem to remember \$400. It took a while to get the knack of it and I was so fearful I had blown a lot of money. Now, I can’t imagine using anything else for serious calculations. It also had the advantage of teaching me about stacks which really came in handy in CS.

Writing a calendar app can be an ongoing project in CS as you can add all kinds of functionality to it as students learn techniques and also a bunch of mathematics in the process.

Like