mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
viscosityModels: State virtual functions are virtual also in the derived classes
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-2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -95,32 +95,32 @@ public:
|
|||||||
|
|
||||||
|
|
||||||
//- Destructor
|
//- Destructor
|
||||||
~BirdCarreau()
|
virtual ~BirdCarreau()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
// Member Functions
|
// Member Functions
|
||||||
|
|
||||||
//- Return the laminar viscosity
|
//- Return the laminar viscosity
|
||||||
tmp<volScalarField> nu() const
|
virtual tmp<volScalarField> nu() const
|
||||||
{
|
{
|
||||||
return nu_;
|
return nu_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the laminar viscosity for patch
|
//- Return the laminar viscosity for patch
|
||||||
tmp<scalarField> nu(const label patchi) const
|
virtual tmp<scalarField> nu(const label patchi) const
|
||||||
{
|
{
|
||||||
return nu_.boundaryField()[patchi];
|
return nu_.boundaryField()[patchi];
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Correct the laminar viscosity
|
//- Correct the laminar viscosity
|
||||||
void correct()
|
virtual void correct()
|
||||||
{
|
{
|
||||||
nu_ = calcNu();
|
nu_ = calcNu();
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Read transportProperties dictionary
|
//- Read transportProperties dictionary
|
||||||
bool read(const dictionary& viscosityProperties);
|
virtual bool read(const dictionary& viscosityProperties);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -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-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -90,32 +90,32 @@ public:
|
|||||||
|
|
||||||
|
|
||||||
//- Destructor
|
//- Destructor
|
||||||
~CrossPowerLaw()
|
virtual ~CrossPowerLaw()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
// Member Functions
|
// Member Functions
|
||||||
|
|
||||||
//- Return the laminar viscosity
|
//- Return the laminar viscosity
|
||||||
tmp<volScalarField> nu() const
|
virtual tmp<volScalarField> nu() const
|
||||||
{
|
{
|
||||||
return nu_;
|
return nu_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the laminar viscosity for patch
|
//- Return the laminar viscosity for patch
|
||||||
tmp<scalarField> nu(const label patchi) const
|
virtual tmp<scalarField> nu(const label patchi) const
|
||||||
{
|
{
|
||||||
return nu_.boundaryField()[patchi];
|
return nu_.boundaryField()[patchi];
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Correct the laminar viscosity
|
//- Correct the laminar viscosity
|
||||||
void correct()
|
virtual void correct()
|
||||||
{
|
{
|
||||||
nu_ = calcNu();
|
nu_ = calcNu();
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Read transportProperties dictionary
|
//- Read transportProperties dictionary
|
||||||
bool read(const dictionary& viscosityProperties);
|
virtual bool read(const dictionary& viscosityProperties);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -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-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -91,32 +91,32 @@ public:
|
|||||||
|
|
||||||
|
|
||||||
//- Destructor
|
//- Destructor
|
||||||
~HerschelBulkley()
|
virtual ~HerschelBulkley()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
// Member Functions
|
// Member Functions
|
||||||
|
|
||||||
//- Return the laminar viscosity
|
//- Return the laminar viscosity
|
||||||
tmp<volScalarField> nu() const
|
virtual tmp<volScalarField> nu() const
|
||||||
{
|
{
|
||||||
return nu_;
|
return nu_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the laminar viscosity for patch
|
//- Return the laminar viscosity for patch
|
||||||
tmp<scalarField> nu(const label patchi) const
|
virtual tmp<scalarField> nu(const label patchi) const
|
||||||
{
|
{
|
||||||
return nu_.boundaryField()[patchi];
|
return nu_.boundaryField()[patchi];
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Correct the laminar viscosity
|
//- Correct the laminar viscosity
|
||||||
void correct()
|
virtual void correct()
|
||||||
{
|
{
|
||||||
nu_ = calcNu();
|
nu_ = calcNu();
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Read transportProperties dictionary
|
//- Read transportProperties dictionary
|
||||||
bool read(const dictionary& viscosityProperties);
|
virtual bool read(const dictionary& viscosityProperties);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -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-2015 OpenFOAM Foundation
|
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -80,30 +80,30 @@ public:
|
|||||||
|
|
||||||
|
|
||||||
//- Destructor
|
//- Destructor
|
||||||
~Newtonian()
|
virtual ~Newtonian()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
// Member Functions
|
// Member Functions
|
||||||
|
|
||||||
//- Return the laminar viscosity
|
//- Return the laminar viscosity
|
||||||
tmp<volScalarField> nu() const
|
virtual tmp<volScalarField> nu() const
|
||||||
{
|
{
|
||||||
return nu_;
|
return nu_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the laminar viscosity for patch
|
//- Return the laminar viscosity for patch
|
||||||
tmp<scalarField> nu(const label patchi) const
|
virtual tmp<scalarField> nu(const label patchi) const
|
||||||
{
|
{
|
||||||
return nu_.boundaryField()[patchi];
|
return nu_.boundaryField()[patchi];
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Correct the laminar viscosity (not appropriate, viscosity constant)
|
//- Correct the laminar viscosity (not appropriate, viscosity constant)
|
||||||
void correct()
|
virtual void correct()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
//- Read transportProperties dictionary
|
//- Read transportProperties dictionary
|
||||||
bool read(const dictionary& viscosityProperties);
|
virtual bool read(const dictionary& viscosityProperties);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -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-2016 OpenFOAM Foundation
|
||||||
\\/ M anipulation |
|
\\/ M anipulation |
|
||||||
-------------------------------------------------------------------------------
|
-------------------------------------------------------------------------------
|
||||||
License
|
License
|
||||||
@ -91,32 +91,32 @@ public:
|
|||||||
|
|
||||||
|
|
||||||
//- Destructor
|
//- Destructor
|
||||||
~powerLaw()
|
virtual ~powerLaw()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
|
||||||
// Member Functions
|
// Member Functions
|
||||||
|
|
||||||
//- Return the laminar viscosity
|
//- Return the laminar viscosity
|
||||||
tmp<volScalarField> nu() const
|
virtual tmp<volScalarField> nu() const
|
||||||
{
|
{
|
||||||
return nu_;
|
return nu_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the laminar viscosity for patch
|
//- Return the laminar viscosity for patch
|
||||||
tmp<scalarField> nu(const label patchi) const
|
virtual tmp<scalarField> nu(const label patchi) const
|
||||||
{
|
{
|
||||||
return nu_.boundaryField()[patchi];
|
return nu_.boundaryField()[patchi];
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Correct the laminar viscosity
|
//- Correct the laminar viscosity
|
||||||
void correct()
|
virtual void correct()
|
||||||
{
|
{
|
||||||
nu_ = calcNu();
|
nu_ = calcNu();
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Read transportProperties dictionary
|
//- Read transportProperties dictionary
|
||||||
bool read(const dictionary& viscosityProperties);
|
virtual bool read(const dictionary& viscosityProperties);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user