CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   FLUENT (https://www.cfd-online.com/Forums/fluent/)
-   -   Fluent -> ParaView (https://www.cfd-online.com/Forums/fluent/37825-fluent-paraview.html)

Newbie September 7, 2005 11:59

Fluent -> ParaView
 
Anyone know if Fluent data can be read by the post processor 'ParaView'.

Had a bit of an explore and it don't seem to want to work. Any experience out there?


Charles September 8, 2005 03:12

Re: Fluent -> ParaView
 
Yes, it can be done. Export to Ensight binary format, read the resulting *.encas file into Paraview with the "Little-endian" option.

Newbie September 8, 2005 12:39

Re: Fluent -> ParaView
 
Thanks - will try.


Newbie September 8, 2005 14:45

Re: Fluent -> ParaView
 
One thing I did have to do in case others are reading.

Rename the *.encas file to *.case.

Anyway this worked for me!

Charles September 8, 2005 15:30

Re: Fluent -> ParaView
 
The .encas --> .cas rename is not strictly necessary. You can force Paraview to list all the files in the directory (otherwise it only lists the files with extensions familiar to it) and then select the Ensight files reader when it asks which reader to use. You can also use the ASCII format Ensight files, but you need to strip the leading spaces from all lines containing character strings.


Udio_NT September 9, 2010 03:13

I tried to open .cas and .dat file from Fluent in Paraview, but I'm not able to see the results in the right way. The 3D model is opened and I can see velocities, for example. But I can't see the right countour velocity map.

So I tried to export datas from Fluent in EnSight format. But Paraview gives this error:
ERROR: In ..\..\..\src\Servers\Filters\vtkEnSightGoldBinaryR eader2.cxx, line 94 vtkEnSightGoldBinaryReader2 (046867F0): stat failed.
ERROR: In ..\..\..\src\Servers\Filters\vtkEnSightGoldBinaryR eader2.cxx, line 136
vtkEnSightGoldBinaryReader2 (046867F0): Unable to open file: C:\Users\Utente\Desktop\How to use Paraview\Hybrid 020 010 005\/hybrid
ERROR: In ..\..\..\src\Servers\Filters\vtkEnSightReader2.cxx , line 307
vtkEnSightGoldBinaryReader2 (046867F0): error reading geometry file
ERROR: In ..\..\..\src\VTK\Filtering\vtkExecutive.cxx, line 756
vtkCompositeDataPipeline (047AAA60): Algorithm vtkEnSightGoldBinaryReader2(046867F0) returned failure for request: vtkInformation (04823518)
Debug: Off
Modified Time: 98830
Reference Count: 1
Registered Events: (none)
Request: REQUEST_DATA
FROM_OUTPUT_PORT: 0
FORWARD_DIRECTION: 0
ALGORITHM_AFTER_FORWARD: 1
ERROR: In ..\..\..\src\Servers\Filters\vtkGenericEnSightRead er2.cxx, line 465
vtkGenericEnSightReader2 (047AC148): Unable to open file: C:\Users\Utente\Desktop\How to use Paraview\Hybrid 020 010 005\/hybrid
Warning: In ..\..\..\src\Servers\Filters\vtkGenericEnSightRead er2.cxx, line 466
vtkGenericEnSightReader2 (047AC148): Assuming binary file.


What can I do?

thomas. July 28, 2015 09:08

Hi Claudio,

any luck with your problem (I know you posted it about 5 years ago!)? I am having a similar one.

Thanks in advance!

Udio_NT August 21, 2015 10:23

Hello Thomas,
Did you try to convert Fluent .cas and .dat files into Ensight gold format before opening them in Paraview? Try also to change the extension .encase to .case manually.

thomas. August 22, 2015 03:40

I tried that and it worked! Thanks.

ViLaks August 19, 2019 04:11

Quote:

Originally Posted by Udio_NT (Post 560533)
Hello Thomas,
Did you try to convert Fluent .cas and .dat files into Ensight gold format before opening them in Paraview? Try also to change the extension .encase to .case manually.

Hi Claudio,

Sorry for restarting the thread again.
I just wanted to know if there is any difference between .encas and .case files?
For an application, I need airflow data from Fluent in ensight case gold (.case ) format. But, I am able to export only .encas format from Fluent and the intended application is not able to read this format!!! Can I export .case format form Fluent? Or your suggestion to just rename the file would suffice?

Thanks and Regards
Vignesh

sufjanst August 21, 2019 04:14

You can export your Fluent data as a Tecplot file which works with paraview

Tobi September 7, 2020 07:47

Hi all,

I am trying to convert Fluent data for ParaView too. However, I am unable to get it work.
  • Tecplot is not working, seems that no mesh data are converted (I cannot select any volume data in the export mask of Fluent)
  • Ensight Gold is not working either. I got en error that states that the *.geo file should be in binary data.

Any idea?

Saikumar Bunni September 7, 2020 09:46

Quote:

Originally Posted by Tobi (Post 782224)
Hi all,

I am trying to convert Fluent data for ParaView too. However, I am unable to get it work.
  • Tecplot is not working, seems that no mesh data are converted (I cannot select any volume data in the export mask of Fluent)
  • Ensight Gold is not working either. I got en error that states that the *.geo file should be in binary data.

Any idea?

I don't know if you have a single .dat and .cas file, or if it is a transient simulation with loads of data. One way you could do this is to make use of Fluent --> OpenFOAM conversion commands.

1. Copy all your fluent results files to any of your tutorial cases in your run directory.

2. Change your startTime to latestTime in system/controlDict

3. You can delete the contents of 0 time folder which will be later created with data from fluent t=0 time file.

4. Write a shell script (if you have multiple files)

The algorithm looks as follows,
a. Read the .cas file using ' fluentMestToFoam meshfile.cas'
b. Iterate over the number of .dat files in the folder,
c. Use a for loop to iterate
- read the dat file 'fluentDataToFoam result_t_*.dat'
- make a new directory with mkdir command for the next time step (Ex: mkdir 't+dt')
end


So the theme of the shell script is to create a time file by converting each of the fluent .dat file to OpenFOAM format.

4. Now use the simple paraFoam command to read your data. This procedure can be further used to simulate the flow in OpenFOAM and validate your results.


I use Fluent for steady state simulation for the lack of steady density based solver in OF, however I continue the transient simulation in OpenFOAM using the above procedure. In my case, although I only have one .cas and one .dat file.

Tobi September 7, 2020 13:05

Interesting point. Never thought about going the way via OpenFOAM format. I found the error. It is related to the latest Fluent release 20 R2 --> I had to load the data using 20 R1 and then it worked.

Nevertheless, I keep your idea in my mind but I don't have FOAM on the machines on the working stations at my company.

Moerten October 1, 2020 05:35

Solution to the Fluent 2020 R2 -> Ensight Gold Data -> Paraview Problem
 
Hey together,


by starting my masters thesis in the last few weeks I ran into the same Problems between Fluent and Paraview, utilizing the EnSight data format, that you guy's mentioned previously.


Long story short, I came up with a sulution. At least for anyone that uses the Fluent 2020 R2 release:


Your Ensight .encas-file looks after the export somewhat like the example beneath. Paraview seems to have Problems with the ""-marks, which hold certain filenames, and doesn't support the whole SCRIPTS-section of the file. If you remove the problematic bits of the file (marked in red) and save it as .case-file, you should be good to go importing your solution data in Paraview. However, be careful to no leave a blank line at the end of the textfile. This, for some reason, sends Paraview in a inf-loop while reading the data.



Code:

FORMAT
type:  ensight gold
GEOMETRY
model:  2  2  "generic_meshfile.geo"
VARIABLE
scalar per element:  1  1  total_pressure  "generic_solution_variable.scl1"
vector per element:  1  1  velocity  "velocity_solution.vel"
TIME
time set: 1 Model
number of steps: 2
time values:  2.59587e-09  1.86688e-08
time set: 2 Model
number of steps: 1
time values: 2.59587e-09
FILE
file set: 1
number of steps:2
file set: 2
number of steps: 1
SCRIPTS
metadata: "generic_metadata.xml"

Best regards
Moerten

Tobi October 1, 2020 15:50

Okay, the script section was obvious (only a warning in ParaView) but the quotations ... a good hint :)

sfigueroa72 November 10, 2020 08:46

Quote:

Originally Posted by Tobi (Post 782224)
Hi all,

I am trying to convert Fluent data for ParaView too. However, I am unable to get it work.
  • Tecplot is not working, seems that no mesh data are converted (I cannot select any volume data in the export mask of Fluent)
  • Ensight Gold is not working either. I got en error that states that the *.geo file should be in binary data.

Any idea?

Hello.

If you want to export a non Dynamic Mesh, cgns format works fine on the latest ParaView version

lukasf January 28, 2021 07:33

How to import Fluent .cas.h5 to ParaView?
 
Hi,

so far I was able to import .cas and .dat binary files with ParaView 5.0.1.

The latest ANSYS release like 2020 R1 saves the .cas.h5 and .dat.h5 files.

Hence, I downloaded tested the latestet ParaView versions (5.9.0 and 5.8.0).

I get the following error, when trying to import the .cas.h5 file with the "fluent case reader":

vtkFLUENTReader (0xa6e1d080): Could not open data file my_path_to/fluent.casdatassociated with cas file my_path_to/fluent.cas.h5. Please verify the cas and dat files have the same base name.

Both files have the same name:
fluent.cas.h5
fluent.dat.h5

so I do know what ParaView wants.


When I export the fluent data to ensight I end up with a .cas and .cdat file. The .cas can be read and I see the mesh but not the data.
Converting Fluent data to Foam was always messy for me, too and I do not want to go that way either.

I would like to save time just use the .cas.h5 and .dat.h5 files. This way I do not have to open fluent and change the format for ParaView.

How to import Fluent .cas.h5 files to ParaView?

Moerten January 28, 2021 08:11

Hi Lukas,


are you sure you used Ensight-gold?


Iam not aware of any possibility to read .cas.h5/.dat.h5 files with Paraview. But, if you have been able to read .cas/.dat-files with a previous version of Paraview, there is a default I/O option in the preferences of Fluent 2020R*. Set this option to "Legacy". This might help in your case. Nevertheless, i am pretty sure this won't work for more complex situations eg. dynamic meshes, because fluent denies to write the dynamic-mesh info into legacy files.


Good luck :)

lukasf January 28, 2021 08:55

Hi,


this was helpful, since I cannot reach the ANSYS Support (I guess their support website is down).



It works this way (using ParaView 5.0.1 so I guess the newer ones will work, too). I opened the .cas.h5 files with Fluent and was able to save them to .cas files. You have change I/O to legacy as you mentioned. Otherwise Fluent ignores your command to save it to .cas and saves it as .cas.h5 again :confused:.

File/Preferences/Default Format for I/O => Legacy



If I will encounter problems with the dynamic mesh adaption I will try to find a solution.


To get the Ensight format I talked about I did this in Fluent R2020 R2:

File/Export to CFD-Post

The file type is called: CDAT for CFD-Post and EnSight.


I have not used Ensight Gold yet.


Lukas


All times are GMT -4. The time now is 09:25.