CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Running, Solving & CFD

Binary vs Ascii

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

Like Tree4Likes
  • 1 Post By immortality
  • 3 Post By cdm

Reply
 
LinkBack Thread Tools Display Modes
Old   August 13, 2013, 07:53
Default Binary vs Ascii
  #1
Senior Member
 
immortality's Avatar
 
Ehsan
Join Date: Oct 2012
Location: Iran
Posts: 2,186
Rep Power: 16
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, 12:48
Default
  #2
cdm
Member
 
Join Date: May 2013
Location: Canada
Posts: 32
Rep Power: 4
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.

ASCII
- 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

BINARY
- 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.
Mojtaba.a, Lieven and immortality like this.
cdm is offline   Reply With Quote

Reply

Thread Tools
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 On
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 21:26
Converting Binary to Ascii.. vishwa OpenFOAM 1 February 25, 2010 16:07
binary heavier than ascii Schag OpenFOAM 2 July 22, 2009 08:38
Error to re-open fluent case file J.Gimbun FLUENT 0 April 27, 2006 08:42
Sliding mesh error Karl Kevala FLUENT 4 February 21, 2001 16:52


All times are GMT -4. The time now is 19:55.