Re: Reading Fortran Data file
- To: mathgroup at smc.vnet.net
- Subject: [mg100340] Re: Reading Fortran Data file
- From: Bill Rowe <readnews at sbcglobal.net>
- Date: Mon, 1 Jun 2009 07:09:55 -0400 (EDT)
On 5/31/09 at 6:36 AM, mojoflowstudio at gmail.com (christopher pike) wrote: >Have data fortran data file with numbers like 0.447562485933D-01. I >need all the digits, but mathematica seems to only read this as >0.0448062. <snip> >So how can I read in all the digits. It is far from clear all of the digits have not been read. Mathematica by default does not display all of the digits in a machine precision number. For example, In[1]:= x = RandomReal[] Out[1]= 0.436287 In[2]:= RealDigits[x] Out[2]= {{4,3,6,2,8,7,3,0,2,4,3,3,0,6,3,1},0} Here the value returned by RandomReal has 16 significant digits but only 6 are displayed. My guess is all of the digits in your file have been read.