CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   BC implementation in rhoSonicFoam (https://www.cfd-online.com/Forums/openfoam-solving/58745-bc-implementation-rhosonicfoam.html)

srinath July 10, 2008 08:27

Hello I am looking at the c
 
Hello

I am looking at the code of rhoSonicFoam, and i can't spot any place where the BC's are applied.
It seems to work quite magically.
I find this quite perplexing. Any help will be much appreciated as i have been staring at the code for a whole day.

Thanks
Srinath

kdneroorkar July 10, 2008 09:09

i believe the bcs are applied
 
i believe the bcs are applied when you call solve

jlpelerin July 12, 2008 09:02

Srinath, The boundary condi
 
Srinath,

The boundary conditions are read when you create the fields (see file createFields.H). Each field holds the boundary condition that are specified in the corresponding file (0/U, 0/p, ...).
And as explained by kshitij, when you call solve on a given equation, the boundary conditions, associated to the field the equation refers to, will be taken into account.

I hope it helps.
If you want more details, just ask or start reading the code of the fields objects.

Jean-Luc


All times are GMT -4. The time now is 07:40.