Post Reply 
Finding Min/Max of a function for HP-67
05-23-2016, 08:00 PM
Post: #14
RE: Finding Min/Max of a function for HP-67
(05-26-2014 10:13 PM)Thomas Klemm Wrote:  
(05-26-2014 12:14 PM)Willy R. Kunz Wrote:  A pity the listings don't come with key codes.

Code:
001  31 25 11    LBL A
002     33 01    STO 1       # store guess for optimum x
003     35 52    X<>Y
004     33 00    STO 0       # store tolerance
005  31 25 00    LBL 0
006     34 01    RCL 1       # display current guess for optimum x
007     35 72    PAUSE
008     35 64    ABS
009        01    1
010        61    +
011        43    EEX
012        42    CHS
013        03    3
014        71    *
015     33 02    STO 2       # calculate and store h
016     34 01    RCL 1
017  31 22 15    GSB E
018     33 03    STO 3       # Calculate and store f(x)
019     34 01    RCL 1
020     34 02    RCL 2
021        61    +
022  31 22 15    GSB E
023     33 04    STO 4       # Calculate and store f(x+h)
024     34 01    RCL 1
025     34 02    RCL 2
026        51    -
027  31 22 15    GSB E
028     33 05    STO 5       # Calculate and store f(x-h)
029     34 04    RCL 4
030        61    +
031     34 03    RCL 3
032        02    2
033        71    *
034        51    -
035     34 02    RCL 2
036     32 54    X^2
037        81    /
038     33 03    STO 3       # calculate and store f''(x)
039     34 04    RCL 4
040     34 05    RCL 5
041        51    -
042     34 02    RCL 2
043        81    /
044        02    2
045        81    /           # calculate f'(x)
046     34 03    RCL 3
047        81    /           # calculate diff
048  33 51 01    STO- 1      # x = x - diff
049     35 64    ABS
050     34 00    RCL 0
051     32 71    X<=Y?
052     22 00    GTO 0
053     34 01    RCL 1
054     35 22    RTN
055  31 25 15    LBL E
056     32 52    EXP
057     35 82    LASTX
058     32 54    X^2
059        03    3
060        71    *
061        51    -
062     35 22    RTN

Cheers
Thomas

Thanks Thomas! I was able to copy and paste to my iPhone's RPN-67 SD and it works like a charm!


Regards,
Bob
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Finding Min/Max of a function for HP-67 - bshoring - 05-23-2016 08:00 PM



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