Merge branch 'master' of /home/noisy3/OpenFOAM/OpenFOAM-dev

This commit is contained in:
andy
2011-03-01 17:00:32 +00:00
3 changed files with 12 additions and 8 deletions

View File

@ -44,13 +44,17 @@ void Foam::CollidingCloud<CloudType>::setModels()
template<class CloudType>
template<class TrackData>
void Foam::CollidingCloud<CloudType>::moveCollide(TrackData& td)
void Foam::CollidingCloud<CloudType>::moveCollide
(
TrackData& td,
const scalar deltaT
)
{
td.part() = TrackData::tpVelocityHalfStep;
CloudType::move(td, this->solution().deltaT());
CloudType::move(td, deltaT);
td.part() = TrackData::tpLinearTrack;
CloudType::move(td, this->solution().deltaT());
CloudType::move(td, deltaT);
// td.part() = TrackData::tpRotationalTrack;
// CloudType::move(td);
@ -60,7 +64,7 @@ void Foam::CollidingCloud<CloudType>::moveCollide(TrackData& td)
this->collision().collide();
td.part() = TrackData::tpVelocityHalfStep;
CloudType::move(td, this->solution().deltaT());
CloudType::move(td, deltaT);
}
@ -211,14 +215,14 @@ void Foam::CollidingCloud<CloudType>::motion(TrackData& td)
while(!(++moveCollideSubCycle).end())
{
moveCollide(td);
moveCollide(td, this->db().time().deltaTValue());
}
moveCollideSubCycle.endSubCycle();
}
else
{
moveCollide(td);
moveCollide(td, this->db().time().deltaTValue());
}
}

View File

@ -108,7 +108,7 @@ protected:
//- Move-collide particles
template<class TrackData>
void moveCollide(TrackData& td);
void moveCollide(TrackData& td, const scalar deltaT);
//- Reset state of cloud
void cloudReset(CollidingCloud<CloudType>& c);

View File

@ -295,6 +295,7 @@ bool Foam::KinematicParcel<ParcelType>::move
const polyMesh& mesh = td.cloud().pMesh();
const polyBoundaryMesh& pbMesh = mesh.boundaryMesh();
const scalarField& V = mesh.cellVolumes();
const scalar maxCo = td.cloud().solution().maxCo();
scalar tEnd = (1.0 - p.stepFraction())*trackTime;
const scalar dtMax = tEnd;
@ -315,7 +316,6 @@ bool Foam::KinematicParcel<ParcelType>::move
if (p.active() && magU > ROOTVSMALL)
{
const scalar d = dt*magU;
const scalar maxCo = td.cloud().solution().maxCo();
const scalar dCorr = min(d, maxCo*cbrt(V[cellI]));
dt *=
dCorr/d