Interpolation across regionCouple patches in 1.6-ext
My question concerns interpolation across regionCouple patches in 1.6-ext. There are a number of related threads in the forum, most of which you will find if you search for "regionCoupling".
I successfully use OpenFOAM for solving ion transport problems in insulation material, now also including electrohydrodynamics effects (ion winds).
When I started looking at the implicit region coupling in 1.6-ext, I thought that the coupling across regions was implemented to mimic the processor patches when the regionCoupling patch is in its "attached" state. I liked this, because it would mean that interpolation operations (fvc::interpolation) across coupled patches would use whatever interpolation scheme I select in the fvSchemes dictionary, just as for processor patches.
Now that I dig deeper into the code, and examine the results more closely, I realize that the regionCoupling patches don't work that way. The value at the boundary is hard-coded to harmonic averaging in the regionCoupling patch field class. The fvc::interpolate operator would return a "calculated" patch with this harmonic interpolate, regardless of the fvSchemes settings. This works well for most applications where you have diffusion across material interfaces, but also has some limitations. Without going into details, it is not necessarily what you want when you discretize charge transport across a material interface.
I can easily hack a fix for this (looping and setting the values I want on all boundaries), but I wonder if there is a very fundamental reason that I'm missing for choosing this implementation. Or if it could be done in the way I wanted it... ;)
If the regionCoupled patch (in its attached state) was to work like the processor patch, it would be enough to choose "harmonic" interpolation for the laplacian to reproduce the same results for the conjugate heat transfer solver in 1.6-ext, without compromising the larger generality of the underlying coupledFvPatch class.
It would be interesting to have some comments on this.
regionCoupleFvPatch Theory Questions
I plan to couple the magnetic vectorpotential with a regionCoupleFvPatch.
With the template technology it was very easy to built a vector version of the couplingRegion boundary.
But now i'll plan todo my own interpolation to calculate the patchField.
So i try to understand, on which position in the cells are the different fields are located.
I hope somebody correct me or give additional informations
1. the distance of cellCenter(owner) to interface, i think that's the patch().deltaCoeffs() isnt't it ?
2. the distance of interface to cellCenter(neigbour), i dont have a plan about this :-(
3. the field in the cellCenter(Owner) i think that's comes from this->patchInternalField()
4. the field in the cellCenter(Neigbour). That must be the this->patchNeigbourField()
But there is also a access funktion for the shadowPatchField(). Where is the location of this field?
here two little sketches to show my opinion of the field locations and my used values.
Could please tell me how I could access in DEltaX1 and DeltaX2 in regioncoupling?
|All times are GMT -4. The time now is 05:09.|