comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Obtaining exponent from a scientific format number
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Obtaining exponent from a scientific format number [message #30312] Wed, 17 April 2002 07:01
jicicuendez is currently offline  jicicuendez
Messages: 12
Registered: November 2001
Junior Member
Hi all,

I have a problem and I am looking for a faster solution:

I have a scientific formatted number (e.g. 6.8977653e-18) and I have
to split the exponent and number into two parts like this:
long:68977653
exp:-25
where the first factor has to be a long number and the second the
exponent.
The exponential factors can algo change.

The solution I came up is to turn the number into strings and then
byte(mystring), obtaining the position of '.' and 'e' and then back to
numbers. This seems to be quite slow and since I have a large number
of data I don't think is very efficient.

Thank you very much in advance, I would appreciate any hints.

Juan
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: memory problems on Win2000 or how to delete a variable
Next Topic: one more question on object classification _or_ local/adaptive thresholding

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:23:34 PDT 2025

Total time taken to generate the page: 0.00621 seconds