CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [Gmsh] Internal faces from gmsh how to create patches in OpenFoam (https://www.cfd-online.com/Forums/openfoam-meshing/61865-internal-faces-gmsh-how-create-patches-openfoam.html)

hsieh July 22, 2008 10:14

Hi, Eugene, Thanks a lot!
 
Hi, Eugene,

Thanks a lot! You are an angel.

Pei

saasebo February 25, 2009 09:11

Hi Pei, I am trying to make
 
Hi Pei,

I am trying to make this FAN boundary working, but I do not understand how it should be set up. Is it possible that you could give me some hints?

Best Regards,
Steinar

saasebo February 25, 2009 09:51

Hi Pei, I am trying to make
 
Hi Pei,

I am trying to make this FAN boundary working, but I do not understand how it should be set up. Is it possible that you could give me some hints?

Best Regards,
Steinar

ouafa July 10, 2009 05:18

boundaries gmsh/openfoam
 
bonjour,
en lisant vos échanges sur ce sujet, je m'aperçois que j'ai quasiment le même problème. en effet, j'ai défini un maillage avec gmsh que j'ai ensuite converti par gmshToFoam. dans le dictionnaire boundary, les faces intérieures ne sont pas prises en compte "empty with nFaces=0". j'ai essayé de suivre votre raisonnement mais j'avoue que je ne comprends pas vraimant ce qu'il faudrait que je fasse. est ce au niveau de gmsh ou d'openFoam? la commande createPatches semble résoudre ce problème mais comment l'utiliser?
merci de votre aide et désolée si je vous écris en français.
ouafa.



Quote:

Originally Posted by podallaire (Post 188913)
Thanks for those infos, it worked !

What I did :

1) Modified boundary file and added new patch nFaces 0 in polyMesh/boundary
2) Modified all files in 0
3) createBaffles root case set patch
4) created a faceSetDict to select a second faceZone
5) faceSet root case
6) Moved my mesh from 0 to constant
7) ... restart at 1) to 3)

Regards,

PO


Fonss July 22, 2009 11:30

I was trying to get something similar done in Salome. Basically a large box contains a fan that sucks volume from a certain shape duct or box if you will. The questions is will the fan be a single sheet body/surface/face or does it have to be two faces separated by a small distance as in the link down here.?

"The original FanCenter (imported from gmsh) is now split into FanCenter and FanCenter2 (two sides of the same patch)."http://www.cfd-online.com/Forums/C:%...5Cmini_box.jpg

http://www.cfd-online.com/OpenFOAM_D...es/1/8239.html


I tried several ways on Salome to do this. One is where the box is solid and the duct is empty. I applied a pressure on the fan and inlet/outlet on the duct inlet. Ok I got something but obviously nothing inside the duct. Next i tried to remove the surface that serves as the inlet to the duct. This leaves the duct and fan as an open surface inside a closed volume. This did not mesh on Salome. So that brings the question: IF the fan can be simulated as only one face, how can I bring that face form a pro/e STEP file to Salome to open Foam.

xck1986 November 8, 2011 11:04

a question about inner sampling faces
 
Hi everyone,

I am now simulating two phase flow with Lagrange particle tracking in OpenFOAM.

My domain is a simple rectangular duct. In order to compare the numerical particle properties with experiment data, I need to define a inner patch in my domain, which is parallel to the patch: Inlet and outlet, to sample the particle data.

I have try with createBaffles to convert a faceSet to a patch. But I failed, because I am not familiar with these command.

Does anyone has idea, how to create a inner sampling faces, which is only used to sample the data of the particles, who passes through it.

thanks a lot in advance

latvietis April 25, 2012 16:19

Quote:

Originally Posted by 7islands (Post 188915)
Hi Pierre-Olivier,

If I remember correctly, the procedure continues as follows after 7) of your post.

8) Move your mesh from 0 to constant after a second createBaffles run
9) Create a faceSetDict to select FanCenter
10) faceSet root case
11) Create another faceSetDict to select a subset of FanCenter according to normalToFace<pre>name FanCenter;
action subset;
topoSetSources
(
normalToFace
{
normal (1 0 0); // Vector
cos 0.01; // Tolerance (max cos of angle)
}
);</pre>12) faceSet root case
13) Create a createPatchDict to create a patch FanCenter2 from the faceSet<pre>patches
(
{
name FanCenter2;
type patch;
constructFrom set;
set FanCenter;
}
);</pre>14) createPatch root case

And you will see FanCenter and FanCenter2 separated by their normal directions, with FanCenter2 being the intake-side of the fan.

Takuya


Greetings!

Can anyone please explain this move now? It seems some things have changed since 2008 and this could be done with topoSet (I guess). But I seem to can't figure this out. I managed to get internal patches with Baffles from gmsh, but I can't do these steps (get 2 sided patch).

Sincerely,
Martin

latvietis April 25, 2012 21:24

I'm thinking I'm close, but something is not right:

Code:

FoamFile
{
    version    2.0;
    format      ascii;
    class      dictionary;
    object      topoSetDict;
}

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

actions
(
    {
        name    faceZone_6;
        type    faceSet;
        action  subset;
        source  normalToFace;
        sourceInfo
        {
        normal (0 0 -1);
        cos 0.01;
        }
    }
);

Code:

FoamFile
{
version 2.0;
format ascii;
class dictionary;
object createPatchDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

pointSync false;
// Patches to create.
patches
(
    {
        // Name of new patch
    name faceZone_62;
        // Dictionary to construct new patch from
    patchInfo
    {
    type patch;
    }
        // How to construct: either from 'patches' or 'set'
    constructFrom set;
    set faceZone_6;
    }
);

I tried all normals from (000) to (00-1), and from 3000+ faces it makes a set with about 17 faces. Why is that?

When I try to make a new patch I get this error:
Code:

--> FOAM FATAL ERROR:
Face 8768 specified in set faceZone_6 is not an external face of the mesh.
This application can only repatch existing boundary faces.

This error is with every normal I tried (of course the face number changes).

What am I doing wrong?


All times are GMT -4. The time now is 23:52.