Searching \ for 'base 10 log (with square root)' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: piclist.com/techref/index.htm?key=base+log+with+square
Search entire site for: 'base 10 log (with square root)'.

Truncated match.
PICList Thread
'base 10 log (with square root)'
1996\05\29@201644 by Edwin Park

flavicon
face
    I would now have to ask how are you taking the square root.  I haven't
    put much thought to this, but I would think that a square root is as
    hard to do as a base 10 log


______________________________ Reply Separator _________________________________
Subject: base 10 log
Author:  pic microcontroller discussion list <spam_OUTPICLISTTakeThisOuTspamMITVMA.MIT.EDU>
Sender:
pic microco at INTERNET-GATEWAY
Date:    5/29/96 4:00 PM

eryone's help.  I found a pretty easy way to find the log10.
I'll just going to scale the numbers to between 0 and 1/2 (the spec has
changed since my first post).  Then use 3.33*(sqrt(sqrt(x))-3  That should
be just enough accuracy, considering that I am only dealing with four
decimal places.

Stuart Allman
Studio Sound Design
.....studioKILLspamspam@spam@halcyon.com

1996\05\29@210016 by Stuart Allman

flavicon
face
>     I would now have to ask how are you taking the square root.  I haven't
>     put much thought to this, but I would think that a square root is as
>     hard to do as a base 10 log

In calculus I learn something called Newton's method where I can just make
an educated guess (say 0.5) and follow his method until the answer converges
at the square root, say after 5 iterations.  I guess I should just get a
good DSP book one of these days so I don't have to remember all this
mathematical messy stuff.
:)

Stuart Allman
Studio Sound Design
studiospamKILLspamhalcyon.com

1996\05\29@212523 by fastfwd

face
flavicon
face
Stuart Allman <.....PICLISTKILLspamspam.....MITVMA.MIT.EDU> wrote:

> In calculus I learn something called Newton's method where I can
> just make an educated guess (say 0.5) and follow his method until
> the answer converges at the square root, say after 5 iterations.

Stuart:

The Newton-Raphson Method is horribly inefficient... Its one benefit
is that it's simple enough that you can use it to perform square-root
calculations in your head.  A (really bad) implementation is in one
of Microchip's math appnotes.

By the way, 5 iterations isn't enough for a 16-bit number; if you
treat the number as an integer in the range [0-65535] and use a
starting approximation of 2 (as Microchip's appnote does), you need
11 iterations.  I once calculated the best -- that is, the
quickest-converging -- starting approximation; for 16-bit numbers, I
think it was 181.

I have in front of me a 16-bit square-root routine that takes only
126 cycles to execute on a PIC16C5x.  It's pretty amazing; when I
received it, I offered its author a job.  Unfortunately, he lives in
Germany, so he wasn't interested...

Anyway, he hasn't given me permission to publish it, so I can't post
the routine here.  However, the knowledge that such a solution exists
should be enough to prod someone into trying to duplicate it.

-Andy

Andrew Warren - EraseMEfastfwdspam_OUTspamTakeThisOuTix.netcom.com
Fast Forward Engineering, Vista, California
http://www.geocities.com/SiliconValley/2499

More... (looser matching)
- Last day of these posts
- In 1996 , 1997 only
- Today
- New search...