From 7024c0e4a239e73f8549d89c9217e401e840e663 Mon Sep 17 00:00:00 2001 From: william <william> Date: Thu, 19 Dec 2013 15:03:45 +0000 Subject: [PATCH] BUG: Explicitly set keep particle flag in Colliding and MPPIC clouds This stops all the particles on a given processor being deleted if the last particle considered in the previous step was not being kept. --- .../parcels/Templates/CollidingParcel/CollidingParcel.C | 2 ++ .../intermediate/parcels/Templates/MPPICParcel/MPPICParcel.C | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/src/lagrangian/intermediate/parcels/Templates/CollidingParcel/CollidingParcel.C b/src/lagrangian/intermediate/parcels/Templates/CollidingParcel/CollidingParcel.C index f422f7ea372..36f146d77af 100644 --- a/src/lagrangian/intermediate/parcels/Templates/CollidingParcel/CollidingParcel.C +++ b/src/lagrangian/intermediate/parcels/Templates/CollidingParcel/CollidingParcel.C @@ -80,6 +80,8 @@ bool Foam::CollidingParcel<ParcelType>::move p.angularMomentum() += 0.5*trackTime*p.torque(); + td.keepParticle = true; + break; } diff --git a/src/lagrangian/intermediate/parcels/Templates/MPPICParcel/MPPICParcel.C b/src/lagrangian/intermediate/parcels/Templates/MPPICParcel/MPPICParcel.C index 3844d22f673..0bac21bf8f3 100644 --- a/src/lagrangian/intermediate/parcels/Templates/MPPICParcel/MPPICParcel.C +++ b/src/lagrangian/intermediate/parcels/Templates/MPPICParcel/MPPICParcel.C @@ -76,6 +76,8 @@ bool Foam::MPPICParcel<ParcelType>::move p.UCorrect() = td.cloud().dampingModel().velocityCorrection(p, trackTime); + td.keepParticle = true; + break; } case TrackData::tpPackingNoTrack: @@ -83,6 +85,8 @@ bool Foam::MPPICParcel<ParcelType>::move p.UCorrect() = td.cloud().packingModel().velocityCorrection(p, trackTime); + td.keepParticle = true; + break; } case TrackData::tpCorrectTrack: -- GitLab