mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Merge commit 'origin/master' into splitCyclic
This commit is contained in:
@ -31,19 +31,17 @@ Description
|
|||||||
|
|
||||||
#include "fvCFD.H"
|
#include "fvCFD.H"
|
||||||
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
|
#include "setRootCase.H"
|
||||||
|
|
||||||
# include "setRootCase.H"
|
#include "createTime.H"
|
||||||
|
#include "createMesh.H"
|
||||||
|
#include "createFields.H"
|
||||||
|
|
||||||
# include "createTime.H"
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
# include "createMesh.H"
|
|
||||||
# include "createFields.H"
|
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
|
||||||
|
|
||||||
Info<< "\nCalculating temperature distribution\n" << endl;
|
Info<< "\nCalculating temperature distribution\n" << endl;
|
||||||
|
|
||||||
@ -51,7 +49,7 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
Info<< "Time = " << runTime.timeName() << nl << endl;
|
Info<< "Time = " << runTime.timeName() << nl << endl;
|
||||||
|
|
||||||
# include "readSIMPLEControls.H"
|
#include "readSIMPLEControls.H"
|
||||||
|
|
||||||
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
{
|
{
|
||||||
@ -61,7 +59,7 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
# include "write.H"
|
#include "write.H"
|
||||||
|
|
||||||
Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
||||||
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
||||||
|
|||||||
@ -39,13 +39,13 @@ int main(int argc, char *argv[])
|
|||||||
{
|
{
|
||||||
argList::addBoolOption("writep", "write the final pressure field");
|
argList::addBoolOption("writep", "write the final pressure field");
|
||||||
|
|
||||||
# include "setRootCase.H"
|
#include "setRootCase.H"
|
||||||
# include "createTime.H"
|
#include "createTime.H"
|
||||||
# include "createMesh.H"
|
#include "createMesh.H"
|
||||||
# include "createFields.H"
|
#include "createFields.H"
|
||||||
# include "readSIMPLEControls.H"
|
#include "readSIMPLEControls.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
Info<< nl << "Calculating potential flow" << endl;
|
Info<< nl << "Calculating potential flow" << endl;
|
||||||
|
|
||||||
|
|||||||
@ -1,25 +1,25 @@
|
|||||||
XiModels/XiModel/XiModel.C
|
XiModels/XiModel/XiModel.C
|
||||||
XiModels/XiModel/newXiModel.C
|
XiModels/XiModel/XiModelNew.C
|
||||||
XiModels/fixed/fixed.C
|
XiModels/fixed/fixed.C
|
||||||
XiModels/algebraic/algebraic.C
|
XiModels/algebraic/algebraic.C
|
||||||
XiModels/transport/transport.C
|
XiModels/transport/transport.C
|
||||||
|
|
||||||
XiModels/XiEqModels/XiEqModel/XiEqModel.C
|
XiModels/XiEqModels/XiEqModel/XiEqModel.C
|
||||||
XiModels/XiEqModels/XiEqModel/newXiEqModel.C
|
XiModels/XiEqModels/XiEqModel/XiEqModelNew.C
|
||||||
XiModels/XiEqModels/Gulder/Gulder.C
|
XiModels/XiEqModels/Gulder/Gulder.C
|
||||||
XiModels/XiEqModels/instabilityXiEq/instabilityXiEq.C
|
XiModels/XiEqModels/instabilityXiEq/instabilityXiEq.C
|
||||||
XiModels/XiEqModels/SCOPEBlendXiEq/SCOPEBlendXiEq.C
|
XiModels/XiEqModels/SCOPEBlendXiEq/SCOPEBlendXiEq.C
|
||||||
XiModels/XiEqModels/SCOPEXiEq/SCOPEXiEq.C
|
XiModels/XiEqModels/SCOPEXiEq/SCOPEXiEq.C
|
||||||
|
|
||||||
XiModels/XiGModels/XiGModel/XiGModel.C
|
XiModels/XiGModels/XiGModel/XiGModel.C
|
||||||
XiModels/XiGModels/XiGModel/newXiGModel.C
|
XiModels/XiGModels/XiGModel/XiGModelNew.C
|
||||||
XiModels/XiGModels/KTS/KTS.C
|
XiModels/XiGModels/KTS/KTS.C
|
||||||
XiModels/XiGModels/instabilityG/instabilityG.C
|
XiModels/XiGModels/instabilityG/instabilityG.C
|
||||||
|
|
||||||
PDRModels/turbulence/PDRkEpsilon/PDRkEpsilon.C
|
PDRModels/turbulence/PDRkEpsilon/PDRkEpsilon.C
|
||||||
|
|
||||||
PDRModels/dragModels/PDRDragModel/PDRDragModel.C
|
PDRModels/dragModels/PDRDragModel/PDRDragModel.C
|
||||||
PDRModels/dragModels/PDRDragModel/newPDRDragModel.C
|
PDRModels/dragModels/PDRDragModel/PDRDragModelNew.C
|
||||||
PDRModels/dragModels/basic/basic.C
|
PDRModels/dragModels/basic/basic.C
|
||||||
|
|
||||||
PDRModels/XiEqModels/basicXiSubXiEq/basicXiSubXiEq.C
|
PDRModels/XiEqModels/basicXiSubXiEq/basicXiSubXiEq.C
|
||||||
|
|||||||
@ -36,12 +36,12 @@ Foam::autoPtr<Foam::PDRDragModel> Foam::PDRDragModel::New
|
|||||||
const surfaceScalarField& phi
|
const surfaceScalarField& phi
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word PDRDragModelTypeName = PDRProperties.lookup("PDRDragModel");
|
const word modelType(PDRProperties.lookup("PDRDragModel"));
|
||||||
|
|
||||||
Info<< "Selecting flame-wrinkling model " << PDRDragModelTypeName << endl;
|
Info<< "Selecting flame-wrinkling model " << modelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(PDRDragModelTypeName);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
@ -49,7 +49,7 @@ Foam::autoPtr<Foam::PDRDragModel> Foam::PDRDragModel::New
|
|||||||
(
|
(
|
||||||
"PDRDragModel::New"
|
"PDRDragModel::New"
|
||||||
) << "Unknown PDRDragModel type "
|
) << "Unknown PDRDragModel type "
|
||||||
<< PDRDragModelTypeName << endl << endl
|
<< modelType << nl << nl
|
||||||
<< "Valid PDRDragModels are : " << endl
|
<< "Valid PDRDragModels are : " << endl
|
||||||
<< dictionaryConstructorTablePtr_->sortedToc()
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
@ -29,18 +29,18 @@ License
|
|||||||
|
|
||||||
Foam::autoPtr<Foam::XiEqModel> Foam::XiEqModel::New
|
Foam::autoPtr<Foam::XiEqModel> Foam::XiEqModel::New
|
||||||
(
|
(
|
||||||
const dictionary& XiEqProperties,
|
const dictionary& propDict,
|
||||||
const hhuCombustionThermo& thermo,
|
const hhuCombustionThermo& thermo,
|
||||||
const compressible::RASModel& turbulence,
|
const compressible::RASModel& turbulence,
|
||||||
const volScalarField& Su
|
const volScalarField& Su
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word XiEqModelTypeName = XiEqProperties.lookup("XiEqModel");
|
const word modelType(propDict.lookup("XiEqModel"));
|
||||||
|
|
||||||
Info<< "Selecting flame-wrinkling model " << XiEqModelTypeName << endl;
|
Info<< "Selecting flame-wrinkling model " << modelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(XiEqModelTypeName);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
@ -53,14 +53,13 @@ Foam::autoPtr<Foam::XiEqModel> Foam::XiEqModel::New
|
|||||||
" const volScalarField& Su"
|
" const volScalarField& Su"
|
||||||
")"
|
")"
|
||||||
) << "Unknown XiEqModel type "
|
) << "Unknown XiEqModel type "
|
||||||
<< XiEqModelTypeName << endl << endl
|
<< modelType << nl << nl
|
||||||
<< "Valid XiEqModels are : " << endl
|
<< "Valid XiEqModels are : " << endl
|
||||||
<< dictionaryConstructorTablePtr_->sortedToc()
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<XiEqModel>
|
return autoPtr<XiEqModel>(cstrIter()(propDict, thermo, turbulence, Su));
|
||||||
(cstrIter()(XiEqProperties, thermo, turbulence, Su));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -29,18 +29,18 @@ License
|
|||||||
|
|
||||||
Foam::autoPtr<Foam::XiGModel> Foam::XiGModel::New
|
Foam::autoPtr<Foam::XiGModel> Foam::XiGModel::New
|
||||||
(
|
(
|
||||||
const dictionary& XiGProperties,
|
const dictionary& propDict,
|
||||||
const hhuCombustionThermo& thermo,
|
const hhuCombustionThermo& thermo,
|
||||||
const compressible::RASModel& turbulence,
|
const compressible::RASModel& turbulence,
|
||||||
const volScalarField& Su
|
const volScalarField& Su
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word XiGModelTypeName = XiGProperties.lookup("XiGModel");
|
const word modelType(propDict.lookup("XiGModel"));
|
||||||
|
|
||||||
Info<< "Selecting flame-wrinkling model " << XiGModelTypeName << endl;
|
Info<< "Selecting flame-wrinkling model " << modelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(XiGModelTypeName);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
@ -53,14 +53,13 @@ Foam::autoPtr<Foam::XiGModel> Foam::XiGModel::New
|
|||||||
" const volScalarField& Su"
|
" const volScalarField& Su"
|
||||||
")"
|
")"
|
||||||
) << "Unknown XiGModel type "
|
) << "Unknown XiGModel type "
|
||||||
<< XiGModelTypeName << endl << endl
|
<< modelType << nl << nl
|
||||||
<< "Valid XiGModels are : " << endl
|
<< "Valid XiGModels are : " << endl
|
||||||
<< dictionaryConstructorTablePtr_->sortedToc()
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<XiGModel>
|
return autoPtr<XiGModel>(cstrIter()(propDict, thermo, turbulence, Su));
|
||||||
(cstrIter()(XiGProperties, thermo, turbulence, Su));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -29,7 +29,7 @@ License
|
|||||||
|
|
||||||
Foam::autoPtr<Foam::XiModel> Foam::XiModel::New
|
Foam::autoPtr<Foam::XiModel> Foam::XiModel::New
|
||||||
(
|
(
|
||||||
const dictionary& XiProperties,
|
const dictionary& propDict,
|
||||||
const hhuCombustionThermo& thermo,
|
const hhuCombustionThermo& thermo,
|
||||||
const compressible::RASModel& turbulence,
|
const compressible::RASModel& turbulence,
|
||||||
const volScalarField& Su,
|
const volScalarField& Su,
|
||||||
@ -38,12 +38,12 @@ Foam::autoPtr<Foam::XiModel> Foam::XiModel::New
|
|||||||
const surfaceScalarField& phi
|
const surfaceScalarField& phi
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word XiModelTypeName = XiProperties.lookup("XiModel");
|
const word modelType(propDict.lookup("XiModel"));
|
||||||
|
|
||||||
Info<< "Selecting flame-wrinkling model " << XiModelTypeName << endl;
|
Info<< "Selecting flame-wrinkling model " << modelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(XiModelTypeName);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
@ -51,14 +51,14 @@ Foam::autoPtr<Foam::XiModel> Foam::XiModel::New
|
|||||||
(
|
(
|
||||||
"XiModel::New"
|
"XiModel::New"
|
||||||
) << "Unknown XiModel type "
|
) << "Unknown XiModel type "
|
||||||
<< XiModelTypeName << endl << endl
|
<< modelType << nl << nl
|
||||||
<< "Valid XiModels are : " << endl
|
<< "Valid XiModels are : " << endl
|
||||||
<< dictionaryConstructorTablePtr_->sortedToc()
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<XiModel>
|
return autoPtr<XiModel>
|
||||||
(cstrIter()(XiProperties, thermo, turbulence, Su, rho, b, phi));
|
(cstrIter()(propDict, thermo, turbulence, Su, rho, b, phi));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1,5 +1,5 @@
|
|||||||
combustionModel/combustionModel.C
|
combustionModel/combustionModel.C
|
||||||
combustionModel/newCombustionModel.C
|
combustionModel/combustionModelNew.C
|
||||||
|
|
||||||
infinitelyFastChemistry/infinitelyFastChemistry.C
|
infinitelyFastChemistry/infinitelyFastChemistry.C
|
||||||
|
|
||||||
|
|||||||
@ -29,22 +29,19 @@ License
|
|||||||
|
|
||||||
Foam::autoPtr<Foam::combustionModel> Foam::combustionModel::New
|
Foam::autoPtr<Foam::combustionModel> Foam::combustionModel::New
|
||||||
(
|
(
|
||||||
const dictionary& combustionProperties,
|
const dictionary& propDict,
|
||||||
const hsCombustionThermo& thermo,
|
const hsCombustionThermo& thermo,
|
||||||
const compressible::turbulenceModel& turbulence,
|
const compressible::turbulenceModel& turbulence,
|
||||||
const surfaceScalarField& phi,
|
const surfaceScalarField& phi,
|
||||||
const volScalarField& rho
|
const volScalarField& rho
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word combustionModelTypeName = combustionProperties.lookup
|
const word modelType(propDict.lookup("combustionModel"));
|
||||||
(
|
|
||||||
"combustionModel"
|
|
||||||
);
|
|
||||||
|
|
||||||
Info<< "Selecting combustion model " << combustionModelTypeName << endl;
|
Info<< "Selecting combustion model " << modelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(combustionModelTypeName);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
@ -52,14 +49,14 @@ Foam::autoPtr<Foam::combustionModel> Foam::combustionModel::New
|
|||||||
(
|
(
|
||||||
"combustionModel::New"
|
"combustionModel::New"
|
||||||
) << "Unknown combustionModel type "
|
) << "Unknown combustionModel type "
|
||||||
<< combustionModelTypeName << endl << endl
|
<< modelType << nl << nl
|
||||||
<< "Valid combustionModels are : " << endl
|
<< "Valid combustionModels are : " << endl
|
||||||
<< dictionaryConstructorTablePtr_->toc()
|
<< dictionaryConstructorTablePtr_->toc()
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<combustionModel>
|
return autoPtr<combustionModel>
|
||||||
(cstrIter()(combustionProperties, thermo, turbulence, phi, rho));
|
(cstrIter()(propDict, thermo, turbulence, phi, rho));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -71,9 +71,9 @@ IOdictionary combustionProperties
|
|||||||
);
|
);
|
||||||
|
|
||||||
Info<< "Creating combustion model\n" << endl;
|
Info<< "Creating combustion model\n" << endl;
|
||||||
autoPtr<combustionModel::combustionModel> combustion
|
autoPtr<combustionModel> combustion
|
||||||
(
|
(
|
||||||
combustionModel::combustionModel::New
|
combustionModel::New
|
||||||
(
|
(
|
||||||
combustionProperties,
|
combustionProperties,
|
||||||
thermo,
|
thermo,
|
||||||
|
|||||||
@ -4,5 +4,6 @@ set -x
|
|||||||
|
|
||||||
wclean libso BCs
|
wclean libso BCs
|
||||||
wclean
|
wclean
|
||||||
|
wclean rhoCentralDyMFoam
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -4,5 +4,6 @@ set -x
|
|||||||
|
|
||||||
wmake libso BCs
|
wmake libso BCs
|
||||||
wmake
|
wmake
|
||||||
|
wmake rhoCentralDyMFoam
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -0,0 +1,3 @@
|
|||||||
|
rhoCentralDyMFoam.C
|
||||||
|
|
||||||
|
EXE = $(FOAM_APPBIN)/rhoCentralDyMFoam
|
||||||
@ -0,0 +1,17 @@
|
|||||||
|
EXE_INC = \
|
||||||
|
-I.. \
|
||||||
|
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
||||||
|
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
|
||||||
|
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
|
||||||
|
-I../BCs/lnInclude \
|
||||||
|
-I$(LIB_SRC)/sampling/lnInclude \
|
||||||
|
-I$(LIB_SRC)/dynamicMesh/lnInclude \
|
||||||
|
-I$(LIB_SRC)/meshTools/lnInclude
|
||||||
|
|
||||||
|
EXE_LIBS = \
|
||||||
|
-lfiniteVolume \
|
||||||
|
-lbasicThermophysicalModels \
|
||||||
|
-lspecie \
|
||||||
|
-lrhoCentralFoam \
|
||||||
|
-ldynamicMesh \
|
||||||
|
-lmeshTools
|
||||||
@ -0,0 +1,245 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 1991-2009 OpenCFD Ltd.
|
||||||
|
\\/ M anipulation |
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
License
|
||||||
|
This file is part of OpenFOAM.
|
||||||
|
|
||||||
|
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||||
|
under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||||
|
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||||
|
for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Application
|
||||||
|
rhoCentralFoam
|
||||||
|
|
||||||
|
Description
|
||||||
|
Density-based compressible flow solver based on central-upwind schemes of
|
||||||
|
Kurganov and Tadmor
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#include "fvCFD.H"
|
||||||
|
#include "basicPsiThermo.H"
|
||||||
|
#include "zeroGradientFvPatchFields.H"
|
||||||
|
#include "fixedRhoFvPatchScalarField.H"
|
||||||
|
#include "motionSolver.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
#include "setRootCase.H"
|
||||||
|
|
||||||
|
#include "createTime.H"
|
||||||
|
#include "createMesh.H"
|
||||||
|
#include "createFields.H"
|
||||||
|
#include "readThermophysicalProperties.H"
|
||||||
|
#include "readTimeControls.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
#include "readFluxScheme.H"
|
||||||
|
|
||||||
|
dimensionedScalar v_zero("v_zero", dimVolume/dimTime, 0.0);
|
||||||
|
|
||||||
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
|
autoPtr<Foam::motionSolver> motionPtr = motionSolver::New(mesh);
|
||||||
|
|
||||||
|
while (runTime.run())
|
||||||
|
{
|
||||||
|
// --- upwind interpolation of primitive fields on faces
|
||||||
|
|
||||||
|
surfaceScalarField rho_pos =
|
||||||
|
fvc::interpolate(rho, pos, "reconstruct(rho)");
|
||||||
|
surfaceScalarField rho_neg =
|
||||||
|
fvc::interpolate(rho, neg, "reconstruct(rho)");
|
||||||
|
|
||||||
|
surfaceVectorField rhoU_pos =
|
||||||
|
fvc::interpolate(rhoU, pos, "reconstruct(U)");
|
||||||
|
surfaceVectorField rhoU_neg =
|
||||||
|
fvc::interpolate(rhoU, neg, "reconstruct(U)");
|
||||||
|
|
||||||
|
volScalarField rPsi = 1.0/psi;
|
||||||
|
surfaceScalarField rPsi_pos =
|
||||||
|
fvc::interpolate(rPsi, pos, "reconstruct(T)");
|
||||||
|
surfaceScalarField rPsi_neg =
|
||||||
|
fvc::interpolate(rPsi, neg, "reconstruct(T)");
|
||||||
|
|
||||||
|
surfaceScalarField e_pos =
|
||||||
|
fvc::interpolate(e, pos, "reconstruct(T)");
|
||||||
|
surfaceScalarField e_neg =
|
||||||
|
fvc::interpolate(e, neg, "reconstruct(T)");
|
||||||
|
|
||||||
|
surfaceVectorField U_pos = rhoU_pos/rho_pos;
|
||||||
|
surfaceVectorField U_neg = rhoU_neg/rho_neg;
|
||||||
|
|
||||||
|
surfaceScalarField p_pos = rho_pos*rPsi_pos;
|
||||||
|
surfaceScalarField p_neg = rho_neg*rPsi_neg;
|
||||||
|
|
||||||
|
surfaceScalarField phiv_pos = U_pos & mesh.Sf();
|
||||||
|
surfaceScalarField phiv_neg = U_neg & mesh.Sf();
|
||||||
|
|
||||||
|
volScalarField c = sqrt(thermo.Cp()/thermo.Cv()*rPsi);
|
||||||
|
surfaceScalarField cSf_pos =
|
||||||
|
fvc::interpolate(c, pos, "reconstruct(T)")*mesh.magSf();
|
||||||
|
surfaceScalarField cSf_neg =
|
||||||
|
fvc::interpolate(c, neg, "reconstruct(T)")*mesh.magSf();
|
||||||
|
|
||||||
|
surfaceScalarField ap =
|
||||||
|
max(max(phiv_pos + cSf_pos, phiv_neg + cSf_neg), v_zero);
|
||||||
|
surfaceScalarField am =
|
||||||
|
min(min(phiv_pos - cSf_pos, phiv_neg - cSf_neg), v_zero);
|
||||||
|
|
||||||
|
surfaceScalarField a_pos = ap/(ap - am);
|
||||||
|
|
||||||
|
surfaceScalarField amaxSf("amaxSf", max(mag(am), mag(ap)));
|
||||||
|
|
||||||
|
surfaceScalarField aSf = am*a_pos;
|
||||||
|
|
||||||
|
if (fluxScheme == "Tadmor")
|
||||||
|
{
|
||||||
|
aSf = -0.5*amaxSf;
|
||||||
|
a_pos = 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
surfaceScalarField a_neg = (1.0 - a_pos);
|
||||||
|
|
||||||
|
phiv_pos *= a_pos;
|
||||||
|
phiv_neg *= a_neg;
|
||||||
|
|
||||||
|
surfaceScalarField aphiv_pos = phiv_pos - aSf;
|
||||||
|
surfaceScalarField aphiv_neg = phiv_neg + aSf;
|
||||||
|
|
||||||
|
// Reuse amaxSf for the maximum positive and negative fluxes
|
||||||
|
// estimated by the central scheme
|
||||||
|
amaxSf = max(mag(aphiv_pos), mag(aphiv_neg));
|
||||||
|
|
||||||
|
#include "compressibleCourantNo.H"
|
||||||
|
#include "readTimeControls.H"
|
||||||
|
#include "setDeltaT.H"
|
||||||
|
|
||||||
|
runTime++;
|
||||||
|
|
||||||
|
Info<< "Time = " << runTime.timeName() << nl << endl;
|
||||||
|
|
||||||
|
mesh.movePoints(motionPtr->newPoints());
|
||||||
|
phiv_pos = U_pos & mesh.Sf();
|
||||||
|
phiv_neg = U_neg & mesh.Sf();
|
||||||
|
fvc::makeRelative(phiv_pos, U);
|
||||||
|
fvc::makeRelative(phiv_neg, U);
|
||||||
|
phiv_neg -= mesh.phi();
|
||||||
|
phiv_pos *= a_pos;
|
||||||
|
phiv_neg *= a_neg;
|
||||||
|
aphiv_pos = phiv_pos - aSf;
|
||||||
|
aphiv_neg = phiv_neg + aSf;
|
||||||
|
|
||||||
|
surfaceScalarField phi("phi", aphiv_pos*rho_pos + aphiv_neg*rho_neg);
|
||||||
|
|
||||||
|
surfaceVectorField phiUp =
|
||||||
|
(aphiv_pos*rhoU_pos + aphiv_neg*rhoU_neg)
|
||||||
|
+ (a_pos*p_pos + a_neg*p_neg)*mesh.Sf();
|
||||||
|
|
||||||
|
surfaceScalarField phiEp =
|
||||||
|
aphiv_pos*(rho_pos*(e_pos + 0.5*magSqr(U_pos)) + p_pos)
|
||||||
|
+ aphiv_neg*(rho_neg*(e_neg + 0.5*magSqr(U_neg)) + p_neg)
|
||||||
|
+ aSf*p_pos - aSf*p_neg;
|
||||||
|
|
||||||
|
volTensorField tauMC("tauMC", mu*dev2(fvc::grad(U)().T()));
|
||||||
|
|
||||||
|
// --- Solve density
|
||||||
|
Info<< max(rho) << " " << min(rho) << endl;
|
||||||
|
solve(fvm::ddt(rho) + fvc::div(phi));
|
||||||
|
Info<< max(rho) << " " << min(rho) << endl;
|
||||||
|
|
||||||
|
// --- Solve momentum
|
||||||
|
solve(fvm::ddt(rhoU) + fvc::div(phiUp));
|
||||||
|
|
||||||
|
U.dimensionedInternalField() =
|
||||||
|
rhoU.dimensionedInternalField()
|
||||||
|
/rho.dimensionedInternalField();
|
||||||
|
U.correctBoundaryConditions();
|
||||||
|
rhoU.boundaryField() = rho.boundaryField()*U.boundaryField();
|
||||||
|
|
||||||
|
if (!inviscid)
|
||||||
|
{
|
||||||
|
solve
|
||||||
|
(
|
||||||
|
fvm::ddt(rho, U) - fvc::ddt(rho, U)
|
||||||
|
- fvm::laplacian(mu, U)
|
||||||
|
- fvc::div(tauMC)
|
||||||
|
);
|
||||||
|
rhoU = rho*U;
|
||||||
|
}
|
||||||
|
|
||||||
|
// --- Solve energy
|
||||||
|
surfaceScalarField sigmaDotU =
|
||||||
|
(
|
||||||
|
(
|
||||||
|
fvc::interpolate(mu)*mesh.magSf()*fvc::snGrad(U)
|
||||||
|
+ (mesh.Sf() & fvc::interpolate(tauMC))
|
||||||
|
)
|
||||||
|
& (a_pos*U_pos + a_neg*U_neg)
|
||||||
|
);
|
||||||
|
|
||||||
|
solve
|
||||||
|
(
|
||||||
|
fvm::ddt(rhoE)
|
||||||
|
+ fvc::div(phiEp)
|
||||||
|
- fvc::div(sigmaDotU)
|
||||||
|
);
|
||||||
|
|
||||||
|
e = rhoE/rho - 0.5*magSqr(U);
|
||||||
|
e.correctBoundaryConditions();
|
||||||
|
thermo.correct();
|
||||||
|
rhoE.boundaryField() =
|
||||||
|
rho.boundaryField()*
|
||||||
|
(
|
||||||
|
e.boundaryField() + 0.5*magSqr(U.boundaryField())
|
||||||
|
);
|
||||||
|
|
||||||
|
if (!inviscid)
|
||||||
|
{
|
||||||
|
volScalarField k("k", thermo.Cp()*mu/Pr);
|
||||||
|
solve
|
||||||
|
(
|
||||||
|
fvm::ddt(rho, e) - fvc::ddt(rho, e)
|
||||||
|
- fvm::laplacian(thermo.alpha(), e)
|
||||||
|
+ fvc::laplacian(thermo.alpha(), e)
|
||||||
|
- fvc::laplacian(k, T)
|
||||||
|
);
|
||||||
|
thermo.correct();
|
||||||
|
rhoE = rho*(e + 0.5*magSqr(U));
|
||||||
|
}
|
||||||
|
|
||||||
|
p.dimensionedInternalField() =
|
||||||
|
rho.dimensionedInternalField()
|
||||||
|
/psi.dimensionedInternalField();
|
||||||
|
p.correctBoundaryConditions();
|
||||||
|
rho.boundaryField() = psi.boundaryField()*p.boundaryField();
|
||||||
|
|
||||||
|
runTime.write();
|
||||||
|
|
||||||
|
Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
||||||
|
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
||||||
|
<< nl << endl;
|
||||||
|
}
|
||||||
|
|
||||||
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -49,7 +49,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
Info<< "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
autoPtr<Foam::motionSolver> motionPtr = motionSolver::New(mesh);
|
autoPtr<motionSolver> motionPtr = motionSolver::New(mesh);
|
||||||
|
|
||||||
while (runTime.loop())
|
while (runTime.loop())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -39,6 +39,20 @@ int main(int argc, char *argv[])
|
|||||||
# include "createTime.H"
|
# include "createTime.H"
|
||||||
# include "createMesh.H"
|
# include "createMesh.H"
|
||||||
|
|
||||||
|
Info<< "\nReading field U\n" << endl;
|
||||||
|
volVectorField U
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"U",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh
|
||||||
|
);
|
||||||
|
|
||||||
potential pot(mesh);
|
potential pot(mesh);
|
||||||
|
|
||||||
moleculeCloud molecules(mesh, pot);
|
moleculeCloud molecules(mesh, pot);
|
||||||
|
|||||||
@ -39,6 +39,20 @@ int main(int argc, char *argv[])
|
|||||||
# include "createTime.H"
|
# include "createTime.H"
|
||||||
# include "createMesh.H"
|
# include "createMesh.H"
|
||||||
|
|
||||||
|
Info<< "\nReading field U\n" << endl;
|
||||||
|
volVectorField U
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"U",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh
|
||||||
|
);
|
||||||
|
|
||||||
potential pot(mesh);
|
potential pot(mesh);
|
||||||
|
|
||||||
moleculeCloud molecules(mesh, pot);
|
moleculeCloud molecules(mesh, pot);
|
||||||
|
|||||||
@ -0,0 +1,3 @@
|
|||||||
|
magneticFoam.C
|
||||||
|
|
||||||
|
EXE = $(FOAM_APPBIN)/magneticFoam
|
||||||
@ -0,0 +1,4 @@
|
|||||||
|
EXE_INC = \
|
||||||
|
-I$(LIB_SRC)/finiteVolume/lnInclude
|
||||||
|
|
||||||
|
EXE_LIBS = -lfiniteVolume
|
||||||
@ -0,0 +1,81 @@
|
|||||||
|
Info<< "Reading field psi\n" << endl;
|
||||||
|
volScalarField psi
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"psi",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh
|
||||||
|
);
|
||||||
|
|
||||||
|
Info<< "Reading transportProperties\n" << endl;
|
||||||
|
|
||||||
|
IOdictionary transportProperties
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"transportProperties",
|
||||||
|
runTime.constant(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::NO_WRITE
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
List<magnet> magnets(transportProperties.lookup("magnets"));
|
||||||
|
|
||||||
|
surfaceScalarField murf
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"murf",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh
|
||||||
|
),
|
||||||
|
mesh,
|
||||||
|
1
|
||||||
|
);
|
||||||
|
|
||||||
|
surfaceScalarField Mrf
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"Mrf",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh
|
||||||
|
),
|
||||||
|
mesh,
|
||||||
|
dimensionedScalar("Mr", dimensionSet(0, 1, 0, 0, 0, 1, 0), 0)
|
||||||
|
);
|
||||||
|
|
||||||
|
forAll(magnets, i)
|
||||||
|
{
|
||||||
|
label magnetZonei = mesh.faceZones().findZoneID(magnets[i].name());
|
||||||
|
|
||||||
|
if (magnetZonei == -1)
|
||||||
|
{
|
||||||
|
FatalIOErrorIn(args.executable().c_str(), transportProperties)
|
||||||
|
<< "Cannot find faceZone for magnet " << magnets[i].name()
|
||||||
|
<< exit(FatalIOError);
|
||||||
|
}
|
||||||
|
|
||||||
|
const labelList& faces =
|
||||||
|
mesh.faceZones()[magnetZonei];
|
||||||
|
|
||||||
|
const scalar muri = magnets[i].mur();
|
||||||
|
const scalar Mri = magnets[i].Mr().value();
|
||||||
|
const vector& orientationi = magnets[i].orientation();
|
||||||
|
|
||||||
|
const surfaceVectorField& Sf = mesh.Sf();
|
||||||
|
|
||||||
|
forAll(faces, i)
|
||||||
|
{
|
||||||
|
label facei = faces[i];
|
||||||
|
murf[facei] = muri;
|
||||||
|
Mrf[facei] = Mri*(orientationi & Sf[facei]);
|
||||||
|
}
|
||||||
|
}
|
||||||
169
applications/solvers/electromagnetics/magneticFoam/magnet.H
Normal file
169
applications/solvers/electromagnetics/magneticFoam/magnet.H
Normal file
@ -0,0 +1,169 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ M anipulation |
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
License
|
||||||
|
This file is part of OpenFOAM.
|
||||||
|
|
||||||
|
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||||
|
under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||||
|
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||||
|
for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Class
|
||||||
|
Foam::magnet
|
||||||
|
|
||||||
|
Description
|
||||||
|
Class to hold the defining data for a permanent magnet, in particular
|
||||||
|
the name, relative permeability and remanence.
|
||||||
|
|
||||||
|
SourceFiles
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#ifndef magnet_H
|
||||||
|
#define magnet_H
|
||||||
|
|
||||||
|
#include "dimensionedVector.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
namespace Foam
|
||||||
|
{
|
||||||
|
|
||||||
|
// Forward declaration of classes
|
||||||
|
class Istream;
|
||||||
|
class Ostream;
|
||||||
|
|
||||||
|
// Forward declaration of friend functions and operators
|
||||||
|
class magnet;
|
||||||
|
Istream& operator>>(Istream&, magnet&);
|
||||||
|
Ostream& operator<<(Ostream&, const magnet&);
|
||||||
|
|
||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
Class magnet Declaration
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
class magnet
|
||||||
|
{
|
||||||
|
// Private data
|
||||||
|
|
||||||
|
word name_;
|
||||||
|
scalar relativePermeability_;
|
||||||
|
dimensionedScalar remanence_;
|
||||||
|
vector orientation_;
|
||||||
|
|
||||||
|
public:
|
||||||
|
|
||||||
|
// Constructors
|
||||||
|
|
||||||
|
//- Null constructor for lists
|
||||||
|
inline magnet()
|
||||||
|
:
|
||||||
|
remanence_("Mr", dimensionSet(0, -1, 0, 0, 0, 1, 0), 0),
|
||||||
|
orientation_(vector::zero)
|
||||||
|
{}
|
||||||
|
|
||||||
|
//- Construct from components
|
||||||
|
inline magnet
|
||||||
|
(
|
||||||
|
const word& name,
|
||||||
|
const scalar mur,
|
||||||
|
const scalar Mr,
|
||||||
|
const vector& orientation
|
||||||
|
)
|
||||||
|
:
|
||||||
|
name_(name),
|
||||||
|
relativePermeability_(mur),
|
||||||
|
remanence_("Mr", dimensionSet(0, -1, 0, 0, 0, 1, 0), Mr),
|
||||||
|
orientation_(orientation)
|
||||||
|
{}
|
||||||
|
|
||||||
|
//- Construct from Istream
|
||||||
|
inline magnet(Istream& is)
|
||||||
|
:
|
||||||
|
remanence_("Mr", dimensionSet(0, -1, 0, 0, 0, 1, 0), 0),
|
||||||
|
orientation_(vector::zero)
|
||||||
|
{
|
||||||
|
is >> *this;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Member Functions
|
||||||
|
|
||||||
|
//- Return name
|
||||||
|
inline const word& name() const
|
||||||
|
{
|
||||||
|
return name_;
|
||||||
|
}
|
||||||
|
|
||||||
|
//- Return relative permeability
|
||||||
|
inline scalar mur() const
|
||||||
|
{
|
||||||
|
return relativePermeability_;
|
||||||
|
}
|
||||||
|
|
||||||
|
//- Return remenance
|
||||||
|
inline const dimensionedScalar& Mr() const
|
||||||
|
{
|
||||||
|
return remanence_;
|
||||||
|
}
|
||||||
|
|
||||||
|
//- Return orientation
|
||||||
|
inline const vector& orientation() const
|
||||||
|
{
|
||||||
|
return orientation_;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// IOstream operators
|
||||||
|
|
||||||
|
inline friend Istream& operator>>(Istream& is, magnet& m)
|
||||||
|
{
|
||||||
|
is.readBegin("magnet");
|
||||||
|
is >> m.name_
|
||||||
|
>> m.relativePermeability_
|
||||||
|
>> m.remanence_.value()
|
||||||
|
>> m.orientation_;
|
||||||
|
is.readEnd("magnet");
|
||||||
|
|
||||||
|
// Check state of Istream
|
||||||
|
is.check("operator>>(Istream&, magnet&)");
|
||||||
|
|
||||||
|
return is;
|
||||||
|
}
|
||||||
|
|
||||||
|
inline friend Ostream& operator<<(Ostream& os, const magnet& m)
|
||||||
|
{
|
||||||
|
os << token::BEGIN_LIST
|
||||||
|
<< m.name_ << token::SPACE
|
||||||
|
<< m.relativePermeability_ << token::SPACE
|
||||||
|
<< m.remanence_.value()
|
||||||
|
<< m.orientation_
|
||||||
|
<< token::END_LIST;
|
||||||
|
|
||||||
|
return os;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
} // End namespace Foam
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -0,0 +1,153 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2010-2010 OpenCFD Ltd.
|
||||||
|
\\/ M anipulation |
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
License
|
||||||
|
This file is part of OpenFOAM.
|
||||||
|
|
||||||
|
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||||
|
under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||||
|
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||||
|
for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Application
|
||||||
|
magneticFoam
|
||||||
|
|
||||||
|
Description
|
||||||
|
Solver for the magnetic field generated by permanent magnets.
|
||||||
|
|
||||||
|
A Poisson's equation for the magnetic scalar potential psi is solved
|
||||||
|
from which the magnetic field intensity H and magnetic flux density B
|
||||||
|
are obtained. The paramagnetic particle force field (H dot grad(H))
|
||||||
|
is optionally available.
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#include "fvCFD.H"
|
||||||
|
#include "OSspecific.H"
|
||||||
|
#include "magnet.H"
|
||||||
|
#include "electromagneticConstants.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
argList::addBoolOption
|
||||||
|
(
|
||||||
|
"noH",
|
||||||
|
"do not write the magnetic field intensity field"
|
||||||
|
);
|
||||||
|
|
||||||
|
argList::addBoolOption
|
||||||
|
(
|
||||||
|
"noB",
|
||||||
|
"do not write the magnetic flux density field"
|
||||||
|
);
|
||||||
|
|
||||||
|
argList::addBoolOption
|
||||||
|
(
|
||||||
|
"HdotGradH",
|
||||||
|
"write the paramagnetic particle force field"
|
||||||
|
);
|
||||||
|
|
||||||
|
#include "setRootCase.H"
|
||||||
|
#include "createTime.H"
|
||||||
|
#include "createMesh.H"
|
||||||
|
#include "createFields.H"
|
||||||
|
#include "readSIMPLEControls.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Info<< "Calculating the magnetic field potential" << endl;
|
||||||
|
|
||||||
|
runTime++;
|
||||||
|
|
||||||
|
for (int nonOrth=0; nonOrth<=nNonOrthCorr; nonOrth++)
|
||||||
|
{
|
||||||
|
solve(fvm::laplacian(murf, psi) + fvc::div(murf*Mrf));
|
||||||
|
}
|
||||||
|
|
||||||
|
psi.write();
|
||||||
|
|
||||||
|
if (!args.optionFound("noH") || args.optionFound("HdotGradH"))
|
||||||
|
{
|
||||||
|
volVectorField H
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"H",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh
|
||||||
|
),
|
||||||
|
fvc::reconstruct(fvc::snGrad(psi)*mesh.magSf())
|
||||||
|
);
|
||||||
|
|
||||||
|
if (!args.optionFound("noH"))
|
||||||
|
{
|
||||||
|
Info<< nl
|
||||||
|
<< "Creating field H for time "
|
||||||
|
<< runTime.timeName() << endl;
|
||||||
|
|
||||||
|
H.write();
|
||||||
|
}
|
||||||
|
|
||||||
|
if (args.optionFound("HdotGradH"))
|
||||||
|
{
|
||||||
|
Info<< nl
|
||||||
|
<< "Creating field HdotGradH for time "
|
||||||
|
<< runTime.timeName() << endl;
|
||||||
|
|
||||||
|
volVectorField HdotGradH
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"HdotGradH",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh
|
||||||
|
),
|
||||||
|
H & fvc::grad(H)
|
||||||
|
);
|
||||||
|
|
||||||
|
HdotGradH.write();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!args.optionFound("noB"))
|
||||||
|
{
|
||||||
|
Info<< nl
|
||||||
|
<< "Creating field B for time "
|
||||||
|
<< runTime.timeName() << endl;
|
||||||
|
|
||||||
|
volVectorField B
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"B",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh
|
||||||
|
),
|
||||||
|
constant::electromagnetic::mu0
|
||||||
|
*fvc::reconstruct(murf*fvc::snGrad(psi)*mesh.magSf() + murf*Mrf)
|
||||||
|
);
|
||||||
|
|
||||||
|
B.write();
|
||||||
|
}
|
||||||
|
|
||||||
|
Info<< "\nEnd\n" << endl;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -169,6 +169,21 @@ void Foam::solidWallHeatFluxTemperatureFvPatchScalarField::updateCoeffs()
|
|||||||
gradient() = q_/K();
|
gradient() = q_/K();
|
||||||
|
|
||||||
fixedGradientFvPatchScalarField::updateCoeffs();
|
fixedGradientFvPatchScalarField::updateCoeffs();
|
||||||
|
|
||||||
|
if (debug)
|
||||||
|
{
|
||||||
|
scalar Q = gSum(K()*patch().magSf()*snGrad());
|
||||||
|
|
||||||
|
Info<< patch().boundaryMesh().mesh().name() << ':'
|
||||||
|
<< patch().name() << ':'
|
||||||
|
<< this->dimensionedInternalField().name() << " :"
|
||||||
|
<< " heatFlux:" << Q
|
||||||
|
<< " walltemperature "
|
||||||
|
<< " min:" << gMin(*this)
|
||||||
|
<< " max:" << gMax(*this)
|
||||||
|
<< " avg:" << gAverage(*this)
|
||||||
|
<< endl;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -11,7 +11,7 @@
|
|||||||
basicMultiComponentMixture& composition = thermo.composition();
|
basicMultiComponentMixture& composition = thermo.composition();
|
||||||
PtrList<volScalarField>& Y = composition.Y();
|
PtrList<volScalarField>& Y = composition.Y();
|
||||||
|
|
||||||
word inertSpecie(thermo.lookup("inertSpecie"));
|
const word inertSpecie(thermo.lookup("inertSpecie"));
|
||||||
|
|
||||||
if (!composition.contains(inertSpecie))
|
if (!composition.contains(inertSpecie))
|
||||||
{
|
{
|
||||||
|
|||||||
@ -0,0 +1,3 @@
|
|||||||
|
incompressibleUncoupledKinematicParcelFoam.C
|
||||||
|
|
||||||
|
EXE = $(FOAM_APPBIN)/incompressibleUncoupledKinematicParcelFoam
|
||||||
@ -0,0 +1,27 @@
|
|||||||
|
EXE_INC = \
|
||||||
|
-I$(LIB_SRC)/lagrangian/basic/lnInclude \
|
||||||
|
-I$(LIB_SRC)/lagrangian/intermediate/lnInclude \
|
||||||
|
-I$(LIB_SRC)/thermophysicalModels/specie/lnInclude \
|
||||||
|
-I$(LIB_SRC)/thermophysicalModels/basic/lnInclude \
|
||||||
|
-I$(LIB_SRC)/thermophysicalModels/reactionThermo/lnInclude \
|
||||||
|
-I$(LIB_SRC)/thermophysicalModels/radiation/lnInclude \
|
||||||
|
-I$(LIB_SRC)/turbulenceModels/incompressible/turbulenceModel \
|
||||||
|
-I$(LIB_SRC)/transportModels \
|
||||||
|
-I$(LIB_SRC)/transportModels/incompressible/singlePhaseTransportModel \
|
||||||
|
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
||||||
|
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||||
|
-I$(LIB_SRC)/surfaceFilmModels/lnInclude
|
||||||
|
|
||||||
|
EXE_LIBS = \
|
||||||
|
-llagrangian \
|
||||||
|
-llagrangianIntermediate \
|
||||||
|
-lthermophysicalFunctions \
|
||||||
|
-lbasicThermophysicalModels \
|
||||||
|
-lspecie \
|
||||||
|
-lradiation \
|
||||||
|
-lincompressibleRASModels \
|
||||||
|
-lincompressibleLESModels \
|
||||||
|
-lincompressibleTransportModels \
|
||||||
|
-lfiniteVolume \
|
||||||
|
-lmeshTools \
|
||||||
|
-lsurfaceFilmModels
|
||||||
@ -0,0 +1,147 @@
|
|||||||
|
Info<< "Reading transportProperties\n" << endl;
|
||||||
|
|
||||||
|
IOdictionary transportProperties
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"transportProperties",
|
||||||
|
runTime.constant(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::NO_WRITE
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
dimensionedScalar rhoInfValue
|
||||||
|
(
|
||||||
|
transportProperties.lookup("rhoInf")
|
||||||
|
);
|
||||||
|
|
||||||
|
volScalarField rhoInf
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"rho",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh,
|
||||||
|
rhoInfValue
|
||||||
|
);
|
||||||
|
|
||||||
|
Info<< "\nReading field U\n" << endl;
|
||||||
|
volVectorField U
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"U",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh
|
||||||
|
);
|
||||||
|
|
||||||
|
#include "createPhi.H"
|
||||||
|
|
||||||
|
Info<< "Creating turbulence model\n" << endl;
|
||||||
|
|
||||||
|
singlePhaseTransportModel laminarTransport(U, phi);
|
||||||
|
|
||||||
|
const volScalarField nu = laminarTransport.nu();
|
||||||
|
|
||||||
|
autoPtr<incompressible::turbulenceModel> turbulence
|
||||||
|
(
|
||||||
|
incompressible::turbulenceModel::New(U, phi, laminarTransport)
|
||||||
|
);
|
||||||
|
|
||||||
|
volScalarField mu
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"mu",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::NO_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
nu*rhoInfValue
|
||||||
|
);
|
||||||
|
|
||||||
|
word kinematicCloudName("kinematicCloud");
|
||||||
|
args.optionReadIfPresent("cloudName", kinematicCloudName);
|
||||||
|
|
||||||
|
Info<< "Constructing kinematicCloud " << kinematicCloudName << endl;
|
||||||
|
basicKinematicCloud kinematicCloud
|
||||||
|
(
|
||||||
|
kinematicCloudName,
|
||||||
|
rhoInf,
|
||||||
|
U,
|
||||||
|
mu,
|
||||||
|
g
|
||||||
|
);
|
||||||
|
|
||||||
|
IOobject Hheader
|
||||||
|
(
|
||||||
|
"H",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::NO_READ
|
||||||
|
);
|
||||||
|
|
||||||
|
autoPtr<volVectorField> HPtr_;
|
||||||
|
|
||||||
|
if (Hheader.headerOk())
|
||||||
|
{
|
||||||
|
Info<< "\nReading field H\n" << endl;
|
||||||
|
|
||||||
|
HPtr_.reset
|
||||||
|
(
|
||||||
|
new volVectorField
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"H",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
IOobject HdotGradHheader
|
||||||
|
(
|
||||||
|
"HdotGradH",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::NO_READ
|
||||||
|
);
|
||||||
|
|
||||||
|
autoPtr<volVectorField> HdotGradHPtr_;
|
||||||
|
|
||||||
|
if (HdotGradHheader.headerOk())
|
||||||
|
{
|
||||||
|
Info<< "\nReading field HdotGradH\n" << endl;
|
||||||
|
|
||||||
|
HdotGradHPtr_.reset
|
||||||
|
(
|
||||||
|
new volVectorField
|
||||||
|
(
|
||||||
|
IOobject
|
||||||
|
(
|
||||||
|
"HdotGradH",
|
||||||
|
runTime.timeName(),
|
||||||
|
mesh,
|
||||||
|
IOobject::MUST_READ,
|
||||||
|
IOobject::AUTO_WRITE
|
||||||
|
),
|
||||||
|
mesh
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
@ -0,0 +1,81 @@
|
|||||||
|
/*---------------------------------------------------------------------------*\
|
||||||
|
========= |
|
||||||
|
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||||
|
\\ / O peration |
|
||||||
|
\\ / A nd | Copyright (C) 2008-2009 OpenCFD Ltd.
|
||||||
|
\\/ M anipulation |
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
License
|
||||||
|
This file is part of OpenFOAM.
|
||||||
|
|
||||||
|
OpenFOAM is free software: you can redistribute it and/or modify it
|
||||||
|
under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
|
||||||
|
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||||
|
for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
Application
|
||||||
|
uncoupledKinematicParcelFoam
|
||||||
|
|
||||||
|
Description
|
||||||
|
Transient solver for the passive transport of a single kinematic
|
||||||
|
particle could.
|
||||||
|
|
||||||
|
Uses a pre-calculated velocity field to evolve the cloud.
|
||||||
|
|
||||||
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
#include "fvCFD.H"
|
||||||
|
#include "singlePhaseTransportModel.H"
|
||||||
|
#include "turbulenceModel.H"
|
||||||
|
#include "basicKinematicCloud.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
int main(int argc, char *argv[])
|
||||||
|
{
|
||||||
|
argList::addOption("cloudName", "cloud name");
|
||||||
|
|
||||||
|
#include "setRootCase.H"
|
||||||
|
#include "createTime.H"
|
||||||
|
#include "createMesh.H"
|
||||||
|
#include "readGravitationalAcceleration.H"
|
||||||
|
#include "createFields.H"
|
||||||
|
|
||||||
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
|
|
||||||
|
while (runTime.loop())
|
||||||
|
{
|
||||||
|
Info<< "Time = " << runTime.timeName() << nl << endl;
|
||||||
|
|
||||||
|
Info<< "Evolving " << kinematicCloud.name() << endl;
|
||||||
|
|
||||||
|
laminarTransport.correct();
|
||||||
|
|
||||||
|
mu = nu*rhoInfValue;
|
||||||
|
|
||||||
|
kinematicCloud.evolve();
|
||||||
|
|
||||||
|
runTime.write();
|
||||||
|
|
||||||
|
Info<< "ExecutionTime = " << runTime.elapsedCpuTime() << " s"
|
||||||
|
<< " ClockTime = " << runTime.elapsedClockTime() << " s"
|
||||||
|
<< nl << endl;
|
||||||
|
}
|
||||||
|
|
||||||
|
Info<< "End\n" << endl;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// ************************************************************************* //
|
||||||
@ -11,7 +11,7 @@
|
|||||||
basicMultiComponentMixture& composition = thermo.composition();
|
basicMultiComponentMixture& composition = thermo.composition();
|
||||||
PtrList<volScalarField>& Y = composition.Y();
|
PtrList<volScalarField>& Y = composition.Y();
|
||||||
|
|
||||||
word inertSpecie(thermo.lookup("inertSpecie"));
|
const word inertSpecie(thermo.lookup("inertSpecie"));
|
||||||
|
|
||||||
if (!composition.contains(inertSpecie))
|
if (!composition.contains(inertSpecie))
|
||||||
{
|
{
|
||||||
|
|||||||
@ -11,7 +11,7 @@
|
|||||||
basicMultiComponentMixture& composition = thermo.composition();
|
basicMultiComponentMixture& composition = thermo.composition();
|
||||||
PtrList<volScalarField>& Y = composition.Y();
|
PtrList<volScalarField>& Y = composition.Y();
|
||||||
|
|
||||||
word inertSpecie(thermo.lookup("inertSpecie"));
|
const word inertSpecie(thermo.lookup("inertSpecie"));
|
||||||
|
|
||||||
volScalarField& p = thermo.p();
|
volScalarField& p = thermo.p();
|
||||||
volScalarField& hs = thermo.hs();
|
volScalarField& hs = thermo.hs();
|
||||||
|
|||||||
@ -11,7 +11,7 @@
|
|||||||
basicMultiComponentMixture& composition = thermo.composition();
|
basicMultiComponentMixture& composition = thermo.composition();
|
||||||
PtrList<volScalarField>& Y = composition.Y();
|
PtrList<volScalarField>& Y = composition.Y();
|
||||||
|
|
||||||
word inertSpecie(thermo.lookup("inertSpecie"));
|
const word inertSpecie(thermo.lookup("inertSpecie"));
|
||||||
|
|
||||||
if (!composition.contains(inertSpecie))
|
if (!composition.contains(inertSpecie))
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
interPhaseChangeFoam.C
|
interPhaseChangeFoam.C
|
||||||
phaseChangeTwoPhaseMixtures/phaseChangeTwoPhaseMixture/phaseChangeTwoPhaseMixture.C
|
phaseChangeTwoPhaseMixtures/phaseChangeTwoPhaseMixture/phaseChangeTwoPhaseMixture.C
|
||||||
phaseChangeTwoPhaseMixtures/phaseChangeTwoPhaseMixture/newPhaseChangeTwoPhaseMixture.C
|
phaseChangeTwoPhaseMixtures/phaseChangeTwoPhaseMixture/phaseChangeTwoPhaseMixtureNew.C
|
||||||
phaseChangeTwoPhaseMixtures/Kunz/Kunz.C
|
phaseChangeTwoPhaseMixtures/Kunz/Kunz.C
|
||||||
phaseChangeTwoPhaseMixtures/Merkle/Merkle.C
|
phaseChangeTwoPhaseMixtures/Merkle/Merkle.C
|
||||||
phaseChangeTwoPhaseMixtures/SchnerrSauer/SchnerrSauer.C
|
phaseChangeTwoPhaseMixtures/SchnerrSauer/SchnerrSauer.C
|
||||||
|
|||||||
@ -28,7 +28,7 @@ Description
|
|||||||
|
|
||||||
SourceFiles
|
SourceFiles
|
||||||
phaseChangeTwoPhaseMixture.C
|
phaseChangeTwoPhaseMixture.C
|
||||||
newPhaseChangeModel.C
|
phaseChangeModelNew.C
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
|||||||
@ -36,30 +36,27 @@ Foam::phaseChangeTwoPhaseMixture::New
|
|||||||
const word& alpha1Name
|
const word& alpha1Name
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
IOdictionary transportPropertiesDict
|
// get model name, but do not register the dictionary
|
||||||
|
const word mixtureType
|
||||||
(
|
(
|
||||||
IOobject
|
IOdictionary
|
||||||
(
|
(
|
||||||
"transportProperties",
|
IOobject
|
||||||
U.time().constant(),
|
(
|
||||||
U.db(),
|
"transportProperties",
|
||||||
IOobject::MUST_READ,
|
U.time().constant(),
|
||||||
IOobject::NO_WRITE,
|
U.db(),
|
||||||
false
|
IOobject::MUST_READ,
|
||||||
)
|
IOobject::NO_WRITE,
|
||||||
|
false
|
||||||
|
)
|
||||||
|
).lookup("phaseChangeTwoPhaseMixture")
|
||||||
);
|
);
|
||||||
|
|
||||||
word phaseChangeTwoPhaseMixtureTypeName
|
Info<< "Selecting phaseChange model " << mixtureType << endl;
|
||||||
(
|
|
||||||
transportPropertiesDict.lookup("phaseChangeTwoPhaseMixture")
|
|
||||||
);
|
|
||||||
|
|
||||||
Info<< "Selecting phaseChange model "
|
|
||||||
<< phaseChangeTwoPhaseMixtureTypeName << endl;
|
|
||||||
|
|
||||||
componentsConstructorTable::iterator cstrIter =
|
componentsConstructorTable::iterator cstrIter =
|
||||||
componentsConstructorTablePtr_
|
componentsConstructorTablePtr_->find(mixtureType);
|
||||||
->find(phaseChangeTwoPhaseMixtureTypeName);
|
|
||||||
|
|
||||||
if (cstrIter == componentsConstructorTablePtr_->end())
|
if (cstrIter == componentsConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
@ -67,8 +64,8 @@ Foam::phaseChangeTwoPhaseMixture::New
|
|||||||
(
|
(
|
||||||
"phaseChangeTwoPhaseMixture::New"
|
"phaseChangeTwoPhaseMixture::New"
|
||||||
) << "Unknown phaseChangeTwoPhaseMixture type "
|
) << "Unknown phaseChangeTwoPhaseMixture type "
|
||||||
<< phaseChangeTwoPhaseMixtureTypeName << endl << endl
|
<< mixtureType << nl << nl
|
||||||
<< "Valid phaseChangeTwoPhaseMixtures are : " << endl
|
<< "Valid phaseChangeTwoPhaseMixture types are : " << endl
|
||||||
<< componentsConstructorTablePtr_->sortedToc()
|
<< componentsConstructorTablePtr_->sortedToc()
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
@ -50,7 +50,7 @@ Istream& operator>>
|
|||||||
alphaContactAngleFvPatchScalarField::interfaceThetaProps& tp
|
alphaContactAngleFvPatchScalarField::interfaceThetaProps& tp
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
is >> tp.theta0_ >> tp.uTheta_ >> tp.thetaA_ >> tp.thetaR_;
|
is >> tp.theta0_ >> tp.uTheta_ >> tp.thetaA_ >> tp.thetaR_;
|
||||||
return is;
|
return is;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -159,7 +159,7 @@
|
|||||||
|
|
||||||
Info<< "Selecting Drift-Flux model " << endl;
|
Info<< "Selecting Drift-Flux model " << endl;
|
||||||
|
|
||||||
word VdjModel(transportProperties.lookup("VdjModel"));
|
const word VdjModel(transportProperties.lookup("VdjModel"));
|
||||||
|
|
||||||
Info<< tab << VdjModel << " selected\n" << endl;
|
Info<< tab << VdjModel << " selected\n" << endl;
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
dragModels/dragModel/dragModel.C
|
dragModels/dragModel/dragModel.C
|
||||||
dragModels/dragModel/newDragModel.C
|
dragModels/dragModel/dragModelNew.C
|
||||||
dragModels/Ergun/Ergun.C
|
dragModels/Ergun/Ergun.C
|
||||||
dragModels/GidaspowErgunWenYu/GidaspowErgunWenYu.C
|
dragModels/GidaspowErgunWenYu/GidaspowErgunWenYu.C
|
||||||
dragModels/GidaspowSchillerNaumann/GidaspowSchillerNaumann.C
|
dragModels/GidaspowSchillerNaumann/GidaspowSchillerNaumann.C
|
||||||
|
|||||||
@ -28,7 +28,7 @@ Description
|
|||||||
|
|
||||||
SourceFiles
|
SourceFiles
|
||||||
dragModel.C
|
dragModel.C
|
||||||
newDragModel.C
|
dragModelNew.C
|
||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
|||||||
@ -35,28 +35,24 @@ Foam::autoPtr<Foam::dragModel> Foam::dragModel::New
|
|||||||
const phaseModel& phaseb
|
const phaseModel& phaseb
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word dragModelType
|
const word modelType(interfaceDict.lookup("dragModel" + phasea.name()));
|
||||||
(
|
|
||||||
interfaceDict.lookup("dragModel" + phasea.name())
|
|
||||||
);
|
|
||||||
|
|
||||||
Info<< "Selecting dragModel for phase "
|
Info<< "Selecting dragModel for phase " << phasea.name()
|
||||||
<< phasea.name()
|
<< ": " << modelType << endl;
|
||||||
<< ": "
|
|
||||||
<< dragModelType << endl;
|
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(dragModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalError
|
FatalErrorIn
|
||||||
<< "dragModel::New : " << endl
|
(
|
||||||
<< " unknown dragModelType type "
|
"dragModel::New(...)"
|
||||||
<< dragModelType
|
) << "Unknown dragModel type "
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< modelType << nl << nl
|
||||||
<< " Valid dragModel types are : " << endl;
|
<< "Valid dragModel types are : " << endl
|
||||||
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return cstrIter()(interfaceDict, alpha, phasea, phaseb);
|
return cstrIter()(interfaceDict, alpha, phasea, phaseb);
|
||||||
@ -1,32 +1,32 @@
|
|||||||
kineticTheoryModel/kineticTheoryModel.C
|
kineticTheoryModel/kineticTheoryModel.C
|
||||||
|
|
||||||
viscosityModel/viscosityModel/viscosityModel.C
|
viscosityModel/viscosityModel/viscosityModel.C
|
||||||
viscosityModel/viscosityModel/newViscosityModel.C
|
viscosityModel/viscosityModel/viscosityModelNew.C
|
||||||
viscosityModel/Gidaspow/GidaspowViscosity.C
|
viscosityModel/Gidaspow/GidaspowViscosity.C
|
||||||
viscosityModel/Syamlal/SyamlalViscosity.C
|
viscosityModel/Syamlal/SyamlalViscosity.C
|
||||||
viscosityModel/HrenyaSinclair/HrenyaSinclairViscosity.C
|
viscosityModel/HrenyaSinclair/HrenyaSinclairViscosity.C
|
||||||
viscosityModel/none/noneViscosity.C
|
viscosityModel/none/noneViscosity.C
|
||||||
|
|
||||||
conductivityModel/conductivityModel/conductivityModel.C
|
conductivityModel/conductivityModel/conductivityModel.C
|
||||||
conductivityModel/conductivityModel/newConductivityModel.C
|
conductivityModel/conductivityModel/conductivityModelNew.C
|
||||||
conductivityModel/Gidaspow/GidaspowConductivity.C
|
conductivityModel/Gidaspow/GidaspowConductivity.C
|
||||||
conductivityModel/Syamlal/SyamlalConductivity.C
|
conductivityModel/Syamlal/SyamlalConductivity.C
|
||||||
conductivityModel/HrenyaSinclair/HrenyaSinclairConductivity.C
|
conductivityModel/HrenyaSinclair/HrenyaSinclairConductivity.C
|
||||||
|
|
||||||
radialModel/radialModel/radialModel.C
|
radialModel/radialModel/radialModel.C
|
||||||
radialModel/radialModel/newRadialModel.C
|
radialModel/radialModel/radialModelNew.C
|
||||||
radialModel/CarnahanStarling/CarnahanStarlingRadial.C
|
radialModel/CarnahanStarling/CarnahanStarlingRadial.C
|
||||||
radialModel/Gidaspow/GidaspowRadial.C
|
radialModel/Gidaspow/GidaspowRadial.C
|
||||||
radialModel/LunSavage/LunSavageRadial.C
|
radialModel/LunSavage/LunSavageRadial.C
|
||||||
radialModel/SinclairJackson/SinclairJacksonRadial.C
|
radialModel/SinclairJackson/SinclairJacksonRadial.C
|
||||||
|
|
||||||
granularPressureModel/granularPressureModel/granularPressureModel.C
|
granularPressureModel/granularPressureModel/granularPressureModel.C
|
||||||
granularPressureModel/granularPressureModel/newGranularPressureModel.C
|
granularPressureModel/granularPressureModel/granularPressureModelNew.C
|
||||||
granularPressureModel/Lun/LunPressure.C
|
granularPressureModel/Lun/LunPressure.C
|
||||||
granularPressureModel/SyamlalRogersOBrien/SyamlalRogersOBrienPressure.C
|
granularPressureModel/SyamlalRogersOBrien/SyamlalRogersOBrienPressure.C
|
||||||
|
|
||||||
frictionalStressModel/frictionalStressModel/frictionalStressModel.C
|
frictionalStressModel/frictionalStressModel/frictionalStressModel.C
|
||||||
frictionalStressModel/frictionalStressModel/newFrictionalStressModel.C
|
frictionalStressModel/frictionalStressModel/frictionalStressModelNew.C
|
||||||
frictionalStressModel/JohnsonJackson/JohnsonJacksonFrictionalStress.C
|
frictionalStressModel/JohnsonJackson/JohnsonJacksonFrictionalStress.C
|
||||||
frictionalStressModel/Schaeffer/SchaefferFrictionalStress.C
|
frictionalStressModel/Schaeffer/SchaefferFrictionalStress.C
|
||||||
|
|
||||||
|
|||||||
@ -32,23 +32,23 @@ Foam::autoPtr<Foam::conductivityModel> Foam::conductivityModel::New
|
|||||||
const dictionary& dict
|
const dictionary& dict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word conductivityModelType(dict.lookup("conductivityModel"));
|
const word modelType(dict.lookup("conductivityModel"));
|
||||||
|
|
||||||
Info<< "Selecting conductivityModel "
|
Info<< "Selecting conductivityModel " << modelType << endl;
|
||||||
<< conductivityModelType << endl;
|
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(conductivityModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalError
|
FatalErrorIn
|
||||||
<< "conductivityModel::New(const dictionary&) : " << endl
|
(
|
||||||
<< " unknown conductivityModelType type "
|
"conductivityModel::New(const dictionary&)"
|
||||||
<< conductivityModelType
|
) << "Unknown conductivityModel type "
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< modelType << nl << nl
|
||||||
<< " Valid conductivityModelType types are :" << endl;
|
<< "Valid conductivityModel types are :" << endl
|
||||||
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<conductivityModel>(cstrIter()(dict));
|
return autoPtr<conductivityModel>(cstrIter()(dict));
|
||||||
@ -32,23 +32,24 @@ Foam::autoPtr<Foam::frictionalStressModel> Foam::frictionalStressModel::New
|
|||||||
const dictionary& dict
|
const dictionary& dict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word frictionalStressModelType(dict.lookup("frictionalStressModel"));
|
const word modelType(dict.lookup("frictionalStressModel"));
|
||||||
|
|
||||||
Info<< "Selecting frictionalStressModel "
|
Info<< "Selecting frictionalStressModel " << modelType << endl;
|
||||||
<< frictionalStressModelType << endl;
|
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(frictionalStressModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalError
|
FatalErrorIn
|
||||||
<< "frictionalStressModel::New(const dictionary&) : " << endl
|
(
|
||||||
<< " unknown frictionalStressModelType type "
|
"frictionalStressModel::New(const dictionary&)"
|
||||||
<< frictionalStressModelType
|
)
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< "Unknown frictionalStressModel type "
|
||||||
<< " Valid frictionalStressModelType types are :" << endl;
|
<< modelType << nl << nl
|
||||||
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
<< "Valid frictionalStressModel types are :" << endl
|
||||||
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<frictionalStressModel>(cstrIter()(dict));
|
return autoPtr<frictionalStressModel>(cstrIter()(dict));
|
||||||
@ -32,23 +32,23 @@ Foam::autoPtr<Foam::granularPressureModel> Foam::granularPressureModel::New
|
|||||||
const dictionary& dict
|
const dictionary& dict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word granularPressureModelType(dict.lookup("granularPressureModel"));
|
const word modelType(dict.lookup("granularPressureModel"));
|
||||||
|
|
||||||
Info<< "Selecting granularPressureModel "
|
Info<< "Selecting granularPressureModel " << modelType << endl;
|
||||||
<< granularPressureModelType << endl;
|
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(granularPressureModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalError
|
FatalErrorIn
|
||||||
<< "granularPressureModel::New(const dictionary&) : " << endl
|
(
|
||||||
<< " unknown granularPressureModelType type "
|
"granularPressureModel::New(const dictionary&)"
|
||||||
<< granularPressureModelType
|
) << "Unknown granularPressureModel type "
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< modelType << nl << nl
|
||||||
<< " Valid granularPressureModelType types are :" << endl;
|
<< "Valid granularPressureModel types are :" << endl
|
||||||
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<granularPressureModel>(cstrIter()(dict));
|
return autoPtr<granularPressureModel>(cstrIter()(dict));
|
||||||
@ -32,23 +32,24 @@ Foam::autoPtr<Foam::radialModel> Foam::radialModel::New
|
|||||||
const dictionary& dict
|
const dictionary& dict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word radialModelType(dict.lookup("radialModel"));
|
const word modelType(dict.lookup("radialModel"));
|
||||||
|
|
||||||
Info<< "Selecting radialModel "
|
Info<< "Selecting radialModel " << modelType << endl;
|
||||||
<< radialModelType << endl;
|
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(radialModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalError
|
FatalErrorIn
|
||||||
<< "radialModel::New(const dictionary&) : " << endl
|
(
|
||||||
<< " unknown radialModelType type "
|
"radialModel::New(const dictionary&)"
|
||||||
<< radialModelType
|
)
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< "Unknown radialModel type "
|
||||||
<< " Valid radialModelType types are :" << endl;
|
<< modelType << nl << nl
|
||||||
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
<< "Valid radialModel types are :" << endl
|
||||||
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<radialModel>(cstrIter()(dict));
|
return autoPtr<radialModel>(cstrIter()(dict));
|
||||||
@ -33,23 +33,23 @@ Foam::kineticTheoryModels::viscosityModel::New
|
|||||||
const dictionary& dict
|
const dictionary& dict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word viscosityModelType(dict.lookup("viscosityModel"));
|
const word modelType(dict.lookup("viscosityModel"));
|
||||||
|
|
||||||
Info<< "Selecting viscosityModel "
|
Info<< "Selecting viscosityModel " << modelType << endl;
|
||||||
<< viscosityModelType << endl;
|
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(viscosityModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalError
|
FatalErrorIn
|
||||||
<< "viscosityModel::New(const dictionary&) : " << endl
|
(
|
||||||
<< " unknown viscosityModelType type "
|
"viscosityModel::New(const dictionary&)"
|
||||||
<< viscosityModelType
|
) << "Unknown viscosityModel type "
|
||||||
<< ", constructor not in hash table" << endl << endl
|
<< modelType << nl << nl
|
||||||
<< " Valid viscosityModelType types are :" << endl;
|
<< "Valid viscosityModel types are :" << endl
|
||||||
Info<< dictionaryConstructorTablePtr_->sortedToc() << abort(FatalError);
|
<< dictionaryConstructorTablePtr_->sortedToc()
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|
||||||
return autoPtr<viscosityModel>(cstrIter()(dict));
|
return autoPtr<viscosityModel>(cstrIter()(dict));
|
||||||
@ -59,7 +59,7 @@ public:
|
|||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const ent& e)
|
friend Ostream& operator<<(Ostream& os, const ent& e)
|
||||||
{
|
{
|
||||||
os << e.keyword_ << ' ' << e.i_ << endl;
|
os << e.keyword_ << ' ' << e.i_ << endl;
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@ -88,7 +88,7 @@ public:
|
|||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const Scalar& val)
|
friend Ostream& operator<<(Ostream& os, const Scalar& val)
|
||||||
{
|
{
|
||||||
os << val.data_;
|
os << val.data_;
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -38,7 +38,7 @@ public:
|
|||||||
|
|
||||||
friend std::ostream& operator<<(std::ostream& os, const Vector<C>& v)
|
friend std::ostream& operator<<(std::ostream& os, const Vector<C>& v)
|
||||||
{
|
{
|
||||||
os << v.X << '\t' << v.Y << '\n';
|
os << v.X << '\t' << v.Y << '\n';
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -89,7 +89,7 @@ int main()
|
|||||||
|
|
||||||
{
|
{
|
||||||
OStringStream os;
|
OStringStream os;
|
||||||
os << table1;
|
os << table1;
|
||||||
HASHTABLE_CLASS<double> readTable(IStringStream(os.str())(), 100);
|
HASHTABLE_CLASS<double> readTable(IStringStream(os.str())(), 100);
|
||||||
|
|
||||||
Info<< "Istream constructor:" << readTable << endl;
|
Info<< "Istream constructor:" << readTable << endl;
|
||||||
|
|||||||
@ -54,7 +54,7 @@ public:
|
|||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const Scalar& s)
|
friend Ostream& operator<<(Ostream& os, const Scalar& s)
|
||||||
{
|
{
|
||||||
os << s.data_;
|
os << s.data_;
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -60,7 +60,7 @@ public:
|
|||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const Scalar& val)
|
friend Ostream& operator<<(Ostream& os, const Scalar& val)
|
||||||
{
|
{
|
||||||
os << val.data_;
|
os << val.data_;
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -83,7 +83,7 @@ int main()
|
|||||||
|
|
||||||
{
|
{
|
||||||
OStringStream os;
|
OStringStream os;
|
||||||
os << table1;
|
os << table1;
|
||||||
HASHTABLE_CLASS<double> readTable(IStringStream(os.str())(), 100);
|
HASHTABLE_CLASS<double> readTable(IStringStream(os.str())(), 100);
|
||||||
|
|
||||||
Info<< "Istream constructor:" << readTable << endl;
|
Info<< "Istream constructor:" << readTable << endl;
|
||||||
|
|||||||
@ -56,7 +56,7 @@ public:
|
|||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const ent& e)
|
friend Ostream& operator<<(Ostream& os, const ent& e)
|
||||||
{
|
{
|
||||||
os << e.keyword_ << ' ' << e.i_ << endl;
|
os << e.keyword_ << ' ' << e.i_ << endl;
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1,4 +1,3 @@
|
|||||||
globalIndex.C
|
|
||||||
globalIndexTest.C
|
globalIndexTest.C
|
||||||
|
|
||||||
EXE = $(FOAM_USER_APPBIN)/globalIndexTest
|
EXE = $(FOAM_USER_APPBIN)/globalIndexTest
|
||||||
|
|||||||
@ -108,13 +108,17 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
List<wallPoint> allFaceInfo(mesh.nFaces());
|
||||||
|
List<wallPoint> allCellInfo(mesh.nCells());
|
||||||
|
|
||||||
MeshWave<wallPoint> wallDistCalc
|
FaceCellWave<wallPoint> wallDistCalc
|
||||||
(
|
(
|
||||||
mesh,
|
mesh,
|
||||||
changedFaces,
|
changedFaces,
|
||||||
faceDist,
|
faceDist,
|
||||||
0 // max iterations
|
allFaceInfo,
|
||||||
|
allCellInfo,
|
||||||
|
0 // max iterations
|
||||||
);
|
);
|
||||||
|
|
||||||
Info<< "\nStarting time loop\n" << endl;
|
Info<< "\nStarting time loop\n" << endl;
|
||||||
@ -148,16 +152,13 @@ int main(int argc, char *argv[])
|
|||||||
// Copy face and cell values into field
|
// Copy face and cell values into field
|
||||||
//
|
//
|
||||||
|
|
||||||
const List<wallPoint>& cellInfo = wallDistCalc.allCellInfo();
|
|
||||||
const List<wallPoint>& faceInfo = wallDistCalc.allFaceInfo();
|
|
||||||
|
|
||||||
label nIllegal = 0;
|
label nIllegal = 0;
|
||||||
|
|
||||||
// Copy cell values
|
// Copy cell values
|
||||||
forAll(cellInfo, cellI)
|
forAll(allCellInfo, cellI)
|
||||||
{
|
{
|
||||||
scalar dist = cellInfo[cellI].distSqr();
|
scalar dist = allCellInfo[cellI].distSqr();
|
||||||
if (cellInfo[cellI].valid())
|
if (allCellInfo[cellI].valid())
|
||||||
{
|
{
|
||||||
wallDistUncorrected[cellI] = Foam::sqrt(dist);
|
wallDistUncorrected[cellI] = Foam::sqrt(dist);
|
||||||
}
|
}
|
||||||
@ -176,11 +177,10 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
forAll(patchField, patchFaceI)
|
forAll(patchField, patchFaceI)
|
||||||
{
|
{
|
||||||
label meshFaceI =
|
const label meshFaceI = patchField.patch().start() + patchFaceI;
|
||||||
patchField.patch().patch().start() + patchFaceI;
|
|
||||||
|
|
||||||
scalar dist = faceInfo[meshFaceI].distSqr();
|
scalar dist = allFaceInfo[meshFaceI].distSqr();
|
||||||
if (faceInfo[meshFaceI].valid())
|
if (allFaceInfo[meshFaceI].valid())
|
||||||
{
|
{
|
||||||
patchField[patchFaceI] = Foam::sqrt(dist);
|
patchField[patchFaceI] = Foam::sqrt(dist);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -47,8 +47,7 @@ void writeObj(Ostream& os,const pointField& points)
|
|||||||
{
|
{
|
||||||
const point& pt = points[pointI];
|
const point& pt = points[pointI];
|
||||||
|
|
||||||
os << "v " << pt.x() << ' ' << pt.y()
|
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << endl;
|
||||||
<< ' ' << pt.z() << endl;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -92,14 +92,14 @@ int main(int argc, char * argv[])
|
|||||||
{
|
{
|
||||||
OSHA1stream os;
|
OSHA1stream os;
|
||||||
|
|
||||||
os << str;
|
os << str;
|
||||||
Info<< os.digest() << endl;
|
Info<< os.digest() << endl;
|
||||||
|
|
||||||
os << str;
|
os << str;
|
||||||
Info<< os.digest() << endl;
|
Info<< os.digest() << endl;
|
||||||
|
|
||||||
os.rewind();
|
os.rewind();
|
||||||
os << "The quick brown fox jumps over the lazy dog";
|
os << "The quick brown fox jumps over the lazy dog";
|
||||||
Info<< os.digest() << endl;
|
Info<< os.digest() << endl;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -110,9 +110,9 @@ const labelListListList& block::boundaryPatches() const
|
|||||||
|
|
||||||
Ostream& operator<<(Ostream& os, const block& b)
|
Ostream& operator<<(Ostream& os, const block& b)
|
||||||
{
|
{
|
||||||
os << b.Vertices << nl
|
os << b.Vertices << nl
|
||||||
<< b.Cells << nl
|
<< b.Cells << nl
|
||||||
<< b.BoundaryPatches << endl;
|
<< b.BoundaryPatches << endl;
|
||||||
|
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -57,7 +57,7 @@ void hexBlock::readPoints(Istream& is)
|
|||||||
{
|
{
|
||||||
forAll(points_, i)
|
forAll(points_, i)
|
||||||
{
|
{
|
||||||
is >> points_[i].x() >> points_[i].y() >> points_[i].z();
|
is >> points_[i].x() >> points_[i].y() >> points_[i].z();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Calculate the handedness of the block
|
// Calculate the handedness of the block
|
||||||
|
|||||||
@ -128,13 +128,13 @@ void hexBlock::readPoints
|
|||||||
Info<< "Reading " << nPoints << " x coordinates..." << endl;
|
Info<< "Reading " << nPoints << " x coordinates..." << endl;
|
||||||
for (label i=0; i < nPoints; i++)
|
for (label i=0; i < nPoints; i++)
|
||||||
{
|
{
|
||||||
is >> points_[i].x();
|
is >> points_[i].x();
|
||||||
}
|
}
|
||||||
|
|
||||||
Info<< "Reading " << nPoints << " y coordinates..." << endl;
|
Info<< "Reading " << nPoints << " y coordinates..." << endl;
|
||||||
for (label i=0; i < nPoints; i++)
|
for (label i=0; i < nPoints; i++)
|
||||||
{
|
{
|
||||||
is >> points_[i].y();
|
is >> points_[i].y();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (twoDThicknes > 0)
|
if (twoDThicknes > 0)
|
||||||
@ -156,7 +156,7 @@ void hexBlock::readPoints
|
|||||||
Info<< "Reading " << nPoints << " z coordinates..." << endl;
|
Info<< "Reading " << nPoints << " z coordinates..." << endl;
|
||||||
for (label i=0; i < nPoints; i++)
|
for (label i=0; i < nPoints; i++)
|
||||||
{
|
{
|
||||||
is >> points_[i].z();
|
is >> points_[i].z();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -166,7 +166,7 @@ void hexBlock::readPoints
|
|||||||
Info<< "Reading " << nPoints << " blanks..." << endl;
|
Info<< "Reading " << nPoints << " blanks..." << endl;
|
||||||
for (label i=0; i < nPoints; i++)
|
for (label i=0; i < nPoints; i++)
|
||||||
{
|
{
|
||||||
is >> iBlank;
|
is >> iBlank;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -166,7 +166,9 @@ void starMesh::markBoundaryFaces()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FatalError << " $ bset,add,vset,all" << abort(FatalError);
|
FatalError
|
||||||
|
<< " $ bset,add,vset,all"
|
||||||
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -51,7 +51,7 @@ using namespace Foam;
|
|||||||
|
|
||||||
void writeOBJ(const point& pt, Ostream& os)
|
void writeOBJ(const point& pt, Ostream& os)
|
||||||
{
|
{
|
||||||
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << nl;
|
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << nl;
|
||||||
}
|
}
|
||||||
|
|
||||||
// All edges of mesh
|
// All edges of mesh
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
extrudeModel/extrudeModel.C
|
extrudeModel/extrudeModel.C
|
||||||
extrudeModel/newExtrudeModel.C
|
extrudeModel/extrudeModelNew.C
|
||||||
linearNormal/linearNormal.C
|
linearNormal/linearNormal.C
|
||||||
linearDirection/linearDirection.C
|
linearDirection/linearDirection.C
|
||||||
linearRadial/linearRadial.C
|
linearRadial/linearRadial.C
|
||||||
|
|||||||
@ -32,20 +32,21 @@ Foam::autoPtr<Foam::extrudeModel> Foam::extrudeModel::New
|
|||||||
const dictionary& dict
|
const dictionary& dict
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
word extrudeModelType(dict.lookup("extrudeModel"));
|
const word modelType(dict.lookup("extrudeModel"));
|
||||||
|
|
||||||
Info<< "Selecting extrudeModel " << extrudeModelType << endl;
|
Info<< "Selecting extrudeModel " << modelType << endl;
|
||||||
|
|
||||||
dictionaryConstructorTable::iterator cstrIter =
|
dictionaryConstructorTable::iterator cstrIter =
|
||||||
dictionaryConstructorTablePtr_->find(extrudeModelType);
|
dictionaryConstructorTablePtr_->find(modelType);
|
||||||
|
|
||||||
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
if (cstrIter == dictionaryConstructorTablePtr_->end())
|
||||||
{
|
{
|
||||||
FatalErrorIn("extrudeModel::New(const dictionary&)")
|
FatalErrorIn
|
||||||
<< "Unknown extrudeModelType type "
|
(
|
||||||
<< extrudeModelType
|
"extrudeModel::New(const dictionary&)"
|
||||||
<< ", constructor not in hash table" << nl << nl
|
) << "Unknown extrudeModel type "
|
||||||
<< " Valid extrudeModel types are :" << nl
|
<< modelType << nl << nl
|
||||||
|
<< "Valid extrudeModel types are :" << nl
|
||||||
<< dictionaryConstructorTablePtr_->sortedToc() << nl
|
<< dictionaryConstructorTablePtr_->sortedToc() << nl
|
||||||
<< exit(FatalError);
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
@ -55,4 +56,3 @@ Foam::autoPtr<Foam::extrudeModel> Foam::extrudeModel::New
|
|||||||
|
|
||||||
|
|
||||||
// ************************************************************************* //
|
// ************************************************************************* //
|
||||||
|
|
||||||
@ -58,7 +58,7 @@ Foam::Ostream& Foam::operator<<
|
|||||||
|
|
||||||
if (faceI != -1)
|
if (faceI != -1)
|
||||||
{
|
{
|
||||||
os<< " fc:" << c.patch_.localFaces()[faceI].centre(pts);
|
os << " fc:" << c.patch_.localFaces()[faceI].centre(pts);
|
||||||
}
|
}
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -233,7 +233,7 @@ void Foam::patchPointEdgeCirculator::setCanonical()
|
|||||||
|
|
||||||
|
|
||||||
//- Step to next edge.
|
//- Step to next edge.
|
||||||
Foam::patchPointEdgeCirculator::patchPointEdgeCirculator&
|
Foam::patchPointEdgeCirculator&
|
||||||
Foam::patchPointEdgeCirculator::operator++()
|
Foam::patchPointEdgeCirculator::operator++()
|
||||||
{
|
{
|
||||||
if (index_ == -1)
|
if (index_ == -1)
|
||||||
|
|||||||
@ -59,9 +59,8 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
word setName(cellSetDict.lookup("name"));
|
const word setName(cellSetDict.lookup("name"));
|
||||||
|
const word actionName(cellSetDict.lookup("action"));
|
||||||
word actionName(cellSetDict.lookup("action"));
|
|
||||||
|
|
||||||
topoSetSource::setAction action = topoSetSource::toAction(actionName);
|
topoSetSource::setAction action = topoSetSource::toAction(actionName);
|
||||||
|
|
||||||
|
|||||||
@ -59,9 +59,8 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
word setName(faceSetDict.lookup("name"));
|
const word setName(faceSetDict.lookup("name"));
|
||||||
|
const word actionName(faceSetDict.lookup("action"));
|
||||||
word actionName(faceSetDict.lookup("action"));
|
|
||||||
|
|
||||||
topoSetSource::setAction action = topoSetSource::toAction(actionName);
|
topoSetSource::setAction action = topoSetSource::toAction(actionName);
|
||||||
|
|
||||||
|
|||||||
@ -43,7 +43,7 @@ int main(int argc, char *argv[])
|
|||||||
# include "createTime.H"
|
# include "createTime.H"
|
||||||
# include "createMesh.H"
|
# include "createMesh.H"
|
||||||
|
|
||||||
autoPtr<Foam::motionSolver> motionPtr = motionSolver::New(mesh);
|
autoPtr<motionSolver> motionPtr = motionSolver::New(mesh);
|
||||||
|
|
||||||
while (runTime.loop())
|
while (runTime.loop())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -113,7 +113,7 @@ int main(int argc, char *argv[])
|
|||||||
argList::validArgs.clear();
|
argList::validArgs.clear();
|
||||||
argList::validArgs.append("OBJ file");
|
argList::validArgs.append("OBJ file");
|
||||||
argList::validArgs.append("output VTK file");
|
argList::validArgs.append("output VTK file");
|
||||||
argList::argList args(argc, argv);
|
argList args(argc, argv);
|
||||||
|
|
||||||
const fileName objName = args[1];
|
const fileName objName = args[1];
|
||||||
const fileName outName = args[2];
|
const fileName outName = args[2];
|
||||||
|
|||||||
@ -59,9 +59,8 @@ int main(int argc, char *argv[])
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
word setName(pointSetDict.lookup("name"));
|
const word setName(pointSetDict.lookup("name"));
|
||||||
|
const word actionName(pointSetDict.lookup("action"));
|
||||||
word actionName(pointSetDict.lookup("action"));
|
|
||||||
|
|
||||||
topoSetSource::setAction action = topoSetSource::toAction(actionName);
|
topoSetSource::setAction action = topoSetSource::toAction(actionName);
|
||||||
|
|
||||||
|
|||||||
@ -331,7 +331,7 @@ int main(int argc, char *argv[])
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
word setName(refineDict.lookup("set"));
|
const word setName(refineDict.lookup("set"));
|
||||||
|
|
||||||
cellSet cells(mesh, setName);
|
cellSet cells(mesh, setName);
|
||||||
|
|
||||||
|
|||||||
@ -974,7 +974,7 @@ int main(int argc, char *argv[])
|
|||||||
IStringStream is(rawLine + ' ');
|
IStringStream is(rawLine + ' ');
|
||||||
|
|
||||||
// Type: cellSet, faceSet, pointSet, faceZoneSet
|
// Type: cellSet, faceSet, pointSet, faceZoneSet
|
||||||
is >> setType;
|
is >> setType;
|
||||||
|
|
||||||
stat = parseType(runTime, mesh, setType, is);
|
stat = parseType(runTime, mesh, setType, is);
|
||||||
|
|
||||||
|
|||||||
@ -85,20 +85,20 @@ void Foam::writeFuns::write
|
|||||||
fField.size()*sizeof(float)
|
fField.size()*sizeof(float)
|
||||||
);
|
);
|
||||||
|
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
forAll(fField, i)
|
forAll(fField, i)
|
||||||
{
|
{
|
||||||
os << fField[i] << ' ';
|
os << fField[i] << ' ';
|
||||||
|
|
||||||
if (i > 0 && (i % 10) == 0)
|
if (i > 0 && (i % 10) == 0)
|
||||||
{
|
{
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -134,20 +134,20 @@ void Foam::writeFuns::write
|
|||||||
elems.size()*sizeof(label)
|
elems.size()*sizeof(label)
|
||||||
);
|
);
|
||||||
|
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
forAll(elems, i)
|
forAll(elems, i)
|
||||||
{
|
{
|
||||||
os << elems[i] << ' ';
|
os << elems[i] << ' ';
|
||||||
|
|
||||||
if (i > 0 && (i % 10) == 0)
|
if (i > 0 && (i % 10) == 0)
|
||||||
{
|
{
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -64,13 +64,13 @@ namespace Foam
|
|||||||
|
|
||||||
|
|
||||||
// Hack to do zones which have Lists in them. See above.
|
// Hack to do zones which have Lists in them. See above.
|
||||||
bool writeZones(const word& name, Time& runTime)
|
bool writeZones(const word& name, const fileName& meshDir, Time& runTime)
|
||||||
{
|
{
|
||||||
IOobject io
|
IOobject io
|
||||||
(
|
(
|
||||||
name,
|
name,
|
||||||
runTime.timeName(),
|
runTime.timeName(),
|
||||||
polyMesh::meshSubDir,
|
meshDir,
|
||||||
runTime,
|
runTime,
|
||||||
IOobject::MUST_READ,
|
IOobject::MUST_READ,
|
||||||
IOobject::NO_WRITE,
|
IOobject::NO_WRITE,
|
||||||
@ -144,8 +144,20 @@ bool writeZones(const word& name, Time& runTime)
|
|||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
timeSelector::addOptions();
|
timeSelector::addOptions();
|
||||||
|
# include "addRegionOption.H"
|
||||||
# include "setRootCase.H"
|
# include "setRootCase.H"
|
||||||
# include "createTime.H"
|
# include "createTime.H"
|
||||||
|
|
||||||
|
fileName meshDir = polyMesh::meshSubDir;
|
||||||
|
fileName regionPrefix = "";
|
||||||
|
word regionName = polyMesh::defaultRegion;
|
||||||
|
if (args.optionReadIfPresent("region", regionName))
|
||||||
|
{
|
||||||
|
Info<< "Using region " << regionName << nl << endl;
|
||||||
|
regionPrefix = regionName;
|
||||||
|
meshDir = regionName/polyMesh::meshSubDir;
|
||||||
|
}
|
||||||
|
|
||||||
Foam::instantList timeDirs = Foam::timeSelector::select0(runTime, args);
|
Foam::instantList timeDirs = Foam::timeSelector::select0(runTime, args);
|
||||||
|
|
||||||
forAll(timeDirs, timeI)
|
forAll(timeDirs, timeI)
|
||||||
@ -154,27 +166,32 @@ int main(int argc, char *argv[])
|
|||||||
Info<< "Time = " << runTime.timeName() << endl;
|
Info<< "Time = " << runTime.timeName() << endl;
|
||||||
|
|
||||||
// Convert all the standard mesh files
|
// Convert all the standard mesh files
|
||||||
writeMeshObject<cellIOList>("cells", runTime);
|
writeMeshObject<cellIOList>("cells", meshDir, runTime);
|
||||||
writeMeshObject<labelIOList>("owner", runTime);
|
writeMeshObject<labelIOList>("owner", meshDir, runTime);
|
||||||
writeMeshObject<labelIOList>("neighbour", runTime);
|
writeMeshObject<labelIOList>("neighbour", meshDir, runTime);
|
||||||
writeMeshObject<faceIOList>("faces", runTime);
|
writeMeshObject<faceIOList>("faces", meshDir, runTime);
|
||||||
writeMeshObject<pointIOField>("points", runTime);
|
writeMeshObject<pointIOField>("points", meshDir, runTime);
|
||||||
writeMeshObject<labelIOList>("pointProcAddressing", runTime);
|
writeMeshObject<labelIOList>("pointProcAddressing", meshDir, runTime);
|
||||||
writeMeshObject<labelIOList>("faceProcAddressing", runTime);
|
writeMeshObject<labelIOList>("faceProcAddressing", meshDir, runTime);
|
||||||
writeMeshObject<labelIOList>("cellProcAddressing", runTime);
|
writeMeshObject<labelIOList>("cellProcAddressing", meshDir, runTime);
|
||||||
writeMeshObject<labelIOList>("boundaryProcAddressing", runTime);
|
writeMeshObject<labelIOList>
|
||||||
|
(
|
||||||
|
"boundaryProcAddressing",
|
||||||
|
meshDir,
|
||||||
|
runTime
|
||||||
|
);
|
||||||
|
|
||||||
if (runTime.writeFormat() == IOstream::ASCII)
|
if (runTime.writeFormat() == IOstream::ASCII)
|
||||||
{
|
{
|
||||||
// Only do zones when converting from binary to ascii
|
// Only do zones when converting from binary to ascii
|
||||||
// The other way gives problems since working on dictionary level.
|
// The other way gives problems since working on dictionary level.
|
||||||
writeZones("cellZones", runTime);
|
writeZones("cellZones", meshDir, runTime);
|
||||||
writeZones("faceZones", runTime);
|
writeZones("faceZones", meshDir, runTime);
|
||||||
writeZones("pointZones", runTime);
|
writeZones("pointZones", meshDir, runTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Get list of objects from the database
|
// Get list of objects from the database
|
||||||
IOobjectList objects(runTime, runTime.timeName());
|
IOobjectList objects(runTime, runTime.timeName(), regionPrefix);
|
||||||
|
|
||||||
forAllConstIter(IOobjectList, objects, iter)
|
forAllConstIter(IOobjectList, objects, iter)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -40,13 +40,18 @@ namespace Foam
|
|||||||
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
|
||||||
|
|
||||||
template<class T>
|
template<class T>
|
||||||
inline bool writeMeshObject(const word& name, Time& runTime)
|
inline bool writeMeshObject
|
||||||
|
(
|
||||||
|
const word& name,
|
||||||
|
const fileName& meshDir,
|
||||||
|
Time& runTime
|
||||||
|
)
|
||||||
{
|
{
|
||||||
IOobject io
|
IOobject io
|
||||||
(
|
(
|
||||||
name,
|
name,
|
||||||
runTime.timeName(),
|
runTime.timeName(),
|
||||||
polyMesh::meshSubDir,
|
meshDir,
|
||||||
runTime,
|
runTime,
|
||||||
IOobject::MUST_READ,
|
IOobject::MUST_READ,
|
||||||
IOobject::NO_WRITE,
|
IOobject::NO_WRITE,
|
||||||
|
|||||||
@ -153,9 +153,9 @@ int main(int argc, char *argv[])
|
|||||||
}
|
}
|
||||||
|
|
||||||
// get requested numberOfSubdomains
|
// get requested numberOfSubdomains
|
||||||
label nDomains = 0;
|
const label nDomains = readLabel
|
||||||
{
|
(
|
||||||
IOdictionary decompDict
|
IOdictionary
|
||||||
(
|
(
|
||||||
IOobject
|
IOobject
|
||||||
(
|
(
|
||||||
@ -167,10 +167,8 @@ int main(int argc, char *argv[])
|
|||||||
IOobject::NO_WRITE,
|
IOobject::NO_WRITE,
|
||||||
false
|
false
|
||||||
)
|
)
|
||||||
);
|
).lookup("numberOfSubdomains")
|
||||||
|
);
|
||||||
decompDict.lookup("numberOfSubdomains") >> nDomains;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (decomposeFieldsOnly)
|
if (decomposeFieldsOnly)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -72,14 +72,17 @@ labelList calcFaceAddressing
|
|||||||
<< " face labels:" << faces << endl
|
<< " face labels:" << faces << endl
|
||||||
<< " cellI:" << cellI << endl;
|
<< " cellI:" << cellI << endl;
|
||||||
|
|
||||||
FatalError << "Faces consist of vertices:" << endl;
|
FatalError
|
||||||
|
<< "Faces consist of vertices:" << endl;
|
||||||
|
|
||||||
forAll(faces, faceI)
|
forAll(faces, faceI)
|
||||||
{
|
{
|
||||||
FatalError
|
FatalError
|
||||||
<< " face:" << faces[faceI]
|
<< " face:" << faces[faceI]
|
||||||
<< allFaces[faces[faceI]] << endl;
|
<< allFaces[faces[faceI]] << endl;
|
||||||
}
|
}
|
||||||
FatalError << exit(FatalError);
|
FatalError
|
||||||
|
<< exit(FatalError);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return shapeToMesh;
|
return shapeToMesh;
|
||||||
|
|||||||
@ -85,12 +85,12 @@ void writeBytes(char* start, int nBytes)
|
|||||||
// Debug: write wall flags data
|
// Debug: write wall flags data
|
||||||
void writeWallFlags(Ostream& os, label cellI, const labelList& wallFlags)
|
void writeWallFlags(Ostream& os, label cellI, const labelList& wallFlags)
|
||||||
{
|
{
|
||||||
os << "cell " << cellI << " wallsFlags:";
|
os << "cell " << cellI << " wallsFlags:";
|
||||||
forAll(wallFlags, wallFaceI)
|
forAll(wallFlags, wallFaceI)
|
||||||
{
|
{
|
||||||
os << wallFlags[wallFaceI] << " ";
|
os << wallFlags[wallFaceI] << ' ';
|
||||||
}
|
}
|
||||||
os << endl;
|
os << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -28,7 +28,8 @@ word format
|
|||||||
|
|
||||||
if ((format != "ascii") && (format != "ieeei4r8"))
|
if ((format != "ascii") && (format != "ieeei4r8"))
|
||||||
{
|
{
|
||||||
FatalError << "format type: " << format << " unknown."
|
FatalError
|
||||||
|
<< "format type: " << format << " unknown."
|
||||||
<< " Valid options are: ascii ieeei4r8"
|
<< " Valid options are: ascii ieeei4r8"
|
||||||
<< abort(FatalError);
|
<< abort(FatalError);
|
||||||
|
|
||||||
@ -44,6 +45,7 @@ if
|
|||||||
(cells != "hex")
|
(cells != "hex")
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
FatalError << "cells type: " << cells << " unknown."
|
FatalError
|
||||||
|
<< "cells type: " << cells << " unknown."
|
||||||
<< abort(FatalError);
|
<< abort(FatalError);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -99,12 +99,12 @@ void print(const char* msg, Ostream& os, const PtrList<GeoField>& flds)
|
|||||||
{
|
{
|
||||||
if (flds.size())
|
if (flds.size())
|
||||||
{
|
{
|
||||||
os << msg;
|
os << msg;
|
||||||
forAll(flds, i)
|
forAll(flds, i)
|
||||||
{
|
{
|
||||||
os<< ' ' << flds[i].name();
|
os << ' ' << flds[i].name();
|
||||||
}
|
}
|
||||||
os << endl;
|
os << endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -113,9 +113,9 @@ void print(Ostream& os, const wordList& flds)
|
|||||||
{
|
{
|
||||||
forAll(flds, i)
|
forAll(flds, i)
|
||||||
{
|
{
|
||||||
os<< ' ' << flds[i];
|
os << ' ' << flds[i];
|
||||||
}
|
}
|
||||||
os << endl;
|
os << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -163,12 +163,12 @@ void print(const char* msg, Ostream& os, const PtrList<GeoField>& flds)
|
|||||||
{
|
{
|
||||||
if (flds.size())
|
if (flds.size())
|
||||||
{
|
{
|
||||||
os << msg;
|
os << msg;
|
||||||
forAll(flds, i)
|
forAll(flds, i)
|
||||||
{
|
{
|
||||||
os<< ' ' << flds[i].name();
|
os << ' ' << flds[i].name();
|
||||||
}
|
}
|
||||||
os << endl;
|
os << endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -177,9 +177,9 @@ void print(Ostream& os, const wordList& flds)
|
|||||||
{
|
{
|
||||||
forAll(flds, i)
|
forAll(flds, i)
|
||||||
{
|
{
|
||||||
os<< ' ' << flds[i];
|
os << ' ' << flds[i];
|
||||||
}
|
}
|
||||||
os << endl;
|
os << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -94,20 +94,20 @@ void Foam::writeFuns::write
|
|||||||
fField.size()*sizeof(float)
|
fField.size()*sizeof(float)
|
||||||
);
|
);
|
||||||
|
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
forAll(fField, i)
|
forAll(fField, i)
|
||||||
{
|
{
|
||||||
os << fField[i] << ' ';
|
os << fField[i] << ' ';
|
||||||
|
|
||||||
if (i > 0 && (i % 10) == 0)
|
if (i > 0 && (i % 10) == 0)
|
||||||
{
|
{
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -143,20 +143,20 @@ void Foam::writeFuns::write
|
|||||||
elems.size()*sizeof(label)
|
elems.size()*sizeof(label)
|
||||||
);
|
);
|
||||||
|
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
forAll(elems, i)
|
forAll(elems, i)
|
||||||
{
|
{
|
||||||
os << elems[i] << ' ';
|
os << elems[i] << ' ';
|
||||||
|
|
||||||
if (i > 0 && (i % 10) == 0)
|
if (i > 0 && (i % 10) == 0)
|
||||||
{
|
{
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
os << std::endl;
|
os << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -186,11 +186,11 @@ void Foam::writeFuns::writeHeader
|
|||||||
|
|
||||||
if (binary)
|
if (binary)
|
||||||
{
|
{
|
||||||
os << "BINARY" << std::endl;
|
os << "BINARY" << std::endl;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
os << "ASCII" << std::endl;
|
os << "ASCII" << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -502,15 +502,14 @@ void vtkPV3FoamReader::PrintSelf(ostream& os, vtkIndent indent)
|
|||||||
vtkDebugMacro(<<"PrintSelf");
|
vtkDebugMacro(<<"PrintSelf");
|
||||||
|
|
||||||
this->Superclass::PrintSelf(os,indent);
|
this->Superclass::PrintSelf(os,indent);
|
||||||
os<< indent << "File name: "
|
os << indent << "File name: "
|
||||||
<< (this->FileName ? this->FileName : "(none)") << "\n";
|
<< (this->FileName ? this->FileName : "(none)") << "\n";
|
||||||
|
|
||||||
foamData_->PrintSelf(os, indent);
|
foamData_->PrintSelf(os, indent);
|
||||||
|
|
||||||
os<< indent << "Time step range: "
|
os << indent << "Time step range: "
|
||||||
<< this->TimeStepRange[0] << " - " << this->TimeStepRange[1]
|
<< this->TimeStepRange[0] << " - " << this->TimeStepRange[1] << "\n"
|
||||||
<< "\n";
|
<< indent << "Time step: " << this->GetTimeStep() << endl;
|
||||||
os<< indent << "Time step: " << this->GetTimeStep() << endl;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -283,8 +283,8 @@ void vtkPV3blockMeshReader::PrintSelf(ostream& os, vtkIndent indent)
|
|||||||
vtkDebugMacro(<<"PrintSelf");
|
vtkDebugMacro(<<"PrintSelf");
|
||||||
|
|
||||||
this->Superclass::PrintSelf(os,indent);
|
this->Superclass::PrintSelf(os,indent);
|
||||||
os<< indent << "File name: "
|
os << indent << "File name: "
|
||||||
<< (this->FileName ? this->FileName : "(none)") << "\n";
|
<< (this->FileName ? this->FileName : "(none)") << "\n";
|
||||||
|
|
||||||
foamData_->PrintSelf(os, indent);
|
foamData_->PrintSelf(os, indent);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -41,7 +41,7 @@ Foam::Ostream& Foam::operator<<
|
|||||||
|
|
||||||
Foam::Istream& Foam::operator>>(Foam::Istream& is, Foam::sumData& wDist)
|
Foam::Istream& Foam::operator>>(Foam::Istream& is, Foam::sumData& wDist)
|
||||||
{
|
{
|
||||||
return is >> wDist.oldFace_ >> wDist.sum_ >> wDist.count_;
|
return is >> wDist.oldFace_ >> wDist.sum_ >> wDist.count_;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
tabulatedWallFunction/tabulatedWallFunction.C
|
tabulatedWallFunction/tabulatedWallFunction.C
|
||||||
tabulatedWallFunction/newTabulatedWallFunction.C
|
tabulatedWallFunction/tabulatedWallFunctionNew.C
|
||||||
|
|
||||||
SpaldingsLaw/SpaldingsLaw.C
|
SpaldingsLaw/SpaldingsLaw.C
|
||||||
general/general.C
|
general/general.C
|
||||||
|
|||||||
@ -51,7 +51,7 @@ int main(int argc, char *argv[])
|
|||||||
argList::validArgs.append("surface file");
|
argList::validArgs.append("surface file");
|
||||||
argList::validArgs.append("min length");
|
argList::validArgs.append("min length");
|
||||||
argList::validArgs.append("output surface file");
|
argList::validArgs.append("output surface file");
|
||||||
argList::argList args(argc, argv);
|
argList args(argc, argv);
|
||||||
|
|
||||||
const fileName inFileName = args[1];
|
const fileName inFileName = args[1];
|
||||||
const scalar minLen = args.argRead<scalar>(2);
|
const scalar minLen = args.argRead<scalar>(2);
|
||||||
|
|||||||
@ -50,7 +50,7 @@ int main(int argc, char *argv[])
|
|||||||
argList::validArgs.clear();
|
argList::validArgs.clear();
|
||||||
argList::validArgs.append("surface file");
|
argList::validArgs.append("surface file");
|
||||||
argList::validArgs.append("output surface file");
|
argList::validArgs.append("output surface file");
|
||||||
argList::argList args(argc, argv);
|
argList args(argc, argv);
|
||||||
|
|
||||||
const fileName surfFileName = args[1];
|
const fileName surfFileName = args[1];
|
||||||
const fileName outFileName = args[2];
|
const fileName outFileName = args[2];
|
||||||
|
|||||||
@ -39,7 +39,7 @@ int main(int argc, char *argv[])
|
|||||||
argList::noParallel();
|
argList::noParallel();
|
||||||
argList::validArgs.clear();
|
argList::validArgs.clear();
|
||||||
argList::validArgs.append("input file");
|
argList::validArgs.append("input file");
|
||||||
argList::argList args(argc, argv);
|
argList args(argc, argv);
|
||||||
|
|
||||||
const fileName surfName = args[1];
|
const fileName surfName = args[1];
|
||||||
|
|
||||||
|
|||||||
@ -65,7 +65,7 @@ void writeOBJ(Ostream& os, const pointField& pts)
|
|||||||
{
|
{
|
||||||
const point& pt = pts[i];
|
const point& pt = pts[i];
|
||||||
|
|
||||||
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << endl;
|
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -85,7 +85,7 @@ void dumpPoints(const triSurface& surf, const labelList& borderPoint)
|
|||||||
{
|
{
|
||||||
const point& pt = surf.localPoints()[pointI];
|
const point& pt = surf.localPoints()[pointI];
|
||||||
|
|
||||||
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << endl;
|
os << "v " << pt.x() << ' ' << pt.y() << ' ' << pt.z() << endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -108,7 +108,7 @@ void dumpEdges(const triSurface& surf, const boolList& borderEdge)
|
|||||||
{
|
{
|
||||||
const edge& e = surf.edges()[edgeI];
|
const edge& e = surf.edges()[edgeI];
|
||||||
|
|
||||||
os << "l " << e.start()+1 << ' ' << e.end()+1 << endl;
|
os << "l " << e.start()+1 << ' ' << e.end()+1 << endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -70,7 +70,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
|
|
||||||
scalar T0(readScalar(control.lookup("T0")));
|
scalar T0(readScalar(control.lookup("T0")));
|
||||||
word fuelName(control.lookup("fuel"));
|
const word fuelName(control.lookup("fuel"));
|
||||||
scalar n(readScalar(control.lookup("n")));
|
scalar n(readScalar(control.lookup("n")));
|
||||||
scalar m(readScalar(control.lookup("m")));
|
scalar m(readScalar(control.lookup("m")));
|
||||||
|
|
||||||
|
|||||||
@ -71,7 +71,7 @@ int main(int argc, char *argv[])
|
|||||||
|
|
||||||
|
|
||||||
scalar P(readScalar(control.lookup("P")));
|
scalar P(readScalar(control.lookup("P")));
|
||||||
word fuel(control.lookup("fuel"));
|
const word fuelName(control.lookup("fuel"));
|
||||||
scalar n(readScalar(control.lookup("n")));
|
scalar n(readScalar(control.lookup("n")));
|
||||||
scalar m(readScalar(control.lookup("m")));
|
scalar m(readScalar(control.lookup("m")));
|
||||||
|
|
||||||
@ -97,7 +97,7 @@ int main(int argc, char *argv[])
|
|||||||
Info<< nl << "Reading Burcat data for relevant species" << nl << endl;
|
Info<< nl << "Reading Burcat data for relevant species" << nl << endl;
|
||||||
|
|
||||||
// Reactants
|
// Reactants
|
||||||
thermo FUEL(thermoData.lookup(fuel));
|
thermo FUEL(thermoData.lookup(fuelName));
|
||||||
thermo O2(thermoData.lookup("O2"));
|
thermo O2(thermoData.lookup("O2"));
|
||||||
thermo N2(thermoData.lookup("N2"));
|
thermo N2(thermoData.lookup("N2"));
|
||||||
|
|
||||||
|
|||||||
@ -95,13 +95,13 @@ public:
|
|||||||
|
|
||||||
friend Istream& operator>>(Istream& is, substance& s)
|
friend Istream& operator>>(Istream& is, substance& s)
|
||||||
{
|
{
|
||||||
is >> s.name_ >> s.volFrac_;
|
is >> s.name_ >> s.volFrac_;
|
||||||
return is;
|
return is;
|
||||||
}
|
}
|
||||||
|
|
||||||
friend Ostream& operator<<(Ostream& os, const substance& s)
|
friend Ostream& operator<<(Ostream& os, const substance& s)
|
||||||
{
|
{
|
||||||
os << s.name_ << token::SPACE << s.volFrac_;
|
os << s.name_ << token::SPACE << s.volFrac_;
|
||||||
return os;
|
return os;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@ -2,9 +2,8 @@
|
|||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
chmod a+rX $WM_PROJECT_DIR
|
# fix permissions (NB: '+X' and not '+x'!)
|
||||||
chmod a+rX $WM_PROJECT_DIR/doc
|
chmod a+rX $WM_PROJECT_DIR $WM_PROJECT_DIR/doc Doxygen
|
||||||
chmod -R a+rX Doxygen
|
|
||||||
|
|
||||||
Doxygen/Allwmake
|
Doxygen/Allwmake
|
||||||
|
|
||||||
|
|||||||
@ -2,11 +2,21 @@
|
|||||||
cd ${0%/*} || exit 1 # run from this directory
|
cd ${0%/*} || exit 1 # run from this directory
|
||||||
set -x
|
set -x
|
||||||
|
|
||||||
|
rm -rf latex man
|
||||||
|
|
||||||
|
# remove html directory in background
|
||||||
|
mv html html-stagedRemove$$ 2> /dev/null
|
||||||
|
rm -rf html-stagedRemove$$ >/dev/null 2>&1 &
|
||||||
|
|
||||||
|
# ensure that created files are readable by everyone
|
||||||
umask 22
|
umask 22
|
||||||
rm -rf html latex man
|
|
||||||
doxygen
|
doxygen
|
||||||
|
|
||||||
# fix permissions (NB: '+X' and not '+x'!)
|
# fix permissions (NB: '+X' and not '+x'!)
|
||||||
chmod -R a+rX ./
|
chmod -R a+rX html latex man 2>/dev/null
|
||||||
|
|
||||||
|
echo
|
||||||
|
echo "Done doxygen"
|
||||||
|
echo
|
||||||
|
|
||||||
# ----------------------------------------------------------------- end-of-file
|
# ----------------------------------------------------------------- end-of-file
|
||||||
|
|||||||
@ -14,7 +14,9 @@
|
|||||||
<body>
|
<body>
|
||||||
<a id="openfoam"> </a>
|
<a id="openfoam"> </a>
|
||||||
<!-- Top banner -->
|
<!-- Top banner -->
|
||||||
<table style="border-width: 0px; width: 800px; background: #ddddff;" cellspacing=0 cellpadding=0>
|
<table
|
||||||
|
style="border-width: 0px; width: 800px; background: #ddddff;"
|
||||||
|
cellspacing="0" cellpadding="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td style="width: 9px; height:54px"></td>
|
<td style="width: 9px; height:54px"></td>
|
||||||
<td style="width: 250px; height:54px; vertical-align:middle;
|
<td style="width: 250px; height:54px; vertical-align:middle;
|
||||||
@ -38,23 +40,23 @@ horizontal-align: left; ">
|
|||||||
<td valign="top">
|
<td valign="top">
|
||||||
<table width="801" border="0" cellspacing="1" cellpadding="0" bgcolor="#ffffff">
|
<table width="801" border="0" cellspacing="1" cellpadding="0" bgcolor="#ffffff">
|
||||||
<tr>
|
<tr>
|
||||||
<td class=leftmenu>
|
<td class="leftmenu">
|
||||||
<a href="http://foam.sourceforge.net/doc/Doxygen/html"
|
<a href="http://foam.sourceforge.net/doc/Doxygen/html"
|
||||||
class="menuLefton">Source Guide</a>
|
class="menuLefton">Source Guide</a>
|
||||||
</td>
|
</td>
|
||||||
<td class=topmenu>
|
<td class="topmenu">
|
||||||
<a href="http://www.openfoam.com/about/"
|
<a href="http://www.openfoam.com/about/"
|
||||||
class="menuTopoff">OpenCFD</a>
|
class="menuTopoff">OpenCFD</a>
|
||||||
</td>
|
</td>
|
||||||
<td class=topmenu>
|
<td class="topmenu">
|
||||||
<a href="http://www.openfoam.com/features/"
|
<a href="http://www.openfoam.com/features/"
|
||||||
class="menuTopoff">Features</a>
|
class="menuTopoff">Features</a>
|
||||||
</td>
|
</td>
|
||||||
<td class=topmenu>
|
<td class="topmenu">
|
||||||
<a href="http://www.openfoam.com/contact/"
|
<a href="http://www.openfoam.com/contact/"
|
||||||
class="menuTopoff">Contact</a>
|
class="menuTopoff">Contact</a>
|
||||||
</td>
|
</td>
|
||||||
<td class=topmenu>
|
<td class="topmenu">
|
||||||
<a href="http://www.openfoam.com/"
|
<a href="http://www.openfoam.com/"
|
||||||
class="menuTopoff">OpenFOAM</a>
|
class="menuTopoff">OpenFOAM</a>
|
||||||
</td>
|
</td>
|
||||||
@ -64,6 +66,8 @@ horizontal-align: left; ">
|
|||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<table style="border-width: 0px; width: 800px; background: #ffffff;" cellspacing=5 cellpadding=0>
|
<table
|
||||||
|
style="border-width: 0px; width: 800px; background: #ffffff;"
|
||||||
|
cellspacing="5" cellpadding="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
|
|||||||
@ -1,101 +1,100 @@
|
|||||||
/* tabs styles, based on http://www.alistapart.com/articles/slidingdoors */
|
/* tabs styles, based on http://www.alistapart.com/articles/slidingdoors */
|
||||||
|
|
||||||
DIV.tabs
|
div.tabs
|
||||||
{
|
{
|
||||||
float : left;
|
float : left;
|
||||||
width : 100%;
|
width : 100%;
|
||||||
margin-bottom : 2px;
|
margin-bottom : 2px;
|
||||||
padding-bottom : 6px;
|
padding-bottom : 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs UL
|
div.tabs ul
|
||||||
{
|
{
|
||||||
margin : 0px;
|
margin : 0px;
|
||||||
padding-left : 0px;
|
padding-left : 0px;
|
||||||
border-right : 1px solid #84B0C7;
|
border-right : 1px solid #84B0C7;
|
||||||
list-style : none;
|
list-style : none;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs LI, DIV.tabs FORM
|
div.tabs li, div.tabs form
|
||||||
{
|
{
|
||||||
display : inline;
|
display : inline;
|
||||||
margin : 0px;
|
margin : 0px;
|
||||||
padding : 0px;
|
padding : 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs FORM
|
div.tabs form
|
||||||
{
|
{
|
||||||
float : left;
|
float : left;
|
||||||
padding : 0px 9px;
|
padding : 0px 9px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs A
|
div.tabs a
|
||||||
{
|
{
|
||||||
float : left;
|
float : left;
|
||||||
font-size : 12px;
|
font-size : 12px;
|
||||||
font-weight : bold;
|
font-weight : bold;
|
||||||
text-decoration : none;
|
text-decoration : none;
|
||||||
border-right : 1px solid #000000;
|
border-right : 1px solid #000000;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs A:hover
|
div.tabs a:hover
|
||||||
{
|
{
|
||||||
background-position: 100% -150px;
|
background-position: 100% -150px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs A:link, DIV.tabs A:visited,
|
div.tabs a:link, div.tabs a:visited, div.tabs a:active, div.tabs a:hover
|
||||||
DIV.tabs A:active, DIV.tabs A:hover
|
|
||||||
{
|
{
|
||||||
color: #000000;
|
color : #000000;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs SPAN
|
div.tabs span
|
||||||
{
|
{
|
||||||
float : left;
|
float : left;
|
||||||
display : block;
|
display : block;
|
||||||
padding : 0px 9px;
|
padding : 0px 9px;
|
||||||
white-space : nowrap;
|
white-space : nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs INPUT
|
div.tabs input
|
||||||
{
|
{
|
||||||
float : right;
|
float : right;
|
||||||
display : inline;
|
display : inline;
|
||||||
font-size : 12px;
|
font-size : 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs TD
|
div.tabs td
|
||||||
{
|
{
|
||||||
font-size : 12px;
|
font-size : 12px;
|
||||||
font-weight : bold;
|
font-weight : bold;
|
||||||
text-decoration : none;
|
text-decoration : none;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Commented Backslash Hack hides rule from IE5-Mac \*/
|
/* Commented backslash hack hides rule from IE5-Mac \*/
|
||||||
DIV.tabs SPAN {float : none;}
|
div.tabs span { float : none; }
|
||||||
/* End IE5-Mac hack */
|
/* End IE5-Mac hack */
|
||||||
|
|
||||||
DIV.tabs A:hover SPAN
|
div.tabs a:hover span
|
||||||
{
|
{
|
||||||
background-position: 0% -150px;
|
background-position: 0% -150px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs LI#current A
|
div.tabs li#current a
|
||||||
{
|
{
|
||||||
border-width : 0px;
|
border-width : 0px;
|
||||||
border-right : 1px solid #000000;
|
border-right : 1px solid #000000;
|
||||||
color: #0000ff;
|
color : #0000ff;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.tabs LI#current SPAN
|
div.tabs li#current span
|
||||||
{
|
{
|
||||||
padding-bottom : 0px;
|
padding-bottom : 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
DIV.nav
|
div.nav
|
||||||
{
|
{
|
||||||
background : none;
|
background : none;
|
||||||
border : none;
|
border : none;
|
||||||
border-bottom : 1px solid #000000;
|
border-bottom : 1px solid #000000;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1,48 +0,0 @@
|
|||||||
#!/usr/bin/perl -w
|
|
||||||
use strict;
|
|
||||||
use File::Find ();
|
|
||||||
|
|
||||||
# -----------------------------------------------------------------------------
|
|
||||||
#
|
|
||||||
# Script
|
|
||||||
# find-its
|
|
||||||
#
|
|
||||||
# Description
|
|
||||||
# Search for *.[CH] files with "it's"
|
|
||||||
# This contraction (== "it is") looks too much like "its" (possesive)
|
|
||||||
# and confuses non-native (and some native) English speakers.
|
|
||||||
#
|
|
||||||
# - print filename and lineNumber
|
|
||||||
#
|
|
||||||
# -----------------------------------------------------------------------------
|
|
||||||
|
|
||||||
my $re_filespec = qr{^.+\.[CH]$};
|
|
||||||
|
|
||||||
# for the convenience of &wanted calls, including -eval statements:
|
|
||||||
## use vars qw( *name *dir *prune );
|
|
||||||
## *name = *File::Find::name;
|
|
||||||
## *dir = *File::Find::dir;
|
|
||||||
## *prune = *File::Find::prune;
|
|
||||||
|
|
||||||
sub wanted {
|
|
||||||
unless ( lstat($_) and -f _ and -r _ and not -l _ and /$re_filespec/ ) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
local @ARGV = $_;
|
|
||||||
while (<>) {
|
|
||||||
if (m{it\'s}) {
|
|
||||||
print "$File::Find::name line=$.\n";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
close ARGV;
|
|
||||||
}
|
|
||||||
|
|
||||||
## Traverse desired filesystems
|
|
||||||
for my $dir (@ARGV) {
|
|
||||||
no warnings 'File::Find';
|
|
||||||
warn "(**) checking '$dir' ...\n";
|
|
||||||
File::Find::find( { wanted => \&wanted }, $dir );
|
|
||||||
}
|
|
||||||
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user