|
[Sponsors] |
June 6, 2017, 07:18 |
how surfaceToCell works?
|
#1 |
Member
Join Date: May 2017
Posts: 38
Rep Power: 9 |
Hello everybody,
I would like to understand how surfaceToCell works in topoSet for a cellSet source. surfaceToCell is composed of of this arguments: - surface - outsidepoint - cut - inside - outside - near - curvature I don't understand the meaning of these arguments except "surface". Someone can help me? Thanks in advance |
|
June 6, 2017, 08:45 |
|
#2 |
Senior Member
|
Hi,
Code:
$ src $ pwd $HOME/OpenFOAM/OpenFOAM-4.1/src $ find . -name 'surfaceToCell.*' ./meshTools/sets/cellSources/surfaceToCell/surfaceToCell.C ./meshTools/sets/cellSources/surfaceToCell/surfaceToCell.H ./meshTools/lnInclude/surfaceToCell.C ./meshTools/lnInclude/surfaceToCell.H $ less ./meshTools/sets/cellSources/surfaceToCell/surfaceToCell.H Code:
//- Name of surface file const fileName surfName_; //- Points which are outside const pointField outsidePoints_; //- Include cut cells const bool includeCut_; //- Include inside cells const bool includeInside_; //- Include outside cells const bool includeOutside_; //- Determine inside/outside purely using geometric test // (does not allow includeCut) const bool useSurfaceOrientation_; //- If > 0 : include cells with distance from cellCentre to surface // less than nearDist. const scalar nearDist_; //- If > -1 : include cells with normals at nearest surface points // varying more than curvature_. const scalar curvature_; |
|
June 6, 2017, 09:38 |
|
#3 | |
Member
Join Date: May 2017
Posts: 38
Rep Power: 9 |
Quote:
Thank you for your help. but it is not yet clear for me. If we take for example the motorbike tutorials, the outsidepoints are outside the moto but inside the domain, outside the moto and outside the domain or inside the moto? About the cut cells, how it is possible to choose the cells cut by motorbike surface? Inside, I think it's inside the motorbike but, in this case there are not cells inside. Outside I think it's outside the motorbike but in the domain. near I understand and I don't understand the function of curvature. |
||
June 6, 2017, 10:12 |
|
#4 |
Senior Member
|
Hi,
Now it is not clear to me, what you are asking. You started from cellSet source in topoSet, i.e. you were selecting CELLS. Now you talk about points (though maybe it was my mistake to include this property in example). You have surface. You can select cells of a computation domain, that are inside this surface, outside this surface, and cut by this surface. To define meaning of "inside" and "outside", you can use either reference point, or surface orientation. Curvature works only for nearDist. And it means the following: Code:
Info<< " Selecting cells with cellCentre closer than " << nearDist_ << " to surface and curvature factor" << " less than " << curvature_ << endl; |
|
June 7, 2017, 03:57 |
|
#5 |
Member
Join Date: May 2017
Posts: 38
Rep Power: 9 |
in my previous message I wanted to apply surfaceToCell in the motorbike case to understand. But I'm agree with you it wasn't clear. Do you know this tutorial?
|
|
June 7, 2017, 05:12 |
|
#6 |
Senior Member
|
It is MUCH easier to understand if you really try to apply this topoSet to your problem and then post your cognitive dissonances.
I know the tutorial. |
|
April 22, 2020, 12:42 |
|
#7 |
Senior Member
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 931
Rep Power: 13 |
For future reference, the following tutorials in v1912 contain examples of `surfaceToCell`:
mesh/foamyHexMesh/flange/system/topoSetDict-background multiphase/interFoam/laminar/waves/mangroveInteraction/system/setFieldsDict Code:
surfaceToCell { file "./constant/triSurface/seaweed.stl"; outsidePoints ((2 0.25 0.15)); includeCut true; includeInside true; includeOutside false; nearDistance -1; curvature -100; fieldValues ( volScalarFieldValue MangrovesIndex 1 ); }
__________________
The OpenFOAM community is the biggest contributor to OpenFOAM: User guide/Wiki-1/Wiki-2/Code guide/Code Wiki/Journal Nilsson/Guerrero/Holzinger/Holzmann/Nagy/Santos/Nozaki/Jasak/Primer Governance Bugs/Features: OpenFOAM (ESI-OpenCFD-Trademark) Bugs/Features: FOAM-Extend (Wikki-FSB) Bugs: OpenFOAM.org How to create a MWE New: Forkable OpenFOAM mirror |
|
Tags |
cellset, openfoam, surfacetocell, toposet |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[OpenFOAM.com] Multiple Installation Issue: Parallel Processing No Longer Works | dancfd | OpenFOAM Installation | 11 | November 20, 2018 17:08 |
[GAMBIT] Gambit works on Windows, but not in Linux | victorz | ANSYS Meshing & Geometry | 8 | April 14, 2013 21:40 |
Parallel runs with sonicDyMFoam crashes (works fine with sonicFoam) | jnilsson | OpenFOAM Running, Solving & CFD | 0 | March 9, 2012 07:45 |
git problem: 1.7.x works but 1.6.x not | af631717 | OpenFOAM Installation | 2 | August 23, 2010 06:22 |
ARTICLES AND WORKS CONCERNING CFD OF LIQUID-LIQUID DISPERSION AND DROPS SIZE IN AGITATED SYSTEMS.. | tim | Main CFD Forum | 1 | June 22, 1999 09:07 |