Minor updates

This commit is contained in:
henry 2008-05-01 16:45:02 +01:00
parent 5413edb32c
commit f13d2060dc
4 changed files with 28 additions and 12 deletions

View File

@ -50,6 +50,7 @@ SourceFiles
#include "Tuple2.H"
#include "OFstream.H"
#include "Switch.H"
#include "pointFieldFwd.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -59,6 +60,7 @@ namespace Foam
// Forward declaration of classes
class objectRegistry;
class dictionary;
class mapPolyMesh;
/*---------------------------------------------------------------------------*\
Class forces Declaration
@ -204,6 +206,14 @@ public:
//- Calculate and return forces and moment
virtual forcesMoments calcForcesMoment() const;
//- Update for changes of mesh
virtual void updateMesh(const mapPolyMesh&)
{}
//- Update for changes of mesh
virtual void movePoints(const pointField&)
{}
};

View File

@ -207,12 +207,12 @@ public:
inline scalar Kc(const scalar T) const;
//- Equilibrium constant [] i.t.o. mole-fractions
// For low pressures (where the gas mixture is near perfect)
// For low pressures (where the gas mixture is near perfect)
// Kx = Kp(pstd/p)^nui
inline scalar Kx(const scalar T, const scalar p) const;
//- Equilibrium constant [] i.t.o. number of moles
// For low pressures (where the gas mixture is near perfect)
// For low pressures (where the gas mixture is near perfect)
// Kn = Kp(n*pstd/p)^nui where n = number of moles in mixture
inline scalar Kn
(

View File

@ -119,7 +119,7 @@ tmp<volScalarField> twoPhaseMixture::mu() const
{
volScalarField limitedAlpha1 = min(max(alpha1_, scalar(0)), scalar(1));
return tmp<volScalarField>
return tmp<volScalarField>
(
new volScalarField
(
@ -136,7 +136,7 @@ tmp<surfaceScalarField> twoPhaseMixture::muf() const
surfaceScalarField alpha1f =
min(max(fvc::interpolate(alpha1_), scalar(0)), scalar(1));
return tmp<surfaceScalarField>
return tmp<surfaceScalarField>
(
new surfaceScalarField
(
@ -150,10 +150,10 @@ tmp<surfaceScalarField> twoPhaseMixture::muf() const
tmp<surfaceScalarField> twoPhaseMixture::nuf() const
{
surfaceScalarField alpha1f =
surfaceScalarField alpha1f =
min(max(fvc::interpolate(alpha1_), scalar(0)), scalar(1));
return tmp<surfaceScalarField>
return tmp<surfaceScalarField>
(
new surfaceScalarField
(
@ -171,7 +171,11 @@ bool twoPhaseMixture::read()
{
if (transportModel::read())
{
if (nuModel1_().read(*this) && nuModel2_().read(*this))
if
(
nuModel1_().read(subDict(phase1Name_))
&& nuModel2_().read(subDict(phase2Name_))
)
{
nuModel1_->viscosityProperties().lookup("rho") >> rho1_;
nuModel2_->viscosityProperties().lookup("rho") >> rho2_;

View File

@ -54,7 +54,9 @@ class twoPhaseMixture
:
public transportModel
{
// Private data
protected:
// Protected data
word phase1Name_;
word phase2Name_;
@ -141,7 +143,7 @@ public:
tmp<surfaceScalarField> muf() const;
//- Return the kinematic laminar viscosity
tmp<volScalarField> nu() const
virtual tmp<volScalarField> nu() const
{
return nu_;
}
@ -149,14 +151,14 @@ public:
//- Return the face-interpolated dynamic laminar viscosity
tmp<surfaceScalarField> nuf() const;
//- Correct the laminar viscosity
void correct()
//- Correct the laminar viscosity
virtual void correct()
{
calcNu();
}
//- Read base transportProperties dictionary
bool read();
virtual bool read();
};