Skip to content
Snippets Groups Projects
Commit 6b054eab authored by Henry's avatar Henry
Browse files

MGridGenGAMGAgglomerate: Use sum magSf rather than mag(sum Sf) for face-weighting

This is more consistent with the faceArea agglomeration and generates more reliable agglomerations.
parent 43ac6073
Branches
Tags
No related merge requests found
......@@ -30,11 +30,6 @@ Description
#include "fvMesh.H"
#include "syncTools.H"
//extern "C"
//{
//# include "mgridgen.h"
//}
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
void Foam::MGridGenGAMGAgglomeration::
......
......@@ -59,7 +59,11 @@ Foam::MGridGenGAMGAgglomeration::MGridGenGAMGAgglomeration
// Start geometric agglomeration from the cell volumes and areas of the mesh
scalarField* VPtr = const_cast<scalarField*>(&fvMesh_.cellVolumes());
SubField<vector> Sf(fvMesh_.faceAreas(), fvMesh_.nInternalFaces());
vectorField magFaceAreas(vector::one*mag(fvMesh_.faceAreas()));
SubField<vector> Sf(magFaceAreas, fvMesh_.nInternalFaces());
//SubField<vector> Sf(fvMesh_.faceAreas(), fvMesh_.nInternalFaces());
vectorField* SfPtr = const_cast<vectorField*>
(
&Sf.operator const vectorField&()
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment