|
[Sponsors] |
August 30, 2010, 12:07 |
Binary files
|
#1 |
New Member
Join Date: Aug 2010
Posts: 15
Rep Power: 16 |
Hello,
I have 2 separate questions regarding OpenFOAM binary output: 1) Is there a flag in the OpenFOAM file structure that can tell me whether binary data is written in single or double precision? 2) Also, is there a way to tell whether big or little endian is used to write the binary data in the file? Thanks. -amtri |
|
September 17, 2010, 02:05 |
|
#2 | |
Senior Member
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36 |
Quote:
OpenFOAM compiles in double precision mode by default. Best,
__________________
Alberto Passalacqua GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541) OpenQBMM - An open-source implementation of quadrature-based moment methods. To obtain more accurate answers, please specify the version of OpenFOAM you are using. |
||
March 15, 2011, 05:15 |
|
#3 | |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
Regards Bastian |
||
March 16, 2011, 00:43 |
|
#4 |
Senior Member
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36 |
What is the logic behind this? You would lose the double precision used in the mesh immediately at the first operation you force to be single precision.
__________________
Alberto Passalacqua GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541) OpenQBMM - An open-source implementation of quadrature-based moment methods. To obtain more accurate answers, please specify the version of OpenFOAM you are using. |
|
March 16, 2011, 03:59 |
|
#5 | |
Senior Member
BastiL
Join Date: Mar 2009
Posts: 530
Rep Power: 20 |
Quote:
The accuracy differences between SP and DP for my cases are very small. I can reproduce this behaviour with the ASCII-option: Saving my mesh with 6 digits prevents simpleFoam from running both in SP and DP but saving with 10 digits makes simpleFoam to run in both SP and DP. However SP is about 40% quicker and I don't really want to save in ASCII as it doubles the required diskspace. Regards Bastian Last edited by bastil; March 16, 2011 at 04:17. |
||
March 16, 2011, 19:35 |
|
#6 |
Senior Member
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36 |
You can simply save the mesh in compressed format as ASCII, and then switch to binary for the data.
Best,
__________________
Alberto Passalacqua GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541) OpenQBMM - An open-source implementation of quadrature-based moment methods. To obtain more accurate answers, please specify the version of OpenFOAM you are using. |
|
March 17, 2011, 10:01 |
|
#7 |
Senior Member
Olivier
Join Date: Jun 2009
Location: France, grenoble
Posts: 272
Rep Power: 18 |
hello,
On some testcase i did some time ago, with a lot of time step saving, I've got the best speedup with compressed ascii file, binary file where little slower, and ascii file much slower. so try compressed file ! olivier |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
UDF issue | MASOUD | Fluent UDF and Scheme Programming | 14 | December 6, 2012 14:39 |
critical error during installation of openfoam | Fabio88 | OpenFOAM Installation | 21 | June 2, 2010 04:01 |
Problems in compiling paraview in Suse 10.3 platform | chiven | OpenFOAM Installation | 3 | December 1, 2009 08:21 |
Error to re-open fluent case file | J.Gimbun | FLUENT | 0 | April 27, 2006 09:42 |
Results saving in CFD | hawk | Main CFD Forum | 16 | July 21, 2005 21:51 |