I am using ReadList
to read an input file as Table
format, and exporting the results. The input.m
file contains expression (say exp
). In the file I have the numerical values for the variables.
Block[{}, Export["output.m", ReadList["input.m"], "Table"] ]
While it is printing small numbers as decimal (e.g. 771640.5749154771
), for bigger numbers it changes to a different format, like 2.8702708449431164e6
.
Is it possible to keep the decimal format for those large numbers as well?
There are some solutions using DecimalForm
, NumberForm
etc. However I do not know how to implement those in this particular piece of code. Should I enclose the exp
as NumberForm[exp, 15]
? Or is there any alternate solution like globally setting $NumberForm
?