CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Running, Solving & CFD (
-   -   Accessing data of geometricField (

bird August 28, 2007 05:29

Hi all, i am a openfoam nov
Hi all,

i am a openfoam novice. I want to access gamma in the interFoam example. I want to do ray tracing of the fluid surface. But i have problems with all these templates. How can a transfer the data of volScalarField to my own source code? Is there a standard method to copy the internalField containing gamma to an array? I want to store the coordinates of the cells and the corresponding gamma values in two different arrays.

Waiting for an answer,

mattijs August 28, 2007 18:21

Code snippet (untested): fo
Code snippet (untested):

forAll(gamma, cellI)
Pout<< "cellI:" << cellI << " cc:" << mesh.C()[cellI] << " gamma:" << gamma[cellI] << endl;

All times are GMT -4. The time now is 20:30.