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

Home » Public Forums » archive » Float procedure
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
Float procedure [message #13751] Tue, 01 December 1998 00:00
Charlie Solomon is currently offline  Charlie Solomon
Messages: 10
Registered: September 1998
Junior Member
Hi,

Can anyone shed some light on how this byte array is converted into a
floating point number?
two_words = bytarr(4)
two_words = [244, 232, 165, 64]
IDL> print, two_words, format = '(z)'
f4
e8
a5
40
IDL> print, float(two_words, 0)
2.13062e-038

On my computer at work (NT4, x86) I get a different value...5.18469
Here at home (Win98, x86) I get this really small number....
IDL> print, !version
{ x86 Win32 Windows 5.1.1 Jul 20 1998}

Thanks in advance,

Charlie Solomon
Raytheon Systems Co.
El Segundo, CA
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: IDL 5.2 crashes NT4???
Next Topic: IDL5.2 crashes NT4???

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

Current Time: Wed Oct 08 17:36:49 PDT 2025

Total time taken to generate the page: 0.00548 seconds