mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' of /home/dm4/OpenFOAM/OpenFOAM-dev
This commit is contained in:
@ -2,7 +2,7 @@
|
|||||||
========= |
|
========= |
|
||||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
\\ / O peration |
|
\\ / O peration |
|
||||||
\\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -95,7 +95,9 @@ Foam::forceSuSp Foam::SRFForce<CloudType>::calcNonCoupled
|
|||||||
const vector& r = p.position();
|
const vector& r = p.position();
|
||||||
|
|
||||||
// Coriolis and centrifugal acceleration terms
|
// Coriolis and centrifugal acceleration terms
|
||||||
value.Su() = mass*(2.0*(p.U() ^ omega) + (omega ^ (r ^ omega)));
|
value.Su() =
|
||||||
|
mass*(1.0 - p.rhoc()/p.rho())
|
||||||
|
*(2.0*(p.U() ^ omega) + (omega ^ (r ^ omega)));
|
||||||
|
|
||||||
return value;
|
return value;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -144,11 +144,21 @@ void Foam::fieldAverage::initialize()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ensure first averaging works unconditionally
|
||||||
|
prevTimeIndex_ = -1;
|
||||||
|
|
||||||
|
initialised_ = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void Foam::fieldAverage::calcAverages()
|
void Foam::fieldAverage::calcAverages()
|
||||||
{
|
{
|
||||||
|
if (!initialised_)
|
||||||
|
{
|
||||||
|
initialize();
|
||||||
|
}
|
||||||
|
|
||||||
const label currentTimeIndex =
|
const label currentTimeIndex =
|
||||||
static_cast<const fvMesh&>(obr_).time().timeIndex();
|
static_cast<const fvMesh&>(obr_).time().timeIndex();
|
||||||
|
|
||||||
@ -374,16 +384,6 @@ void Foam::fieldAverage::execute()
|
|||||||
{
|
{
|
||||||
if (active_)
|
if (active_)
|
||||||
{
|
{
|
||||||
if (!initialised_)
|
|
||||||
{
|
|
||||||
initialize();
|
|
||||||
|
|
||||||
// ensure first averaging works unconditionally
|
|
||||||
prevTimeIndex_ = -1;
|
|
||||||
|
|
||||||
initialised_ = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
calcAverages();
|
calcAverages();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -397,16 +397,6 @@ void Foam::fieldAverage::write()
|
|||||||
{
|
{
|
||||||
if (active_)
|
if (active_)
|
||||||
{
|
{
|
||||||
if (!initialised_)
|
|
||||||
{
|
|
||||||
initialize();
|
|
||||||
|
|
||||||
// ensure first averaging works unconditionally
|
|
||||||
prevTimeIndex_ = -1;
|
|
||||||
|
|
||||||
initialised_ = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
calcAverages();
|
calcAverages();
|
||||||
writeAverages();
|
writeAverages();
|
||||||
writeAveragingProperties();
|
writeAveragingProperties();
|
||||||
|
|||||||
Reference in New Issue
Block a user