I have found the following usa
I have found the following usage:
findCell-octree <root> <case> <point> [-parallel] So I typed "findCell-octree . cavity (0.05 0.05 0.005)". But it didn't work. How should I input the point? A stupid question, Thanks! |
You will need to put the (0.0
You will need to put the (0.05 0.05 0.005) in quotes otherwise the shell parses each piece as a separate argument:
findCell-octree . cavity "(0.05 0.05 0.005)" |
Hi
How to find the faces of
Hi
How to find the faces of a wall and the cells adjacent with a face (I know the patchId of this Wall)? thanks a lot |
OpenFOAM-1.2/src/OpenFOAM/lnIn
OpenFOAM-1.2/src/OpenFOAM/lnInclude/fvPatch.H
line 187-188: //- Return faceCells const labelList::subList faceCells() const; |
const fvPatch& fvp = mesh.boun
const fvPatch& fvp = mesh.boundary()[patchId];
You can get to the lower level geometry: const polyPatch& pp = fvp.patch() Then you have the .start() and .size() to give you the face indices and lots more (polyPatch.H) |
thanks Mattijs and Eugene, now
thanks Mattijs and Eugene, now I can get the centre of cells, but for patch I need to get the number of this kind of cells.
do you know how can I get it? |
I dont quite understand what y
I dont quite understand what you are getting at.
labelList::subList someName = mesh.boundary()[patchId].faceCells(); forAll(someName, snI) { label boundaryFaceIndex = mesh.boundary()[patchId].patch().start() + snI; label currentFaceCellIndex = someName[snI]; const vector& currentCellCentre = mesh.C()[currentFaceCellIndex]; } Will give you access to the label of the cell adjacent to boundary face with global index "boundaryFaceIndex". The cell centre being at "currentCellCentre". If you mean by "number" the total count of cells adjacent to the specific boundary, then you need to do it manually, i.e. check if a cell has been counted, if not add one to the total and mark the cell as counted via a boolList or some such. |
Thank you Eugene
I think that
Thank you Eugene
I think that it is what I seek. but I have the error message with label currentFaceCellIndex =someName[snI]; In function `int main(int, char**)': /home/baily/OpenFOAM/OpenFOAM-1.1/src/OpenFOAM/lnInclude/SubList.H:61: error: `T& Foam::SubList<t>::operator[](Foam::label) [with T = Foam::label]' is private NewSolverFoam.C:398: error: within this context thank you for your help |
Try,
const labelList::subLi
Try,
const labelList::subList& someName = mesh.boundary()[patchId].faceCells(); and const label& currentFaceCellIndex = someName[snI]; Please see OpenFOAM-1.1/src/OpenFOAM/lnInclude/SubList.H:61 for why things are the way they are. |
Hi,
please how can I get th
Hi,
please how can I get the cells neighbour for a given cell. -- thanks |
mesh.cellCells()
http://www
|
thank you you are the best :-)
thank you you are the best :-)
|
All times are GMT -4. The time now is 19:30. |