CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > ANSYS Meshing & Geometry

[Other] ANSYS to Fluent mesh export in ASCII format

Register Blogs Community New Posts Updated Threads Search

Like Tree21Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 13, 2011, 10:48
Default
  #21
Member
 
Brian Henry
Join Date: Aug 2010
Posts: 42
Rep Power: 15
EphemeralMemory is on a distinguished road
Hey, all, I have a question about mesh formats.

Gambit and Ansys-FLuent have different mesh formats, and I have written in the past a mesh reader in VTK, where we do some open source applications.

Ansys-Fluent meshes are a bit more complicated, however, is there any way I can get Ansys to export meshes as an Gambit-style mesh, opposed to a Ansys-Fluent style mesh?

Thanks
EphemeralMemory is offline   Reply With Quote

Old   June 15, 2011, 11:43
Default
  #22
Senior Member
 
PSYMN's Avatar
 
Simon Pereira
Join Date: Mar 2009
Location: Ann Arbor, MI
Posts: 2,663
Blog Entries: 1
Rep Power: 47
PSYMN has a spectacular aura aboutPSYMN has a spectacular aura about
The *.msh file is an actual mesh file. This is the one output from TGRID and ICEM CFD for many years, and is the one currently used by ANSYS FLUENT. Gambit can also output in this format. It has both ASCII and binary flavors (is that what you are talking about?). It has almost become a defacto neutral format in the industry and many 3rd party solvers import this format.

I am not a Gambit guy, so let me know if you think this is wrong. The Gambit Neutral file is not really a mesh file. It is more a set of instructions for gambit to build a mesh. This is why other ANSYS tools can't read it in.

So maybe we are not talking about the same stuff... What are the two "different mesh formats" that you are talking about?
__________________
-----------------------------------------
Please help guide development at ANSYS by filling in these surveys

Public ANSYS ICEM CFD Users Survey

This second one is more general (Gambit, TGrid and ANSYS Meshing users welcome)...

CFD Online Users Survey
PSYMN is offline   Reply With Quote

Old   June 15, 2011, 12:06
Default
  #23
Member
 
Brian Henry
Join Date: Aug 2010
Posts: 42
Rep Power: 15
EphemeralMemory is on a distinguished road
Its just that a Gambit style mesh and a Ansys-FLuent style mesh have different internal structures; I cannot read it with my free source reader now because the formatting of the ASCII Mesh is very different from that of the Gambit ASCII Mesh.

I can get Ansys ICEM CFD to read a Gambit-style ASCII mesh, for instance, and export it as a Ansys-style ASCII mesh. The two files, when I look at them, have similar sections but very different formatting (which leads to reading problems).

The one problem I have is that I have developed an application that has the Gambit-style mesh in reader classes that I would not rather touch unless i had to. Is it possible to export a mesh in a older mesh format (one preferred by Gambit), or do I have to code another reader?

Thanks for responding!
EphemeralMemory is offline   Reply With Quote

Old   July 6, 2011, 06:41
Default
  #24
New Member
 
Join Date: Jun 2011
Posts: 5
Rep Power: 14
cih89 is on a distinguished road
Hi

This thread looks like something that could help me with this problem:

http://www.cfd-online.com/Forums/ans...ad-matlab.html

as it looks like MATLAB can read ASCII files. I have set the environment variable but now do I export from the meshing part of the workbench or from Fluent? And am I right in understanding that by choosing .msh it will then be ASCII? Sorry if these are very simple questions. I'm very new to this.

Many thanks
cih89 is offline   Reply With Quote

Old   July 6, 2011, 06:55
Default
  #25
New Member
 
Join Date: Feb 2011
Location: France
Posts: 2
Rep Power: 0
Alynx is on a distinguished road
Hello,

look at the previous page of this discussion ;-)

JasonG explains it :
Pei,

Here are some quick steps I followed to setup my computer, hopefully this will assist you:

Step 1: Right click on "My Computer" icon from desktop, click on "Properties", click on the "Advanced" tab, and then click on "Environment Variabls".

Step 2: Under "User Variables for __" click "New", a box should pop up. Fill out the following:

Variable name: AWP_WRITE_FLUENT_MESH_ASCII
Variable value: 1

Step 3: Click "ok" on all the windows to close out of the system properties.

Step 4: Once in the meshing applet of workbench, go to "File" -> "Export", and then select the ".msh" option.

This should export the fluent file in the correct format, and should translate all components (as long as none are overlapping).
Malkocoglu likes this.
Alynx is offline   Reply With Quote

Old   July 6, 2011, 07:01
Default
  #26
New Member
 
Join Date: Jun 2011
Posts: 5
Rep Power: 14
cih89 is on a distinguished road
Thanks for your reply, I realised that just after posting and have now changed what I said ^^. Seems I can't even get my head around using a forum at the moment! There's probably no hope!!
cih89 is offline   Reply With Quote

Old   July 6, 2011, 13:32
Default
  #27
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 334
Rep Power: 18
phsieh2005 is on a distinguished road
Thanks a lot Alynx!

Pei
phsieh2005 is offline   Reply With Quote

Old   July 6, 2011, 16:10
Default Insider answer...
  #28
Senior Member
 
PSYMN's Avatar
 
Simon Pereira
Join Date: Mar 2009
Location: Ann Arbor, MI
Posts: 2,663
Blog Entries: 1
Rep Power: 47
PSYMN has a spectacular aura aboutPSYMN has a spectacular aura about
Hey EphemeralMemory;

I spoke to some experts here and got this back...

Quote:
The only possible-and-significant differences that I can think of are in the "zones" sections. At one point in years long past, we changed how the boundary condition information is stored. We introduced a new section number for it. (All .msh and .cas file sections begin with "(# ", where # is the section ID.)

FLUENT can still read both types of sections, but GAMBIT may only write the original type. TGrid can probably read and write both types, so it can probably be used as a translator between the two.
I guess it may be worth updating your reader?

If you don't think this is the issue, can you share your example files...
__________________
-----------------------------------------
Please help guide development at ANSYS by filling in these surveys

Public ANSYS ICEM CFD Users Survey

This second one is more general (Gambit, TGrid and ANSYS Meshing users welcome)...

CFD Online Users Survey
PSYMN is offline   Reply With Quote

Old   October 7, 2011, 09:42
Default Setting user variable under Windows (7)
  #29
New Member
 
Julius
Join Date: Mar 2009
Posts: 27
Rep Power: 17
juliuslein is on a distinguished road
Hey all,

first of all thanks for your posts and the hint with the environment variable. If you are not willing and / or allowed to set this variable permanently you can write a tiny .bat-file that does exactly this for you. Just create a text file, rename it to "start.bat" and paste in the following (please adapt your working directory):

set AWP_WRITE_FLUENT_MESH_ASCII=1
"C:\Program Files\ANSYS Inc\v121\Framework\bin\Win64\runwb2.exe"

Good luck
juliuslein is offline   Reply With Quote

Old   February 7, 2012, 04:37
Default
  #30
New Member
 
Mr. Amol Ramteke
Join Date: Feb 2012
Location: Pune, INDIA
Posts: 10
Rep Power: 14
WaterDynamics is on a distinguished road
Thanks it works
WaterDynamics is offline   Reply With Quote

Old   February 12, 2012, 21:10
Default
  #31
Senior Member
 
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36
alberto will become famous soon enoughalberto will become famous soon enough
Any experience with ANSYS Mesh Version 14? It does not seem to take this environment variable into account, and keeps exporting a binary .msh file (FLUENT format).

Thanks in advance.

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.
alberto is offline   Reply With Quote

Old   February 13, 2012, 11:16
Default
  #32
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 334
Rep Power: 18
phsieh2005 is on a distinguished road
Hi, Alberto,

In Meshing, click "Tools", select "Options", then, click Export. You should see ANSYS Fluent. Next to "Format of input files (*.msh)", select ASCII (this is a pull down menu).

Have fun!

Pei-Ying
phsieh2005 is offline   Reply With Quote

Old   February 14, 2012, 03:06
Default
  #33
New Member
 
Mr. Amol Ramteke
Join Date: Feb 2012
Location: Pune, INDIA
Posts: 10
Rep Power: 14
WaterDynamics is on a distinguished road
It work for me when I use Ansys 12.1 but not for Ansys 14.0, Any Clue why




Quote:
Originally Posted by JasonG View Post
Pei,

Here are some quick steps I followed to setup my computer, hopefully this will assist you:

Step 1: Right click on "My Computer" icon from desktop, click on "Properties", click on the "Advanced" tab, and then click on "Environment Variabls".

Step 2: Under "User Variables for __" click "New", a box should pop up. Fill out the following:

Variable name: AWP_WRITE_FLUENT_MESH_ASCII
Variable value: 1

Step 3: Click "ok" on all the windows to close out of the system properties.

Step 4: Once in the meshing applet of workbench, go to "File" -> "Export", and then select the ".msh" option.

This should export the fluent file in the correct format, and should translate all components (as long as none are overlapping).
WaterDynamics is offline   Reply With Quote

Old   February 14, 2012, 03:15
Default
  #34
New Member
 
Mr. Amol Ramteke
Join Date: Feb 2012
Location: Pune, INDIA
Posts: 10
Rep Power: 14
WaterDynamics is on a distinguished road
Quote:
Originally Posted by phsieh2005 View Post
Hi, Alberto,

In Meshing, click "Tools", select "Options", then, click Export. You should see ANSYS Fluent. Next to "Format of input files (*.msh)", select ASCII (this is a pull down menu).

Have fun!

Pei-Ying
Thanks Pei- Ying

Amol
PSYMN and archeoptyrx like this.
WaterDynamics is offline   Reply With Quote

Old   February 14, 2012, 09:28
Default
  #35
Senior Member
 
PSYMN's Avatar
 
Simon Pereira
Join Date: Mar 2009
Location: Ann Arbor, MI
Posts: 2,663
Blog Entries: 1
Rep Power: 47
PSYMN has a spectacular aura aboutPSYMN has a spectacular aura about
Right, now that it is an option, the environment variable is not needed.
__________________
-----------------------------------------
Please help guide development at ANSYS by filling in these surveys

Public ANSYS ICEM CFD Users Survey

This second one is more general (Gambit, TGrid and ANSYS Meshing users welcome)...

CFD Online Users Survey
PSYMN is offline   Reply With Quote

Old   March 16, 2013, 01:52
Default use the GUI
  #36
New Member
 
Juan Diego Colmenares
Join Date: Jun 2012
Posts: 3
Rep Power: 13
juaneco2710 is on a distinguished road
In the Meshing module of Workbench, go to:

Tools -> Options -> Meshing -> Export

set the export format to ASCII. That's it! This worked for me for ANSYS 14.0 on Windows 8.
pooja1991 likes this.
juaneco2710 is offline   Reply With Quote

Old   May 3, 2013, 16:06
Default
  #37
Member
 
sandy
Join Date: May 2013
Posts: 91
Rep Power: 12
archeoptyrx is on a distinguished road
Hey JAson ,

I followed the steps as you said . But when i tried to convert the mesh file which is generated after all these steps . (in ASCII format) in linux using fluentMeshToFoam fluent.msh .. its showing errors .

Help me out guys

Quote:
Originally Posted by JasonG View Post
Pei,

Here are some quick steps I followed to setup my computer, hopefully this will assist you:

Step 1: Right click on "My Computer" icon from desktop, click on "Properties", click on the "Advanced" tab, and then click on "Environment Variabls".

Step 2: Under "User Variables for __" click "New", a box should pop up. Fill out the following:

Variable name: AWP_WRITE_FLUENT_MESH_ASCII
Variable value: 1

Step 3: Click "ok" on all the windows to close out of the system properties.

Step 4: Once in the meshing applet of workbench, go to "File" -> "Export", and then select the ".msh" option.

This should export the fluent file in the correct format, and should translate all components (as long as none are overlapping).
archeoptyrx is offline   Reply With Quote

Old   May 3, 2013, 16:58
Default
  #38
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 334
Rep Power: 18
phsieh2005 is on a distinguished road
Hi,

First try opening the mesh file to check if it is in ASCII format.

If yes, try fluent3DMeshToFoam to convert to openFoam format.

Pei-Ying
phsieh2005 is offline   Reply With Quote

Old   May 3, 2013, 17:39
Default
  #39
Member
 
sandy
Join Date: May 2013
Posts: 91
Rep Power: 12
archeoptyrx is on a distinguished road
This is for a 3D mesh right ? . Mine is a 2D mesh . so using fluentMeshToFoam flat.msh would help ? ???? . I am new to OpenFoam . Correct me if i was wrong .
archeoptyrx is offline   Reply With Quote

Old   May 3, 2013, 21:30
Default
  #40
Senior Member
 
Pei-Ying Hsieh
Join Date: Mar 2009
Posts: 334
Rep Power: 18
phsieh2005 is on a distinguished road
Hi,

Sorry that I never tried converting a 2D mesh into openFoam. However, openFoam only deals with 3D mesh. So, you might want to extrude your 2D mesh to 3D with 1 cell thick, then, try the conversion again.

Good luck!

Peiying
phsieh2005 is offline   Reply With Quote

Reply


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
export ascii file with fluent Clementine FLUENT 3 August 2, 2012 09:52
Exporting structured mesh from ICEMCFD to Fluent? jeevan kumar FLUENT 1 January 23, 2012 11:21
how to export mesh file to Fluent sachin CFX 4 May 14, 2007 08:31
Icemcfd 11: Loss of mesh from surface mesh option? Joe CFX 2 March 26, 2007 18:10
how to export mesh from ICEM CFD to Ansys siv CFX 10 March 23, 2006 08:19


All times are GMT -4. The time now is 18:07.