I am using a native-windows version of openFoam v2306 and downloaded paraview separately. They are in different folders on my computer (runs on windows 10). I have found the folder for running tutorial scenerial and is trying to view the mesh as described in an openfoam tutorial I found. However, this tutorial only included the use of paraFoam script in the terminal, which is discouraged in the openfoam download website (using native paraview is encouraged). But I don’t see any .mesh and .foam file in the “run” folder. All of them are simply “files” when I opened up their property. And because of such, I can’t find the mesh to view in paraview. Could you tell me how should I complete this part?
create an empty .foam
file in the folder, then open it with ParaView.
In the “run/cavity” folder? Also, could you tell me how to create an empty file?
And here is the end of the output after I entered “blockMesh”
No patch pairs to merge
Writing polyMesh with 0 cellZones
Mesh Information
boundingBox: (0 0 0) (0.1 0.1 0.01)
nPoints: 882
nCells: 400
nFaces: 1640
nInternalFaces: 760
Patches
patch 0 (start: 760 size: 20) name: movingWall
patch 1 (start: 780 size: 60) name: fixedWalls
patch 2 (start: 840 size: 800) name: frontAndBack
End
Does this means I have a mesh or not?
In the “run/cavity” folder?
In the directory containing the AllRun
script.
Also, could you tell me how to create an empty file?
Linux/Mac:
touch file.foam
Windows:
Right click, new text file, file.foam
Does this means I have a mesh or not?
I have no idea, this is a question for OpenFOAM
I have tried to use another method I found by running “foamToVTK -ascii” in the command line. But instead of outputting a .vtk file, and .vtm file was outputted. I managed to open this .vtm file in paraview, but instead of a 2d mesh as described in openfoam tutorial, it was a 3d mesh. Am I doing things correctly?
you want to ask foamToVTK
developers.
Understood, also, I input the name “file.foam” in the text file. However, now the name becomes file.foam.txt though. Am I doing this right?
remove the .txt
You need to actually use openFOAM before, you have no results to visualize yet.
I indeed just opened the folder and created the file. But yesterday I have ran the mesh creation process, this is why I have these three folders
put the .foam in this folder, alongside the constant
and system
folder.
Thank you, I can open the file in paraview now. But shouldn’t this (tutorial Lid-driven cavity flow) be a 2d mesh instead of 3d?
Thank you, I have managed to process the tutorial and generated a 3d pressure field over this 3d mesh. But when I am trying to slice it into a 2d contour plot according to the tutorial. the “slice” filter is greyed out:
Could you tell me why?
Please click on the Information tab and tell us what kind of dataset you have loaded.
This is about the “slice” issue, right?
Yes, I was trying to understanding why all those filters (not just Slice) were grayed out. They shouldn’t be with this type of dataset.
Did you click Apply after selecting the OpenFOAM file? You’ll need to do that before trying to apply a filter.
I use a native-paraView software. I just opened the file.foam file by selecting it in the “open” window. I don’t remember seeing a “apply”
The “Apply” button is key for ParaView. In your screenshot with the tutorial and ParaView window, the “Apply” button is visible in the “Properties” tab. It’s a big green button. Click it after selecting the dataset, then the filters should be available to use.