- **OpenFOAM Programming & Development**
(*https://www.cfd-online.com/Forums/openfoam-programming-development/*)

- - **Interpolate scalars on boundary faces**
(*https://www.cfd-online.com/Forums/openfoam-programming-development/72343-interpolate-scalars-boundary-faces.html*)

Interpolate scalars on boundary facesHi Foamers,
I need to write a b.c. for a scalar field for which the boundary field must be an accurate interpolation of the internal field. Is there any ready to use interpolation tool? I'm managing to use linearInterpolation(), like in phi construction, but does it use only linear scheme? What I have to do to use higher order schemes (cubic)? Thanks, Ivan |

Ok, yesterday I wrote down some errors (the stuff about linearInterpolate).
Now my question is: is possible using fvc::interpolate() to extrapolate the boundary field of a volScalarField starting from the internal field values? To add some infos, I need to do it as in a piece of my codes there's a scalar field that's not a solution of a PDE, but is just evaluated algebrically, and I need some good extimation of its boundary values in order to do some other calculations (zeroGradient b.c. it's not enough and the field is time-varying, so I cannot impose at the beginnig the value). Thank for the help!!! Ivan |

This is an old post but:
for any field X, the function fvc::interpolate(X) should consider the boundary conditions specified for X to interpolate it to boundary faces. i.e. if you assign a correct boundary condition it will evaluate the values at boundary faces correctly. I am not so good at the boundary conditions to help you in choosing the correct BC. By default, it uses zeroGradient BC, I think. |

All times are GMT -4. The time now is 09:31. |