CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Pre-Processing (https://www.cfd-online.com/Forums/openfoam-pre-processing/)
-   -   decomposePar changes sign of surfaceVectorField at processor boundary (https://www.cfd-online.com/Forums/openfoam-pre-processing/137419-decomposepar-changes-sign-surfacevectorfield-processor-boundary.html)

hertzsprung June 16, 2014 08:45

decomposePar changes sign of surfaceVectorField at processor boundary
 
Digging through the source code I found the a comment in src/parallel/decompose/decompose/fvFieldDecomposer.H:

Code:

//- Processor patch field decomposer class. Surface field is assumed
//  to have direction (so manipulates sign when mapping)

which is the wrong assumption for my wind vector field. What's the best way around this?

hjasak June 17, 2014 02:46

Are you sure you know what you're doing? This works on surface fields such as flux, where the neighbour processor geometry flips the face area vector. This is the reason for sign change.

If you have a surfaceVectorField, simply re-interpolate in parallel or evaluate eg. Sampling in parallel. Without the change of sign, fluxes would be wrong.

Hrv


All times are GMT -4. The time now is 01:32.