CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM (
-   -   How can I use patchtopatchinterpolation? (

aperture September 26, 2010 21:41

How can I use patchtopatchinterpolation?
Dear all,
I'm a new commer of OpenFoam.
I want to do 1-way FSI. For mapping the presure field on the surface of the solid, I may need to run patchtopatchinterpolation utility. How can I run it?

THX in advance.

bigphil September 27, 2010 05:37


I am not sure if there is a patchToPatchInterpolation stand-alone utility (please correct me if I am wrong)
but the code is all there for you to use.

You have to include patchToPatchInterpolation.H in your solver, and you declare the patchToPatchInterpolation like this:

patchToPatchInterpolation fromPatch_To_toPatch_Interpolate
 mesh.boundaryMesh()[fromPatchIndex],    // from patch
 mesh.boundaryMesh()[toPatchIndex],    // to patch

Different intersection methods can be used.

And then to use the your patchToPatchInterpolation, you would do something like this:

vectorField interpolatedQuantity = fromPatch_To_toPatch_Interpolate.faceInterpolate<vector>

You can use pointInterpolate too and interpolate scalars and tensors too (I think).

Hope it helps,

aperture September 28, 2010 01:04

I'll try that.
Thanks !

Eli1993 May 12, 2016 05:55

Hello everyone
I am working with bubbleintertrackFoam solver to simulte a bubble in a still liquid column. I am getting an error as

Error in B-to-A face patchToPatchInterpolation.

From function freeSurface::makeInterpolators()
in file makeFreeSurfaceData.C at line 105.

Can anyone help me to understand meaning of above said line or suggest me what to do.

All times are GMT -4. The time now is 13:53.