CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Running, Solving & CFD (
-   -   How to set all X variable to zero at all boundaries (

sampaio June 1, 2006 18:14

Dear all, I need to set som
Dear all,

I need to set some surfaceScalarField, lets say, "X", to zero only at boundaries, but at all boundaries.

Can I use something like:

X.boundaryField() = 0.0 * X.boundaryField();

(I dont need to loop through patches, do I?)

I know this is a simple question, but I read somewhere else that sometimes you need == instead of =, and I need to make sure X is zero at all boundaries...

Thanks a lot,

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