program problems with HP67/97



#8

Hi,

I am trying to reverse engineer a formula from from an HP67 programme. Most of it is pretty clear, however I don't understand what the following program steps from 38 to 45 are doing so can anybody help:

037
038 STO1
039 CHS
040 2
041 ENT
042 Pi
043 x
044 +
045 STO2
046

Thanks,

Bob


#9

It looks like whatever is in X gets stored to register 01 then X is sign-changed, added to 2pi and stored to register 02.

#10

Hi, Bob:

    Assuming you've got a value, say N, in the display (X register)
    at the beginning, after you execute these steps you'll have:
        In Register 1:      

    N

    In both Register 2 and the display (X register):

    -N + 2*Pi

    but you should delete step 041 ENT, (assuming you mean ENTER),
    because ENTER isn't needed to separate the numeric entry "2"
    from the constant value "Pi".
Best regards from V.

#11

Quote:
but you should delete step 041 ENT, (assuming you mean ENTER),
because ENTER isn't needed to separate the numeric entry "2"
from the constant value "Pi".

Doesn't that ENTER mean that you would have

  • R1 = N
  • X = 2Pi+2
  • Y = -N
  • R2 = 2Pi +2

I'm on the opposite North American coast from my 67, but I have my 41 with me. That distribution is what I get when I run the following program:

  • 01 LBL 'TST
  • 02 STO 01
  • 03 CHS
  • 04 2
  • 05 ENTER^
  • 06 PI
  • 07 *
  • 08 +
  • 09 STO 02

Regards,
Howard


#12

Hi, Howard:

Howard posted:


"Doesn't that ENTER mean that you would have

  R1 = N 
X = 2Pi+2
Y = -N
R2 = 2Pi +2

    It depends on whether [ENTER] disables stack lift for the
    following numeric entry (so that it overwrites the contents
    of the X register) *AND* [PI] is considered a numeric entry
    key in the HP-67, which I can't test right now.

    I assumed that either that's the case (so that [ENTER], [PI]
    does overwrite X) or the original coder wrongly thought it
    did, because frankly I find much more plausible that he is trying to compute:

             -N + 2*Pi
    which is frequently seen as part of many computations, than:
              2*Pi + 2
    which seems pretty useless to me.
Best regards from V.

#13

Quote:
It depends on whether [ENTER] disables stack lift for the following numeric entry (so that it overwrites the contents of the X register) *AND* [PI] is considered a numeric entry key in the HP-67, which I can't test right now.

That's exactly the case on my 97 so it should be the same for the 67.

Marcus


#14

Best regards from V.


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP67 eBay auction Cristian Arezzini 3 2,191 12-08-2013, 03:47 PM
Last Post: Raymond Del Tondo
  HP67/97 M.E. Pac cover Ignacio Sánchez 2 1,518 11-22-2013, 04:04 AM
Last Post: Ignacio Sánchez Reig
  HP Prime: run a program in another program Davi Ribeiro de Oliveira 6 2,765 11-11-2013, 08:28 PM
Last Post: Davi Ribeiro de Oliveira
  HP67 motor in HP65 card reader - too slow Harald 4 2,132 05-21-2012, 06:52 PM
Last Post: Dave Shaffer (Arizona)
  Android HP67 - v1.1 posted MikeO 14 4,092 02-08-2012, 07:29 AM
Last Post: Thomas Okken
  HP67 Emulator for Android MikeO 23 6,249 01-28-2012, 07:06 AM
Last Post: Ingo Paschke
  HP 67, 97, 97+ emulator Olivier De Smet 8 2,822 11-11-2011, 09:57 AM
Last Post: Israel Otero
  HP67 for the Android MikeO 17 4,283 05-24-2011, 10:05 AM
Last Post: Vincent Weber
  HP65 vs HP67 card reader Alberto Fenini 2 1,383 04-17-2011, 05:09 PM
Last Post: Alberto Fenini
  old HP67/97 programs for satellite communications Don Shepherd 2 1,131 03-01-2010, 04:55 PM
Last Post: Don Shepherd

Forum Jump: