Merge remote-tracking branch 'origin/hotfix/gcc47' into nextRelease

Conflicts:
	src/OpenFOAM/fields/PointPatchFields/constraint/processor/ProcessorPointPatchField.C
This commit is contained in:
Henrik Rusche 2013-07-03 21:22:32 +02:00
commit 62f43224bd
2 changed files with 79 additions and 180 deletions

View file

@ -962,8 +962,7 @@ initInterfaceMatrixUpdate
const lduMatrix& m,
const scalarField& coeffs,
const direction,
const Pstream::commsTypes commsType,
const bool switchToLhs
const Pstream::commsTypes commsType
) const
{
tmp<scalarField> tlocalMult(new scalarField(this->size(), 0));
@ -987,100 +986,6 @@ initInterfaceMatrixUpdate
// use the counter.
label coeffI = 0;
if (switchToLhs)
{
// Owner side
// ~~~~~~~~~~
{
const labelList& cutOwn = procPatch_.cutEdgeOwnerIndices();
const labelList& cutOwnStart = procPatch_.cutEdgeOwnerStart();
forAll (mp, pointI)
{
label ownIndex = cutOwnStart[pointI];
label endOwn = cutOwnStart[pointI + 1];
for (; ownIndex < endOwn; ownIndex++)
{
localMult[pointI] +=
coeffs[coeffI]*psiInternal[U[cutOwn[ownIndex]]];
// Multiply the internal side as well using the cut mask
result[U[cutOwn[ownIndex]]] -=
cutMask[coeffI]*coeffs[coeffI]*psiInternal[mp[pointI]];
coeffI++;
}
}
}
// Neighbour side
// ~~~~~~~~~~~~~~
{
const labelList& cutNei = procPatch_.cutEdgeNeighbourIndices();
const labelList& cutNeiStart = procPatch_.cutEdgeNeighbourStart();
forAll (mp, pointI)
{
label neiIndex = cutNeiStart[pointI];
label endNei = cutNeiStart[pointI + 1];
for (; neiIndex < endNei; neiIndex++)
{
localMult[pointI] +=
coeffs[coeffI]*psiInternal[L[cutNei[neiIndex]]];
// Multiply the internal side as well using the cut mask
result[L[cutNei[neiIndex]]] -=
cutMask[coeffI]*coeffs[coeffI]*psiInternal[mp[pointI]];
coeffI++;
}
}
}
// Doubly cut coefficients
// ~~~~~~~~~~~~~~~~~~~~~~~
// There exists a possibility of having an internal edge for a
// point on the processor patch which is in fact connected to
// another point of the same patch. This particular nastiness
// introduces a deformation in the solution because the edge is
// either multiplied twice or not at all. For this purpose, the
// offending edges need to be separated out and multiplied
// appropriately. This will only happen for cell tetrahedral
// decomposition and is generally nasty.
// No need for cut mask here
{
const labelList& doubleCut = procPatch_.doubleCutEdgeIndices();
const labelList& doubleCutOwner = procPatch_.doubleCutOwner();
const labelList& doubleCutNeighbour =
procPatch_.doubleCutNeighbour();
forAll (doubleCut, edgeI)
{
// Owner side
localMult[doubleCutOwner[edgeI]] +=
coeffs[coeffI]*psiInternal[U[doubleCut[edgeI]]];
coeffI++;
// Neighbour side
localMult[doubleCutNeighbour[edgeI]] +=
coeffs[coeffI]*psiInternal[L[doubleCut[edgeI]]];
coeffI++;
}
}
// Add the local multiplication to this side as well
forAll (mp, pointI)
{
result[mp[pointI]] -= localMult[pointI];
}
}
else
{
// Owner side
// ~~~~~~~~~~
{
@ -1147,8 +1052,7 @@ initInterfaceMatrixUpdate
const labelList& doubleCut = procPatch_.doubleCutEdgeIndices();
const labelList& doubleCutOwner = procPatch_.doubleCutOwner();
const labelList& doubleCutNeighbour =
procPatch_.doubleCutNeighbour();
const labelList& doubleCutNeighbour = procPatch_.doubleCutNeighbour();
forAll (doubleCut, edgeI)
{
@ -1170,7 +1074,6 @@ initInterfaceMatrixUpdate
{
result[mp[pointI]] += localMult[pointI];
}
}
// Send the localMult
sendField(tlocalMult, commsType);
@ -1197,13 +1100,9 @@ updateInterfaceMatrix
const lduMatrix&,
const scalarField&,
const direction,
const Pstream::commsTypes commsType,
const bool switchToLhs
const Pstream::commsTypes commsType
) const
{
// Switch to lhs handled in init
// HJ, 22/May/2013
// Get the neighbour side multiplication
tmp<scalarField> tneiMult = receivePointField<scalar>(commsType);
this->addToInternalField(result, tneiMult());

View file

@ -317,7 +317,7 @@ void Foam::ReactingMultiphaseParcel<ParcelType>::calc
);
// Clac mass and enthalpy transfer due to surface reactions
calcSurfaceReactions
this->calcSurfaceReactions
(
td,
dt,