From: Radical NetSurfer Newsgroups: comp.os.msdos.djgpp Subject: Generating Exponents FAST! Date: Tue, 22 May 2001 04:53:31 -0400 Message-ID: <0q9kgtgddkvj69od8094172vodtrpubgsh@4ax.com> X-Newsreader: Forte Agent 1.8/32.548 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 216.202.140.48 X-Original-NNTP-Posting-Host: 216.202.140.48 X-Trace: 22 May 2001 04:55:04 -0400, 216.202.140.48 Lines: 30 X-Original-NNTP-Posting-Host: 208.192.4.30 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com This is the problem: all you have to work with is signed short ep; NOW, you want to generate double precision values of the form: 10 ^ ep, pow(10, ep); is one obvious approach Which requires the time and computational overhead of whatever is involved in pow() function.... IS THERE A MORE DIRECT ROUTE to generating 10 ^ ep? These are the values I need, based on +3, +2, +1, 0, -1, -2, -3, etc.: 1000, 100, 10, 1, 0.1, 0.01, 0.001, 0.0001, etc. Any suggestion appreciated! thanks! email: radsmail AT juno DOT com http://members.tripod.com/~RadSurfer/ Join us on Yahoo at: http://groups.yahoo.com/group/BorlandCPPBuilder for informal discussions about all versions of C++Builder... [Computer programming for Windows 95, and Console32] (you must be a Yahoo member to join)