HP-65 accuracy error
12-16-2019, 11:02 PM (This post was last modified: 12-17-2019 11:55 PM by Don Shepherd.)
Post: #9
 Don Shepherd Senior Member Posts: 745 Joined: Dec 2013
RE: HP-65 accuracy error
(12-16-2019 09:48 PM)SlideRule Wrote:  Any hints as to the identity of the the 65 program (my curiosity)?
SlideRule
Yes, it's a little encryption/decryption program I adapted for the 65 from a version I wrote for the 12c. For the 65, you press A to display no decimals, then press E to encrypt five 2-digit numbers representing letters of your message. The encryption results in a big base 10 number from the 5 2-digit numbers in base 40, and entering E decrypts the big base 10 number back into the original 2-digit base 40 numbers. Except it doesn't give you the same 2-digit numbers you started with because of the Y^X error. The 12c version of this program works fine.

updated on Dec. 17, 2019 --
I modified the program below to remove the two Y^X operations and just used regular multiplication to adjust the multipliers in each loop instead of the Y^X operations, and now the program works fine. If anyone is interested, I'll post the new code. It's good to know that there is a relatively easy workaround for this problem.

Here is the 65 version that does not work correctly (lowercase for ease of entry):

lbl a
dsp
.
0
rtn

lbl d (decode)
sto 1
0
sto 2
sto 3
lbl 2
rcl 1
40
/
sto 4
lst x
x<-->y
frac
x
10
rcl 3
y^x generates the wrong number
x
sto + 2
rcl 4
int
sto 1
0
x=y
goto 3
2
sto + 3
goto 2
lbl 3
rcl 2
rtn

lbl e (encode)
sto 1
0
sto 2
sto 3
lbl 1
rcl 1
100
/
int
sto 1
lst x
frac
100
x
40
rcl 2
y^x
x
sto + 3
1
sto + 2
4
rcl 2
x<=y
goto 1
rcl 3
rtn
 « Next Oldest | Next Newest »

 Messages In This Thread HP-65 accuracy error - Don Shepherd - 12-16-2019, 04:51 PM RE: HP-65 accuracy error - toml_12953 - 12-16-2019, 05:26 PM RE: HP-65 accuracy error - Don Shepherd - 12-16-2019, 05:44 PM RE: HP-65 accuracy error - TomC - 12-16-2019, 06:38 PM RE: HP-65 accuracy error - SlideRule - 12-16-2019, 09:48 PM RE: HP-65 accuracy error - Don Shepherd - 12-16-2019 11:02 PM RE: HP-65 accuracy error - teenix - 12-16-2019, 06:53 PM RE: HP-65 accuracy error - Gene - 12-16-2019, 07:10 PM RE: HP-65 accuracy error - Jake Schwartz - 12-16-2019, 08:55 PM

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