Shop OBEX P1 Docs P2 Docs Learn Events
Amp-hour meter -x**.23 — Parallax Forums

Amp-hour meter -x**.23

ArchiverArchiver Posts: 46,084
edited 2002-11-14 00:42 in General Discussion
Tracy, Al, et al:

Solved my problem with computing a power. What I actually needed to compute
was

x**1.237

for x in the range 1 to 100
which makes life much easier.

I fit a 2nd order polynomial to this, then compared the results. Found out
that by splitting the range in to, from x = 1 to 10, and x= 11 to 100,
using a different 2nd order poly for each, I could get a fit to within 1%.
Using Tracy's notes on the "**" operator (which I had never used before), I
was able write a routine that did the above calculation. Works great!

Thanks for the pointers.

Larry

Larry Bradley
Orleans (Ottawa), Ontario, CANADA
Sign In or Register to comment.