Bug 831 - Insufficient numerical precision of timestamped simulation time in the ascii trace file (ns-3.7)
Insufficient numerical precision of timestamped simulation time in the ascii ...
Status: RESOLVED INVALID
Product: ns-3
Classification: Unclassified
Component: core
ns-3.7
PC Linux
: P5 normal
Assigned To: Craig Dowell
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-03-03 18:36 UTC by Jakub Konka
Modified: 2010-05-16 18:25 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jakub Konka 2010-03-03 18:36:51 UTC
Overview:
The simulation time expressed in seconds and timestamped in the ascii trace file has insufficient numerical precision, and can cause erroneous results especially for high-speed wired data networks. 

Compare with bug 830 http://www.nsnam.org/bugzilla/﷒0﷓

The only difference between the two bugs is in the underlying NS3 modules: in ns-3-dev OutputStreamWrapper was responsible, in ns-3.7 AsciiWriter is.

In AsciiWriter module case, the bug can be fixed in exactly the same way as in OutputStreamWrapper (see bug 830 http://www.nsnam.org/bugzilla/﷒1﷓ ).
Comment 1 Craig Dowell 2010-04-07 14:45:49 UTC
With the new tracing framework, a user can set the floating point precision of the underlying stream to whatever is required.

  AsciiTraceHelper helper;
  Ptr<OutputStreamWrapper> stream = helper.CreateFileStream ("file");
  stream->GetStream ()->precision (8);

Does that meet your needs?