diff --git a/applications/utilities/mesh/manipulation/renumberMesh/Allwmake b/applications/utilities/mesh/manipulation/renumberMesh/Allwmake new file mode 100755 index 0000000000..f5f12d5993 --- /dev/null +++ b/applications/utilities/mesh/manipulation/renumberMesh/Allwmake @@ -0,0 +1,14 @@ +#!/bin/sh +cd ${0%/*} || exit 1 # run from this directory + +export SLOAN_LINK_FLAGS='' + +if [ -f "${FOAM_LIBBIN}/libSloanRenumber.so" ] +then + echo "Found libSloanRenumber.so -- enabling Sloan renumbering support." + export SLOAN_LINK_FLAGS="-lSloanRenumber" +fi + +wmake + +# ----------------------------------------------------------------- end-of-file diff --git a/applications/utilities/mesh/manipulation/renumberMesh/Make/options b/applications/utilities/mesh/manipulation/renumberMesh/Make/options index 6a2c95738d..72eeafc9d1 100644 --- a/applications/utilities/mesh/manipulation/renumberMesh/Make/options +++ b/applications/utilities/mesh/manipulation/renumberMesh/Make/options @@ -1,4 +1,5 @@ EXE_INC = \ + -DFULLDEBUG -g -O0 \ -I$(LIB_SRC)/meshTools/lnInclude \ -I$(LIB_SRC)/dynamicMesh/lnInclude \ -I$(LIB_SRC)/finiteVolume/lnInclude \ @@ -11,4 +12,5 @@ EXE_LIBS = \ -lfiniteVolume \ -lgenericPatchFields \ -lrenumberMethods \ + $(SLOAN_LINK_FLAGS) \ -ldecompositionMethods -L$(FOAM_LIBBIN)/dummy -lmetisDecomp -lscotchDecomp diff --git a/applications/utilities/mesh/manipulation/renumberMesh/renumberMesh.C b/applications/utilities/mesh/manipulation/renumberMesh/renumberMesh.C index 487fde704a..4120f8c67a 100644 --- a/applications/utilities/mesh/manipulation/renumberMesh/renumberMesh.C +++ b/applications/utilities/mesh/manipulation/renumberMesh/renumberMesh.C @@ -131,9 +131,9 @@ void getBand forAll(nIntersect, cellI) { - for (label rowI = cellI-cellBandwidth[cellI]; rowI < cellI; rowI++) + for (label colI = cellI-cellBandwidth[cellI]; colI <= cellI; colI++) { - nIntersect[rowI]++; + nIntersect[colI]++; } } @@ -598,14 +598,6 @@ int main(int argc, char *argv[]) sumSqrIntersect ); - if (band != getBand(mesh.faceOwner(), mesh.faceNeighbour())) - { - FatalErrorIn(args.executable()) - << "band:" << band - << abort(FatalError); - } - - reduce(band, maxOp