The Museum of HP Calculators

HP Forum Archive 16

[ Return to Index | Top of Index ]

[JOKE] RPN vs. Algebraic: The Match !
Message #1 Posted by Valentin Albillo on 28 Mar 2006, 6:13 a.m.

Hi, all:

[Caveat emptor: All that follows is thoroughly tongue-in-cheek, to try and cheer up the Forum a little. V.]

There's been a number of recent posts praising how RPN makes the process of evaluating an algebraical expression easy and intuitive, without having to deal with parentheses and/or implicit rules of precedence, etc.

Well, let's put it to test. Suppose we're asked to evaluate these expressions:

    0.5 + 0.2 * 0.3 
and
    0.312 * 0.437 + 0.251
Here's how I would do it algebraically:
    Using the distributive property of addition over multiplication,
    also known as the distributive law of sum: a + b*c = (a+b)*(a+c):

0.5 + 0.2 * 0.3 = = (0.5 + 0.2) * (0.5 + 0.3) = 0.7 * 0.8 = 0.56

Similarly for the second one:

0.312 * 0.437 + 0.251 = = (0.312 + 0.251) * (0.437 + 0.251) = 0.563 * 0.688 = 0.387344

For a more complicated test, let's suppose we're asked to evaluate the following expression:
   (2+1/4)^(3/2)

Here's how I would do it algebraically:

    Using the rule of exponents: (a+b)^c = c*(a+b):

(2+1/4)^(3/2) = = (3/2) * (2+1/4) = (3/2) * (9/4) = (3*9) / (2*4) = 27/8

What ? You don't like these algebraically obtained values of mine ? Well, let's see if RPN gets you any better results. :-)

Best regards from V.

Edited: 28 Mar 2006, 6:18 a.m.

      
Here is an old PPC joke
Message #2 Posted by Namir on 28 Mar 2006, 8:05 a.m.,
in response to message #1 by Valentin Albillo

This is an old PPC joke I heard over 20 years ago in one of the PPC national meetings. The joke is purely fictional.

The Santa Ana municipality issued a citation to Richard Nelson, founder of the PPC, for improperly disposing of trash bags! Richard was shocked because he did not improperly dispose of trash, pure and simple! It just was not in his character to do that! He drove to the municipality and confronted the official who issued the citation to protest against this error. “What crazy evidence led you to point the finger at me?!!”, protested Richard. The official calmly responded, “We found a fully functioning TI-59 calculator in the trash bag!”

Edited: 28 Mar 2006, 8:06 a.m.

            
An update on an old PPC joke
Message #3 Posted by Palmer O. Hanson, Jr. on 28 Mar 2006, 10:43 p.m.,
in response to message #2 by Namir

Last month I broke down and purchased my first new-in-the-box High-Priced programmable calculator -- an hp-33s. I told Richard Nelson. Last week Richard told me that he had purchased a TI-89. Repent! The end of the world may be nearer than you think!

                  
Re: An update on an old PPC joke
Message #4 Posted by Gene on 29 Mar 2006, 9:08 a.m.,
in response to message #3 by Palmer O. Hanson, Jr.

Yes, and I have seen that TI-89 in Richard's hands.

I have to admit I felt like sitting down quietly somewhere. :-)

                        
Re: An update on an old PPC joke
Message #5 Posted by Namir on 29 Mar 2006, 12:57 p.m.,
in response to message #4 by Gene

This si truly shocking to me! I am emailing Dr Phil to help me deal with this trauma!

:-(

Namir

      
Re: [JOKE] RPN vs. Algebraic: The Match !
Message #6 Posted by Marcus von Cube, Germany on 28 Mar 2006, 12:50 p.m.,
in response to message #1 by Valentin Albillo

Valentin,

let's try:

    0.5 + 0.2 * 0.3 

We have to transform the infix notation to postfix notation first:

    0.5 -> 0 5 .
    0.2 -> 0 2 .
    0.3 -> 0 3 .

The complete evaluation in RPN looks like the following:

0 ENTER 2 . 0 ENTER 3 . * 0 ENTER 5 . +    
which gives the result 5.00 accurate two 2 digits.

Marcus

            
Re: [JOKE] RPN vs. Algebraic: The Match !
Message #7 Posted by Howard Owen on 28 Mar 2006, 3:40 p.m.,
in response to message #6 by Marcus von Cube, Germany

Typical sloppy RPN hackery.

The error is in the conversion to RPN. The digit string should be reversed, with the decimal staying put:

0.2 -> 2.0

0.3 -> 3.0

0.5 -> 5.0

Thus, algebraically we have:

5.0 + 2.0 * 3.0

and by the 2nd commutative law of addition:

5.0 + 3.0 * 2.0 + 6.4

or, in RPN:

2 ENTER 2 +

Which is five, purely by coincidence.

                  
Re: [JOKE] RPN vs. Algebraic: The Match !
Message #8 Posted by Vieira, L. C. (Brazil) on 29 Mar 2006, 1:46 p.m.,
in response to message #7 by Howard Owen

Indeed! (in the lack of a better word)

                        
Re: [JOKE] RPN vs. Algebraic: The Match !
Message #9 Posted by Valentin Albillo on 30 Mar 2006, 3:32 a.m.,
in response to message #8 by Vieira, L. C. (Brazil)

Hi, Luiz Claudio:

Luiz Claudio posted:

"Indeed! (in the lack of a better word)"

    It's "for lack of a better word" or "for lack of a better term".

    By the way, congratulations for your fellow countryman Mr. Marcos Pontes becoming the first Brazilian cosmonaut ! :-)

Best regards from V.
                              
Re: [JOKE] RPN vs. Algebraic: The Match !
Message #10 Posted by Vieira, Luiz C. (Brazil) on 30 Mar 2006, 3:57 a.m.,
in response to message #9 by Valentin Albillo

Hi, Valentin;

Thanks! Twice! d8^)

Best regards.

Luiz (Brazil)


[ Return to Index | Top of Index ]

Go back to the main exhibit hall