From 5c0c1f63e019e3428d0a31706566a51166e70c40 Mon Sep 17 00:00:00 2001 From: mattijs Date: Wed, 29 Sep 2010 13:05:38 +0100 Subject: [PATCH] BUG: streamLineParticle : was using GREAT for deltaT which triggers lots of problems. Now using sqrt(GREAT). --- .../functionObjects/field/streamLine/streamLineParticle.C | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/postProcessing/functionObjects/field/streamLine/streamLineParticle.C b/src/postProcessing/functionObjects/field/streamLine/streamLineParticle.C index 78478222cb..ce90b7a55d 100644 --- a/src/postProcessing/functionObjects/field/streamLine/streamLineParticle.C +++ b/src/postProcessing/functionObjects/field/streamLine/streamLineParticle.C @@ -157,7 +157,9 @@ bool Foam::streamLineParticle::move(streamLineParticle::trackData& td) td.switchProcessor = false; td.keepParticle = true; - scalar deltaT = GREAT; //cloud().pMesh().time().deltaTValue(); + // Set very large dt. Note: cannot use GREAT since 1/GREAT is SMALL + // which is a trigger value for the tracking... + scalar deltaT = Foam::sqrt(GREAT); //cloud().pMesh().time().deltaTValue(); scalar tEnd = (1.0 - stepFraction())*deltaT; scalar dtMax = tEnd; @@ -169,6 +171,9 @@ bool Foam::streamLineParticle::move(streamLineParticle::trackData& td) && tEnd > ROOTVSMALL ) { + // TBD: implement subcycling so step through cells in more than + // one step. + // set the lagrangian time-step scalar dt = min(dtMax, tEnd);