Where can I find the piece of
Where can I find the piece of code that describes how the nonorthogonal correction is implemented in a solver like icoFoam? Thanks.

The code for icoFoam is in
$
The code for icoFoam is in
$FOAM_APP/solvers/incompressible/icoFoam /Ola 
yes, I have read the code but
yes, I have read the code but the implementation of how the nonorthogonal correction is implemented is internal and does not show on the icoFoam.C. I read that nonorthogonal grid will result when treating a laplacian term in some terms that will be treated explicitly. May be that is why there is a loop. But I'm looking for the details of how such terms are implemented in openfoam.
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++) { fvScalarMatrix pEqn ( fvm::laplacian(rUA, p) == fvc::div(phi) ); pEqn.setReference(pRefCell, pRefValue); pEqn.solve(); if (nonOrth == nNonOrthCorr) { phi = pEqn.flux(); } } Thanks. 
42
42

Try:
 my Thesis for a refere
Try:
 my Thesis for a reference  gaussLaplacianScheme.C, line 165 fvm.source() = mesh.V()* fvc::div ( gammaMagSf*this>tsnGradScheme_().correction(vf) )().internalField(); where the correction comes from the snGradScheme, eg. correctedSnGrad.C, line 89: mesh.correctionVectors() & linear < typename outerProduct<vector,>::cmptType>::type >(mesh).interpolate ( gradScheme<typename>::cmptType>::New ( mesh, mesh.gradScheme(ssf.name()) )() //gaussGrad<typename>::cmptType>(mesh) .grad(vf.component(cmpt)) ) Clear? Hrv 
Thanks Hrv for your help.
Thanks Hrv for your help.

Hi Hrv
do i need to checkme
Hi Hrv
do i need to checkmesh before calculation,and creat the nonorth information file in the constant dictionary? to let the Nonorthogonal correction affect. thanks wayne 
No, just run it with a correct
No, just run it with a corrected snGrad scheme.
Hrv 
Hi!
I've been struggling to fully understand the laplacian schemes, and I think this may be the right thread to get some enlightment. I'm still stuck at two points... 1) I was able to follow the overrelaxed approach (as explained in Hrv's thesis) until this point: gaussLaplacian.C: 00066 fvm.upper() = deltaCoeffs.internalField()*gammaMagSf.internalFie ld(); 00067 fvm.negSumDiag(); Line 0066 fills the upper array of the fvMatrix with coefficients Gamma*[S^2/(d dot S)]. Tell me if I'm completely wrong, but I think this only holds true for scalar fields. However, if you take the laplacian of a vector field (e.g. laplacian(nu,U)), you should end up with a tensor dotted with the orthogonal part of the surface normal vector. This should give offdiagonal contributions that should end up in the source term, right? Where do they come into play? I couldn't figure it out yet. 2) The second question that I have concerns the nonorthogonol correction: 00156 const surfaceVectorField Sn(mesh.Sf()/mesh.magSf()); 00157 00158 const surfaceVectorField SfGamma(mesh.Sf() & gamma); 00159 const GeometricField<scalar, fvsPatchField, surfaceMesh> SfGammaSn 00160 ( 00161 SfGamma & Sn 00162 ); 00163 const surfaceVectorField SfGammaCorr(SfGamma  SfGammaSn*Sn); 00164 00165 tmp<fvMatrix<Type> > tfvm = fvmLaplacianUncorrected(SfGammaSn, vf); 00166 fvMatrix<Type>& fvm = tfvm(); 00167 00168 tmp<GeometricField<Type, fvsPatchField, surfaceMesh> > tfaceFluxCorrection 00169 = gammaSnGradCorr(SfGammaCorr, vf); 00170 00171 if (this>tsnGradScheme_().corrected()) 00172 { 00173 tfaceFluxCorrection() += 00174 SfGammaSn*this>tsnGradScheme_().correction(vf); 00175 } 00176 00177 fvm.source() = mesh.V()*fvc::div(tfaceFluxCorrection())().internalField(); At line 00163 the nonorthogonal part of the surface vector is calculated. It should be gamma&(S  (d*S^2)/(d dot S)) (following Hrv's thesis). However this doesn't correspond to the equation in line 00163. I guess the programming is correct, since nobody ever complained in the forums, but maybe someone knows the answer to my (probably stupid) questions. 
Hi!
For those who have problems understanding the laplacians in OpenFOAM, I found the answers to my questions in Ferzinger & Perić (1997) > Chapter 8, Diffusive Fluxes Hrv's PhD is a good lecture for laplacians in OpenFOAM, and F&P rounds the missing details up. 
All times are GMT 4. The time now is 11:58. 