mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge branch 'master' into splitCyclic
Conflicts: applications/utilities/parallelProcessing/decomposePar/domainDecomposition.C applications/utilities/parallelProcessing/decomposePar/domainDecomposition.H applications/utilities/parallelProcessing/decomposePar/domainDecompositionMesh.C src/OpenFOAM/algorithms/MeshWave/FaceCellWave.C src/OpenFOAM/matrices/lduMatrix/lduAddressing/lduInterfaceFields/cyclicLduInterfaceField/cyclicLduInterfaceField.C src/OpenFOAM/meshes/polyMesh/globalMeshData/globalMeshData.C src/OpenFOAM/meshes/polyMesh/globalMeshData/globalMeshData.H src/OpenFOAM/meshes/polyMesh/syncTools/dummyTransform.H src/OpenFOAM/meshes/polyMesh/syncTools/syncTools.C src/edgeMesh/edgeFormats/vtk/VTKedgeFormat.H src/mesh/blockMesh/curvedEdges/spline.H src/meshTools/PointEdgeWave/PointEdgeWave.C src/meshTools/sets/topoSets/faceSet.C
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@ -51,7 +51,9 @@ doc/[Dd]oxygen/latex
|
|||||||
doc/[Dd]oxygen/man
|
doc/[Dd]oxygen/man
|
||||||
|
|
||||||
# generated files in the main directory (e.g. ReleaseNotes-?.?.html)
|
# generated files in the main directory (e.g. ReleaseNotes-?.?.html)
|
||||||
|
# and in the doc directory
|
||||||
/*.html
|
/*.html
|
||||||
|
/doc/*.html
|
||||||
|
|
||||||
# source packages - anywhere
|
# source packages - anywhere
|
||||||
*.tar.bz2
|
*.tar.bz2
|
||||||
|
|||||||
11
README
11
README
@ -2,7 +2,7 @@
|
|||||||
#
|
#
|
||||||
#+TITLE: OpenFOAM README for version 1.6
|
#+TITLE: OpenFOAM README for version 1.6
|
||||||
#+AUTHOR: OpenCFD Ltd.
|
#+AUTHOR: OpenCFD Ltd.
|
||||||
#+DATE: July 2009
|
#+DATE: November 2009
|
||||||
#+LINK: http://www.opencfd.co.uk
|
#+LINK: http://www.opencfd.co.uk
|
||||||
#+OPTIONS: author:nil ^:{}
|
#+OPTIONS: author:nil ^:{}
|
||||||
|
|
||||||
@ -168,9 +168,9 @@
|
|||||||
+ rm -rf paraview-3.6.1/platforms
|
+ rm -rf paraview-3.6.1/platforms
|
||||||
+ ./makeParaView
|
+ ./makeParaView
|
||||||
|
|
||||||
The PV3FoamReader module is an OpenFOAM utility that can be compiled in the
|
The PV3blockMeshReader and the PV3FoamReader ParaView plugins are compiled
|
||||||
usual manner as follows:
|
as usual for OpenFOAM utilities:
|
||||||
+ cd $FOAM_UTILITIES/postProcessing/graphics/PV3FoamReader
|
+ cd $FOAM_UTILITIES/postProcessing/graphics/PV3Readers/
|
||||||
+ ./Allwclean
|
+ ./Allwclean
|
||||||
+ ./Allwmake
|
+ ./Allwmake
|
||||||
|
|
||||||
@ -187,7 +187,8 @@
|
|||||||
newly built qmake as an argument:
|
newly built qmake as an argument:
|
||||||
+ ./makeParaView -qmake <path_to_qmake>
|
+ ./makeParaView -qmake <path_to_qmake>
|
||||||
|
|
||||||
The user must then recompile the PV3FoamReader module as normal (see above).
|
The user must then recompile the PV3blockMeshReader and the
|
||||||
|
PV3FoamReader plugins as usual (see above).
|
||||||
|
|
||||||
* Documentation
|
* Documentation
|
||||||
http://www.OpenFOAM.org/doc
|
http://www.OpenFOAM.org/doc
|
||||||
|
|||||||
@ -38,11 +38,9 @@ Description
|
|||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
|
argList::addBoolOption("writep", "write the final pressure field");
|
||||||
argList::validOptions.insert("writep", "");
|
|
||||||
|
|
||||||
# include "setRootCase.H"
|
# include "setRootCase.H"
|
||||||
|
|
||||||
# include "createTime.H"
|
# include "createTime.H"
|
||||||
# include "createMesh.H"
|
# include "createMesh.H"
|
||||||
# include "createFields.H"
|
# include "createFields.H"
|
||||||
|
|||||||
@ -124,11 +124,6 @@ public:
|
|||||||
|
|
||||||
// Member Functions
|
// Member Functions
|
||||||
|
|
||||||
tmp<volScalarField> mut() const
|
|
||||||
{
|
|
||||||
return mut_;
|
|
||||||
}
|
|
||||||
|
|
||||||
//- Return the effective diffusivity for k
|
//- Return the effective diffusivity for k
|
||||||
tmp<volScalarField> DkEff() const
|
tmp<volScalarField> DkEff() const
|
||||||
{
|
{
|
||||||
@ -147,41 +142,44 @@ public:
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the effective turbulent thermal diffusivity
|
//- Return the turbulence viscosity
|
||||||
tmp<volScalarField> alphaEff() const
|
virtual tmp<volScalarField> mut() const
|
||||||
{
|
{
|
||||||
return tmp<volScalarField>
|
return mut_;
|
||||||
(
|
}
|
||||||
new volScalarField("alphaEff", alphat_ + alpha())
|
|
||||||
);
|
//- Return the turbulence thermal diffusivity
|
||||||
|
virtual tmp<volScalarField> alphat() const
|
||||||
|
{
|
||||||
|
return alphat_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the turbulence kinetic energy
|
//- Return the turbulence kinetic energy
|
||||||
tmp<volScalarField> k() const
|
virtual tmp<volScalarField> k() const
|
||||||
{
|
{
|
||||||
return k_;
|
return k_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the turbulence kinetic energy dissipation rate
|
//- Return the turbulence kinetic energy dissipation rate
|
||||||
tmp<volScalarField> epsilon() const
|
virtual tmp<volScalarField> epsilon() const
|
||||||
{
|
{
|
||||||
return epsilon_;
|
return epsilon_;
|
||||||
}
|
}
|
||||||
|
|
||||||
//- Return the Reynolds stress tensor
|
//- Return the Reynolds stress tensor
|
||||||
tmp<volSymmTensorField> R() const;
|
virtual tmp<volSymmTensorField> R() const;
|
||||||
|
|
||||||
//- Return the effective stress tensor including the laminar stress
|
//- Return the effective stress tensor including the laminar stress
|
||||||
tmp<volSymmTensorField> devRhoReff() const;
|
virtual tmp<volSymmTensorField> devRhoReff() const;
|
||||||
|
|
||||||
//- Return the source term for the momentum equation
|
//- Return the source term for the momentum equation
|
||||||
tmp<fvVectorMatrix> divDevRhoReff(volVectorField& U) const;
|
virtual tmp<fvVectorMatrix> divDevRhoReff(volVectorField& U) const;
|
||||||
|
|
||||||
//- Solve the turbulence equations and correct the turbulence viscosity
|
//- Solve the turbulence equations and correct the turbulence viscosity
|
||||||
void correct();
|
virtual void correct();
|
||||||
|
|
||||||
//- Read turbulenceProperties dictionary
|
//- Read turbulenceProperties dictionary
|
||||||
bool read();
|
virtual bool read();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -22,7 +22,7 @@
|
|||||||
volScalarField GEta = GEtaCoef/tauEta;
|
volScalarField GEta = GEtaCoef/tauEta;
|
||||||
volScalarField XiEqEta = 1.0 + XiCoef*sqrt(up/(Su + SuMin))*Reta;
|
volScalarField XiEqEta = 1.0 + XiCoef*sqrt(up/(Su + SuMin))*Reta;
|
||||||
|
|
||||||
volScalarField R =
|
volScalarField R =
|
||||||
GEta*XiEqEta/(XiEqEta - 0.999) + GIn*XiIn/(XiIn - 0.999);
|
GEta*XiEqEta/(XiEqEta - 0.999) + GIn*XiIn/(XiIn - 0.999);
|
||||||
|
|
||||||
volScalarField XiEqStar = R/(R - GEta - GIn);
|
volScalarField XiEqStar = R/(R - GEta - GIn);
|
||||||
@ -42,7 +42,7 @@
|
|||||||
volScalarField GEta = GEtaCoef/tauEta;
|
volScalarField GEta = GEtaCoef/tauEta;
|
||||||
volScalarField XiEqEta = 1.0 + XiCoef*sqrt(up/(Su + SuMin))*Reta;
|
volScalarField XiEqEta = 1.0 + XiCoef*sqrt(up/(Su + SuMin))*Reta;
|
||||||
|
|
||||||
volScalarField R =
|
volScalarField R =
|
||||||
GEta*XiEqEta/(XiEqEta - 0.999) + GIn*XiIn/(XiIn - 0.999);
|
GEta*XiEqEta/(XiEqEta - 0.999) + GIn*XiIn/(XiIn - 0.999);
|
||||||
|
|
||||||
volScalarField XiEqStar = R/(R - GEta - GIn);
|
volScalarField XiEqStar = R/(R - GEta - GIn);
|
||||||
|
|||||||
@ -91,7 +91,7 @@ bool Foam::XiModels::algebraic::read(const dictionary& XiProperties)
|
|||||||
XiModel::read(XiProperties);
|
XiModel::read(XiProperties);
|
||||||
|
|
||||||
XiModelCoeffs_.lookup("XiShapeCoef") >> XiShapeCoef;
|
XiModelCoeffs_.lookup("XiShapeCoef") >> XiShapeCoef;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -117,7 +117,7 @@ inline Foam::scalar Foam::laminarFlameSpeedModels::SCOPE::polyPhi
|
|||||||
{
|
{
|
||||||
scalar x = phi - 1.0;
|
scalar x = phi - 1.0;
|
||||||
|
|
||||||
return
|
return
|
||||||
a[0]
|
a[0]
|
||||||
*(
|
*(
|
||||||
scalar(1)
|
scalar(1)
|
||||||
|
|||||||
@ -45,7 +45,7 @@ if (adjustTimeStep)
|
|||||||
maxDeltaT
|
maxDeltaT
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
Info<< "deltaT = " << runTime.deltaTValue() << endl;
|
Info<< "deltaT = " << runTime.deltaTValue() << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -88,7 +88,7 @@ volScalarField DpDt =
|
|||||||
|
|
||||||
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
||||||
|
|
||||||
forAll (Y, i)
|
forAll(Y, i)
|
||||||
{
|
{
|
||||||
fields.add(Y[i]);
|
fields.add(Y[i]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -64,7 +64,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.run())
|
while (runTime.run())
|
||||||
{
|
{
|
||||||
@ -85,7 +85,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
dieselSpray.evolve();
|
dieselSpray.evolve();
|
||||||
|
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -61,7 +61,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.run())
|
while (runTime.run())
|
||||||
{
|
{
|
||||||
@ -72,11 +72,11 @@ int main(int argc, char *argv[])
|
|||||||
runTime++;
|
runTime++;
|
||||||
Info<< "Time = " << runTime.timeName() << nl << endl;
|
Info<< "Time = " << runTime.timeName() << nl << endl;
|
||||||
|
|
||||||
Info << "Evolving Spray" << endl;
|
Info<< "Evolving Spray" << endl;
|
||||||
|
|
||||||
dieselSpray.evolve();
|
dieselSpray.evolve();
|
||||||
|
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -78,7 +78,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.run())
|
while (runTime.run())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -77,7 +77,7 @@ volScalarField DpDt =
|
|||||||
|
|
||||||
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
||||||
|
|
||||||
forAll (Y, i)
|
forAll(Y, i)
|
||||||
{
|
{
|
||||||
fields.add(Y[i]);
|
fields.add(Y[i]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -54,7 +54,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.run())
|
while (runTime.run())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -77,7 +77,7 @@ volScalarField DpDt =
|
|||||||
|
|
||||||
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
||||||
|
|
||||||
forAll (Y, i)
|
forAll(Y, i)
|
||||||
{
|
{
|
||||||
fields.add(Y[i]);
|
fields.add(Y[i]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -55,7 +55,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.run())
|
while (runTime.run())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
wmake libso BCs
|
wmake libso BCs
|
||||||
wmake
|
wmake
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -6,5 +6,5 @@ EXE_INC = \
|
|||||||
EXE_LIBS = \
|
EXE_LIBS = \
|
||||||
-lfiniteVolume \
|
-lfiniteVolume \
|
||||||
-lbasicThermophysicalModels \
|
-lbasicThermophysicalModels \
|
||||||
-lspecie
|
-lspecie
|
||||||
|
|
||||||
|
|||||||
@ -22,8 +22,6 @@ License
|
|||||||
along with OpenFOAM; if not, write to the Free Software Foundation,
|
along with OpenFOAM; if not, write to the Free Software Foundation,
|
||||||
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||||
|
|
||||||
Description
|
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#include "maxwellSlipUFvPatchVectorField.H"
|
#include "maxwellSlipUFvPatchVectorField.H"
|
||||||
@ -155,7 +153,7 @@ void maxwellSlipUFvPatchVectorField::updateCoeffs()
|
|||||||
|
|
||||||
refValue() = Uwall_;
|
refValue() = Uwall_;
|
||||||
|
|
||||||
if(thermalCreep_)
|
if (thermalCreep_)
|
||||||
{
|
{
|
||||||
const volScalarField& vsfT =
|
const volScalarField& vsfT =
|
||||||
this->db().objectRegistry::lookupObject<volScalarField>("T");
|
this->db().objectRegistry::lookupObject<volScalarField>("T");
|
||||||
@ -167,7 +165,7 @@ void maxwellSlipUFvPatchVectorField::updateCoeffs()
|
|||||||
refValue() -= 3.0*pnu/(4.0*pT)*transform(I - n*n, gradpT);
|
refValue() -= 3.0*pnu/(4.0*pT)*transform(I - n*n, gradpT);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(curvature_)
|
if (curvature_)
|
||||||
{
|
{
|
||||||
const fvPatchTensorField& ptauMC =
|
const fvPatchTensorField& ptauMC =
|
||||||
patch().lookupPatchField<volTensorField, tensor>("tauMC");
|
patch().lookupPatchField<volTensorField, tensor>("tauMC");
|
||||||
|
|||||||
@ -22,8 +22,6 @@ License
|
|||||||
along with OpenFOAM; if not, write to the Free Software Foundation,
|
along with OpenFOAM; if not, write to the Free Software Foundation,
|
||||||
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
|
|
||||||
Description
|
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#include "mixedFixedValueSlipFvPatchFields.H"
|
#include "mixedFixedValueSlipFvPatchFields.H"
|
||||||
|
|||||||
@ -84,7 +84,7 @@ int main(int argc, char *argv[])
|
|||||||
(
|
(
|
||||||
fvm::ddt(rhoU)
|
fvm::ddt(rhoU)
|
||||||
+ fvm::div(phiv, rhoU)
|
+ fvm::div(phiv, rhoU)
|
||||||
==
|
==
|
||||||
- fvc::grad(p)
|
- fvc::grad(p)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
wmake libso BCs
|
wmake libso BCs
|
||||||
wmake
|
wmake
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -131,7 +131,7 @@ void inviscidWallPFvPatchScalarField::updateCoeffs()
|
|||||||
const fvPatchField<vector>& rhoUp =
|
const fvPatchField<vector>& rhoUp =
|
||||||
patch().lookupPatchField<volVectorField, vector>("rhoU");
|
patch().lookupPatchField<volVectorField, vector>("rhoU");
|
||||||
|
|
||||||
const fvsPatchField<scalar>& phip =
|
const fvsPatchField<scalar>& phip =
|
||||||
patch().lookupPatchField<surfaceScalarField, scalar>("phi");
|
patch().lookupPatchField<surfaceScalarField, scalar>("phi");
|
||||||
|
|
||||||
const fvsPatchField<scalar>& rAp =
|
const fvsPatchField<scalar>& rAp =
|
||||||
@ -147,7 +147,7 @@ void inviscidWallPFvPatchScalarField::updateCoeffs()
|
|||||||
void inviscidWallPFvPatchScalarField::write(Ostream& os) const
|
void inviscidWallPFvPatchScalarField::write(Ostream& os) const
|
||||||
{
|
{
|
||||||
fixedGradientFvPatchScalarField::write(os);
|
fixedGradientFvPatchScalarField::write(os);
|
||||||
os.writeKeyword("fluxFraction")
|
os.writeKeyword("fluxFraction")
|
||||||
<< fluxFraction_ << token::END_STATEMENT << nl;
|
<< fluxFraction_ << token::END_STATEMENT << nl;
|
||||||
writeEntry("value", os);
|
writeEntry("value", os);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -145,7 +145,7 @@ void mixedRhoEFvPatchScalarField::updateCoeffs()
|
|||||||
|
|
||||||
const volScalarField& T = db().lookupObject<volScalarField>("T");
|
const volScalarField& T = db().lookupObject<volScalarField>("T");
|
||||||
const label patchi = patch().index();
|
const label patchi = patch().index();
|
||||||
fvPatchScalarField& Tp =
|
fvPatchScalarField& Tp =
|
||||||
const_cast<fvPatchScalarField&>(T.boundaryField()[patchi]);
|
const_cast<fvPatchScalarField&>(T.boundaryField()[patchi]);
|
||||||
|
|
||||||
Tp.evaluate();
|
Tp.evaluate();
|
||||||
@ -164,7 +164,7 @@ void mixedRhoEFvPatchScalarField::updateCoeffs()
|
|||||||
refGrad() =
|
refGrad() =
|
||||||
rhop*Cv.value()*Tp.snGrad()
|
rhop*Cv.value()*Tp.snGrad()
|
||||||
+ (
|
+ (
|
||||||
refValue()
|
refValue()
|
||||||
- (0.5*rhop.patchInternalField()*
|
- (0.5*rhop.patchInternalField()*
|
||||||
magSqr(rhoUp.patchInternalField()/rhop.patchInternalField()))
|
magSqr(rhoUp.patchInternalField()/rhop.patchInternalField()))
|
||||||
)*patch().deltaCoeffs();
|
)*patch().deltaCoeffs();
|
||||||
|
|||||||
@ -66,7 +66,7 @@ public:
|
|||||||
const dictionary&
|
const dictionary&
|
||||||
);
|
);
|
||||||
|
|
||||||
//- Construct by mapping given fixedRhoUFvPatchVectorField
|
//- Construct by mapping given fixedRhoUFvPatchVectorField
|
||||||
// onto a new patch
|
// onto a new patch
|
||||||
fixedRhoUFvPatchVectorField
|
fixedRhoUFvPatchVectorField
|
||||||
(
|
(
|
||||||
|
|||||||
@ -50,14 +50,14 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
label nAveragingSteps = 0;
|
label nAveragingSteps = 0;
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.loop())
|
while (runTime.loop())
|
||||||
{
|
{
|
||||||
|
|
||||||
nAveragingSteps++;
|
nAveragingSteps++;
|
||||||
|
|
||||||
Info << "Time = " << runTime.timeName() << endl;
|
Info<< "Time = " << runTime.timeName() << endl;
|
||||||
|
|
||||||
molecules.evolve();
|
molecules.evolve();
|
||||||
|
|
||||||
@ -74,12 +74,12 @@ int main(int argc, char *argv[])
|
|||||||
nAveragingSteps = 0;
|
nAveragingSteps = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
||||||
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
||||||
<< nl << endl;
|
<< nl << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -48,14 +48,14 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
label nAveragingSteps = 0;
|
label nAveragingSteps = 0;
|
||||||
|
|
||||||
Info << "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
while (runTime.loop())
|
while (runTime.loop())
|
||||||
{
|
{
|
||||||
|
|
||||||
nAveragingSteps++;
|
nAveragingSteps++;
|
||||||
|
|
||||||
Info << "Time = " << runTime.timeName() << endl;
|
Info<< "Time = " << runTime.timeName() << endl;
|
||||||
|
|
||||||
molecules.evolve();
|
molecules.evolve();
|
||||||
|
|
||||||
@ -70,12 +70,12 @@ int main(int argc, char *argv[])
|
|||||||
nAveragingSteps = 0;
|
nAveragingSteps = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
||||||
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
||||||
<< nl << endl;
|
<< nl << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
electrostaticFoam.C
|
electrostaticFoam.C
|
||||||
|
|
||||||
EXE = $(FOAM_APPBIN)/electrostaticFoam
|
EXE = $(FOAM_APPBIN)/electrostaticFoam
|
||||||
|
|||||||
@ -117,7 +117,7 @@ int main(int argc, char *argv[])
|
|||||||
<< nl << endl;
|
<< nl << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -11,7 +11,7 @@
|
|||||||
runTime.path()/runTime.timeName()/"uniform"/"gradP.raw"
|
runTime.path()/runTime.timeName()/"uniform"/"gradP.raw"
|
||||||
);
|
);
|
||||||
|
|
||||||
if(gradPFile.good())
|
if (gradPFile.good())
|
||||||
{
|
{
|
||||||
gradPFile >> gradP;
|
gradPFile >> gradP;
|
||||||
Info<< "Reading average pressure gradient" <<endl
|
Info<< "Reading average pressure gradient" <<endl
|
||||||
|
|||||||
@ -5,7 +5,7 @@
|
|||||||
runTime.path()/runTime.timeName()/"uniform"/"gradP.raw"
|
runTime.path()/runTime.timeName()/"uniform"/"gradP.raw"
|
||||||
);
|
);
|
||||||
|
|
||||||
if(gradPFile.good())
|
if (gradPFile.good())
|
||||||
{
|
{
|
||||||
gradPFile << gradP << endl;
|
gradPFile << gradP << endl;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
icoFoam.C
|
icoFoam.C
|
||||||
|
|
||||||
EXE = $(FOAM_APPBIN)/icoFoam
|
EXE = $(FOAM_APPBIN)/icoFoam
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
nonNewtonianIcoFoam.C
|
nonNewtonianIcoFoam.C
|
||||||
|
|
||||||
EXE = $(FOAM_APPBIN)/nonNewtonianIcoFoam
|
EXE = $(FOAM_APPBIN)/nonNewtonianIcoFoam
|
||||||
|
|||||||
@ -29,7 +29,7 @@
|
|||||||
|
|
||||||
for (label i=0; i<p.boundaryField().size(); i++)
|
for (label i=0; i<p.boundaryField().size(); i++)
|
||||||
{
|
{
|
||||||
if(p.boundaryField()[i].fixesValue())
|
if (p.boundaryField()[i].fixesValue())
|
||||||
{
|
{
|
||||||
pcorrTypes[i] = fixedValueFvPatchScalarField::typeName;
|
pcorrTypes[i] = fixedValueFvPatchScalarField::typeName;
|
||||||
}
|
}
|
||||||
@ -50,7 +50,7 @@
|
|||||||
pcorrTypes
|
pcorrTypes
|
||||||
);
|
);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pcorrEqn
|
fvScalarMatrix pcorrEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
Info << "Reading field p\n" << endl;
|
Info<< "Reading field p\n" << endl;
|
||||||
volScalarField p
|
volScalarField p
|
||||||
(
|
(
|
||||||
IOobject
|
IOobject
|
||||||
@ -12,7 +12,7 @@
|
|||||||
mesh
|
mesh
|
||||||
);
|
);
|
||||||
|
|
||||||
Info << "Reading field U\n" << endl;
|
Info<< "Reading field U\n" << endl;
|
||||||
volVectorField U
|
volVectorField U
|
||||||
(
|
(
|
||||||
IOobject
|
IOobject
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
simpleFoam.C
|
simpleFoam.C
|
||||||
|
|
||||||
EXE = $(FOAM_APPBIN)/simpleFoam
|
EXE = $(FOAM_APPBIN)/simpleFoam
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
Info << "Reading field p\n" << endl;
|
Info<< "Reading field p\n" << endl;
|
||||||
volScalarField p
|
volScalarField p
|
||||||
(
|
(
|
||||||
IOobject
|
IOobject
|
||||||
@ -12,7 +12,7 @@
|
|||||||
mesh
|
mesh
|
||||||
);
|
);
|
||||||
|
|
||||||
Info << "Reading field U\n" << endl;
|
Info<< "Reading field U\n" << endl;
|
||||||
volVectorField U
|
volVectorField U
|
||||||
(
|
(
|
||||||
IOobject
|
IOobject
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -28,7 +28,7 @@
|
|||||||
|
|
||||||
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
||||||
|
|
||||||
forAll (Y, i)
|
forAll(Y, i)
|
||||||
{
|
{
|
||||||
fields.add(Y[i]);
|
fields.add(Y[i]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -84,7 +84,7 @@
|
|||||||
Info<< "Creating multi-variate interpolation scheme\n" << endl;
|
Info<< "Creating multi-variate interpolation scheme\n" << endl;
|
||||||
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
||||||
|
|
||||||
forAll (Y, i)
|
forAll(Y, i)
|
||||||
{
|
{
|
||||||
fields.add(Y[i]);
|
fields.add(Y[i]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
Info << "Solving chemistry" << endl;
|
Info<< "Solving chemistry" << endl;
|
||||||
|
|
||||||
chemistry.solve
|
chemistry.solve
|
||||||
(
|
(
|
||||||
|
|||||||
@ -90,7 +90,7 @@
|
|||||||
|
|
||||||
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
multivariateSurfaceInterpolationScheme<scalar>::fieldTable fields;
|
||||||
|
|
||||||
forAll (Y, i)
|
forAll(Y, i)
|
||||||
{
|
{
|
||||||
fields.add(Y[i]);
|
fields.add(Y[i]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -47,8 +47,10 @@
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
word kinematicCloudName("kinematicCloud");
|
const word kinematicCloudName
|
||||||
args.optionReadIfPresent("cloudName", kinematicCloudName);
|
(
|
||||||
|
args.optionLookupOrDefault<word>("cloudName", "kinematicCloud")
|
||||||
|
);
|
||||||
|
|
||||||
Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
|
Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
|
||||||
basicKinematicCloud kinematicCloud
|
basicKinematicCloud kinematicCloud
|
||||||
|
|||||||
@ -42,7 +42,7 @@ Description
|
|||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
argList::validOptions.insert("cloudName", "cloud name");
|
argList::addOption("cloudName", "cloud name");
|
||||||
|
|
||||||
#include "setRootCase.H"
|
#include "setRootCase.H"
|
||||||
#include "createTime.H"
|
#include "createTime.H"
|
||||||
|
|||||||
@ -41,7 +41,7 @@ fvVectorMatrix UbEqn(Ub, Ub.dimensions()*dimVol/dimTime);
|
|||||||
- fvc::interpolate(nuEffb)
|
- fvc::interpolate(nuEffb)
|
||||||
*mesh.magSf()*fvc::snGrad(beta)/fvc::interpolate(beta + scalar(0.001));
|
*mesh.magSf()*fvc::snGrad(beta)/fvc::interpolate(beta + scalar(0.001));
|
||||||
|
|
||||||
UbEqn =
|
UbEqn =
|
||||||
(
|
(
|
||||||
(scalar(1) + Cvm*rhob*alpha/rhob)*
|
(scalar(1) + Cvm*rhob*alpha/rhob)*
|
||||||
(
|
(
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
if(turbulence)
|
if (turbulence)
|
||||||
{
|
{
|
||||||
if (mesh.changing())
|
if (mesh.changing())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
surfaceScalarField Dp("(rho*(1|A(U)))", alphaf*rUaAf/rhoa + betaf*rUbAf/rhob);
|
surfaceScalarField Dp("(rho*(1|A(U)))", alphaf*rUaAf/rhoa + betaf*rUbAf/rhob);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -36,7 +36,7 @@ scalar acousticCoNum = 0.0;
|
|||||||
|
|
||||||
if (mesh.nInternalFaces())
|
if (mesh.nInternalFaces())
|
||||||
{
|
{
|
||||||
surfaceScalarField SfUfbyDelta =
|
surfaceScalarField SfUfbyDelta =
|
||||||
mesh.surfaceInterpolation::deltaCoeffs()*mag(phiv);
|
mesh.surfaceInterpolation::deltaCoeffs()*mag(phiv);
|
||||||
|
|
||||||
CoNum = max(SfUfbyDelta/mesh.magSf())
|
CoNum = max(SfUfbyDelta/mesh.magSf())
|
||||||
|
|||||||
@ -3,12 +3,12 @@
|
|||||||
|
|
||||||
dimensionedScalar totalMass = fvc::domainIntegrate(rho);
|
dimensionedScalar totalMass = fvc::domainIntegrate(rho);
|
||||||
|
|
||||||
scalar sumLocalContErr =
|
scalar sumLocalContErr =
|
||||||
(
|
(
|
||||||
fvc::domainIntegrate(mag(rho - thermoRho))/totalMass
|
fvc::domainIntegrate(mag(rho - thermoRho))/totalMass
|
||||||
).value();
|
).value();
|
||||||
|
|
||||||
scalar globalContErr =
|
scalar globalContErr =
|
||||||
(
|
(
|
||||||
fvc::domainIntegrate(rho - thermoRho)/totalMass
|
fvc::domainIntegrate(rho - thermoRho)/totalMass
|
||||||
).value();
|
).value();
|
||||||
|
|||||||
@ -47,7 +47,7 @@ if (adjustTimeStep)
|
|||||||
maxDeltaT
|
maxDeltaT
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
Info<< "deltaT = " << runTime.deltaTValue() << endl;
|
Info<< "deltaT = " << runTime.deltaTValue() << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -42,7 +42,7 @@
|
|||||||
|
|
||||||
adjustPhi(phi, U, pcorr);
|
adjustPhi(phi, U, pcorr);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pcorrEqn
|
fvScalarMatrix pcorrEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -30,7 +30,7 @@
|
|||||||
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
||||||
)*rUAf;
|
)*rUAf;
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqnIncomp
|
fvScalarMatrix pEqnIncomp
|
||||||
(
|
(
|
||||||
|
|||||||
@ -42,7 +42,7 @@
|
|||||||
|
|
||||||
adjustPhi(phi, U, pcorr);
|
adjustPhi(phi, U, pcorr);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pcorrEqn
|
fvScalarMatrix pcorrEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -18,7 +18,7 @@
|
|||||||
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
||||||
)*rAUf;
|
)*rAUf;
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
adjustPhi(phi, U, pcorr);
|
adjustPhi(phi, U, pcorr);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pcorrEqn
|
fvScalarMatrix pcorrEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -19,7 +19,7 @@
|
|||||||
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
||||||
)*rUAf;
|
)*rUAf;
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
adjustPhi(phi, U, pcorr);
|
adjustPhi(phi, U, pcorr);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pcorrEqn
|
fvScalarMatrix pcorrEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -23,7 +23,7 @@
|
|||||||
const volScalarField& vDotcP = vDotP[0]();
|
const volScalarField& vDotcP = vDotP[0]();
|
||||||
const volScalarField& vDotvP = vDotP[1]();
|
const volScalarField& vDotvP = vDotP[1]();
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -63,7 +63,7 @@ Ostream& operator<<
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
os << tp.theta0_ << token::SPACE
|
os << tp.theta0_ << token::SPACE
|
||||||
<< tp.uTheta_ << token::SPACE
|
<< tp.uTheta_ << token::SPACE
|
||||||
<< tp.thetaA_ << token::SPACE
|
<< tp.thetaA_ << token::SPACE
|
||||||
<< tp.thetaR_;
|
<< tp.thetaR_;
|
||||||
|
|
||||||
|
|||||||
@ -125,7 +125,7 @@ Foam::tmp<Foam::volScalarField> Foam::multiphaseMixture::rho() const
|
|||||||
|
|
||||||
tmp<volScalarField> trho = iter()*iter().rho();
|
tmp<volScalarField> trho = iter()*iter().rho();
|
||||||
|
|
||||||
for(++iter; iter != phases_.end(); ++iter)
|
for (++iter; iter != phases_.end(); ++iter)
|
||||||
{
|
{
|
||||||
trho() += iter()*iter().rho();
|
trho() += iter()*iter().rho();
|
||||||
}
|
}
|
||||||
@ -140,7 +140,7 @@ Foam::tmp<Foam::volScalarField> Foam::multiphaseMixture::mu() const
|
|||||||
|
|
||||||
tmp<volScalarField> tmu = iter()*iter().rho()*iter().nu();
|
tmp<volScalarField> tmu = iter()*iter().rho()*iter().nu();
|
||||||
|
|
||||||
for(++iter; iter != phases_.end(); ++iter)
|
for (++iter; iter != phases_.end(); ++iter)
|
||||||
{
|
{
|
||||||
tmu() += iter()*iter().rho()*iter().nu();
|
tmu() += iter()*iter().rho()*iter().nu();
|
||||||
}
|
}
|
||||||
@ -156,7 +156,7 @@ Foam::tmp<Foam::surfaceScalarField> Foam::multiphaseMixture::muf() const
|
|||||||
tmp<surfaceScalarField> tmuf =
|
tmp<surfaceScalarField> tmuf =
|
||||||
fvc::interpolate(iter())*iter().rho()*fvc::interpolate(iter().nu());
|
fvc::interpolate(iter())*iter().rho()*fvc::interpolate(iter().nu());
|
||||||
|
|
||||||
for(++iter; iter != phases_.end(); ++iter)
|
for (++iter; iter != phases_.end(); ++iter)
|
||||||
{
|
{
|
||||||
tmuf() +=
|
tmuf() +=
|
||||||
fvc::interpolate(iter())*iter().rho()*fvc::interpolate(iter().nu());
|
fvc::interpolate(iter())*iter().rho()*fvc::interpolate(iter().nu());
|
||||||
@ -210,7 +210,7 @@ Foam::multiphaseMixture::surfaceTensionForce() const
|
|||||||
PtrDictionary<phase>::const_iterator iter2 = iter1;
|
PtrDictionary<phase>::const_iterator iter2 = iter1;
|
||||||
++iter2;
|
++iter2;
|
||||||
|
|
||||||
for(; iter2 != phases_.end(); ++iter2)
|
for (; iter2 != phases_.end(); ++iter2)
|
||||||
{
|
{
|
||||||
const phase& alpha2 = iter2();
|
const phase& alpha2 = iter2();
|
||||||
|
|
||||||
@ -489,7 +489,7 @@ void Foam::multiphaseMixture::solveAlphas
|
|||||||
if (cycleAlpha)
|
if (cycleAlpha)
|
||||||
{
|
{
|
||||||
PtrDictionary<phase>::iterator refPhaseIter = phases_.begin();
|
PtrDictionary<phase>::iterator refPhaseIter = phases_.begin();
|
||||||
for(label i=0; i<nSolves%phases_.size(); i++)
|
for (label i=0; i<nSolves%phases_.size(); i++)
|
||||||
{
|
{
|
||||||
++refPhaseIter;
|
++refPhaseIter;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -28,7 +28,7 @@ License
|
|||||||
|
|
||||||
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Foam::phase::phase
|
Foam::phase::phase
|
||||||
(
|
(
|
||||||
const word& name,
|
const word& name,
|
||||||
const dictionary& phaseDict,
|
const dictionary& phaseDict,
|
||||||
|
|||||||
@ -18,7 +18,7 @@
|
|||||||
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
+ fvc::interpolate(rho)*(g & mesh.Sf())
|
||||||
)*rUAf;
|
)*rUAf;
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
mul = muc +
|
mul = muc +
|
||||||
plasticViscosity
|
plasticViscosity
|
||||||
(
|
(
|
||||||
plasticViscosityCoeff,
|
plasticViscosityCoeff,
|
||||||
|
|||||||
@ -17,7 +17,7 @@ phi =
|
|||||||
surfaceScalarField phiU("phiU", phi);
|
surfaceScalarField phiU("phiU", phi);
|
||||||
phi += fvc::interpolate(rho)*(g & mesh.Sf())*rUAf;
|
phi += fvc::interpolate(rho)*(g & mesh.Sf())*rUAf;
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
phi = phiU + fvc::interpolate(rho)*(g & mesh.Sf())*rUAf;
|
phi = phiU + fvc::interpolate(rho)*(g & mesh.Sf())*rUAf;
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -56,7 +56,7 @@ fvVectorMatrix UbEqn(Ub, Ub.dimensions()*dimVol/dimTime);
|
|||||||
-fvc::interpolate(nuEffb)*mesh.magSf()*fvc::snGrad(beta)
|
-fvc::interpolate(nuEffb)*mesh.magSf()*fvc::snGrad(beta)
|
||||||
/fvc::interpolate(beta + scalar(0.001));
|
/fvc::interpolate(beta + scalar(0.001));
|
||||||
|
|
||||||
UbEqn =
|
UbEqn =
|
||||||
(
|
(
|
||||||
(scalar(1) + Cvm*rhob*alpha/rhob)*
|
(scalar(1) + Cvm*rhob*alpha/rhob)*
|
||||||
(
|
(
|
||||||
|
|||||||
@ -190,7 +190,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Info << "dragPhase is " << dragPhase << endl;
|
Info<< "dragPhase is " << dragPhase << endl;
|
||||||
kineticTheoryModel kineticTheory
|
kineticTheoryModel kineticTheory
|
||||||
(
|
(
|
||||||
phasea,
|
phasea,
|
||||||
|
|||||||
@ -78,18 +78,18 @@ Foam::tmp<Foam::volScalarField> Foam::GidaspowErgunWenYu::K
|
|||||||
|
|
||||||
forAll(Re, celli)
|
forAll(Re, celli)
|
||||||
{
|
{
|
||||||
if(Re[celli] > 1000.0)
|
if (Re[celli] > 1000.0)
|
||||||
{
|
{
|
||||||
Cds[celli] = 0.44;
|
Cds[celli] = 0.44;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Wen and Yu (1966)
|
// Wen and Yu (1966)
|
||||||
tmp<volScalarField> tKWenYu = 0.75*Cds*phaseb_.rho()*Ur*bp/phasea_.d();
|
tmp<volScalarField> tKWenYu = 0.75*Cds*phaseb_.rho()*Ur*bp/phasea_.d();
|
||||||
volScalarField& KWenYu = tKWenYu();
|
volScalarField& KWenYu = tKWenYu();
|
||||||
|
|
||||||
// Ergun
|
// Ergun
|
||||||
forAll (beta, cellj)
|
forAll(beta, cellj)
|
||||||
{
|
{
|
||||||
if (beta[cellj] <= 0.8)
|
if (beta[cellj] <= 0.8)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -77,7 +77,7 @@ Foam::tmp<Foam::volScalarField> Foam::GidaspowSchillerNaumann::K
|
|||||||
|
|
||||||
forAll(Re, celli)
|
forAll(Re, celli)
|
||||||
{
|
{
|
||||||
if(Re[celli] > 1000.0)
|
if (Re[celli] > 1000.0)
|
||||||
{
|
{
|
||||||
Cds[celli] = 0.44;
|
Cds[celli] = 0.44;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -74,7 +74,7 @@ Foam::tmp<Foam::volScalarField> Foam::SchillerNaumann::K
|
|||||||
|
|
||||||
forAll(Re, celli)
|
forAll(Re, celli)
|
||||||
{
|
{
|
||||||
if(Re[celli] > 1000.0)
|
if (Re[celli] > 1000.0)
|
||||||
{
|
{
|
||||||
Cds[celli] = 0.44;
|
Cds[celli] = 0.44;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -73,7 +73,7 @@ Foam::tmp<Foam::volScalarField> Foam::SyamlalOBrien::K
|
|||||||
volScalarField A = pow(beta, 4.14);
|
volScalarField A = pow(beta, 4.14);
|
||||||
volScalarField B = 0.8*pow(beta, 1.28);
|
volScalarField B = 0.8*pow(beta, 1.28);
|
||||||
|
|
||||||
forAll (beta, celli)
|
forAll(beta, celli)
|
||||||
{
|
{
|
||||||
if (beta[celli] > 0.85)
|
if (beta[celli] > 0.85)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -77,7 +77,7 @@ Foam::tmp<Foam::volScalarField> Foam::WenYu::K
|
|||||||
|
|
||||||
forAll(Re, celli)
|
forAll(Re, celli)
|
||||||
{
|
{
|
||||||
if(Re[celli] > 1000.0)
|
if (Re[celli] > 1000.0)
|
||||||
{
|
{
|
||||||
Cds[celli] = 0.44;
|
Cds[celli] = 0.44;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -41,7 +41,7 @@ Foam::autoPtr<Foam::dragModel> Foam::dragModel::New
|
|||||||
interfaceDict.lookup("dragModel" + phasea.name())
|
interfaceDict.lookup("dragModel" + phasea.name())
|
||||||
);
|
);
|
||||||
|
|
||||||
Info << "Selecting dragModel for phase "
|
Info<< "Selecting dragModel for phase "
|
||||||
<< phasea.name()
|
<< phasea.name()
|
||||||
<< ": "
|
<< ": "
|
||||||
<< dragModelType << endl;
|
<< dragModelType << endl;
|
||||||
@ -57,7 +57,7 @@ Foam::autoPtr<Foam::dragModel> Foam::dragModel::New
|
|||||||
<< dragModelType
|
<< dragModelType
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< ", constructor not in hash table" << endl << endl
|
||||||
<< " Valid dragModel types are : " << endl;
|
<< " Valid dragModel types are : " << endl;
|
||||||
Info << dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return cstrIter()(interfaceDict, alpha, phasea, phaseb);
|
return cstrIter()(interfaceDict, alpha, phasea, phaseb);
|
||||||
|
|||||||
@ -35,9 +35,9 @@ Foam::autoPtr<Foam::conductivityModel> Foam::conductivityModel::New
|
|||||||
{
|
{
|
||||||
word conductivityModelType(dict.lookup("conductivityModel"));
|
word conductivityModelType(dict.lookup("conductivityModel"));
|
||||||
|
|
||||||
Info<< "Selecting conductivityModel "
|
Info<< "Selecting conductivityModel "
|
||||||
<< conductivityModelType << endl;
|
<< conductivityModelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(conductivityModelType);
|
dictionaryConstructorTablePtr_->find(conductivityModelType);
|
||||||
|
|
||||||
|
|||||||
@ -73,7 +73,7 @@ frictionalPressure
|
|||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
|
|
||||||
return
|
return
|
||||||
Fr*pow(max(alpha - alphaMinFriction, scalar(0)), eta)
|
Fr*pow(max(alpha - alphaMinFriction, scalar(0)), eta)
|
||||||
/pow(max(alphaMax - alpha, scalar(5.0e-2)), p);
|
/pow(max(alphaMax - alpha, scalar(5.0e-2)), p);
|
||||||
}
|
}
|
||||||
@ -104,9 +104,9 @@ Foam::tmp<Foam::volScalarField> Foam::JohnsonJacksonFrictionalStress::muf
|
|||||||
const dimensionedScalar& alphaMax,
|
const dimensionedScalar& alphaMax,
|
||||||
const volScalarField& pf,
|
const volScalarField& pf,
|
||||||
const volTensorField& D,
|
const volTensorField& D,
|
||||||
const dimensionedScalar& phi
|
const dimensionedScalar& phi
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
return dimensionedScalar("0.5", dimTime, 0.5)*pf*sin(phi);
|
return dimensionedScalar("0.5", dimTime, 0.5)*pf*sin(phi);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -125,7 +125,7 @@ Foam::tmp<Foam::volScalarField> Foam::SchaefferFrictionalStress::muf
|
|||||||
|
|
||||||
volScalarField& muff = tmuf();
|
volScalarField& muff = tmuf();
|
||||||
|
|
||||||
forAll (D, celli)
|
forAll(D, celli)
|
||||||
{
|
{
|
||||||
if (alpha[celli] > alphaMax.value()-5e-2)
|
if (alpha[celli] > alphaMax.value()-5e-2)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -35,9 +35,9 @@ Foam::autoPtr<Foam::frictionalStressModel> Foam::frictionalStressModel::New
|
|||||||
{
|
{
|
||||||
word frictionalStressModelType(dict.lookup("frictionalStressModel"));
|
word frictionalStressModelType(dict.lookup("frictionalStressModel"));
|
||||||
|
|
||||||
Info<< "Selecting frictionalStressModel "
|
Info<< "Selecting frictionalStressModel "
|
||||||
<< frictionalStressModelType << endl;
|
<< frictionalStressModelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(frictionalStressModelType);
|
dictionaryConstructorTablePtr_->find(frictionalStressModelType);
|
||||||
|
|
||||||
|
|||||||
@ -35,9 +35,9 @@ Foam::autoPtr<Foam::granularPressureModel> Foam::granularPressureModel::New
|
|||||||
{
|
{
|
||||||
word granularPressureModelType(dict.lookup("granularPressureModel"));
|
word granularPressureModelType(dict.lookup("granularPressureModel"));
|
||||||
|
|
||||||
Info<< "Selecting granularPressureModel "
|
Info<< "Selecting granularPressureModel "
|
||||||
<< granularPressureModelType << endl;
|
<< granularPressureModelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(granularPressureModelType);
|
dictionaryConstructorTablePtr_->find(granularPressureModelType);
|
||||||
|
|
||||||
|
|||||||
@ -65,7 +65,7 @@ Foam::tmp<Foam::volScalarField> Foam::CarnahanStarlingRadial::g0
|
|||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
|
|
||||||
return
|
return
|
||||||
1.0/(1.0 - alpha)
|
1.0/(1.0 - alpha)
|
||||||
+ 3.0*alpha/(2.0*sqr(1.0 - alpha))
|
+ 3.0*alpha/(2.0*sqr(1.0 - alpha))
|
||||||
+ sqr(alpha)/(2.0*pow(1.0 - alpha, 3));
|
+ sqr(alpha)/(2.0*pow(1.0 - alpha, 3));
|
||||||
@ -78,8 +78,8 @@ Foam::tmp<Foam::volScalarField> Foam::CarnahanStarlingRadial::g0prime
|
|||||||
const dimensionedScalar& alphaMax
|
const dimensionedScalar& alphaMax
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
return
|
return
|
||||||
- alpha/sqr(1.0 - alpha)
|
- alpha/sqr(1.0 - alpha)
|
||||||
+ (3.0*(1.0 - alpha) + 6.0*sqr(alpha))/(2.0*(1.0 - alpha))
|
+ (3.0*(1.0 - alpha) + 6.0*sqr(alpha))/(2.0*(1.0 - alpha))
|
||||||
+ (2.0*alpha*(1.0 - alpha) + 3.0*pow(alpha, 3))
|
+ (2.0*alpha*(1.0 - alpha) + 3.0*pow(alpha, 3))
|
||||||
/(2.0*pow(1.0 - alpha, 4));
|
/(2.0*pow(1.0 - alpha, 4));
|
||||||
|
|||||||
@ -74,7 +74,7 @@ Foam::tmp<Foam::volScalarField> Foam::GidaspowRadial::g0prime
|
|||||||
const dimensionedScalar& alphaMax
|
const dimensionedScalar& alphaMax
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
return
|
return
|
||||||
(-1.0/5.0)*pow(alpha/alphaMax, -2.0/3.0)
|
(-1.0/5.0)*pow(alpha/alphaMax, -2.0/3.0)
|
||||||
/(alphaMax*sqr(1.0 - pow(alpha/alphaMax, 1.0/3.0)));
|
/(alphaMax*sqr(1.0 - pow(alpha/alphaMax, 1.0/3.0)));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -74,7 +74,7 @@ Foam::tmp<Foam::volScalarField> Foam::SinclairJacksonRadial::g0prime
|
|||||||
const dimensionedScalar& alphaMax
|
const dimensionedScalar& alphaMax
|
||||||
) const
|
) const
|
||||||
{
|
{
|
||||||
return
|
return
|
||||||
(-1.0/3.0)*pow(alpha/alphaMax, -2.0/3.0)
|
(-1.0/3.0)*pow(alpha/alphaMax, -2.0/3.0)
|
||||||
/(alphaMax*sqr(1.0 - pow(alpha/alphaMax, 1.0/3.0)));
|
/(alphaMax*sqr(1.0 - pow(alpha/alphaMax, 1.0/3.0)));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -35,9 +35,9 @@ Foam::autoPtr<Foam::radialModel> Foam::radialModel::New
|
|||||||
{
|
{
|
||||||
word radialModelType(dict.lookup("radialModel"));
|
word radialModelType(dict.lookup("radialModel"));
|
||||||
|
|
||||||
Info<< "Selecting radialModel "
|
Info<< "Selecting radialModel "
|
||||||
<< radialModelType << endl;
|
<< radialModelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(radialModelType);
|
dictionaryConstructorTablePtr_->find(radialModelType);
|
||||||
|
|
||||||
|
|||||||
@ -42,12 +42,12 @@
|
|||||||
|
|
||||||
phib = (fvc::interpolate(Ub) & mesh.Sf()) + fvc::ddtPhiCorr(rUbA, Ub, phib)
|
phib = (fvc::interpolate(Ub) & mesh.Sf()) + fvc::ddtPhiCorr(rUbA, Ub, phib)
|
||||||
+ phiDragb;
|
+ phiDragb;
|
||||||
|
|
||||||
phi = alphaf*phia + betaf*phib;
|
phi = alphaf*phia + betaf*phib;
|
||||||
|
|
||||||
surfaceScalarField Dp("(rho*(1|A(U)))", alphaf*rUaAf/rhoa + betaf*rUbAf/rhob);
|
surfaceScalarField Dp("(rho*(1|A(U)))", alphaf*rUaAf/rhoa + betaf*rUbAf/rhob);
|
||||||
|
|
||||||
for(int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
fvScalarMatrix pEqn
|
fvScalarMatrix pEqn
|
||||||
(
|
(
|
||||||
|
|||||||
@ -7,20 +7,20 @@
|
|||||||
labelListList neighbour = mesh.cellCells();
|
labelListList neighbour = mesh.cellCells();
|
||||||
scalarField cellVolumes = mesh.cellVolumes();
|
scalarField cellVolumes = mesh.cellVolumes();
|
||||||
|
|
||||||
forAll (alphaEx, celli)
|
forAll(alphaEx, celli)
|
||||||
{
|
{
|
||||||
// Finding the labels of the neighbouring cells
|
// Finding the labels of the neighbouring cells
|
||||||
labelList neighbourCell = neighbour[celli];
|
labelList neighbourCell = neighbour[celli];
|
||||||
|
|
||||||
// Initializing neighbouring cells contribution
|
// Initializing neighbouring cells contribution
|
||||||
scalar neighboursEx = 0.0;
|
scalar neighboursEx = 0.0;
|
||||||
|
|
||||||
forAll (neighbourCell, cellj)
|
forAll(neighbourCell, cellj)
|
||||||
{
|
{
|
||||||
labelList neighboursNeighbour = neighbour[neighbourCell[cellj]];
|
labelList neighboursNeighbour = neighbour[neighbourCell[cellj]];
|
||||||
scalar neighboursNeighbourCellVolumes = 0.0;
|
scalar neighboursNeighbourCellVolumes = 0.0;
|
||||||
|
|
||||||
forAll (neighboursNeighbour, cellk)
|
forAll(neighboursNeighbour, cellk)
|
||||||
{
|
{
|
||||||
neighboursNeighbourCellVolumes +=
|
neighboursNeighbourCellVolumes +=
|
||||||
cellVolumes[neighboursNeighbour[cellk]];
|
cellVolumes[neighboursNeighbour[cellk]];
|
||||||
|
|||||||
@ -177,7 +177,7 @@ void tractionDisplacementFvPatchVectorField::updateCoeffs()
|
|||||||
gradient() =
|
gradient() =
|
||||||
(
|
(
|
||||||
(traction_ + pressure_*n)/rho.value()
|
(traction_ + pressure_*n)/rho.value()
|
||||||
+ twoMuLambda*fvPatchField<vector>::snGrad() - (n & sigmaD)
|
+ twoMuLambda*fvPatchField<vector>::snGrad() - (n & sigmaD)
|
||||||
)/twoMuLambda;
|
)/twoMuLambda;
|
||||||
|
|
||||||
Switch thermalStress(thermalProperties.lookup("thermalStress"));
|
Switch thermalStress(thermalProperties.lookup("thermalStress"));
|
||||||
@ -187,7 +187,7 @@ void tractionDisplacementFvPatchVectorField::updateCoeffs()
|
|||||||
dimensionedScalar alpha(thermalProperties.lookup("alpha"));
|
dimensionedScalar alpha(thermalProperties.lookup("alpha"));
|
||||||
dimensionedScalar threeKalpha = threeK*alpha;
|
dimensionedScalar threeKalpha = threeK*alpha;
|
||||||
|
|
||||||
const fvPatchField<scalar>& T =
|
const fvPatchField<scalar>& T =
|
||||||
patch().lookupPatchField<volScalarField, scalar>("T");
|
patch().lookupPatchField<volScalarField, scalar>("T");
|
||||||
|
|
||||||
gradient() += n*threeKalpha.value()*T/twoMuLambda;
|
gradient() += n*threeKalpha.value()*T/twoMuLambda;
|
||||||
|
|||||||
@ -72,7 +72,7 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
volTensorField gradDcorr = fvc::grad(Dcorr);
|
volTensorField gradDcorr = fvc::grad(Dcorr);
|
||||||
|
|
||||||
sigmaExp =
|
sigmaExp =
|
||||||
(lambda - mu)*gradDcorr + mu*gradDcorr.T()
|
(lambda - mu)*gradDcorr + mu*gradDcorr.T()
|
||||||
+ (lambda*I)*tr(gradDcorr);
|
+ (lambda*I)*tr(gradDcorr);
|
||||||
|
|
||||||
|
|||||||
@ -171,7 +171,7 @@ void tractionDisplacementCorrectionFvPatchVectorField::updateCoeffs()
|
|||||||
const fvPatchField<symmTensor>& sigmaD =
|
const fvPatchField<symmTensor>& sigmaD =
|
||||||
patch().lookupPatchField<volSymmTensorField, symmTensor>("sigmaD");
|
patch().lookupPatchField<volSymmTensorField, symmTensor>("sigmaD");
|
||||||
|
|
||||||
const fvPatchField<tensor>& sigmaExp =
|
const fvPatchField<tensor>& sigmaExp =
|
||||||
patch().lookupPatchField<volTensorField, tensor>("sigmaExp");
|
patch().lookupPatchField<volTensorField, tensor>("sigmaExp");
|
||||||
|
|
||||||
gradient() =
|
gradient() =
|
||||||
|
|||||||
@ -1,3 +0,0 @@
|
|||||||
BSplineTest.C
|
|
||||||
|
|
||||||
EXE = $(FOAM_USER_APPBIN)/BSplineTest
|
|
||||||
@ -1,69 +0,0 @@
|
|||||||
/*--------------------------------*- C++ -*----------------------------------*\
|
|
||||||
| ========= | |
|
|
||||||
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
|
|
||||||
| \\ / O peration | Version: 1.6 |
|
|
||||||
| \\ / A nd | Web: http://www.OpenFOAM.org |
|
|
||||||
| \\/ M anipulation | |
|
|
||||||
\*---------------------------------------------------------------------------*/
|
|
||||||
(
|
|
||||||
// Upper body longitudinal splines.
|
|
||||||
(
|
|
||||||
(-0.22685 -0.01125166 0) // 7
|
|
||||||
(-0.21685 -0.01340204 0)
|
|
||||||
(-0.20685 -0.01529684 0)
|
|
||||||
(-0.19685 -0.01694748 0)
|
|
||||||
(-0.18685 -0.01836538 0)
|
|
||||||
(-0.17685 -0.01956197 0)
|
|
||||||
(-0.16685 -0.02054868 0)
|
|
||||||
(-0.15685 -0.02133693 0)
|
|
||||||
(-0.14685 -0.02193816 0)
|
|
||||||
(-0.13685 -0.02236377 0)
|
|
||||||
(-0.12685 -0.02262521 0)
|
|
||||||
(-0.11685 -0.02273389 0) // 2
|
|
||||||
)
|
|
||||||
|
|
||||||
(
|
|
||||||
(-0.22685 0 0.01125166) // 8
|
|
||||||
(-0.21685 0 0.01340204)
|
|
||||||
(-0.20685 0 0.01529684)
|
|
||||||
(-0.19685 0 0.01694748)
|
|
||||||
(-0.18685 0 0.01836538)
|
|
||||||
(-0.17685 0 0.01956197)
|
|
||||||
(-0.16685 0 0.02054868)
|
|
||||||
(-0.15685 0 0.02133693)
|
|
||||||
(-0.14685 0 0.02193816)
|
|
||||||
(-0.13685 0 0.02236377)
|
|
||||||
(-0.12685 0 0.02262521)
|
|
||||||
(-0.11685 0 0.02273389) // 3
|
|
||||||
)
|
|
||||||
|
|
||||||
(
|
|
||||||
(-0.22685 0.01125166 0) // 9
|
|
||||||
(-0.21685 0.01340204 0)
|
|
||||||
(-0.20685 0.01529684 0)
|
|
||||||
(-0.19685 0.01694748 0)
|
|
||||||
(-0.18685 0.01836538 0)
|
|
||||||
(-0.17685 0.01956197 0)
|
|
||||||
(-0.16685 0.02054868 0)
|
|
||||||
(-0.15685 0.02133693 0)
|
|
||||||
(-0.14685 0.02193816 0)
|
|
||||||
(-0.13685 0.02236377 0)
|
|
||||||
(-0.12685 0.02262521 0)
|
|
||||||
(-0.11685 0.02273389 0) // 4
|
|
||||||
)
|
|
||||||
|
|
||||||
(
|
|
||||||
(-0.22685 0 -0.01125166) // 6
|
|
||||||
(-0.21685 0 -0.01340204)
|
|
||||||
(-0.20685 0 -0.01529684)
|
|
||||||
(-0.19685 0 -0.01694748)
|
|
||||||
(-0.18685 0 -0.01836538)
|
|
||||||
(-0.17685 0 -0.01956197)
|
|
||||||
(-0.16685 0 -0.02054868)
|
|
||||||
(-0.15685 0 -0.02133693)
|
|
||||||
(-0.14685 0 -0.02193816)
|
|
||||||
(-0.13685 0 -0.02236377)
|
|
||||||
(-0.12685 0 -0.02262521)
|
|
||||||
(-0.11685 0 -0.02273389) // 1
|
|
||||||
)
|
|
||||||
);
|
|
||||||
@ -84,7 +84,7 @@ public:
|
|||||||
|
|
||||||
~Scalar()
|
~Scalar()
|
||||||
{
|
{
|
||||||
Info <<"delete Scalar: " << data_ << endl;
|
Info<<"delete Scalar: " << data_ << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const Scalar& val)
|
friend Ostream& operator<<(Ostream& os, const Scalar& val)
|
||||||
@ -169,7 +169,7 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
Info<< " = " << iter() << endl;
|
Info<< " = " << iter() << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
PtrDictionary<Scalar> scalarDict2;
|
PtrDictionary<Scalar> scalarDict2;
|
||||||
for (int i = 8; i<15; i++)
|
for (int i = 8; i<15; i++)
|
||||||
{
|
{
|
||||||
@ -186,22 +186,22 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
Info<< "elem = " << *iter << endl;
|
Info<< "elem = " << *iter << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
scalarDict.transfer(scalarDict2);
|
scalarDict.transfer(scalarDict2);
|
||||||
|
|
||||||
|
|
||||||
Scalar* p = scalarDict.lookupPtr("ent8");
|
Scalar* p = scalarDict.lookupPtr("ent8");
|
||||||
|
|
||||||
// This does not (yet) work
|
// This does not (yet) work
|
||||||
// Scalar* q = scalarDict.remove("ent10");
|
// Scalar* q = scalarDict.remove("ent10");
|
||||||
|
|
||||||
if (p)
|
if (p)
|
||||||
{
|
{
|
||||||
Info << "found: " << *p << endl;
|
Info<< "found: " << *p << endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Info << "no p: " << endl;
|
Info<< "no p: " << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
scalarDict.clear();
|
scalarDict.clear();
|
||||||
|
|||||||
@ -92,6 +92,8 @@ int main(int argc, char *argv[])
|
|||||||
labelHashSet setD(1);
|
labelHashSet setD(1);
|
||||||
setD.insert(11);
|
setD.insert(11);
|
||||||
setD.insert(100);
|
setD.insert(100);
|
||||||
|
setD.insert(49);
|
||||||
|
setD.insert(36);
|
||||||
setD.insert(2008);
|
setD.insert(2008);
|
||||||
|
|
||||||
Info<< "setD : " << setD << endl;
|
Info<< "setD : " << setD << endl;
|
||||||
@ -138,6 +140,17 @@ int main(int argc, char *argv[])
|
|||||||
// this doesn't work (yet?)
|
// this doesn't work (yet?)
|
||||||
// setD[12] = true;
|
// setD[12] = true;
|
||||||
|
|
||||||
|
List<label> someLst(10);
|
||||||
|
forAll(someLst, elemI)
|
||||||
|
{
|
||||||
|
someLst[elemI] = elemI*elemI;
|
||||||
|
}
|
||||||
|
|
||||||
|
label added = setD.set(someLst);
|
||||||
|
Info<< "added " << added << " from " << someLst.size() << endl;
|
||||||
|
Info<< "setD : " << setD << endl;
|
||||||
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -72,7 +72,7 @@ int main(int argc, char *argv[])
|
|||||||
<< "list: " << idl() << nl
|
<< "list: " << idl() << nl
|
||||||
<< endl;
|
<< endl;
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -155,7 +155,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
Info<< psi << endl;
|
Info<< psi << endl;
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -155,7 +155,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
Info<< psi << endl;
|
Info<< psi << endl;
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -47,11 +47,11 @@ using namespace Foam;
|
|||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
argList::noParallel();
|
argList::noParallel();
|
||||||
argList::validOptions.insert("reList", "reList");
|
argList::addOption("reList", "reList");
|
||||||
argList::validOptions.insert("wordList", "wordList");
|
argList::addOption("wordList", "wordList");
|
||||||
argList::validOptions.insert("stringList", "stringList");
|
argList::addOption("stringList", "stringList");
|
||||||
argList::validOptions.insert("float", "xx");
|
argList::addOption("float", "xx");
|
||||||
argList::validOptions.insert("flag", "");
|
argList::addBoolOption("flag");
|
||||||
|
|
||||||
# include "setRootCase.H"
|
# include "setRootCase.H"
|
||||||
|
|
||||||
|
|||||||
@ -53,15 +53,15 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
if (bananaIter == banana.end())
|
if (bananaIter == banana.end())
|
||||||
{
|
{
|
||||||
Info << "not found" << endl;
|
Info<< "not found" << endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Info << "5 is " << bananaIter() << endl;
|
Info<< "5 is " << bananaIter() << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Same with STL
|
// Same with STL
|
||||||
Info << "Same with STL" << endl;
|
Info<< "Same with STL" << endl;
|
||||||
|
|
||||||
std::map<label, bool> STLbanana;
|
std::map<label, bool> STLbanana;
|
||||||
STLbanana[5] = true;
|
STLbanana[5] = true;
|
||||||
@ -69,11 +69,11 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
if (STLbananaIter == STLbanana.end())
|
if (STLbananaIter == STLbanana.end())
|
||||||
{
|
{
|
||||||
Info << "not found" << endl;
|
Info<< "not found" << endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Info << "5 is " << STLbananaIter->second << endl;
|
Info<< "5 is " << STLbananaIter->second << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -71,7 +71,7 @@ int main(int argc, char *argv[])
|
|||||||
hmm4 = hmm5;
|
hmm4 = hmm5;
|
||||||
Info<< hmm5 << endl;
|
Info<< hmm5 << endl;
|
||||||
|
|
||||||
Info << "End\n" << endl;
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user