CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   Integral value over patch (https://www.cfd-online.com/Forums/openfoam/75414-integral-value-over-patch.html)

ternik April 25, 2010 02:22

Integral value over patch
 
Hi Foamers,

for the flow past square cylinder I would like to calculate the integral of variable (e.g. pressure) over the patch (actually part of patch). Numerical integration (Trapezoidal or Simpson's rule) and "Integrate Variables" in ParaView yields the same (O.K., reasonably close) results, but "patchIntegrate" utility in OF-1.5 gives me the following:

Patch area = sum(S) [0 2 0 0 0 0 0] (37.375 591.5 0)
Reading volScalarField p
Integral of p over patch WallSquareFront[3] = (0.151872 0 0)


The difference is quite big (num. int. and ParaView give approx. 3.02538) - can someone, please explain me why or what is the cause? In addition, what numerical integration is used in ParaView and patchIntegrate utility (Trapezoidal, Simpson...)?

wish you nice day,
Primoz


All times are GMT -4. The time now is 06:48.