CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   Access mesh data (https://www.cfd-online.com/Forums/openfoam-programming-development/233160-access-mesh-data.html)

negarnaghash January 15, 2021 14:18

Access mesh data
 
Hi all,

I'm trying to add a piece of code to the reactingParcel foam source code. And for my purpose, I need to grab the containing cell of a sample particle in the domain and access its pressure and temperature to manipulate it for further actions.
So far I found that each particle has a "celli_" defined in the particle.H class az and index of the containing cell of the particle. Now I need to pass that value to the mesh to be able to read that specific cell pressure and temperature but to be honest, this whole recursive use of classes in OpenFoam is extremely confusing to me.
So I appreciate any thoughts or suggestions on this problem.


All times are GMT -4. The time now is 16:14.