RPN Question
10-25-2017, 11:11 AM (This post was last modified: 10-25-2017 01:02 PM by Gamo.)
Post: #1
 Gamo Senior Member Posts: 605 Joined: Dec 2016
RPN Question
To divide x by 2
ENTER 2 ÷
What other keystokes will do the same that use only functions and No numbers except number to enter ?
No (÷ x + -)

10-25-2017, 12:10 PM (This post was last modified: 10-25-2017 12:12 PM by Paul Dale.)
Post: #2
 Paul Dale Senior Member Posts: 1,645 Joined: Dec 2013
RE: RPN Question
The WP 34S possibly has the shortest solution at two functions:

Code:
yards->m m->fathom

More general is a statistical approach:

Code:
CLSigma Sigma+ CLx Sigma+ x-bar

Neither the arithmetic operators nor digits are required in either sequence.

Pauli
10-25-2017, 12:29 PM (This post was last modified: 10-25-2017 12:30 PM by Gerson W. Barbosa.)
Post: #3
 Gerson W. Barbosa Senior Member Posts: 1,331 Joined: Dec 2013
RE: RPN Question
(10-25-2017 12:10 PM)Paul Dale Wrote:  The WP 34S possibly has the shortest solution at two functions:

Code:
yards->m m->fathom

Also, if losing T is not an issue:

Code:
ENTER  ||

Gerson.
10-25-2017, 12:43 PM
Post: #4
 Paul Dale Senior Member Posts: 1,645 Joined: Dec 2013
RE: RPN Question
My first thought was the || function but I then made a mistake trying it and moved on.

Pauli
10-25-2017, 01:05 PM
Post: #5
 jebem Senior Member Posts: 1,328 Joined: Feb 2014
RE: RPN Question
(10-25-2017 12:29 PM)Gerson W. Barbosa Wrote:  Also, if losing T is not an issue:
Code:
ENTER  ||
Gerson.

Am I wrong, or it is the Electronics Engineer in you that came up with that elegant answer?

Jose Mesquita

10-25-2017, 01:10 PM (This post was last modified: 10-25-2017 01:16 PM by Didier Lachieze.)
Post: #6
 Didier Lachieze Senior Member Posts: 1,215 Joined: Dec 2013
RE: RPN Question
For small numbers (between -99 & 99) you can do: [10^x] [√x] [LOG]
You can extend the range to [-230.25, 230.25] with: [e^x] [√x] [LN]
10-25-2017, 01:33 PM
Post: #7
 Gerson W. Barbosa Senior Member Posts: 1,331 Joined: Dec 2013
RE: RPN Question
(10-25-2017 01:05 PM)jebem Wrote:
(10-25-2017 12:29 PM)Gerson W. Barbosa Wrote:  Also, if losing T is not an issue:
Code:
ENTER  ||
Gerson.

Am I wrong, or it is the Electronics Engineer in you that came up with that elegant answer?

Here is a funny example of different coding for the same problem, according to the authors’ professions:

BTW, my solution for that one was “3 XOR” (valid for the HP-42S only). No, I am not logic circuit designer :-)

Gerson.
10-25-2017, 01:37 PM
Post: #8
 Gerson W. Barbosa Senior Member Posts: 1,331 Joined: Dec 2013
RE: RPN Question
(10-25-2017 01:10 PM)Didier Lachieze Wrote:  For small numbers (between -99 & 99) you can do: [10^x] [√x] [LOG]
You can extend the range to [-230.25, 230.25] with: [e^x] [√x] [LN]

Nice solution for small arguments! I’d thought of “LN SINH”, but this will work only for very large arguments.

Gerson.
10-25-2017, 01:54 PM
Post: #9
 Gamo Senior Member Posts: 605 Joined: Dec 2016
RE: RPN Question
Didier is right my intended answer is [e^x] [√x] [LN]

Someone also suggest ENTER 50 % is very good idea.
10-25-2017, 02:21 PM (This post was last modified: 10-25-2017 03:23 PM by emece67.)
Post: #10
 emece67 Senior Member Posts: 363 Joined: Feb 2015
RE: RPN Question
(10-25-2017 12:29 PM)Gerson W. Barbosa Wrote:
Code:
ENTER  ||

This seems hardly beatable to me. Other approach still in the wp34s may be:

Code:
LB DEC X 2^X
limited, of course, to arguments >=0.

Also:
Code:
1/x RCL+ X 1/x

This last one keeps T intact, updates L in the right way, and also works with arguments <=0:
Code:
STO L STO- L INC L INC L RCL/ L

Regards.

César - Information must flow.
10-25-2017, 06:32 PM
Post: #11
 Craig Bladow Member Posts: 279 Joined: Apr 2016
RE: RPN Question
Solution for HP 41CX
Code:
 <   (Enter this in Alpha mode) ATOX NUMBER P-R

Check out NQ41!
10-25-2017, 08:59 PM
Post: #12
 Dieter Senior Member Posts: 2,397 Joined: Dec 2013
RE: RPN Question
(10-25-2017 12:10 PM)Paul Dale Wrote:  The WP 34S possibly has the shortest solution at two functions:

It could have the definitely shortest solution with one single function call if (if!) the HALF function proposed back then would have made it into the 34s firmware. ;-)

Yes, I still would appreciate such a function, and I think it would nicely complement STO+X or RCL+X for doubling X.

Dieter
10-29-2017, 02:43 AM
Post: #13
 Craig Bladow Member Posts: 279 Joined: Apr 2016
RE: RPN Question
(10-25-2017 02:21 PM)emece67 Wrote:
Code:
1/x RCL+ X 1/x

Since the 41C doesn't have RCL+
Code:
1/x ST+ X 1/x

Check out NQ41!
10-29-2017, 07:44 AM
Post: #14
 Dieter Senior Member Posts: 2,397 Joined: Dec 2013
RE: RPN Question
(10-25-2017 02:21 PM)emece67 Wrote:
Code:
1/x RCL+ X 1/x

Since the 41C doesn't have RCL+
Code:
1/x ST+ X 1/x

Note that this method may cause roundoff errors: 7 → 3,499999999.

Dieter
10-29-2017, 09:42 PM
Post: #15
 Craig Bladow Member Posts: 279 Joined: Apr 2016
RE: RPN Question
(10-29-2017 07:44 AM)Dieter Wrote:  Note that this method may cause roundoff errors: 7 → 3,499999999.

I believe we have found machine epsilon for the 41, 1x10^-9.

Since HP could have achieved a smaller epsilon if they had used binary vs. bcd format in the HP-41, there must have been some other tradeoff or legacy design that led them to use BCD.

Check out NQ41!
10-29-2017, 09:47 PM
Post: #16
 Mark Hardman Senior Member Posts: 515 Joined: Dec 2013
RE: RPN Question

Ceci n'est pas une signature.
10-29-2017, 11:49 PM
Post: #17
 rprosperi Senior Member Posts: 4,299 Joined: Dec 2013
RE: RPN Question
(10-29-2017 09:47 PM)Mark Hardman Wrote:

Thank you.

I'll leave it there...

--Bob Prosperi
 « Next Oldest | Next Newest »

User(s) browsing this thread: 1 Guest(s)