Access cell value
Dear Foamers,
Within the forAll loop, I need to find the owner of faceI and get the cell value of T. fixedGradientFvPatchScalarField& bufferField= refCast<fixedGradientFvPatchScalarField>(T.boundar yField()[patchIndex]); scalarField& bufferMesh = bufferField.gradient(); forAll (bufferField, faceI) { } Thanks all in advance Senthil |
I think it's in lduMesh. Look through fvMesh, lduMesh, primitiveMesh. It'll be owner_ or something like that. One of them will give you access. Discretization schemes use it... look in GaussConvection, or Laplacian.
|
David,
Thanks for the tip. Just for others who might have the same issue...below is the code that should be within the forAll loop to access the cell value: const unallocLabelList& owner = mesh.owner(); Info << T[owner[faceI]]; Thanks Senthil |
All times are GMT -4. The time now is 23:36. |