CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Binary vs Ascii

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree5Likes
  • 1 Post By immortality
  • 4 Post By cdm

LinkBack Thread Tools Search this Thread Display Modes
Old   August 13, 2013, 08:53
Default Binary vs Ascii
Senior Member
immortality's Avatar
Join Date: Oct 2012
Location: Iran
Posts: 2,208
Rep Power: 22
immortality is on a distinguished road
whats the usage differences and advantages of each one?
I have tested that Binary run takes 1/4 space of Ascii run but its a bit slower(I'm not sure,only it looks in terminal) than Ascii and I read somewhere that Binary is more accurate than Ascii.
are my conclusions true or not?
Mojtaba.a likes this.
Injustice Anywhere is a Threat for Justice Everywhere.Martin Luther King.
To Be or Not To Be,Thats the Question!
The Only Stupid Question Is the One that Goes Unasked.
immortality is offline   Reply With Quote

Old   August 15, 2013, 13:48
Join Date: May 2013
Location: Canada
Posts: 32
Rep Power: 8
cdm is on a distinguished road
In general, binary is faster for read/write since the computer does not have to convert to a human-readable format. However, there are advantages (and disadvantages) to each.

For example, say you have a large (fine mesh) simulation where you plan on outputting hundreds or thousands of timesteps. In this case, binary would be better because writing many data points and many timesteps can be done relatively instantaneously (compared to converting and writing thousands of ASCII files).

Alternatively, if you have a small case and you're outputting relatively few timesteps, you can use ASCII without any significant performance hit and you can even open up the timestep files in a text editor to peruse them.

- for large meshes, file size can be significant
- can view/modify the files in text editor
- no problem for smaller cases and/or writing few timesteps

- smaller file sizes
- fast write of data
- cannot view/modify in text editor
- good for large cases and/or writing many timesteps

Just a note: you can switch between the two write methods on the fly by modifying the controlDict entry while your case is running.
cdm is offline   Reply With Quote


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Binary or Ascii? dancfd OpenFOAM Running, Solving & CFD 2 May 6, 2013 22:26
Converting Binary to Ascii.. vishwa OpenFOAM 1 February 25, 2010 16:07
binary heavier than ascii Schag OpenFOAM 2 July 22, 2009 09:38
Error to re-open fluent case file J.Gimbun FLUENT 0 April 27, 2006 09:42
Sliding mesh error Karl Kevala FLUENT 4 February 21, 2001 16:52

All times are GMT -4. The time now is 12:50.