CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Meshing & Mesh Conversion

Problem converting fluent (.msh) into .foam format with very big mesh

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

Like Tree1Likes
  • 1 Post By Abracurcix

Reply
 
LinkBack Thread Tools Display Modes
Old   May 30, 2013, 10:24
Exclamation Problem converting fluent (.msh) into .foam format with very big mesh
  #1
New Member
 
Balti
Join Date: Nov 2012
Posts: 16
Rep Power: 4
Balti is on a distinguished road
Hello,

I have a big mesh (750M of cells and number of faces is 2281418248>2^31=integer max limit)

I have been trying to convert this Fluent .msh file (saved in ASCII) for use in OpenFOAM 2.2.0. I use fluentMeshToFoam.
I obtain this error message:

number of faces: -2112910716


--> FOAM FATAL ERROR:
bad set size -2112910716

From function List<T>::setSize(const label)
in file /common/SnappyHex/OpenFOAM/OpenFOAM-2.2.0/src/OpenFOAM/lnInclude/List.C at line 322.

FOAM aborting


I searched and if you try to read the hexadecimal number 820F8A84 (=2182056580 = number of internal faces that we read in the .msh file) and save it in an integer variable you obtain -2112910716.

So my question is: how can I bypass this problem? I want to export my .msh file into .foam.

Thanks a lot for your future answers
Balti is offline   Reply With Quote

Old   June 10, 2013, 14:29
Default
  #2
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings Balti,

Quick question: Are you using OpenFOAM in 32bit or 64bit?

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   June 13, 2013, 07:09
Default
  #3
New Member
 
Balti
Join Date: Nov 2012
Posts: 16
Rep Power: 4
Balti is on a distinguished road
Good question... How can I know it ?
I downloaded the source pack 2.2.0 and I followed the instruction from http://www.openfoam.org/download/source.php to compile.
Balti is offline   Reply With Quote

Old   June 15, 2013, 06:21
Default
  #4
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Balti,

Run:
Code:
uname -m
If it says "i686" or similar, then you're using 32bit.
If it says "x86_64", then you're using 64bit.

If you are using 32bit, it's only natural that it cannot handle more than 2^31 cells/faces/points.

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   June 16, 2013, 22:52
Default
  #5
New Member
 
Albert Pinto
Join Date: May 2013
Posts: 16
Rep Power: 4
Abracurcix is on a distinguished road
Hello Bruno,
I am having this exact problem too (with OpenFOAM-2.2.x, built on a 64 bit machine with GCC-4.8.1). The wmake scripts do not appear to pick up the FOAM_LABEL64 option in the file OpenFoam-2.2.x/src/OpenFOAM/primitives/ints/label/label.H. Forcing the -DFOAM_LABEL64 option, by including it in ptFlags in wmake/rules/linux64Gcc48/c++ creates problem in building the surfMesh library on OpenFOAM-2.2.x/src. A it stands now, both fluentMeshToFoam and fluent3dMeshTo Foam fail due to the "bad set size"message. Any suggestions, please?

Cheers,
Albert

p.s. If one could judiciously include the FOAM_LABEL64 option, then FOAM_LONG_MAX would be set to a value greater than 2 Billion and the type "label" would be synonymous with long int (instead of int as it is now). I haven't figured out how to do this without breaking other libraries.
Balti likes this.
Abracurcix is offline   Reply With Quote

Old   June 17, 2013, 02:39
Default
  #6
New Member
 
Balti
Join Date: Nov 2012
Posts: 16
Rep Power: 4
Balti is on a distinguished road
Code:
uname -m
gives me "x86_64"

Like "Abracurcix" I tried to modify some configuration files to force the type 'label' to be long int instead of int.
I modified OpenFOAM-2.2.0/wmake/rules/General/general/linux64Gcc/c, and .../linux64Gcc/c++ including -DFOAM_LABEL64 or changing -m32 into -m64 but in each case, it induces some errors during the compilation (I don't have these error messages but I can reproduce it if needed it).

Any suggestions ?

Thanks a lot
Balti is offline   Reply With Quote

Old   June 17, 2013, 17:10
Default
  #7
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings to all!

Then this is related to this thread: bad setSize while building up a too large mesh ?

But this is really hard to debug, specially without a machine with a very large amount of RAM, as I said on that other thread, on post #5
Quote:
Originally Posted by wyldckat View Post
Nonetheless, if your machines do have that amount of RAM or more, I do strongly suggest that you report this on the bug tracker: http://www.openfoam.org/bugs/

@Albert: Gcc 4.8.1? But OpenFOAM 2.2.x doesn't officially support this version of Gcc!

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   June 18, 2013, 19:09
Default
  #8
New Member
 
Albert Pinto
Join Date: May 2013
Posts: 16
Rep Power: 4
Abracurcix is on a distinguished road
Hello Bruno,
The problem is not with Gcc-4.8.1. I've tried building with gcc-4.6 and the same problem (i.e. bad set size) persists. Also, some of the tutorial test cases with the 4.6 and 4.8.1 builds work. The problem, really, is more basic. Enforcing FOAM_LABEL64 breaks the surfMesh library (and some other libraries too). In your email, you indicate that you do not have access to a 1TB RAM machine. Could you please try building with FOAM_LABEL64 turned on and let us know if you have been able to build all the .so libraries and executables?

Thanks,
Albert
Abracurcix is offline   Reply With Quote

Old   June 20, 2013, 16:43
Default
  #9
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Albert,

OK, I'll try to have a look into this during the weekend.

Best regards,
Bruno
wyldckat 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
No layers in a small gap bobburnquist OpenFOAM Native Meshers: snappyHexMesh and Others 6 August 26, 2015 09:38
Exporting from V grid to fluent, .msh format Karl SG OpenFOAM Other Meshers: ICEM, Star, Ansys, Pointwise, GridPro, Ansa, ... 0 April 14, 2013 23:33
Converting Starccm+ mesh Ladnam OpenFOAM 0 September 14, 2011 06:30
problem in converting mesh from fluent kiran OpenFOAM 1 October 31, 2010 22:35
Problem with Dynamic Mesh and Fluent Claude Main CFD Forum 0 December 12, 2006 07:03


All times are GMT -4. The time now is 00:59.