ln and e^x on the 16C?
|
01-28-2018, 08:52 PM
(This post was last modified: 01-28-2018 08:54 PM by Gerson W. Barbosa.)
Post: #10
|
|||
|
|||
RE: ln and e^x on the 16C?
(03-22-2016 05:44 PM)Dave Britten Wrote: If I could add some programs to calculate ln(x) or e^x, then I could at least get powers and roots in place for those occasions when it's needed. Before I go reinventing the wheel (with a clumsy Taylor series or something), has anybody already tackled this problem on the 16? If you haven’t come up with anything better and you’re still interested, you might want to try this, if reduced accuracy isn’t a problem: 01 LBL A ; ln(x) 02 1 03 EEX 04 CHS 05 3 06 CF 1 07 1 08 + 09 STO I 10 CLx 11 LASTx 12 x<>y 13 x<=y 14 GSB 2 15 LBL 0 16 √x 17 RCL I 18 x>y 19 GTO 1 20 Rv 21 x<>y 22 ENTER 23 + 24 x<>y 25 GTO 0 26 LBL 1 27 Rv 28 ENTER 29 + 30 1 31 - 32 √x 33 x<>y 34 ENTER 35 + 36 * 37 LASTx 38 - 39 F? 1 40 CHS 41 RTN 42 LBL 2 43 SF 1 44 1/x 45 RTN 46 LBL B ; e^x 47 1 48 3 49 STO I 50 Rv 51 8 52 1 53 9 54 2 55 + 56 LASTx 57 / 58 ENTER 59 * 60 1 61 + 62 2 63 / 64 LBL 4 65 ENTER 66 * 67 DSZ 68 GTO 4 69 RTN Examples: 2 GSB A -> 0.693148000 GSB B -> 2.000013165 12345 GSB A -> 9.42101000 GSB B -> 12345.12104 6.789 EEX 79 GSB A -> 183.8196 GSB B -> 6.687315E79 0.12345 GSB A -> -2.091921000 GSB B -> 0.123449622 230 GSB B -> 7.496895E99 GSB A -> 229.9703000 1 GSB A -> 0.000000000 GSB B -> 1.000000000 GSB B -> 2.718292170 GSB B -> 15.15444181 GSB A -> 2.718294000 GSB A -> 1.000005000 GSB A -> 0.000005000 0.693147181 CHS GSB B -> 0.50000016 0 GSB A -> Error 0 2 CHS GSB A -> Error 0 |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
ln and e^x on the 16C? - Dave Britten - 03-22-2016, 05:44 PM
RE: ln and e^x on the 16C? - Jake Schwartz - 03-22-2016, 10:07 PM
RE: ln and e^x on the 16C? - Dave Britten - 03-22-2016, 11:51 PM
RE: ln and e^x on the 16C? - Gene - 01-29-2018, 04:00 AM
RE: ln and e^x on the 16C? - Dave Britten - 01-29-2018, 03:27 PM
RE: ln and e^x on the 16C? - Bob Patton - 03-23-2016, 12:25 AM
RE: ln and e^x on the 16C? - Gerson W. Barbosa - 03-23-2016, 01:38 AM
RE: ln and e^x on the 16C? - Tugdual - 03-26-2016, 06:31 AM
RE: ln and e^x on the 16C? - Didier Lachieze - 03-26-2016, 08:41 AM
RE: ln and e^x on the 16C? - Dave Britten - 03-26-2016, 11:52 AM
RE: ln and e^x on the 16C? - Tugdual - 03-27-2016, 04:31 PM
RE: ln and e^x on the 16C? - Gerson W. Barbosa - 01-28-2018 08:52 PM
|
User(s) browsing this thread: 1 Guest(s)