From db109ba80216df3108003dec12199f8ad50abfd4 Mon Sep 17 00:00:00 2001 From: Will Bainbridge Date: Fri, 9 Aug 2019 15:04:17 +0100 Subject: [PATCH] MPPICCloud: Added error indicating incompatibility of sub-models with moving meshes MPPIC requires significant extension for damping and packing modelling to work on moving meshes. At present the predictor-corrector process used by these models does not maintain a consistent time-state relative to a moving mesh. The cloud needs to enact the correction track from the original starting point, rather than from the end of the non-corrected track. This will require additional tracking or storage and communication steps. Resolves bug report https://bugs.openfoam.org/view.php?id=3318 --- .../clouds/Templates/MPPICCloud/MPPICCloud.C | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/src/lagrangian/intermediate/clouds/Templates/MPPICCloud/MPPICCloud.C b/src/lagrangian/intermediate/clouds/Templates/MPPICCloud/MPPICCloud.C index ec951a5b5c..57bc36d36e 100644 --- a/src/lagrangian/intermediate/clouds/Templates/MPPICCloud/MPPICCloud.C +++ b/src/lagrangian/intermediate/clouds/Templates/MPPICCloud/MPPICCloud.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | Website: https://openfoam.org - \\ / A nd | Copyright (C) 2013-2018 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2013-2019 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -200,6 +200,13 @@ void Foam::MPPICCloud::motion if (dampingModel_->active()) { + if (this->mesh().moving()) + { + FatalErrorInFunction + << "MPPIC damping modelling does not support moving meshes." + << exit(FatalError); + } + // update averages td.updateAverages(cloud); @@ -224,6 +231,13 @@ void Foam::MPPICCloud::motion if (packingModel_->active()) { + if (this->mesh().moving()) + { + FatalErrorInFunction + << "MPPIC packing modelling does not support moving meshes." + << exit(FatalError); + } + // same procedure as for damping td.updateAverages(cloud); packingModel_->cacheFields(true);