![]() |
Mardi Gras Basic Trigs (HP-12C) - Printable Version +- HP Forums (https://archived.hpcalc.org/museumforum) +-- Forum: HP Museum Forums (https://archived.hpcalc.org/museumforum/forum-1.html) +--- Forum: Old HP Forum Archives (https://archived.hpcalc.org/museumforum/forum-2.html) +--- Thread: Mardi Gras Basic Trigs (HP-12C) (/thread-179837.html) |
Mardi Gras Basic Trigs (HP-12C) - Gerson W. Barbosa - 03-08-2011 01- 2 21- +
Re: Mardi Gras Basic Trigs (HP-12C) - Jim Yohe - 03-08-2011 But you said that you enter the angle in radians so an angle of 89.999999 should yield you -1.99520539304 which still isn't close to "your" implied 62,500,000.00. ;-)
Re: Mardi Gras Basic Trigs (HP-12C) - Gerson W. Barbosa - 03-08-2011 I should have written tan(89.999999 degrees), sorry! Angles in degrees have to be converted to radians, like in the second table examples, which have been multiplied by 1.745329252e-02, that is, pi/180. Regards, Gerson. ------------ The HP-12c Platinum should give more accurate results, but I don't have one to check this out.
Edited: 8 Mar 2011, 3:33 p.m.
Re: Mardi Gras Basic Trigs (HP-12C) - Marcus von Cube, Germany - 03-08-2011 Gerson, can you give some background on the formulas used?
Re: Mardi Gras Basic Trigs (HP-12C) - Gerson W. Barbosa - 03-08-2011 Hi Marcus, Sorry for the lack of documentation. I hope the following is clear. Basically, I combined cos(x) and cosh(x) and used my HP-28S to obtain the required Taylor series. Regards, Gerson.
3: 'COS(X)'
Re: Mardi Gras Basic Trigs (HP-12C) - Marcus von Cube, Germany - 03-09-2011 Thanks for the explanation, Gerson. Did you find the idea somewhere? I assume you did, but not in a book or on the Net but in a corner of your brain. ;)
Re: Mardi Gras Basic Trigs (HP-12C) - Stuart Sprott - 03-09-2011 I can remember using a sharp 167p ( at least I think it was a 167p)back in the early 1970s, before the HP35 took the world by storm. It had 100 program steps, basic arithmetic functions, square root and 10 memory registers. Note no trig functions. It was possible to program accurate trig functions. The only problem was that once the function was generated their was little room left for anything else. All the same we managed to write some basic Surveying programs that at time seemed out of this world. Prior to this you had to use trig tables and curta calculators. We used infinite series for the trig functions. See below. Sin x = x - x3/3! + x5/5! - x7/7! + ...... where x is in radians and in the above context x3 means x cubed. I spent hours programming this machine. It was my introduction to programming. I was totally hooked.
The machine was about the size of a present day lap top and about double the thickness. The program was lost the minute you switched off the calculator. However you could store the program on a punch card. The card had to be manually punched as you wrote the program. Re: Mardi Gras Basic Trigs (HP-12C) - Gerson W. Barbosa - 03-09-2011 Marcus, I certainly knew the Taylor series for sin(x) and cos(x) are similar to those for sinh(x) and cosh(x), except the former ones are alternating series and the latter ones are not. However, it never had occured to me to combine them to approximate the trigonometric functions... not until yesterday morning when playing with my 28S I added the first few terms of the sin(x) and sinh(x) series together and realized this might work. Then I tried cos(x) and cosh(x) and the resulting series appeared to require less steps on the 12C. Anyway, other than rewriting the series, I haven't tried to optimize the program, so I think there is still room for improvement. I think the program runs fast even on the older HP-38, I'll try it on Nonpareil later. Regards,
Gerson.
Re: Mardi Gras Basic Trigs (HP-12C) - Gerson W. Barbosa - 03-09-2011 Stuart,
I know what you mean. Once I knew a retired municipal surveyor who had a small surveying office at home and spent more time there doing calculations than at the field. He had no computer, only one 11C loaded with of couple of simple programs and one sharp scientific calculator to help him. He showed me a printed spread sheet as an example of the calculations he did. I told him it was nonsense to do that kind of work without a computer and advised him to get at least a pocket computer. He purchased a CASIO PB 700 for about 100 dollars (4 kB RAM, later upgraded to whopping 16 kB!) and I wrote him a BASIC program which did in seconds the work it previously took him a whole day or two. Cheers, Gerson.
Re: Mardi Gras Basic Trigs (HP-12C) - Steve Perkins - 03-09-2011 Nice implementation and explanation! I hadn't realized that the 12C Platinum carried 12 significant digits (while showing up to 10).
I verified your table is correct using my Platinum that I had to dig out.
Re: Mardi Gras Basic Trigs (HP-12C) - Gerson W. Barbosa - 03-09-2011 Hello Steve, Thanks for taking the time to key that in and verifying the table. I was curious to know about the Platinum results. As I said, no optimization has been tried yet. The program is fast on the ordinary 12C but somewhat long. Regards, Gerson.
|