diff --git a/applications/utilities/miscellaneous/foamHelp/Allwmake b/applications/utilities/miscellaneous/foamHelp/Allwmake
new file mode 100755
index 0000000000..4724935b92
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/Allwmake
@@ -0,0 +1,8 @@
+#!/bin/sh
+cd ${0%/*} || exit 1 # run from this directory
+
+wmake libso helpTypes
+wmake
+
+
+# ----------------------------------------------------------------- end-of-file
diff --git a/applications/utilities/miscellaneous/foamHelp/Make/files b/applications/utilities/miscellaneous/foamHelp/Make/files
new file mode 100644
index 0000000000..263901fe72
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/Make/files
@@ -0,0 +1,3 @@
+foamHelp.C
+
+EXE = $(FOAM_APPBIN)/foamHelp
diff --git a/applications/utilities/miscellaneous/foamHelp/Make/options b/applications/utilities/miscellaneous/foamHelp/Make/options
new file mode 100644
index 0000000000..41ca9e9b57
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/Make/options
@@ -0,0 +1,15 @@
+EXE_INC = \
+ -IhelpTypes/lnInclude \
+ -I$(LIB_SRC)/finiteVolume/lnInclude
+
+EXE_LIBS = \
+ -lhelpTypes \
+ -lfiniteVolume \
+ -lincompressibleTurbulenceModel \
+ -lcompressibleTurbulenceModel \
+ -lincompressibleRASModels \
+ -lcompressibleRASModels \
+ -lincompressibleLESModels \
+ -lcompressibleLESModels \
+ -lradiationModels \
+ -lfluidThermophysicalModels
diff --git a/src/thermophysicalModels/basic/basicThermo/basicThermoNew.C b/applications/utilities/miscellaneous/foamHelp/foamHelp.C
similarity index 56%
rename from src/thermophysicalModels/basic/basicThermo/basicThermoNew.C
rename to applications/utilities/miscellaneous/foamHelp/foamHelp.C
index e7dda0d9d5..39e0cb9130 100644
--- a/src/thermophysicalModels/basic/basicThermo/basicThermoNew.C
+++ b/applications/utilities/miscellaneous/foamHelp/foamHelp.C
@@ -21,50 +21,47 @@ License
You should have received a copy of the GNU General Public License
along with OpenFOAM. If not, see .
+Application
+ foamHelp
+
+Description
+ Top level wrapper utility around foam help utilities
+
\*---------------------------------------------------------------------------*/
-#include "basicThermo.H"
+#include "fvCFD.H"
+#include "helpType.H"
+
+using namespace Foam;
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-Foam::autoPtr Foam::basicThermo::New
-(
- const fvMesh& mesh
-)
+int main(int argc, char *argv[])
{
- // get model name, but do not register the dictionary
- // otherwise it is registered in the database twice
- const word modelType
- (
- IOdictionary
- (
- IOobject
- (
- "thermophysicalProperties",
- mesh.time().constant(),
- mesh,
- IOobject::MUST_READ_IF_MODIFIED,
- IOobject::NO_WRITE,
- false
- )
- ).lookup("thermoType")
- );
-
- Info<< "Selecting thermodynamics package " << modelType << endl;
-
- fvMeshConstructorTable::iterator cstrIter =
- fvMeshConstructorTablePtr_->find(modelType);
-
- if (cstrIter == fvMeshConstructorTablePtr_->end())
+ #include "addRegionOption.H"
+ if (argc < 2)
{
- FatalErrorIn("basicThermo::New(const fvMesh&)")
- << "Unknown basicThermo type " << modelType << nl << nl
- << "Valid basicThermo types are:" << nl
- << fvMeshConstructorTablePtr_->sortedToc() << nl
+ FatalError
+ << "No help utility has been supplied" << nl
<< exit(FatalError);
}
- return autoPtr(cstrIter()(mesh));
+ const word utilityName = argv[1];
+
+ Foam::autoPtr utility
+ (
+ helpType::New(utilityName)
+ );
+
+ utility().init();
+
+ #include "setRootCase.H"
+ #include "createTime.H"
+ #include "createNamedMesh.H"
+
+ utility().execute(args, mesh);
+
+ Info<< "End\n" << endl;
}
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/Make/files b/applications/utilities/miscellaneous/foamHelp/helpTypes/Make/files
new file mode 100644
index 0000000000..1f7de8d62e
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/Make/files
@@ -0,0 +1,8 @@
+helpType/helpType.C
+helpType/helpTypeNew.C
+helpBoundary/helpBoundary.C
+helpFunctionObject/helpFunctionObject.C
+
+doxygenXmlParser/doxygenXmlParser.C
+
+LIB = $(FOAM_LIBBIN)/libhelpTypes
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/Make/options b/applications/utilities/miscellaneous/foamHelp/helpTypes/Make/options
new file mode 100644
index 0000000000..1c130c5eb1
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/Make/options
@@ -0,0 +1,13 @@
+EXE_INC = \
+ -I$(LIB_SRC)/finiteVolume/lnInclude
+
+EXE_LIBS = \
+ -lfiniteVolume \
+ -lincompressibleTurbulenceModel \
+ -lcompressibleTurbulenceModel \
+ -lincompressibleRASModels \
+ -lcompressibleRASModels \
+ -lincompressibleLESModels \
+ -lcompressibleLESModels \
+ -lradiationModels \
+ -lbasicThermophysicalModels
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParser.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParser.C
new file mode 100644
index 0000000000..acf9a72d24
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParser.C
@@ -0,0 +1,246 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+\*---------------------------------------------------------------------------*/
+
+#include "doxygenXmlParser.H"
+#include "wordRe.H"
+
+
+// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
+
+Foam::doxygenXmlParser::doxygenXmlParser
+(
+ const fileName& fName,
+ const string& startTag,
+ const string& searchStr,
+ const bool exactMatch
+)
+:
+ dictionary(dictionary::null)
+{
+ IFstream is(fName);
+
+ char c;
+
+ // skip forward to entry name
+ skipForward(is, startTag);
+
+ while (is.get(c))
+ {
+ if (c == '<')
+ {
+ // if in block, read block name
+ string blockName = "";
+ string params = "";
+ bool readingParam = false;
+ while (is.get(c) && c != '>')
+ {
+ if (c == ' ')
+ {
+ readingParam = true;
+ }
+ else
+ {
+ if (readingParam)
+ {
+ params = params + c;
+ }
+ else
+ {
+ blockName = blockName + c;
+ }
+ }
+ }
+
+ if (blockName == '/' + startTag)
+ {
+ break;
+ }
+
+ if ((blockName == "compound") && (params == "kind=\"file\""))
+ {
+ // keep entry
+ word name = "";
+ fileName path = "";
+ word fName = "";
+ bool foundName = false;
+ bool foundPath = false;
+ bool foundFName = false;
+ bool earlyExit = false;
+ while (!foundName || !foundPath || !foundFName)
+ {
+ word entryName;
+ getEntry(is, entryName);
+ if (entryName == "name")
+ {
+ getValue(is, name);
+ if (wordRe(".*.H", wordRe::DETECT).match(name))
+ {
+ foundName = true;
+ }
+ else
+ {
+ // not interested in this compound
+ break;
+ }
+ }
+ else if (entryName == "path")
+ {
+ getValue(is, path);
+
+ // filter path on regExp
+ if (wordRe(searchStr, wordRe::DETECT).match(path))
+ {
+ foundPath = true;
+ }
+ else
+ {
+ // not interested in this compound
+ break;
+ }
+ }
+ else if (entryName == "filename")
+ {
+ getValue(is, fName);
+ foundFName = true;
+ }
+ else
+ {
+ skipBlock(is, entryName);
+ }
+ }
+
+ if (foundPath && !earlyExit)
+ {
+ word tName(path.components().last());
+
+ // only insert if type is not already known
+ // NOTE: not ideal for cases where there are multiple types
+ // but contained within different namespaces
+ // preferentially take exact match if it exists
+ if (exactMatch && (tName + ".H") == name)
+ {
+ dictionary dict(dictionary::null);
+ dict.add("name", name);
+ dict.add("filename", fName + ".html");
+ dict.add("path", path);
+ this->add(tName, dict);
+ }
+ else if
+ (
+ !exactMatch
+ && !found(tName)
+ && wordRe(".*" + tName + ".*", wordRe::DETECT).match(name)
+ )
+ {
+ dictionary dict(dictionary::null);
+ dict.add("name", name);
+ dict.add("filename", fName + ".html");
+ dict.add("path", path);
+ this->add(tName, dict);
+ }
+ }
+
+ // skip remanining entries
+ skipBlock(is, blockName);
+ }
+ else
+ {
+ skipBlock(is, blockName);
+ }
+ }
+ }
+}
+
+
+// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
+
+void Foam::doxygenXmlParser::skipBlock(IFstream& is, const word blockName) const
+{
+ // recurse to move forward in 'is' until come across
+
+ string closeName = "";
+
+ // fast-forward until we reach a '<'
+ char c;
+ while (is.get(c) && c != '<')
+ {}
+
+ // check to see if this is a closing block
+ if (is.get(c) && c == '/')
+ {
+ while (is.get(c) && c != '>')
+ {
+ closeName += c;
+ }
+
+ if (closeName == blockName)
+ {
+ // finished reading block
+ return;
+ }
+ else
+ {
+ skipBlock(is, blockName);
+ }
+ }
+ else
+ {
+ skipBlock(is, blockName);
+ }
+}
+
+
+void Foam::doxygenXmlParser::skipForward
+(
+ IFstream& is,
+ const word blockName
+) const
+{
+ // recurse to move forward in 'is' until come across
+
+ // fast-forward until we reach a '<'
+ char c;
+ while (is.get(c) && c != '<')
+ {}
+
+ string entryName = "";
+ while (is.get(c) && c != '>')
+ {
+ entryName = entryName + c;
+ }
+
+ if (entryName == blockName)
+ {
+ return;
+ }
+ else
+ {
+ skipForward(is, blockName);
+ }
+}
+
+
+// ************************************************************************* //
+
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParser.H b/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParser.H
new file mode 100644
index 0000000000..f2abdaee8d
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParser.H
@@ -0,0 +1,97 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+Class
+ Foam::doxygenXmlParser
+
+Description
+
+SourceFiles
+
+\*---------------------------------------------------------------------------*/
+
+#ifndef doxygenXmlParser_H
+#define doxygenXmlParser_H
+
+#include "dictionary.H"
+#include "IFstream.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+
+/*---------------------------------------------------------------------------*\
+ Class doxygenXmlParser Declaration
+\*---------------------------------------------------------------------------*/
+
+class doxygenXmlParser
+:
+ public dictionary
+{
+
+public:
+
+ //- Construct from components
+ doxygenXmlParser
+ (
+ const fileName& fName,
+ const string& startTag,
+ const string& searchStr,
+ const bool exactMatch
+ );
+
+
+ // Member functions
+
+ //- Skip past a block
+ void skipBlock(IFstream& is, const word blockName) const;
+
+ //- Skip forward to block
+ void skipForward(IFstream& is, const word blockName) const;
+
+ //- Return the entry
+ template
+ void getEntry(IFstream& is, Type& entry) const;
+
+ //- Return the entry value
+ template
+ void getValue(IFstream& is, Type& entry) const;
+};
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace Foam
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#ifdef NoRepository
+ #include "doxygenXmlParserTemplates.C"
+#endif
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#endif
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParserTemplates.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParserTemplates.C
new file mode 100644
index 0000000000..0ab6632da8
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/doxygenXmlParser/doxygenXmlParserTemplates.C
@@ -0,0 +1,67 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+\*---------------------------------------------------------------------------*/
+
+#include "doxygenXmlParser.H"
+
+// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
+
+template
+void Foam::doxygenXmlParser::getEntry(IFstream& is, Type& entry) const
+{
+ char c;
+ while (is.get(c) && c != '<')
+ {}
+
+ entry = "";
+ if (is.get(c) && c == '/')
+ {
+ return;
+ }
+ else
+ {
+ entry = entry + c;
+ }
+
+ while (is.get(c) && c != '>')
+ {
+ entry = entry + c;
+ }
+}
+
+
+template
+void Foam::doxygenXmlParser::getValue(IFstream& is, Type& entry) const
+{
+ char c;
+
+ entry = "";
+ while (is.get(c) && c != '<')
+ {
+ entry = entry + c;
+ }
+}
+
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundary.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundary.C
new file mode 100644
index 0000000000..9fd46f35c1
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundary.C
@@ -0,0 +1,192 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+\*---------------------------------------------------------------------------*/
+
+#include "helpBoundary.H"
+#include "addToRunTimeSelectionTable.H"
+
+// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
+
+namespace Foam
+{
+ namespace helpTypes
+ {
+ defineTypeNameAndDebug(helpBoundary, 0);
+ addNamedToRunTimeSelectionTable
+ (
+ helpType,
+ helpBoundary,
+ dictionary,
+ boundary
+ );
+ }
+}
+
+
+// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
+
+Foam::helpTypes::helpBoundary::helpBoundary()
+{}
+
+
+// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
+
+Foam::helpTypes::helpBoundary::~helpBoundary()
+{}
+
+
+// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
+
+void Foam::helpTypes::helpBoundary::init()
+{
+ helpType::init();
+
+ argList::validArgs.append("boundary");
+
+ argList::addOption
+ (
+ "field",
+ "word",
+ "list available conditions for field"
+ );
+ argList::addBoolOption
+ (
+ "constraint",
+ "list constraint patches"
+ );
+ argList::addBoolOption
+ (
+ "fixedValue",
+ "list fixed value patches (use with -field option)"
+ );
+}
+
+
+void Foam::helpTypes::helpBoundary::execute
+(
+ const argList& args,
+ const fvMesh& mesh
+)
+{
+ bool abortVar(env("FOAM_ABORT"));
+ if (abortVar)
+ {
+ FatalErrorIn
+ (
+ "void Foam::helpTypes::helpBoundary::execute"
+ "("
+ "const argList&, "
+ "const fvMesh&"
+ ")"
+ )
+ << "Please unset FOAM_ABORT to use this utlity"
+ << exit(FatalError);
+ }
+
+ word condition(word::null);
+ word fieldName(word::null);
+
+ if (args.optionReadIfPresent("browse", condition))
+ {
+ // TODO: strip scoping info if present?
+ // e.g. conditions with leading "compressible::" will not be found
+ // ".*[fF]vPatchField.*" + className + ".*"
+ displayDoc(condition, ".*[fF]vPatchField.*", false);
+ }
+ else if (args.optionFound("constraint"))
+ {
+ HashSet constraintTypes(fvPatch::constraintTypes());
+ Info<< "Constraint types:" << nl;
+ forAllConstIter(HashSet, constraintTypes, iter)
+ {
+ Info<< " " << iter.key() << nl;
+ }
+ Info<< endl;
+ }
+ else if (args.optionReadIfPresent("field", fieldName))
+ {
+ IOobject fieldHeader
+ (
+ fieldName,
+ mesh.time().timeName(),
+ mesh,
+ IOobject::MUST_READ
+ );
+
+ if (fieldHeader.headerOk())
+ {
+ if (args.optionFound("fixedValue"))
+ {
+ fixedValueFieldConditions(fieldHeader);
+ fixedValueFieldConditions(fieldHeader);
+ fixedValueFieldConditions(fieldHeader);
+ fixedValueFieldConditions(fieldHeader);
+ fixedValueFieldConditions(fieldHeader);
+ }
+ else
+ {
+ (void)fieldConditions(fieldHeader, true);
+ (void)fieldConditions(fieldHeader, true);
+ (void)fieldConditions(fieldHeader, true);
+ (void)fieldConditions(fieldHeader, true);
+ (void)fieldConditions(fieldHeader, true);
+ }
+ }
+ else
+ {
+ FatalErrorIn
+ (
+ "void Foam::helpTypes::helpBoundary::execute"
+ "("
+ "const argList&, "
+ "const fvMesh&"
+ ")"
+ )
+ << "Unable to read field " << fieldName << exit(FatalError);
+ }
+ }
+ else if (args.optionReadIfPresent("fixedValue", fieldName))
+ {
+ FatalErrorIn
+ (
+ "void Foam::helpTypes::helpBoundary::execute"
+ "("
+ "const argList&, "
+ "const fvMesh&"
+ ")"
+ )
+ << "-field option must be specified when using the -fixedValue "
+ << "option" << exit(FatalError);
+ }
+ else
+ {
+ // TODO: strip scoping info if present?
+ // e.g. conditions with leading "compressible::" will not be found
+ // ".*[fF]vPatchField.*" + className + ".*"
+ displayDocOptions(".*[fF]vPatchField.*", false);
+ }
+}
+
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundary.H b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundary.H
new file mode 100644
index 0000000000..6166e8e1f3
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundary.H
@@ -0,0 +1,126 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+Class
+ Foam::helpBoundary
+
+Description
+ This class provides help for boundary conditions (patch fields). When no
+ additional arguments are given, the utility outputs all known boundary
+ conditions.
+
+ Usage:
+ \plaintable
+ \c -browse \ | open documentation for patch in browser
+ \c -field \ | boundary conditions for a given field
+ \c -constraint | list constraint boundary conditions
+ \c -fixedValue | list \c fixedValue type boundary conditions
+ \endplaintable
+
+Note
+ To use the \c -fixedValue option, the \c -field option should also be used
+
+SeeAlso
+ Foam::helpType
+ Foam::fvPatchField
+
+SourceFiles
+ helpBoundary.C
+ helpBoundaryTemplates.C
+
+\*---------------------------------------------------------------------------*/
+
+#ifndef helpBoundary_H
+#define helpBoundary_H
+
+#include "helpType.H"
+#include "IOobject.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+namespace helpTypes
+{
+
+/*---------------------------------------------------------------------------*\
+ Class helpBoundary Declaration
+\*---------------------------------------------------------------------------*/
+
+class helpBoundary
+:
+ public helpType
+{
+
+protected:
+
+ // Protected Member Functions
+
+ //- Return/output the available boundary conditions for fields of Type
+ template
+ wordList fieldConditions(const IOobject& io, const bool write) const;
+
+ //- Output the available fixed boundary conditions for fields of Type
+ template
+ void fixedValueFieldConditions(const IOobject& io) const;
+
+
+public:
+
+ //- Runtime type information
+ TypeName("helpBoundary");
+
+ //- Constructor
+ helpBoundary();
+
+ //- Destructor
+ virtual ~helpBoundary();
+
+
+ // Member Functions
+
+ //- Initialise - typically setting static variables,
+ // e.g. command line arguments
+ virtual void init();
+
+ //- Execute the help
+ virtual void execute(const argList& args, const fvMesh& mesh);
+};
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace helpTypes
+} // End namespace Foam
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#ifdef NoRepository
+ #include "helpBoundaryTemplates.C"
+#endif
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#endif
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundaryTemplates.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundaryTemplates.C
new file mode 100644
index 0000000000..f2ce4a0f00
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpBoundary/helpBoundaryTemplates.C
@@ -0,0 +1,161 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+
+\*---------------------------------------------------------------------------*/
+
+#include "GeometricField.H"
+#include "fvPatchField.H"
+#include "volMesh.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+template
+Foam::wordList Foam::helpTypes::helpBoundary::fieldConditions
+(
+ const IOobject& io,
+ const bool write
+) const
+{
+ typedef GeometricField fieldType;
+
+ if (io.headerClassName() == fieldType::typeName)
+ {
+ wordList types
+ (
+ fvPatchField::dictionaryConstructorTablePtr_->sortedToc()
+ );
+
+ if (write)
+ {
+ Info<< "Available boundary conditions for "
+ << pTraits::typeName << " field: " << io.name() << nl;
+
+ forAll(types, i)
+ {
+ Info<< " " << types[i] << nl;
+ }
+
+ Info<< endl;
+ }
+
+ return types;
+ }
+
+ return wordList();
+}
+
+
+template
+void Foam::helpTypes::helpBoundary::fixedValueFieldConditions
+(
+ const IOobject& io
+) const
+{
+ wordList types(fieldConditions(io, false));
+
+ if (!types.size())
+ {
+ return;
+ }
+
+ typedef GeometricField fieldType;
+
+ const fvMesh& mesh = dynamic_cast(io.db());
+
+ fieldType fld
+ (
+ IOobject
+ (
+ "dummy",
+ mesh.time().timeName(),
+ mesh,
+ IOobject::NO_READ,
+ IOobject::NO_WRITE,
+ false
+ ),
+ mesh,
+ dimensioned("zero", dimless, pTraits::zero)
+ );
+
+
+ Info<< "Fixed value boundary conditions for "
+ << pTraits::typeName << " field: " << io.name() << nl;
+
+ // throw exceptions to avoid fatal errors when casting from generic patch
+ // type to incompatible patch type
+ FatalIOError.throwExceptions();
+ FatalError.throwExceptions();
+
+ bool foundFixed = false;
+ forAll(types, i)
+ {
+ const word& patchType = types[i];
+
+ try
+ {
+ polyPatch pp
+ (
+ "defaultFaces",
+ 0,
+ mesh.nInternalFaces(),
+ 0,
+ mesh.boundaryMesh(),
+ patchType
+ );
+
+ fvPatch fvp(pp, mesh.boundary());
+
+ tmp > pf
+ (
+ fvPatchField::New
+ (
+ patchType,
+ fvp,
+ fld
+ )
+ );
+
+ if (pf().fixesValue())
+ {
+ Info<< " " << patchType << nl;
+ foundFixed = true;
+ }
+ }
+ catch (...)
+ {
+ // do nothing
+ }
+ }
+
+ if (!foundFixed)
+ {
+ // no conditions???
+ Info<< " none" << nl;
+ }
+
+ Info<< endl;
+}
+
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpFunctionObject/helpFunctionObject.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpFunctionObject/helpFunctionObject.C
new file mode 100644
index 0000000000..631a1210ff
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpFunctionObject/helpFunctionObject.C
@@ -0,0 +1,88 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+\*---------------------------------------------------------------------------*/
+
+#include "helpFunctionObject.H"
+#include "addToRunTimeSelectionTable.H"
+
+// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
+
+namespace Foam
+{
+ namespace helpTypes
+ {
+ defineTypeNameAndDebug(helpFunctionObject, 0);
+ addNamedToRunTimeSelectionTable
+ (
+ helpType,
+ helpFunctionObject,
+ dictionary,
+ functionObject
+ );
+ }
+}
+
+
+// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
+
+Foam::helpTypes::helpFunctionObject::helpFunctionObject()
+{}
+
+
+// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
+
+Foam::helpTypes::helpFunctionObject::~helpFunctionObject()
+{}
+
+
+// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
+
+void Foam::helpTypes::helpFunctionObject::init()
+{
+ helpType::init();
+
+ argList::validArgs.append("functionObject");
+}
+
+
+void Foam::helpTypes::helpFunctionObject::execute
+(
+ const argList& args,
+ const fvMesh& mesh
+)
+{
+ word function(word::null);
+
+ if (args.optionReadIfPresent("browse", function))
+ {
+ displayDoc(function, ".*[fF]unctionObject.*", true);
+ }
+ else
+ {
+ displayDocOptions(".*[fF]unctionObject.*", true);
+ }
+}
+
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpFunctionObject/helpFunctionObject.H b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpFunctionObject/helpFunctionObject.H
new file mode 100644
index 0000000000..4e8276bcdb
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpFunctionObject/helpFunctionObject.H
@@ -0,0 +1,98 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+Class
+ Foam::helpFunctionObject
+
+Description
+ This class provides help for functionObjects. When no additional arguments
+ are given, the utility outputs all known function objects.
+
+ Usage:
+ \plaintable
+ \c -browse \ | open documentation for object in browser
+ \endplaintable
+
+SeeAlso
+ Foam::helpType
+ Foam::functionObject
+
+SourceFiles
+ helpFunctionObject.C
+
+\*---------------------------------------------------------------------------*/
+
+#ifndef helpFunctionObject_H
+#define helpFunctionObject_H
+
+#include "helpType.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+namespace helpTypes
+{
+
+/*---------------------------------------------------------------------------*\
+ Class helpFunctionObject Declaration
+\*---------------------------------------------------------------------------*/
+
+class helpFunctionObject
+:
+ public helpType
+{
+
+public:
+
+ //- Runtime type information
+ TypeName("helpFunctionObject");
+
+ //- Constructor
+ helpFunctionObject();
+
+ //- Destructor
+ virtual ~helpFunctionObject();
+
+
+ // Member Functions
+
+ //- Initialise - typically setting static variables,
+ // e.g. command line arguments
+ virtual void init();
+
+ //- Execute the help
+ virtual void execute(const argList& args, const fvMesh& mesh);
+};
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace helpTypes
+} // End namespace Foam
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#endif
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpType.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpType.C
new file mode 100644
index 0000000000..0b982e76a7
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpType.C
@@ -0,0 +1,185 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+\*---------------------------------------------------------------------------*/
+
+#include "helpType.H"
+#include "doxygenXmlParser.H"
+#include "SortableList.H"
+
+// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
+
+namespace Foam
+{
+ defineTypeNameAndDebug(helpType, 0);
+ defineRunTimeSelectionTable(helpType, dictionary);
+}
+
+// * * * * * * * * * * * * Protected Member Functions * * * * * * * * * * * //
+
+Foam::fileName Foam::helpType::doxygenPath() const
+{
+ const dictionary& docDict = debug::controlDict().subDict("Documentation");
+ List docDirs(docDict.lookup("doxyDocDirs"));
+
+ label dirI = -1;
+ forAll(docDirs, i)
+ {
+ if (isDir(docDirs[i].expand()))
+ {
+ dirI = i;
+ break;
+ }
+ }
+
+ if (dirI == -1)
+ {
+ Info<< "No Doxygen sources found under search paths: "
+ << docDirs << endl;
+ return fileName();
+ }
+
+ return docDirs[dirI];
+}
+
+
+void Foam::helpType::displayDocOptions
+(
+ const string& searchStr,
+ const bool exactMatch
+) const
+{
+ fileName doxyPath(doxygenPath());
+
+ if (doxyPath.empty())
+ {
+ return;
+ }
+
+ Info<< "Found doxygen help in " << doxyPath.c_str() << nl << endl;
+
+ doxygenXmlParser parser
+ (
+ doxyPath/"../DTAGS",
+ "tagfile",
+ searchStr,
+ exactMatch
+ );
+
+ Info<< "Valid types include:" << nl << SortableList(parser.toc());
+}
+
+
+void Foam::helpType::displayDoc
+(
+ const word& className,
+ const string& searchStr,
+ const bool exactMatch
+) const
+{
+ fileName doxyPath(doxygenPath());
+
+ if (doxyPath.empty())
+ {
+ return;
+ }
+
+ Info<< "Found doxygen help in " << doxyPath.c_str() << nl << endl;
+
+ string docBrowser = getEnv("FOAM_DOC_BROWSER");
+ if (docBrowser.empty())
+ {
+ const dictionary& docDict =
+ debug::controlDict().subDict("Documentation");
+ docDict.lookup("docBrowser") >> docBrowser;
+ }
+
+ doxygenXmlParser parser
+ (
+ doxyPath/"../DTAGS",
+ "tagfile",
+ searchStr,
+ exactMatch
+ );
+
+ if (debug)
+ {
+ Info<< parser;
+ }
+
+ if (parser.found(className))
+ {
+ fileName docFile(doxyPath/parser.subDict(className).lookup("filename"));
+
+ // can use FOAM_DOC_BROWSER='application file://%f' if required
+ docBrowser.replaceAll("%f", docFile);
+
+ fileName classFolder(parser.subDict(className).lookup("path"));
+ word classFile(parser.subDict(className).lookup("name"));
+
+ Info<< "Showing documentation for type " << className << nl << endl;
+
+ Info<< "Source file: " << classFolder.c_str() << classFile << nl
+ << endl;
+
+ system(docBrowser);
+ }
+ else
+ {
+ FatalErrorIn
+ (
+ "void Foam::helpType::displayDoc(const word, const string)"
+ )
+ << "No help for type " << className << " found."
+ << " Valid options include:" << SortableList(parser.toc())
+ << exit(FatalError);
+ }
+}
+
+
+// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
+
+Foam::helpType::helpType()
+{}
+
+
+// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
+
+Foam::helpType::~helpType()
+{}
+
+
+// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
+
+void Foam::helpType::init()
+{
+ argList::addOption
+ (
+ "browse",
+ "word",
+ "display documentation for boundary condition in browser"
+ );
+}
+
+
+// ************************************************************************* //
diff --git a/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpType.H b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpType.H
new file mode 100644
index 0000000000..f5e65709c6
--- /dev/null
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpType.H
@@ -0,0 +1,125 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+Class
+ Foam::helpType
+
+Description
+ Base class for foam help classes
+
+SourceFiles
+ helpType.C
+ helpTypeNew.C
+
+\*---------------------------------------------------------------------------*/
+
+#ifndef helpType_H
+#define helpType_H
+
+#include "runTimeSelectionTables.H"
+#include "autoPtr.H"
+#include "argList.H"
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+namespace Foam
+{
+
+// forward declaration of classes
+
+class fvMesh;
+
+/*---------------------------------------------------------------------------*\
+ Class helpType Declaration
+\*---------------------------------------------------------------------------*/
+
+class helpType
+{
+
+protected:
+
+ //- Return file path to the Doxygen sources (if available)
+ fileName doxygenPath() const;
+
+ //- Display the list of documentation options
+ void displayDocOptions
+ (
+ const string& searchStr,
+ const bool exactMatch
+ ) const;
+
+ //- Display the help documentation in a browser
+ void displayDoc
+ (
+ const word& className,
+ const string& searchStr,
+ const bool exactMatch
+ ) const;
+
+
+public:
+
+ //- Runtime type information
+ TypeName("helpType");
+
+ // Declare runtime constructor selection table
+ declareRunTimeSelectionTable
+ (
+ autoPtr,
+ helpType,
+ dictionary,
+ (),
+ ()
+ );
+
+
+ //- Constructor
+ helpType();
+
+ //- Selector
+ static autoPtr New(const word& helpTypeName);
+
+ //- Destructor
+ virtual ~helpType();
+
+
+ // Member Functions
+
+ //- Initialise - typically setting static variables,
+ // e.g. command line arguments
+ virtual void init();
+
+ //- Execute the help
+ virtual void execute(const argList& args, const fvMesh& mesh) = 0;
+};
+
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+} // End namespace Foam
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+#endif
+
+// ************************************************************************* //
diff --git a/src/thermophysicalModels/basic/rhoThermo/rhoThermo/rhoThermoNew.C b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpTypeNew.C
similarity index 51%
rename from src/thermophysicalModels/basic/rhoThermo/rhoThermo/rhoThermoNew.C
rename to applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpTypeNew.C
index cf46160a58..607ca9b435 100644
--- a/src/thermophysicalModels/basic/rhoThermo/rhoThermo/rhoThermoNew.C
+++ b/applications/utilities/miscellaneous/foamHelp/helpTypes/helpType/helpTypeNew.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -23,49 +23,42 @@ License
\*---------------------------------------------------------------------------*/
-#include "rhoThermo.H"
+#include "helpType.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-Foam::autoPtr Foam::rhoThermo::New
+Foam::autoPtr Foam::helpType::New
(
- const fvMesh& mesh
+ const word& helpTypeName
)
{
- // get model name, but do not register the dictionary
- // otherwise it is registered in the database twice
- const word modelType
- (
- IOdictionary
- (
- IOobject
- (
- "thermophysicalProperties",
- mesh.time().constant(),
- mesh,
- IOobject::MUST_READ_IF_MODIFIED,
- IOobject::NO_WRITE,
- false
- )
- ).lookup("thermoType")
- );
+ Info<< "Selecting helpType " << helpTypeName << endl;
- Info<< "Selecting thermodynamics package " << modelType << endl;
+ dictionaryConstructorTable::iterator cstrIter =
+ dictionaryConstructorTablePtr_->find(helpTypeName);
- fvMeshConstructorTable::iterator cstrIter =
- fvMeshConstructorTablePtr_->find(modelType);
-
- if (cstrIter == fvMeshConstructorTablePtr_->end())
+ if (cstrIter == dictionaryConstructorTablePtr_->end())
{
- FatalErrorIn("rhoThermo::New(const fvMesh&)")
- << "Unknown rhoThermo type "
- << modelType << nl << nl
- << "Valid rhoThermo types are:" << nl
- << fvMeshConstructorTablePtr_->sortedToc() << nl
- << exit(FatalError);
+ // special treatment for -help
+ // exit without stack trace
+ if (helpTypeName == "-help")
+ {
+ FatalErrorIn("helpType::New()")
+ << "Valid helpType selections are:" << nl
+ << dictionaryConstructorTablePtr_->sortedToc() << nl
+ << exit(FatalError);
+ }
+ else
+ {
+ FatalErrorIn("helpType::New()")
+ << "Unknown helpType type " << helpTypeName << nl
+ << "Valid helpType selections are:" << nl
+ << dictionaryConstructorTablePtr_->sortedToc() << nl
+ << abort(FatalError);
+ }
}
- return autoPtr(cstrIter()(mesh));
+ return autoPtr(cstrIter()());
}
diff --git a/applications/utilities/postProcessing/graphics/PV3Readers/PV3FoamReader/PV3FoamReader/pqPV3FoamReaderPanel.cxx b/applications/utilities/postProcessing/graphics/PV3Readers/PV3FoamReader/PV3FoamReader/pqPV3FoamReaderPanel.cxx
index babdd460c9..f795ed8eec 100644
--- a/applications/utilities/postProcessing/graphics/PV3Readers/PV3FoamReader/PV3FoamReader/pqPV3FoamReaderPanel.cxx
+++ b/applications/utilities/postProcessing/graphics/PV3Readers/PV3FoamReader/PV3FoamReader/pqPV3FoamReaderPanel.cxx
@@ -62,6 +62,9 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
QGridLayout* form = new QGridLayout();
this->PanelLayout->addLayout(form, 0, 0, 1, -1);
+ // ROW 0
+ // ~~~~~
+
vtkSMProperty* prop = 0;
// refresh button for updating times/fields
@@ -107,10 +110,16 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
}
+ // ROW 1
+ // ~~~~~
+
QFrame* hline1 = new QFrame(this);
hline1->setFrameStyle(QFrame::HLine | QFrame::Sunken);
form->addWidget(hline1, 1, 0, 1, 3);
+ // ROW 2
+ // ~~~~~
+
// checkbox for caching mesh
if ((prop = this->proxy()->GetProperty("UiCacheMesh")) != 0)
{
@@ -137,62 +146,10 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
}
+ // cell 2,1 empty
- // checkbox for patch names
- if ((prop = this->proxy()->GetProperty("UiShowPatchNames")) != 0)
- {
- // immediate update on the Server Manager side
- prop->SetImmediateUpdate(true);
-
- ShowPatchNames_ = new QCheckBox("Patch Names");
- ShowPatchNames_->setChecked
- (
- vtkSMIntVectorProperty::SafeDownCast(prop)->GetElement(0)
- );
- ShowPatchNames_->setToolTip
- (
- "Show patch names in render window."
- );
-
- // row/col 0,1
- form->addWidget(ShowPatchNames_, 2, 1, Qt::AlignLeft);
- connect
- (
- ShowPatchNames_,
- SIGNAL(stateChanged(int)),
- this,
- SLOT(ShowPatchNamesToggled())
- );
- }
-
-
- // checkbox for Groups Only
- if ((prop = this->proxy()->GetProperty("UiShowGroupsOnly")) != 0)
- {
- // immediate update on the Server Manager side
- prop->SetImmediateUpdate(true);
-
- ShowGroupsOnly_ = new QCheckBox("Groups Only");
- ShowGroupsOnly_->setChecked
- (
- vtkSMIntVectorProperty::SafeDownCast(prop)->GetElement(0)
- );
- ShowGroupsOnly_->setToolTip
- (
- "Show patchGroups only."
- );
-
- // row/col 2, 2
- form->addWidget(ShowGroupsOnly_, 2, 2, Qt::AlignLeft);
- connect
- (
- ShowGroupsOnly_,
- SIGNAL(stateChanged(int)),
- this,
- SLOT(ShowGroupsOnlyToggled())
- );
- }
-
+ // ROW 3
+ // ~~~~~
// checkbox for include sets
if ((prop = this->proxy()->GetProperty("UiIncludeSets")) != 0)
@@ -221,6 +178,36 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
}
+ // checkbox for Groups Only
+ if ((prop = this->proxy()->GetProperty("UiShowGroupsOnly")) != 0)
+ {
+ // immediate update on the Server Manager side
+ prop->SetImmediateUpdate(true);
+
+ ShowGroupsOnly_ = new QCheckBox("Groups Only");
+ ShowGroupsOnly_->setChecked
+ (
+ vtkSMIntVectorProperty::SafeDownCast(prop)->GetElement(0)
+ );
+ ShowGroupsOnly_->setToolTip
+ (
+ "Show patchGroups only."
+ );
+
+ // row/col 2, 2
+ form->addWidget(ShowGroupsOnly_, 3, 1, Qt::AlignLeft);
+ connect
+ (
+ ShowGroupsOnly_,
+ SIGNAL(stateChanged(int)),
+ this,
+ SLOT(ShowGroupsOnlyToggled())
+ );
+ }
+
+
+ // ROW 4
+ // ~~~~~
// checkbox for include zones
if ((prop = this->proxy()->GetProperty("UiIncludeZones")) != 0)
@@ -240,7 +227,7 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
// row/col 1,1
- form->addWidget(IncludeZones_, 3, 1, Qt::AlignLeft);
+ form->addWidget(IncludeZones_, 4, 0, Qt::AlignLeft);
connect
(
IncludeZones_,
@@ -250,6 +237,43 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
}
+ // checkbox for patch names
+ if ((prop = this->proxy()->GetProperty("UiShowPatchNames")) != 0)
+ {
+ // immediate update on the Server Manager side
+ prop->SetImmediateUpdate(true);
+
+ ShowPatchNames_ = new QCheckBox("Patch Names");
+ ShowPatchNames_->setChecked
+ (
+ vtkSMIntVectorProperty::SafeDownCast(prop)->GetElement(0)
+ );
+ ShowPatchNames_->setToolTip
+ (
+ "Show patch names in render window."
+ );
+
+ // row/col 0,1
+ form->addWidget(ShowPatchNames_, 4, 1, Qt::AlignLeft);
+ connect
+ (
+ ShowPatchNames_,
+ SIGNAL(stateChanged(int)),
+ this,
+ SLOT(ShowPatchNamesToggled())
+ );
+ }
+
+ // ROW 5
+ // ~~~~~
+
+ QFrame* hline2 = new QFrame(this);
+ hline2->setFrameStyle(QFrame::HLine | QFrame::Sunken);
+ form->addWidget(hline2, 5, 0, 1, 3);
+
+ // ROW 6
+ // ~~~~~
+
// checkbox for vol field interpolation
if ((prop = this->proxy()->GetProperty("UiInterpolateVolFields")) != 0)
{
@@ -267,7 +291,7 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
// row/col 1,1
- form->addWidget(InterpolateVolFields_, 4, 0, Qt::AlignLeft);
+ form->addWidget(InterpolateVolFields_, 6, 0, Qt::AlignLeft);
connect
(
InterpolateVolFields_,
@@ -294,7 +318,7 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
// row/col 1,1
- form->addWidget(ExtrapolatePatches_, 4, 1, Qt::AlignLeft);
+ form->addWidget(ExtrapolatePatches_, 6, 1, Qt::AlignLeft);
connect
(
ExtrapolatePatches_,
@@ -304,9 +328,12 @@ pqPV3FoamReaderPanel::pqPV3FoamReaderPanel
);
}
- QFrame* hline2 = new QFrame(this);
- hline2->setFrameStyle(QFrame::HLine | QFrame::Sunken);
- form->addWidget(hline2, 5, 0, 1, 3);
+ // ROW 7
+ // ~~~~~
+
+ QFrame* hline3 = new QFrame(this);
+ hline3->setFrameStyle(QFrame::HLine | QFrame::Sunken);
+ form->addWidget(hline3, 7, 0, 1, 3);
}
diff --git a/bin/tools/doxyFilter b/bin/tools/doxyFilter
index b5e59a2370..2e370383e5 100755
--- a/bin/tools/doxyFilter
+++ b/bin/tools/doxyFilter
@@ -54,7 +54,8 @@ then
# ;;
esac
- awk -f $awkScript $1 | \
+ awk -f $WM_PROJECT_DIR/bin/tools/doxyFilter-table.awk $1 | \
+ awk -f $awkScript | \
sed -f $WM_PROJECT_DIR/bin/tools/doxyFilter.sed \
-e s@%filePath%@$filePath@g \
-e s@%fileName%@$fileName@g \
diff --git a/bin/tools/doxyFilter-table.awk b/bin/tools/doxyFilter-table.awk
new file mode 100644
index 0000000000..bfbd80785b
--- /dev/null
+++ b/bin/tools/doxyFilter-table.awk
@@ -0,0 +1,135 @@
+BEGIN {
+ FS = "|";
+ data = "";
+ flag = 0;
+ firstRow = 0;
+}
+
+
+/\\table/ {
+ flag = 1;
+ firstRow = 1;
+ next;
+}
+
+
+/\\endtable/ {
+ if (data != "")
+ {
+ printf "\n";
+ printf data;
+ printf "
\n";
+ }
+
+ data = "";
+ flag = 0;
+ next;
+}
+
+
+/\\vartable/ {
+ flag = 2;
+ firstRow = 1;
+ next;
+}
+
+
+/\\endvartable/ {
+ if (data != "")
+ {
+ printf "\n";
+ printf data;
+ printf "
\n";
+ }
+
+ data = "";
+ flag = 0;
+ next;
+}
+
+
+/\\plaintable/ {
+ flag = 3;
+ firstRow = 1;
+ next;
+}
+
+
+/\\endplaintable/ {
+ if (data != "")
+ {
+ printf "\n";
+ printf data;
+ printf "
\n";
+ }
+
+ data = "";
+ flag = 0;
+ next;
+}
+
+{
+ if (flag > 0)
+ {
+ data = (data "\n");
+ if (flag == 1)
+ {
+ for (i = 0; i <= NF; i++)
+ {
+ if ((i != 0) && (firstRow == 1))
+ {
+ data = (data " | "$i" | \n");
+ }
+ else
+ {
+ if (i == 1)
+ {
+ data = (data " \\c "$i" | \n");
+ }
+ else if (i > 1)
+ {
+ data = (data " "$i" | \n");
+ }
+ }
+ }
+ }
+ else if (flag == 2)
+ {
+ for (i = 0; i <= NF; i++)
+ {
+ if (i == 1)
+ {
+ data = (data " \\f$"$i"\\f$ | \n");
+ data = (data " = | \n");
+ }
+ else if (i > 1)
+ {
+ data = (data " "$i" | \n");
+ }
+ }
+ }
+ else if (flag == 3)
+ {
+ for (i = 0; i <= NF; i++)
+ {
+ if (i == 1)
+ {
+ data = (data " "$i" | \n");
+ data = (data " : | \n");
+ }
+ else if (i > 1)
+ {
+ data = (data " "$i" | \n");
+ }
+ }
+ }
+ data = (data "
\n");
+ firstRow = 0;
+ }
+ else
+ {
+ print $0
+ }
+}
+
+
diff --git a/bin/tools/doxyFilter.sed b/bin/tools/doxyFilter.sed
index 681929a904..a0e6e4ff40 100644
--- a/bin/tools/doxyFilter.sed
+++ b/bin/tools/doxyFilter.sed
@@ -64,6 +64,17 @@ s/^ /\\class /
}
+# Group
+# groupName
+# =>
+# \ingroup namespaceName
+#
+/^Group *$/,/^[^ ]/{
+s/^Group//
+s/^ /\\ingroup /
+}
+
+
# Namespace
# namespaceName
# =>
@@ -150,6 +161,13 @@ s? *\([a-zA-Z0-9]*\.[a-zA-Z]*\)? \1?
s/.*\*\//\*\//
+
+# convert /heading in source files to bold font and add some space
+s#\\heading \(.*\)#
\1#g
+
+# add a linebreak
+s#\\linebreak#
#g
+
}
# -----------------------------------------------------------------------------
diff --git a/doc/Doxygen/Doxyfile b/doc/Doxygen/Doxyfile
index 7c72c4595e..4e3829d65a 100644
--- a/doc/Doxygen/Doxyfile
+++ b/doc/Doxygen/Doxyfile
@@ -608,7 +608,8 @@ INPUT_ENCODING = UTF-8
# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90
FILE_PATTERNS = *.H \
- *.C
+ *.C \
+ *.dox
# The RECURSIVE tag can be used to turn specify whether or not subdirectories
# should be searched for input files as well. Possible values are YES and NO.
diff --git a/doc/Doxygen/css/doxyMod.css b/doc/Doxygen/css/doxyMod.css
index 01a980b463..e5909a50db 100644
--- a/doc/Doxygen/css/doxyMod.css
+++ b/doc/Doxygen/css/doxyMod.css
@@ -61,3 +61,19 @@ tr.memlist
margin-top: 0px;
width: 200px;
}
+
+.OFTable {
+ width: 100%;
+ border: 1px solid rgb(175,175,175);
+ margin-top: 10px;
+ margin-bottom: 10px;
+/* background-color: #F0F0F0; */
+ padding: 5px;
+}
+
+.OFTable th {
+ padding: 5px;
+ border-bottom: 2px solid rgb(175,175,175);
+}
+
+
diff --git a/src/OpenFOAM/db/dictionary/functionEntries/codeStream/codeStream.H b/src/OpenFOAM/db/dictionary/functionEntries/codeStream/codeStream.H
index c6c4b53bf5..b8baa0183c 100644
--- a/src/OpenFOAM/db/dictionary/functionEntries/codeStream/codeStream.H
+++ b/src/OpenFOAM/db/dictionary/functionEntries/codeStream/codeStream.H
@@ -29,12 +29,12 @@ Description
generate the entry itself. So
- codeStream reads three entries: 'code', 'codeInclude' (optional),
'codeOptions' (optional)
- and uses those to generate library sources inside \f codeStream/
+ and uses those to generate library sources inside \c codeStream/
- these get compiled using 'wmake libso'
- the resulting library is loaded in executed with as arguments
\code
(const dictionary& dict, Ostream& os)
- \endcode
+ \endcode
where the dictionary is the current dictionary.
- the code has to write into Ostream which is then used to construct
the actual dictionary entry.
@@ -77,12 +77,12 @@ Description
\c \$ and \c ~ sequences)
Note
- The code to be compiled is stored under the local \f codeStream directory
+ The code to be compiled is stored under the local \c codeStream directory
with a subdirectory name corresponding to the SHA1 of the contents.
The corresponding library code is located under the local
- \f codeStream/platforms/$WM_OPTIONS/lib directory in a library
- \f libcodeStream_SHA1.so
+ \c codeStream/platforms/$WM_OPTIONS/lib directory in a library
+ \c libcodeStream_SHA1.so
SourceFiles
codeStream.C
diff --git a/src/OpenFOAM/db/functionObjects/functionObject/functionObjectsDoc.H b/src/OpenFOAM/db/functionObjects/functionObject/functionObjectsDoc.H
new file mode 100644
index 0000000000..2e09301232
--- /dev/null
+++ b/src/OpenFOAM/db/functionObjects/functionObject/functionObjectsDoc.H
@@ -0,0 +1,31 @@
+/*---------------------------------------------------------------------------*\
+ ========= |
+ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
+ \\ / O peration |
+ \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\/ 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 .
+
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
+\defgroup grpFunctionObjects Function objects
+@{
+ This group contains function objects
+@}
+
+\*---------------------------------------------------------------------------*/
diff --git a/src/OpenFOAM/global/argList/argList.H b/src/OpenFOAM/global/argList/argList.H
index 4ec3bd4075..4cc354d2cb 100644
--- a/src/OpenFOAM/global/argList/argList.H
+++ b/src/OpenFOAM/global/argList/argList.H
@@ -26,7 +26,7 @@ Class
Description
Extract command arguments and options from the supplied
- \a argc and @a argv parameters.
+ \a argc and \a argv parameters.
Sequences with "(" ... ")" are transformed into a stringList.
For example,
diff --git a/src/OpenFOAM/global/foamDoc.H b/src/OpenFOAM/global/foamDoc.H
index 1a38387f5a..cd3f1998a5 100644
--- a/src/OpenFOAM/global/foamDoc.H
+++ b/src/OpenFOAM/global/foamDoc.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -21,6 +21,8 @@ License
You should have received a copy of the GNU General Public License along with
OpenFOAM. If not, see .
+// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
+
\mainpage OpenFOAM®: open source CFD
\section about About OpenFOAM
@@ -34,4 +36,29 @@ License
turbulence and heat transfer, to solid dynamics and electromagnetics.
More ...
+
+\section layout Code Layout
+
+ The OpenFOAM source code comprises of four main components:
+ - src:
+ the core OpenFOAM source code
+
+ - applications:
+ collections of library functionality wrapped up into applications,
+ such as solvers and utilities
+
+ - tutorials:
+ a suite of test cases that highlight a broad cross-section of
+ OpenFOAM's capabilities
+
+ - doc:
+ supporting documentation
+
+
+\section usingTheCode Using the code
+
+ - \subpage pagePostProcessing
+ - \subpage pageBoundaryConditions
+
+
\*---------------------------------------------------------------------------*/
diff --git a/src/OpenFOAM/primitives/strings/word/wordIOList.C b/src/OpenFOAM/primitives/strings/word/wordIOList.C
index dc85ced879..ede987af53 100644
--- a/src/OpenFOAM/primitives/strings/word/wordIOList.C
+++ b/src/OpenFOAM/primitives/strings/word/wordIOList.C
@@ -37,4 +37,42 @@ namespace Foam
defineTemplateTypeNameAndDebugWithName(wordListIOList, "wordListList", 0);
}
+
+void Foam::printTable(const List& wll, Ostream& os)
+{
+ if (!wll.size()) return;
+
+ // Find the maximum word length for each column
+ List columnWidth(wll[0].size(), string::size_type(0));
+ forAll(columnWidth, j)
+ {
+ forAll(wll, i)
+ {
+ columnWidth[j] = max(columnWidth[j], wll[i][j].size());
+ }
+ }
+
+ // Print the rows adding spacing for the columns
+ forAll(wll, i)
+ {
+ forAll(wll[i], j)
+ {
+ os << wll[i][j];
+ for
+ (
+ string::size_type k=0;
+ k wordIOList;
typedef IOList wordListIOList;
+
+ // Print word list list as a table
+ void printTable(const List&, Ostream&);
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
diff --git a/src/combustionModels/singleStepCombustion/singleStepCombustion.C b/src/combustionModels/singleStepCombustion/singleStepCombustion.C
index 8234e573c5..7a354e0c64 100644
--- a/src/combustionModels/singleStepCombustion/singleStepCombustion.C
+++ b/src/combustionModels/singleStepCombustion/singleStepCombustion.C
@@ -102,8 +102,7 @@ singleStepCombustion::~singleStepCombustion()
// * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * * //
template
-Foam::tmp
-singleStepCombustion::R
+tmp singleStepCombustion::R
(
volScalarField& Y
) const
@@ -131,8 +130,8 @@ singleStepCombustion::R
template
-Foam::tmp
-singleStepCombustion< CombThermoType, ThermoType>::Sh() const
+tmp
+singleStepCombustion::Sh() const
{
const label fuelI = singleMixturePtr_->fuelIndex();
volScalarField& YFuel =
@@ -143,8 +142,8 @@ singleStepCombustion< CombThermoType, ThermoType>::Sh() const
template
-Foam::tmp
-singleStepCombustion< CombThermoType, ThermoType>::dQ() const
+tmp
+singleStepCombustion::dQ() const
{
tmp tdQ
(
@@ -175,7 +174,7 @@ singleStepCombustion< CombThermoType, ThermoType>::dQ() const
template
-bool singleStepCombustion< CombThermoType, ThermoType>::read()
+bool singleStepCombustion::read()
{
if (CombThermoType::read())
{
diff --git a/src/fieldSources/basicSource/explicitSetValue/ExplicitSetValue.H b/src/fieldSources/basicSource/explicitSetValue/ExplicitSetValue.H
index ec0a9d2ce1..1c3adcb279 100644
--- a/src/fieldSources/basicSource/explicitSetValue/ExplicitSetValue.H
+++ b/src/fieldSources/basicSource/explicitSetValue/ExplicitSetValue.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -25,19 +25,23 @@ Class
Foam::explicitSetValue
Description
- Explicit set values on fields.
+ Set values field values explicity.
Sources described by:
- ExplicitSetValueCoeffs
+ \verbatim
+ ExplicitSetValueCoeffs
+ {
+ injectionRate
{
- injectionRate
- {
- k 30.7;
- epsilon 1.5;
- }
+ k 30.7;
+ epsilon 1.5;
}
+ }
+ \endverbatim
+SeeAlso
+ Foam::basicSource
SourceFiles
explicitSetValue.C
diff --git a/src/fieldSources/basicSource/explicitSource/ExplicitSource.H b/src/fieldSources/basicSource/explicitSource/ExplicitSource.H
index 95e752d17b..30a18dd5d3 100644
--- a/src/fieldSources/basicSource/explicitSource/ExplicitSource.H
+++ b/src/fieldSources/basicSource/explicitSource/ExplicitSource.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -29,20 +29,24 @@ Description
Sources described by:
- ExplicitSourceCoeffs
+ \verbatim
+ ExplicitSourceCoeffs
+ {
+ volumeMode absolute; // specific
+ injectionRate
{
- volumeMode absolute; // specific
- injectionRate
- {
- k 30.7;
- epsilon 1.5;
- }
+ k 30.7;
+ epsilon 1.5;
}
+ }
+ \verbatim
- If volumeMode =
- - absolute: values are given as
- - specific: values are given as /m3
+ Valid options for the \c volumeMode entry include:
+ - absolute: values are given as \
+ - specific: values are given as \/m3
+SeeAlso
+ Foam::basicSource
SourceFiles
ExplicitSource.C
diff --git a/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFFreestreamVelocityFvPatchVectorField/SRFFreestreamVelocityFvPatchVectorField.H b/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFFreestreamVelocityFvPatchVectorField/SRFFreestreamVelocityFvPatchVectorField.H
index 7b7b18b63e..58c7ab9ce0 100644
--- a/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFFreestreamVelocityFvPatchVectorField/SRFFreestreamVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFFreestreamVelocityFvPatchVectorField/SRFFreestreamVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -25,8 +25,43 @@ Class
Foam::SRFVelocityFvPatchVectorField
Description
- Freestream velocity patch to be used with SRF model
- to apply the appropriate rotation transformation in time and space.
+ Freestream velocity condition to be used in conjunction with the single
+ rotating frame (SRF) model (see: SRFModel class)
+
+ Given the free stream velocity in the absolute frame, the condition
+ applies the appropriate rotation transformation in time and space to
+ determine the local velocity using:
+
+ \f[
+ U_p = cos(\theta)*U_{Inf} + sin(theta) (n^UInf) - U_{p,srf}
+ \f]
+
+ where
+ \vartable
+ U_p = patch velocity [m/s]
+ U_{Inf} = free stream velocity in the absolute frame [m/s]
+ theta = swept angle [rad]
+ n = axis direction of the SRF
+ U_{p,srf} = SRF velocity of the patch
+ \endvartable
+
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ UInf | free stream velocity | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type SRFFreestreamVelocity;
+ UInf (0 0 0);
+ value uniform (0 0 0); // optional value entry
+ }
+ \endverbatim
SourceFiles
SRFVelocityFvPatchVectorField.C
@@ -44,7 +79,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class SRFFreestreamVelocityFvPatchVectorField Declaration
+ Class SRFFreestreamVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class SRFFreestreamVelocityFvPatchVectorField
@@ -53,7 +88,7 @@ class SRFFreestreamVelocityFvPatchVectorField
{
// Private data
- //- Velocity of the free stream in the absolute frame
+ //- Velocity of the free stream in the absolute frame [m/s]
vector UInf_;
diff --git a/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFVelocityFvPatchVectorField/SRFVelocityFvPatchVectorField.H b/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFVelocityFvPatchVectorField/SRFVelocityFvPatchVectorField.H
index 829f2444be..32aaa246a7 100644
--- a/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFVelocityFvPatchVectorField/SRFVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/cfdTools/general/SRF/derivedFvPatchFields/SRFVelocityFvPatchVectorField/SRFVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,61 @@ License
Class
Foam::SRFVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions grpWallBoundaryConditions
+
Description
- Velocity patch to be used with SRF model
+ Velocity condition to be used in conjunction with the single
+ rotating frame (SRF) model (see: SRFModel class)
+
+ Given the free stream velocity in the absolute frame, the condition
+ applies the appropriate rotation transformation in time and space to
+ determine the local velocity.
+
+ The optional \c relative flag switches the behaviour of the patch
+ such that:
+
+ - relative = yes: inlet velocity applied 'as is':
+
+ \f[
+ U_p = U_{in}
+ \f]
+
+ - relative = no : SRF velocity is subtracted from the inlet velocity:
+
+ \f[
+ U_p = U_{in} - U_{p,srf}
+ \f]
+
+ where
+ \vartable
+ U_p = patch velocity [m/s]
+ U_{in} = user-specified inlet velocity
+ U_{p,srf} = SRF velocity
+ \endvartable
+
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ relative | relative motion to the SRF? | yes |
+ inletValue | inlet velocity | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type SRFVelocity;
+ relative yes;
+ inletValue uniform (0 0 0);
+ value uniform (0 0 0); // initial value
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
SRFVelocityFvPatchVectorField.C
@@ -57,7 +110,7 @@ class SRFVelocityFvPatchVectorField
//- Is the supplied inlet value relative to the SRF
Switch relative_;
- //- Inlet value
+ //- Inlet value [m/s]
vectorField inletValue_;
diff --git a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C
index 3de1587e7e..8448153a69 100644
--- a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C
+++ b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.C
@@ -165,6 +165,12 @@ void Foam::solutionControl::storePrevIterFields() const
Foam::solutionControl::solutionControl(fvMesh& mesh, const word& algorithmName)
:
+ IOobject
+ (
+ "solutionControl",
+ mesh.time().timeName(),
+ mesh
+ ),
mesh_(mesh),
residualControl_(),
algorithmName_(algorithmName),
diff --git a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H
index 45970fc325..e701813d47 100644
--- a/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H
+++ b/src/finiteVolume/cfdTools/general/solutionControl/solutionControl/solutionControl.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -44,6 +44,8 @@ namespace Foam
\*---------------------------------------------------------------------------*/
class solutionControl
+:
+ public IOobject
{
public:
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/basicSymmetry/basicSymmetryFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/basicSymmetry/basicSymmetryFvPatchField.H
index 70cffc74e0..2e19ff1d2c 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/basicSymmetry/basicSymmetryFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/basicSymmetry/basicSymmetryFvPatchField.H
@@ -24,6 +24,9 @@ License
Class
Foam::basicSymmetryFvPatchField
+Group
+ grpConstraintBoundaryConditions
+
Description
A symmetry patch
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.C
index 79b8c3750e..9f25a143e2 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.C
+++ b/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.C
@@ -28,19 +28,17 @@ License
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-namespace Foam
-{
-
template
-const word& fvPatchField::calculatedType()
+const Foam::word& Foam::fvPatchField::calculatedType()
{
return calculatedFvPatchField::typeName;
}
+
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template
-calculatedFvPatchField::calculatedFvPatchField
+Foam::calculatedFvPatchField::calculatedFvPatchField
(
const fvPatch& p,
const DimensionedField& iF
@@ -51,7 +49,7 @@ calculatedFvPatchField::calculatedFvPatchField
template
-calculatedFvPatchField::calculatedFvPatchField
+Foam::calculatedFvPatchField::calculatedFvPatchField
(
const calculatedFvPatchField& ptf,
const fvPatch& p,
@@ -64,7 +62,7 @@ calculatedFvPatchField::calculatedFvPatchField
template
-calculatedFvPatchField::calculatedFvPatchField
+Foam::calculatedFvPatchField::calculatedFvPatchField
(
const fvPatch& p,
const DimensionedField& iF,
@@ -77,7 +75,7 @@ calculatedFvPatchField::calculatedFvPatchField
template
-calculatedFvPatchField::calculatedFvPatchField
+Foam::calculatedFvPatchField::calculatedFvPatchField
(
const calculatedFvPatchField& ptf
)
@@ -87,7 +85,7 @@ calculatedFvPatchField::calculatedFvPatchField
template
-calculatedFvPatchField::calculatedFvPatchField
+Foam::calculatedFvPatchField::calculatedFvPatchField
(
const calculatedFvPatchField& ptf,
const DimensionedField& iF
@@ -98,7 +96,8 @@ calculatedFvPatchField::calculatedFvPatchField
template
-tmp > fvPatchField::NewCalculatedType
+Foam::tmp >
+Foam::fvPatchField::NewCalculatedType
(
const fvPatch& p
)
@@ -130,7 +129,7 @@ tmp > fvPatchField::NewCalculatedType
template
template
-tmp > fvPatchField::NewCalculatedType
+Foam::tmp > Foam::fvPatchField::NewCalculatedType
(
const fvPatchField& pf
)
@@ -142,7 +141,8 @@ tmp > fvPatchField::NewCalculatedType
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
template
-tmp > calculatedFvPatchField::valueInternalCoeffs
+Foam::tmp >
+Foam::calculatedFvPatchField::valueInternalCoeffs
(
const tmp&
) const
@@ -165,7 +165,8 @@ tmp > calculatedFvPatchField::valueInternalCoeffs
template
-tmp > calculatedFvPatchField::valueBoundaryCoeffs
+Foam::tmp >
+Foam::calculatedFvPatchField::valueBoundaryCoeffs
(
const tmp&
) const
@@ -186,8 +187,10 @@ tmp > calculatedFvPatchField::valueBoundaryCoeffs
return *this;
}
+
template
-tmp > calculatedFvPatchField::gradientInternalCoeffs() const
+Foam::tmp >
+Foam::calculatedFvPatchField::gradientInternalCoeffs() const
{
FatalErrorIn
(
@@ -206,8 +209,10 @@ tmp > calculatedFvPatchField::gradientInternalCoeffs() const
return *this;
}
+
template
-tmp > calculatedFvPatchField::gradientBoundaryCoeffs() const
+Foam::tmp >
+Foam::calculatedFvPatchField::gradientBoundaryCoeffs() const
{
FatalErrorIn
(
@@ -227,17 +232,12 @@ tmp > calculatedFvPatchField::gradientBoundaryCoeffs() const
}
-// Write
template
-void calculatedFvPatchField::write(Ostream& os) const
+void Foam::calculatedFvPatchField::write(Ostream& os) const
{
fvPatchField::write(os);
this->writeEntry("value", os);
}
-// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
-} // End namespace Foam
-
// ************************************************************************* //
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.H
index afb676b229..7caa505a8d 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/calculated/calculatedFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,24 @@ License
Class
Foam::calculatedFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Foam::calculatedFvPatchField
+ This boundary condition is not designed to be evaluated; it is assmued
+ that the value is assigned via field assignment, and not via a call to
+ e.g. \c updateCoeffs or \c evaluate.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type calculated;
+ value uniform (0 0 0); // optional value entry
+ }
+ \endverbatim
SourceFiles
calculatedFvPatchField.C
@@ -43,7 +59,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class calculatedFvPatch Declaration
+ Class calculatedFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/coupled/coupledFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/coupled/coupledFvPatchField.H
index 8677c34ed3..1f2dcbfb61 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/coupled/coupledFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/coupled/coupledFvPatchField.H
@@ -24,8 +24,11 @@ License
Class
Foam::coupledFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::coupledFvPatchField
+ Abstract base class for coupled patches.
SourceFiles
coupledFvPatchField.C
@@ -45,7 +48,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class coupledFvPatch Declaration
+ Class coupledFvPatch Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/directionMixed/directionMixedFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/directionMixed/directionMixedFvPatchField.H
index 0199838eab..54686db761 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/directionMixed/directionMixedFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/directionMixed/directionMixedFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,11 @@ License
Class
Foam::directionMixedFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Foam::directionMixedFvPatchField
+ Base class for direction-mixed boundary conditions.
SourceFiles
directionMixedFvPatchField.C
@@ -43,7 +46,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class directionMixedFvPatch Declaration
+ Class directionMixedFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.H
index cdf83f486a..3d00735453 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/fixedGradient/fixedGradientFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,40 @@ License
Class
Foam::fixedGradientFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Foam::fixedGradientFvPatchField
+ This boundary condition supplies a fixed gradient condition, such that
+ the patch values are calculated using:
+
+ \f[
+ x_p = x_c + \frac{\nabla(x)}{\Delta}
+ \f]
+
+ where
+ \vartable
+ x_p | patch values
+ x_c | internal field values
+ \nabla(x)| gradient (user-specified)
+ \Delta | inverse distance from patch face centre to cell centre
+ \endvartable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ gradient | gradient | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fixedGradient;
+ gradient uniform 0;
+ }
+ \endverbatim
SourceFiles
fixedGradientFvPatchField.C
@@ -43,7 +75,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class fixedGradientFvPatch Declaration
+ Class fixedGradientFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.H
index 65e7abea4a..3540c9254c 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/fixedValue/fixedValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,28 @@ License
Class
Foam::fixedValueFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Foam::fixedValueFvPatchField
+ This boundary condition supplies a fixed value constraint, and is the base
+ class for a number of other boundary conditions.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ value | values | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fixedValue;
+ value uniform 0; // example for scalar field usage
+ }
+ \endverbatim
SourceFiles
fixedValueFvPatchField.C
@@ -43,7 +63,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class fixedValueFvPatch Declaration
+ Class fixedValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.H
index 51481e0f91..77dba4ada8 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/mixed/mixedFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,45 @@ License
Class
Foam::mixedFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Foam::mixedFvPatchField
+ This boundary condition provides a base class for 'mixed' type boundary
+ conditions, i.e. conditions that mix fixed value and patch-normal gradient
+ conditions.
+
+ The respective contributions from each is determined by a weight field:
+
+ \f[
+ x_p = w x_p + (1-w) \left(x_c + \frac{\nabla_\perp x}{\Delta}\right)
+ \f]
+
+ where
+ \vartable
+ x_p | patch values
+ x_c | patch internal cell values
+ w | weight field
+ \Delta| inverse distance from face centre to internal cell centre
+ w | weighting (0-1)
+ \endvartable
+
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ valueFraction | weight field | yes |
+ refValue | fixed value | yes |
+ refGrad | patch normal gradient | yes |
+ \endtable
+
+Note
+ This condition is not usually applied directly; instead, use a derived
+ mixed condition such as \c inletOutlet
+
+SeeAlso
+ Foam::inletOutletFvPatchField
SourceFiles
mixedFvPatchField.C
@@ -43,7 +80,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class mixedFvPatch Declaration
+ Class mixedFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.H
index a40d212cd7..06671ea132 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/sliced/slicedFvPatchField.H
@@ -24,6 +24,9 @@ License
Class
Foam::slicedFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
Specialization of fvPatchField which creates the underlying
fvPatchField as a slice of the given complete field.
@@ -33,6 +36,9 @@ Description
Should only used as a template argument for SlicedGeometricField.
+SeeAlso
+ Foam::fvPatchField
+
SourceFiles
slicedFvPatchField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/transform/transformFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/transform/transformFvPatchField.H
index 2c9a2c15c6..0eab206104 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/transform/transformFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/transform/transformFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,6 +24,9 @@ License
Class
Foam::transformFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
Foam::transformFvPatchField
diff --git a/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.H
index 5726c739a9..cb238253f1 100644
--- a/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/basic/zeroGradient/zeroGradientFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,22 @@ License
Class
Foam::zeroGradientFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Foam::zeroGradientFvPatchField
+ This boundary condition applies a zero-gradient condition from the patch
+ internal field onto the patch faces.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type zeroGradient;
+ }
+ \endverbatim
SourceFiles
zeroGradientFvPatchField.C
@@ -43,7 +57,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class zeroGradientFvPatch Declaration
+ Class zeroGradientFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.H
index c3ba07477d..ded4696854 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/cyclic/cyclicFvPatchField.H
@@ -24,8 +24,27 @@ License
Class
Foam::cyclicFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::cyclicFvPatchField
+ This boundary condition enforces a cyclic condition between a pair of
+ boundaries.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type cyclic;
+ }
+ \endverbatim
+
+Note
+ The patches must be topologically similar, i.e. if the owner patch is
+ transformed to the neighbour patch, the patches should be identical (or
+ very similar).
SourceFiles
cyclicFvPatchField.C
@@ -45,7 +64,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class cyclicFvPatch Declaration
+ Class cyclicFvPatch Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/cyclicAMI/cyclicAMIFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/cyclicAMI/cyclicAMIFvPatchField.H
index 933a865f30..c9ad16c6c9 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/cyclicAMI/cyclicAMIFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/cyclicAMI/cyclicAMIFvPatchField.H
@@ -24,8 +24,31 @@ License
Class
Foam::cyclicAMIFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::cyclicAMIFvPatchField
+ This boundary condition enforces a cyclic condition between a pair of
+ boundaries, whereby communication between the patches is performed using
+ an arbitrary mesh interface (AMI) interpolation.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type cyclicAMI;
+ }
+ \endverbatim
+
+Note
+ The outer boundary of the patch pairs must be similar, i.e. if the owner
+ patch is transformed to the neighbour patch, the outer perimiter of each
+ patch should be identical (or very similar).
+
+SeeAlso
+ Foam::AMIInterpolation
SourceFiles
cyclicAMIFvPatchField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.C b/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.C
index 2d995bdd6e..953a59b820 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.C
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -25,15 +25,10 @@ License
#include "cyclicSlipFvPatchField.H"
-// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
-namespace Foam
-{
-
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
template
-cyclicSlipFvPatchField::cyclicSlipFvPatchField
+Foam::cyclicSlipFvPatchField::cyclicSlipFvPatchField
(
const fvPatch& p,
const DimensionedField& iF
@@ -44,7 +39,7 @@ cyclicSlipFvPatchField::cyclicSlipFvPatchField
template
-cyclicSlipFvPatchField::cyclicSlipFvPatchField
+Foam::cyclicSlipFvPatchField::cyclicSlipFvPatchField
(
const cyclicSlipFvPatchField& ptf,
const fvPatch& p,
@@ -57,7 +52,7 @@ cyclicSlipFvPatchField::cyclicSlipFvPatchField
template
-cyclicSlipFvPatchField::cyclicSlipFvPatchField
+Foam::cyclicSlipFvPatchField::cyclicSlipFvPatchField
(
const fvPatch& p,
const DimensionedField& iF,
@@ -69,7 +64,7 @@ cyclicSlipFvPatchField::cyclicSlipFvPatchField
template
-cyclicSlipFvPatchField::cyclicSlipFvPatchField
+Foam::cyclicSlipFvPatchField::cyclicSlipFvPatchField
(
const cyclicSlipFvPatchField& ptf
)
@@ -79,7 +74,7 @@ cyclicSlipFvPatchField::cyclicSlipFvPatchField
template
-cyclicSlipFvPatchField::cyclicSlipFvPatchField
+Foam::cyclicSlipFvPatchField::cyclicSlipFvPatchField
(
const cyclicSlipFvPatchField& ptf,
const DimensionedField& iF
@@ -89,8 +84,4 @@ cyclicSlipFvPatchField::cyclicSlipFvPatchField
{}
-// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
-} // End namespace Foam
-
// ************************************************************************* //
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.H
index 89306747b8..3c68fe2b36 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/cyclicSlip/cyclicSlipFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,25 @@ License
Class
Foam::cyclicSlipFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::cyclicSlipFvPatchField
+ This boundary condition is a light wrapper around the cyclicFvPatchField
+ condition, providing no new functionality.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type cyclicSlip;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::cyclicFvPatchField
SourceFiles
cyclicSlipFvPatchField.C
@@ -44,7 +61,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class cyclicSlipFvPatch Declaration
+ Class cyclicSlipFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
@@ -52,7 +69,6 @@ class cyclicSlipFvPatchField
:
public cyclicFvPatchField
{
- // Private data
public:
@@ -119,7 +135,6 @@ public:
new cyclicSlipFvPatchField(*this, iF)
);
}
-
};
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/empty/emptyFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/empty/emptyFvPatchField.H
index dd76378011..7b88714619 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/empty/emptyFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/empty/emptyFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,24 @@ License
Class
Foam::emptyFvPatchField
+Group
+ grpConstraintBoundaryConditions
+
Description
- Foam::emptyFvPatchField
+ This boundary condition provides an 'empty' condition for reduced
+ dimensions cases, i.e. 1- and 2-D geometries. Apply this condition to
+ patches whose normal is aligned to geometric directions that do not
+ constitue solution directions.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type empty;
+ }
+ \endverbatim
SourceFiles
emptyFvPatchField.C
@@ -44,7 +60,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class emptyFvPatch Declaration
+ Class emptyFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/jumpCyclic/jumpCyclicFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/jumpCyclic/jumpCyclicFvPatchField.H
index 4c4f94bce6..a5fd2343bf 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/jumpCyclic/jumpCyclicFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/jumpCyclic/jumpCyclicFvPatchField.H
@@ -24,8 +24,15 @@ License
Class
Foam::jumpCyclicFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::jumpCyclicFvPatchField
+ This boundary condition provides a base class for coupled-cyclic
+ conditions with a specified 'jump' (or offset) between the values
+
+SeeAlso
+ Foam::cyclicFvPatchField
SourceFiles
jumpCyclicFvPatchField.C
@@ -43,7 +50,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class cyclicFvPatch Declaration
+ Class jumpCyclicFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.H
index 5d4468045d..576d4d0833 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/nonuniformTransformCyclic/nonuniformTransformCyclicFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,18 @@ License
Class
Foam::nonuniformTransformCyclicFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::nonuniformTransformCyclicFvPatchField
+ This boundary condition enforces a cyclic condition between a pair of
+ boundaries, incorporating a non-uniform transformation.
SourceFiles
nonuniformTransformCyclicFvPatchField.C
+ nonuniformTransformCyclicFvPatchFields.H
+ nonuniformTransformCyclicFvPatchFields.C
+ nonuniformTransformCyclicFvPatchFieldsFwd.H
\*---------------------------------------------------------------------------*/
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/processor/processorFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/processor/processorFvPatchField.H
index 690a9dbe4f..a913aaf606 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/processor/processorFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/processor/processorFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,21 @@ License
Class
Foam::processorFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::processorFvPatchField
+ This boundary condition enables processor communication across patches.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type processor;
+ }
+ \endverbatim
SourceFiles
processorFvPatchField.C
@@ -45,7 +58,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class processorFvPatch Declaration
+ Class processorFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/processorCyclic/processorCyclicFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/processorCyclic/processorCyclicFvPatchField.H
index 8de27ade32..c03236b0da 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/processorCyclic/processorCyclicFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/processorCyclic/processorCyclicFvPatchField.H
@@ -24,11 +24,31 @@ License
Class
Foam::processorCyclicFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Foam::processorCyclicFvPatchField
+ This boundary condition enables processor communication across cyclic
+ patches.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type processor;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::processorFvPatchField
SourceFiles
processorCyclicFvPatchField.C
+ processorCyclicFvPatchFields.H
+ processorCyclicFvPatchFields.C
+ processorCyclicFvPatchFieldsFwd.H
\*---------------------------------------------------------------------------*/
@@ -44,7 +64,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class processorCyclicFvPatch Declaration
+ Class processorCyclicFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.H
index c95ffb95d6..a5812c09b4 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/symmetry/symmetryFvPatchField.H
@@ -24,11 +24,27 @@ License
Class
Foam::symmetryFvPatchField
+Group
+ grpConstraintBoundaryConditions
+
Description
- Foam::symmetryFvPatchField
+ This boundary condition enforces a symmetry constraint
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type symmetryPlane;
+ }
+ \endverbatim
SourceFiles
symmetryFvPatchField.C
+ symmetryFvPatchFields.C
+ symmetryFvPatchFields.H
+ symmetryFvPatchFieldsFwd.H
\*---------------------------------------------------------------------------*/
@@ -44,7 +60,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class symmetryFvPatch Declaration
+ Class symmetryFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/constraint/wedge/wedgeFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/constraint/wedge/wedgeFvPatchField.H
index ec49aaf74f..6ab1a7f081 100644
--- a/src/finiteVolume/fields/fvPatchFields/constraint/wedge/wedgeFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/constraint/wedge/wedgeFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,25 @@ License
Class
Foam::wedgeFvPatchField
+Group
+ grpConstraintBoundaryConditions
+
Description
- Foam::wedgeFvPatchField
+ This boundary condition is similar to the cyclic condition, except that
+ it is applied to 2-D geometries.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type wedge;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::cyclicFvPatchField
SourceFiles
wedgeFvPatchField.C
@@ -44,7 +61,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class wedgeFvPatch Declaration
+ Class wedgeFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.C b/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.C
index 86cd31df92..3b3667bbb5 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.C
@@ -292,6 +292,7 @@ void Foam::activeBaffleVelocityFvPatchVectorField::updateCoeffs()
void Foam::activeBaffleVelocityFvPatchVectorField::write(Ostream& os) const
{
fvPatchVectorField::write(os);
+ writeEntryIfDifferent(os, "p", "p", pName_);
os.writeKeyword("cyclicPatch")
<< cyclicPatchName_ << token::END_STATEMENT << nl;
os.writeKeyword("orientation")
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.H
index 19281b5220..1c3dfa4dd4 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/activeBaffleVelocity/activeBaffleVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,65 @@ License
Class
Foam::activeBaffleVelocityFvPatchVectorField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Boundary condition that modifies mesh areas based on velocity.
+ This velocity boundary condition simulates the opening of a baffle due
+ to local flow conditions, by merging the behaviours of wall and cyclic
+ conditions. The baffle joins two mesh regions, where the open fraction
+ determines the interpolation weights applied to each cyclic- and
+ neighbour-patch contribution.
+
+ We determine whether the baffle is opening or closing from the sign of
+ the net force across the baffle, from which the baffle open fraction is
+ updated using:
+
+ \f[
+ x = x_{old} + sign(F_{net})\frac{dt}{DT}
+ \f]
+
+ where
+
+ \vartable
+ x | baffle open fraction [0-1]
+ x_{old} | baffle open fraction on previous evaluation
+ dt | simulation time step
+ DT | time taken to open the baffle
+ F_{net} | net force across the baffle
+ \endvartable
+
+ The open fraction is then applied to scale the patch areas.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ p | pressure field name | no | p
+ cyclicPatch | cylclic patch name | yes |
+ orientation | 1 or -1 used to switch flow direction | yes|
+ openFraction | current opatch open fraction [0-1]| yes |
+ openingTime | time taken to open the baffle | yes |
+ maxOpenFractionDelta | max open fraction change per timestep | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type activeBaffleVelocity;
+ p p;
+ cyclicPatch cyclic1;
+ orientation 1;
+ openFraction 0.2;
+ openingTime 5.0;
+ maxOpenFractionDelta 0.1;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedValueFvPatchField
+ Foam::cyclicFvPatchField
SourceFiles
activeBaffleVelocityFvPatchVectorField.C
@@ -44,7 +101,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class activeBaffleVelocityFvPatch Declaration
+ Class activeBaffleVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class activeBaffleVelocityFvPatchVectorField
@@ -163,17 +220,10 @@ public:
// Mapping functions
//- Map (and resize as needed) from self given a mapping object
- virtual void autoMap
- (
- const fvPatchFieldMapper&
- );
+ virtual void autoMap(const fvPatchFieldMapper&);
//- Reverse map the given fvPatchField onto this fvPatchField
- virtual void rmap
- (
- const fvPatchVectorField&,
- const labelList&
- );
+ virtual void rmap(const fvPatchVectorField&, const labelList&);
//- Update the coefficients associated with the patch field
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.C b/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.C
index 2e65230aae..18321c9013 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.C
@@ -92,7 +92,7 @@ activePressureForceBaffleVelocityFvPatchVectorField
)
:
fixedValueFvPatchVectorField(p, iF),
- pName_("p"),
+ pName_(dict.lookupOrDefault("p", "p")),
cyclicPatchName_(dict.lookup("cyclicPatch")),
cyclicPatchLabel_(p.patch().boundaryMesh().findPatchID(cyclicPatchName_)),
orientation_(readLabel(dict.lookup("orientation"))),
@@ -278,6 +278,8 @@ void Foam::activePressureForceBaffleVelocityFvPatchVectorField::updateCoeffs()
{
valueDiff -=p[nbrFaceCells[facei]]*mag(initCyclicSf_[facei]);
}
+
+ Info<< "Force difference = " << valueDiff << endl;
}
else //pressure based
{
@@ -290,6 +292,8 @@ void Foam::activePressureForceBaffleVelocityFvPatchVectorField::updateCoeffs()
{
valueDiff -= p[nbrFaceCells[facei]];
}
+
+ Info<< "Pressure difference = " << valueDiff << endl;
}
if ((mag(valueDiff) > mag(minThresholdValue_) || baffleActivated_))
@@ -316,7 +320,6 @@ void Foam::activePressureForceBaffleVelocityFvPatchVectorField::updateCoeffs()
}
Info<< "Open fraction = " << openFraction_ << endl;
- Info<< "Pressure difference = " << valueDiff << endl;
vectorField::subField Sfw = patch().patch().faceAreas();
vectorField newSfw((1 - openFraction_)*initWallSf_);
@@ -351,6 +354,7 @@ void Foam::activePressureForceBaffleVelocityFvPatchVectorField::
write(Ostream& os) const
{
fvPatchVectorField::write(os);
+ writeEntryIfDifferent(os, "p", "p", pName_);
os.writeKeyword("cyclicPatch")
<< cyclicPatchName_ << token::END_STATEMENT << nl;
os.writeKeyword("orientation")
@@ -361,8 +365,6 @@ write(Ostream& os) const
<< maxOpenFractionDelta_ << token::END_STATEMENT << nl;
os.writeKeyword("openFraction")
<< openFraction_ << token::END_STATEMENT << nl;
- os.writeKeyword("p")
- << pName_ << token::END_STATEMENT << nl;
os.writeKeyword("minThresholdValue")
<< minThresholdValue_ << token::END_STATEMENT << nl;
os.writeKeyword("forceBased")
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.H
index 2e5b6982fe..c313f296fe 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/activePressureForceBaffleVelocity/activePressureForceBaffleVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,12 +24,64 @@ License
Class
Foam::activePressureForceBaffleVelocityFvPatchVectorField
-Description
- Bounday which emulates the operation of a release pressure panel.
+Group
+ grpCoupledBoundaryConditions
- The boundary condition modifies mesh areas based on difference
- of pressure or force face beween both sides of the panel. Once opened the
- panel continues to open at a fixed rate.
+Description
+ This boundary condition is applied to the flow velocity, to simulate the
+ opening of a baffle due to local flow conditions, by merging the behaviours
+ of wall and cyclic conditions.
+
+ The baffle joins two mesh regions, where the open fraction determines
+ the interpolation weights applied to each cyclic- and neighbour-patch
+ contribution.
+
+ Once opened the baffle continues to open at a fixed rate using
+
+ \f[
+ x = x_{old} + \frac{dt}{DT}
+ \f]
+
+ where
+
+ \vartable
+ x | baffle open fraction [0-1]
+ x_{old} | baffle open fraction on previous evaluation
+ dt | simulation time step
+ DT | time taken to open the baffle
+ \endvartable
+
+ The open fraction is then applied to scale the patch areas.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ p | pressure field name | no | p
+ cyclicPatch | cylclic patch name | yes |
+ orientation | 1 or -1 used to switch flow direction | yes|
+ openFraction | current opatch open fraction [0-1]| yes |
+ openingTime | time taken to open the baffle | yes |
+ maxOpenFractionDelta | max open fraction change per timestep | yes |
+ minThresholdValue | minimum open fraction for activation | yes |
+ forceBased | force (true) or pressure-based (false) activation | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type activePressureForceBaffleVelocity;
+ p p;
+ cyclicPatch cyclic1;
+ orientation 1;
+ openFraction 0.2;
+ openingTime 5.0;
+ maxOpenFractionDelta 0.1;
+ minThresholdValue 0.01;
+ forceBased false;
+ }
+ \endverbatim
SourceFiles
activePressureForceBaffleVelocityFvPatchVectorField.C
@@ -48,7 +100,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class activePressureForceBaffleVelocityFvPatch Declaration
+ Class activePressureForceBaffleVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class activePressureForceBaffleVelocityFvPatchVectorField
@@ -102,6 +154,7 @@ class activePressureForceBaffleVelocityFvPatchVectorField
//- Baffle is activated
bool baffleActivated_;
+
public:
//- Runtime type information
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/advective/advectiveFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/advective/advectiveFvPatchField.H
index 0734a95682..5c62df1049 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/advective/advectiveFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/advective/advectiveFvPatchField.H
@@ -24,37 +24,53 @@ License
Class
Foam::advectiveFvPatchField
+Group
+ grpOutletBoundaryConditions
+
Description
- Advective outflow boundary condition based on solving DDt(psi, U) = 0
- at the boundary.
+ This boundary condition provides an advective outflow condition, based on
+ solving DDt(psi, U) = 0 at the boundary.
The standard (Euler, backward, CrankNicholson) time schemes are
supported. Additionally an optional mechanism to relax the value at
the boundary to a specified far-field value is provided which is
- switched on by specifying the relaxation length-scale lInf and the
- far-field value fieldInf.
+ switched on by specifying the relaxation length-scale \c lInf and the
+ far-field value \c fieldInf.
The flow/wave speed at the outlet is provided by the virtual function
advectionSpeed() the default implementation of which requires the name of
- the flux field (phi) and optionally the density (rho) if the mass-flux
- rather than the volumetric-flux is given.
- \verbatim
- outlet
- {
- type advective;
- phi phi;
- // rho rho; // Not needed, phi volumetric
- // fieldInf 1e5; // Optional
- // lInf 0.1; // Optional
- }
- \endverbatim
+ the flux field \c (phi) and optionally the density \c (rho) if the
+ mass-flux rather than the volumetric-flux is given.
The flow/wave speed at the outlet can be changed by deriving a specialised
- BC from this class and overriding advectionSpeed() e.g. in
+ BC from this class and over-riding advectionSpeed() e.g. in
waveTransmissiveFvPatchField the advectionSpeed() calculates and returns
the flow-speed plus the acoustic wave speed creating an acoustic wave
transmissive boundary condition.
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ fieldInf | value of field beyond patch | no |
+ lInf | distance beyond patch for \c fieldInf | no |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type advective;
+ phi phi;
+ }
+ \endverbatim
+
+Note
+ If \c lInf is specified, \c fieldInf will be required; \c rho is only
+ required in the case of a mass-based flux.
+
SourceFiles
advectiveFvPatchField.C
@@ -71,7 +87,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class advectiveFvPatch Declaration
+ Class advectiveFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/buoyantPressure/buoyantPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/buoyantPressure/buoyantPressureFvPatchScalarField.H
index 79d9eaa543..19b7930b86 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/buoyantPressure/buoyantPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/buoyantPressure/buoyantPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,58 @@ License
Class
Foam::buoyantPressureFvPatchScalarField
-Description
- Set the pressure gradient boundary condition appropriately for buoyant flow.
+Group
+ grpGenericBoundaryConditions grpWallBoundaryConditions
- If the variable name is "pd" assume it is p - rho*g.h and set the gradient
- appropriately. Otherwise assume the variable is the static pressure.
+Description
+ This boundary condition sets the pressure gradient appropriately for
+ buoyant flow.
+
+ If the variable name is one of:
+ - \c pd
+ - \c p_rgh
+ - \c ph_rgh
+ we assume that the pressure variable is \f$p - \rho(g \cdot h)\f$ and the
+ gradient set using:
+ \f[
+ \nabla(p) = -\nabla_\perp(\rho)(g \cdot h)
+ \f]
+
+ where
+
+ \vartable
+ \rho | density [kg/m3]
+ g | acceleration due to gravity [m/s2]
+ h | patch face centres [m]
+ \endvartable
+
+ Otherwise we assume that it is the static pressure, and the gradient
+ calculated using:
+ \f[
+ \nabla(p) = \rho(g \cdot n)
+ \f]
+
+ where
+ \vartable
+ n | patch face normal vectors
+ \endvartable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ rho | density field name | no | rho
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type buoyantPressure;
+ rho rho;
+ value uniform 0;
+ }
+ \endverbatim
SourceFiles
buoyantPressureFvPatchScalarField.C
@@ -47,7 +94,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class buoyantPressureFvPatch Declaration
+ Class buoyantPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class buoyantPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/codedFixedValue/codedFixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/codedFixedValue/codedFixedValueFvPatchField.H
index c7fdc5c644..9723a2116a 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/codedFixedValue/codedFixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/codedFixedValue/codedFixedValueFvPatchField.H
@@ -24,41 +24,46 @@ License
Class
Foam::codedFixedValueFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
Constructs on-the-fly a new boundary condition (derived from
fixedValueFvPatchField) which is then used to evaluate.
+ \heading Patch usage
+
Example:
\verbatim
- movingWall
- {
- type codedFixedValue;
- value uniform 0;
- redirectType rampedFixedValue; // name of generated bc
+ myPatch
+ {
+ type codedFixedValue;
+ value uniform 0;
+ redirectType rampedFixedValue; // name of generated BC
- code
- #{
- operator==(min(10, 0.1*this->db().time().value()));
- #};
+ code
+ #{
+ operator==(min(10, 0.1*this->db().time().value()));
+ #};
- //codeInclude
- //#{
- // #include "fvCFD.H"
- //#};
+ //codeInclude
+ //#{
+ // #include "fvCFD.H"
+ //#};
- //codeOptions
- //#{
- // -I$(LIB_SRC)/finiteVolume/lnInclude
- //#};
- }
+ //codeOptions
+ //#{
+ // -I$(LIB_SRC)/finiteVolume/lnInclude
+ //#};
+ }
\endverbatim
A special form is if the 'code' section is not supplied. In this case
- the code gets read from a (runTimeModifiable!) dictionary system/codeDict
- which would have a corresponding entry
+ the code is read from a (runTimeModifiable!) dictionary system/codeDict
+ which would have a corresponding entry:
\verbatim
- rampedFixedValue
+ myPatch
{
code
#{
@@ -68,7 +73,8 @@ Description
\endverbatim
SeeAlso
- Foam::dynamicCode and Foam::functionEntries::codeStream
+ Foam::dynamicCode
+ Foam::functionEntries::codeStream
SourceFiles
codedFixedValueFvPatchField.C
@@ -92,7 +98,7 @@ class dynamicCodeContext;
class IOdictionary;
/*---------------------------------------------------------------------------*\
- Class codedFixedValueFvPatch Declaration
+ Class codedFixedValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
@@ -110,6 +116,7 @@ class codedFixedValueFvPatchField
mutable autoPtr > redirectPatchFieldPtr_;
+
// Private Member Functions
const IOdictionary& dict() const;
@@ -132,6 +139,7 @@ class codedFixedValueFvPatchField
// Get the dictionary to initialize the codeContext
virtual const dictionary& codeDict() const;
+
public:
// Static data members
@@ -209,8 +217,6 @@ public:
}
-
-
// Member functions
//- Get reference to the underlying patch
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/codedMixed/codedMixedFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/codedMixed/codedMixedFvPatchField.H
index cc08ba319d..3ab69cc81c 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/codedMixed/codedMixedFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/codedMixed/codedMixedFvPatchField.H
@@ -24,41 +24,42 @@ License
Class
Foam::codedMixedFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
Constructs on-the-fly a new boundary condition (derived from
mixedFvPatchField) which is then used to evaluate.
+ \heading Patch usage
+
Example:
\verbatim
- movingWall
- {
- type codedMixed;
+ myPatch
+ {
+ type codedMixed;
+ value uniform 0;
+ redirectType rampedMixed; // name of generated BC
- refValue uniform (0 0 0);
- refGradient uniform (0 0 0);
- valueFraction uniform 1;
+ code
+ #{
+ this->refValue() =
+ vector(1, 0, 0)
+ *min(10, 0.1*this->db().time().value());
+ this->refGrad() = vector::zero;
+ this->valueFraction() = 1.0;
+ #};
- redirectType rampedMixed; // name of generated bc
+ //codeInclude
+ //#{
+ // #include "fvCFD.H"
+ //#};
- code
- #{
- this->refValue() =
- vector(1, 0, 0)
- *min(10, 0.1*this->db().time().value());
- this->refGrad() = vector::zero;
- this->valueFraction() = 1.0;
- #};
-
- //codeInclude
- //#{
- // #include "fvCFD.H"
- //#};
-
- //codeOptions
- //#{
- // -I$(LIB_SRC)/finiteVolume/lnInclude
- //#};
- }
+ //codeOptions
+ //#{
+ // -I$(LIB_SRC)/finiteVolume/lnInclude
+ //#};
+ }
\endverbatim
A special form is if the 'code' section is not supplied. In this case
@@ -66,19 +67,20 @@ Description
which would have a corresponding entry
\verbatim
- rampedMixed
- {
- code
- #{
- this->refValue() = min(10, 0.1*this->db().time().value());
- this->refGrad() = vector::zero;
- this->valueFraction() = 1.0;
- #};
- }
+ myPatch
+ {
+ code
+ #{
+ this->refValue() = min(10, 0.1*this->db().time().value());
+ this->refGrad() = vector::zero;
+ this->valueFraction() = 1.0;
+ #};
+ }
\endverbatim
SeeAlso
- Foam::dynamicCode and Foam::functionEntries::codeStream
+ Foam::dynamicCode
+ Foam::functionEntries::codeStream
SourceFiles
codedMixedFvPatchField.C
@@ -102,7 +104,7 @@ class dynamicCodeContext;
class IOdictionary;
/*---------------------------------------------------------------------------*\
- Class codedMixedFvPatch Declaration
+ Class codedMixedFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
@@ -120,6 +122,7 @@ class codedMixedFvPatchField
mutable autoPtr > redirectPatchFieldPtr_;
+
// Private Member Functions
const IOdictionary& dict() const;
@@ -142,6 +145,7 @@ class codedMixedFvPatchField
// Get the dictionary to initialize the codeContext
virtual const dictionary& codeDict() const;
+
public:
// Static data members
@@ -219,8 +223,6 @@ public:
}
-
-
// Member functions
//- Get reference to the underlying patchField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/cylindricalInletVelocity/cylindricalInletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/cylindricalInletVelocity/cylindricalInletVelocityFvPatchVectorField.H
index de15affbc7..4e3db2fdff 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/cylindricalInletVelocity/cylindricalInletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/cylindricalInletVelocity/cylindricalInletVelocityFvPatchVectorField.H
@@ -2,16 +2,16 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ 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 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
@@ -19,19 +19,33 @@ License
for more details.
You should have received a copy of the GNU General Public License
- along with OpenFOAM; if not, write to the Free Software Foundation,
- Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ along with OpenFOAM. If not, see .
Class
Foam::cylindricalInletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Describes an inlet vector boundary condition in cylindrical coordinates
- given a central axis, central point, rpm, axial and radial velocity.
+ This boundary condition describes an inlet vector boundary condition in
+ cylindrical co-ordinates given a central axis, central point, rpm, axial
+ and radial velocity.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ axis | axis of rotation | yes |
+ centre | centre of rotation | yes |
+ axialVelocity | axial velocity profile [m/s] | yes |
+ radialVelocity | radial velocity profile [m/s] | yes |
+ rpm | rotational speed (revolutions per minute) | yes|
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
+ myPatch
{
type cylindricalInletVelocity;
axis (0 0 1);
@@ -42,9 +56,14 @@ Description
}
\endverbatim
- The axialVelocity, radialVelocity and rpm entries are DataEntry types, able
- to describe time varying functions. The example above gives the usage for
- supplying constant values.
+Note
+ The \c axialVelocity, \c radialVelocity and \c rpm entries are DataEntry
+ types, able to describe time varying functions. The example above gives
+ the usage for supplying constant values.
+
+SeeAlso
+ Foam::fixedValueFvPatchField
+ Foam::DataEntry
SourceFiles
cylindricalInletVelocityFvPatchVectorField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H
index b3799c2bd9..3eea1382f3 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fan/fanFvPatchField.H
@@ -24,47 +24,59 @@ License
Class
Foam::fanFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Jump boundary condition. Operates on cyclic. Jump specified as a DataEntry.
- (table, fileTable, csv etc.)
+ This boundary condition provides a jump condition, using the \c cyclic
+ condition as a base.
+
+ The jump is specified as a \c DataEntry type, to enable the use of, e.g.
+ contant, polynomial, table values.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ patchType | underlying patch type should be \c cyclic| yes |
+ jump | current jump value | yes |
+ jumpTable | jump data, e.g. \c csvFile | yes |
+ \endtable
Example of the boundary condition specification:
\verbatim
- fan_half0
+ myPatch
+ {
+ type fan;
+ patchType cyclic;
+ jump uniform 0;
+ jumpTable csvFile;
+ csvFileCoeffs
{
- type fan;
- patchType cyclic;
- jump uniform 0;
- jumpTable csvFile;
- csvFileCoeffs
- {
- hasHeaderLine 1;
- refColumn 0;
- componentColumns 1(1);
- separator ",";
- fileName "$FOAM_CASE/constant/pressureVsU";
- }
- value uniform 0;
+ hasHeaderLine 1;
+ refColumn 0;
+ componentColumns 1(1);
+ separator ",";
+ fileName "$FOAM_CASE/constant/pressureVsU";
}
+ value uniform 0;
+ }
\endverbatim
+ The above example shows the use of a comma separated (CSV) file to specify
+ the jump condition.
- Backwards compatibility: if the 'f' keyword is detected it assumes
- it is a power of the flowrate.
+Note
+ The underlying \c patchType should be set to \c cyclic
- \verbatim
- fan_half0
- {
- type fan;
- patchType cyclic;
- jump uniform 0;
- f 2(100 -0.1);
- value uniform 0;
- }
- \endverbatim
+SeeAlso
+ Foam::DataEntry
SourceFiles
fanFvPatchField.C
+ fanFvPatchFields.H
+ fanFvPatchFields.C
+ fanFvPatchFieldsFwd.H
\*---------------------------------------------------------------------------*/
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fanPressure/fanPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/fanPressure/fanPressureFvPatchScalarField.H
index 9720684193..022fb48ccb 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fanPressure/fanPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fanPressure/fanPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,43 +24,53 @@ License
Class
Foam::fanPressureFvPatchScalarField
-Description
- Assigns pressure inlet or outlet total pressure condition for a fan.
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
- User specifies:
- - pressure drop vs volumetric flow rate table (fan curve) file name;
- - direction of normal flow through the fan, in or out;
- - total pressure of the environment.
+Description
+ This boundary condition can be applied to assign either a pressure inlet
+ or outlet total pressure condition for a fan.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ fileName | fan curve file name | yes |
+ outOfBounds | out of bounds handling | yes |
+ direction | direction of flow through fan [in/out] | yes |
+ p0 | environmental total pressure | yes |
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
- {
- type fanPressure;
- fileName "fanCurve"; // Fan curve file name
- outOfBounds clamp; // (error|warn|clamp|repeat)
- direction in; // Direction of flow through fan
- p0 uniform 0; // Environmental total pressure
- value uniform 0; // Initial pressure
- }
+ inlet
+ {
+ type fanPressure;
+ fileName "fanCurve";
+ outOfBounds clamp;
+ direction in;
+ p0 uniform 0;
+ value uniform 0;
+ }
- outlet
- {
- type fanPressure;
- fileName "fanCurve"; // Fan curve file name
- outOfBounds clamp; // (error|warn|clamp|repeat)
- direction out; // Direction of flow through fan
- p0 uniform 0; // Environmental total pressure
- value uniform 0; // Initial pressure
- }
+ outlet
+ {
+ type fanPressure;
+ fileName "fanCurve";
+ outOfBounds clamp;
+ direction out;
+ p0 uniform 0;
+ value uniform 0;
+ }
\endverbatim
See Also
- Foam::totalPressureFvPatchScalarField and
+ Foam::fanFvPatchField
+ Foam::totalPressureFvPatchScalarField
Foam::interpolationTable
SourceFiles
- fanPressureFvPatchScalarField.C
+ fanPressureFvPatchScalarField.C
\*---------------------------------------------------------------------------*/
@@ -93,8 +103,10 @@ public:
ffdOut
};
+ //- Fan flow directions names
static const NamedEnum fanFlowDirectionNames_;
+
private:
// Private data
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fixedFluxPressure/fixedFluxPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/fixedFluxPressure/fixedFluxPressureFvPatchScalarField.H
index de8f837abd..8476e63dff 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fixedFluxPressure/fixedFluxPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fixedFluxPressure/fixedFluxPressureFvPatchScalarField.H
@@ -24,15 +24,53 @@ License
Class
Foam::fixedFluxPressureFvPatchScalarField
+Group
+ grpOutletBoundaryConditions
+
Description
- Adjusts the pressure gradient such that the flux on the boundary is that
- specified by the velocity boundary condition.
+ This boundary condition adjusts the pressure gradient such that the flux
+ on the boundary is that specified by the velocity boundary condition.
The predicted flux to be compensated by the pressure gradient is evaluated
- as (phi - phiHbyA), both of which are looked-up from the database as is
- the pressure diffusivity Dp used to calculate the gradient.
+ as \f$(\phi - \phi_{H/A})\f$, both of which are looked-up from the database,
+ as is the pressure diffusivity used to calculate the gradient using:
- The names of the phi, phiHbyA and Dp fields may be optionally specified.
+ \f[
+ \nabla(p) = \frac{\phi_{H/A} - \phi}{|Sf| D_p}
+ \f]
+
+ where
+
+ \vartable
+ phi | flux
+ D_p | pressure diffusivity
+ Sf | patch face areas [m2]
+ \endvartable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phiHbyA | name of predicted flux field | no | phiHbyA
+ phi | name of flux field | no | phi
+ rho | name of density field | no | rho
+ Dp | name of pressure diffusivity field | no | Dp
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fixedFluxPressure;
+ phiHbyA phiHbyA;
+ phi phi;
+ rho rho;
+ Dp Dp;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedGradientFvPatchField
SourceFiles
fixedFluxPressureFvPatchScalarField.C
@@ -52,7 +90,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class fixedFluxPressureFvPatch Declaration
+ Class fixedFluxPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class fixedFluxPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fixedInternalValueFvPatchField/fixedInternalValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/fixedInternalValueFvPatchField/fixedInternalValueFvPatchField.H
index cd27459a94..75a9742240 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fixedInternalValueFvPatchField/fixedInternalValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fixedInternalValueFvPatchField/fixedInternalValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,33 @@ License
Class
Foam::fixedInternalValueFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Boundary condition providing mechanism to set boundary (cell) values
- directly into a matrix, i.e. to set a constraint condition. Default
+ This boundary condition provides a mechanism to set boundary (cell) values
+ directly into a matrix, i.e. to set a constraint condition. Default
behaviour is to act as a zero gradient condition.
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fixedInternalValue;
+ value uniform 0; // place holder
+ }
+ \endverbatim
+
+Note
+ This is used as a base for conditions such as the turbulence \c epsilon
+ wall function, which applies a near-wall constraint for high Reynolds
+ number flows.
+
+SeeAlso
+ Foam::epsilonWallFunctionFvPatchScalarField
+
SourceFiles
fixedInternalValueFvPatchField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fixedJump/fixedJumpFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/fixedJump/fixedJumpFvPatchField.H
index c746b975cf..30ec57fc54 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fixedJump/fixedJumpFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fixedJump/fixedJumpFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,9 +24,19 @@ License
Class
Foam::fixedJumpFvPatchField
+Group
+ grpCoupledBoundaryConditions
+
Description
Base class for "jump" of a field
+Note
+ not used directly
+
+SeeAlso
+ Foam::fanFvPatchScalarField
+ Foam::fanPressureFvPatchScalarField
+
SourceFiles
fixedJumpFvPatchField.C
@@ -62,7 +72,6 @@ protected:
public:
-
// Constructors
//- Construct from patch and internal field
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fixedMean/fixedMeanFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/fixedMean/fixedMeanFvPatchField.H
index b59969a967..ed31cfb998 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fixedMean/fixedMeanFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fixedMean/fixedMeanFvPatchField.H
@@ -24,9 +24,31 @@ License
Class
Foam::fixedMeanFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Extrapolates field to the patch using the near-cell values and adjusts
- the distribution to match the specified meanValue.
+ This boundary condition extrapolates field to the patch using the near-cell
+ values and adjusts the distribution to match the specified mean value.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ meanValue | mean value | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fixedMean;
+ meanValue 1.0;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
fixedMeanFvPatchField.C
@@ -44,7 +66,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class fixedMeanFvPatch Declaration
+ Class fixedMeanFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fixedNormalSlip/fixedNormalSlipFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/fixedNormalSlip/fixedNormalSlipFvPatchField.H
index 3a59c98f4e..bbaf0a257b 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fixedNormalSlip/fixedNormalSlipFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fixedNormalSlip/fixedNormalSlipFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,30 @@ License
Class
Foam::fixedNormalSlipFvPatchField
+Group
+ grpGenericBoundaryConditions grpWallBoundaryConditions
+
Description
- Foam::fixedNormalSlipFvPatchField
+ This boundary condition sets the patch-normal component to a fixed value.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ fixedValue | fixed value | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fixedNormalSlip;
+ fixedValue uniform 0; // example entry for a scalar field
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::transformFvPatchField
SourceFiles
fixedNormalSlipFvPatchField.C
@@ -43,7 +65,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class fixedNormalSlipFvPatch Declaration
+ Class fixedNormalSlipFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fixedPressureCompressibleDensity/fixedPressureCompressibleDensityFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/fixedPressureCompressibleDensity/fixedPressureCompressibleDensityFvPatchScalarField.H
index a27409e94b..47aab74d5c 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fixedPressureCompressibleDensity/fixedPressureCompressibleDensityFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fixedPressureCompressibleDensity/fixedPressureCompressibleDensityFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,20 +24,50 @@ License
Class
Foam::fixedPressureCompressibleDensityFvPatchScalarField
+Group
+ grpInletBoundaryConditions
+
Description
- Calculate compressible density as a function of pressure and fluid
- properties.
+ This boundary condition calculates a (liquid) compressible density as a
+ function of pressure and fluid properties:
+
+ \f[
+ \rho = \rho_{l,sat} + \psi_l*(p - p_{sat})
+ \f]
+
+ where
+
+ \vartable
+ \rho | density [kg/m3]
+ \rho_{l,sat} | saturation liquid density [kg/m3]
+ \psi_l | liquid compressibility
+ p | pressure [Pa]
+ p_{sat} | saturation pressure [Pa]
+ \endvartable
+
+ The variables \c rholSat, \c pSat and \c psil are retrieved from the
+ \c thermodynamicProperties dictionary.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ p | pressure field name | no | p
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
- {
- type fixedPressureCompressibleDensity;
- p p; // Name of static pressure field
- value uniform 1; // Initial value
- }
+ myPatch
+ {
+ type fixedPressureCompressibleDensity;
+ p p;
+ value uniform 1;
+ }
\endverbatim
+SeeAlso
+ Foam::fixedValueFvPatchField
+
SourceFiles
fixedPressureCompressibleDensityFvPatchScalarField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/flowRateInletVelocity/flowRateInletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/flowRateInletVelocity/flowRateInletVelocityFvPatchVectorField.H
index 1a5d2f493d..8051261154 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/flowRateInletVelocity/flowRateInletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/flowRateInletVelocity/flowRateInletVelocityFvPatchVectorField.H
@@ -24,37 +24,67 @@ License
Class
Foam::flowRateInletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Describes a volumetric/mass flow normal vector boundary condition by its
- magnitude as an integral over its area.
+ This boundary condition provides a velocity boundary condition, derived
+ from the flux (volumetric or mass-based), whose direction is assumed
+ to be normal to the patch.
- Either specify 'volumetricFlowRate' or 'massFlowRate' (requires additional
- 'rho' or 'rhoInlet' entry).
+ For a mass-based flux:
+ - the flow rate should be provided in kg/s
+ - if \c rhoName is "none" the flow rate is in m3/s
+ - otherwise \c rhoName should correspond to the name of the density field
+ - if the density field cannot be found in the database, the user must
+ specify the inlet density using the \c rhoInlet entry
- Example of the boundary condition specification:
+ For a volumetric-based flux:
+ - the flow rate is in m3/s
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ massFlowRate | mass flow rate [kg/s] | no |
+ volumetricFlowRate | volumetric flow rate [m3/s]| no |
+ rhoInlet | inlet density | no |
+ \endtable
+
+ Example of the boundary condition specification for a volumetric flow rate:
\verbatim
- inlet
+ myPatch
{
- type flowRateInletVelocity;
- volumetricFlowRate 0.2; // Volumetric [m3/s]
+ type flowRateInletVelocity;
+ volumetricFlowRate 0.2;
+ value uniform (0 0 0); // placeholder
}
\endverbatim
+ Example of the boundary condition specification for a mass flow rate:
\verbatim
- inlet
+ myPatch
{
type flowRateInletVelocity;
- massFlowRate 0.2; // mass flow rate [kg/s]
- rho rho; // rho [m3/s or kg/s]
- rhoInlet 1.0 // uniform rho if no rho field registered
- // (e.g. at startup)
+ massFlowRate 0.2;
+ rho rho;
+ rhoInlet 1.0;
}
\endverbatim
+
+ The \c flowRate entry is a \c DataEntry type, meaning that it can be
+ specified as constant, a polynomial fuction of time, and ...
Note
- - The value is positive inwards
- - May not work correctly for transonic inlets
- - Strange behaviour with potentialFoam since the U equation is not solved
+ - \c rhoInlet is required for the case of a mass flow rate, where the
+ density field is not available at start-up
+ - the value is positive into the domain (as an inlet)
+ - may not work correctly for transonic inlets
+ - strange behaviour with potentialFoam since the U equation is not solved
+
+SeeAlso
+ Foam::DataEntry
+ Foam::fixedValueFvPatchField
SourceFiles
flowRateInletVelocityFvPatchVectorField.C
@@ -72,7 +102,7 @@ SourceFiles
namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class flowRateInletVelocityFvPatch Declaration
+ Class flowRateInletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class flowRateInletVelocityFvPatchVectorField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.C b/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.C
index fbd74afe20..a3f7387390 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -29,8 +29,6 @@ License
#include "volFields.H"
#include "surfaceFields.H"
-// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
-
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam::fluxCorrectedVelocityFvPatchVectorField::
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.H
index 6631d205b4..4519a5ed9d 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/fluxCorrectedVelocity/fluxCorrectedVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,53 @@ License
Class
Foam::fluxCorrectedVelocityFvPatchVectorField
+Group
+ grpOutletBoundaryConditions
+
Description
- Velocity outlet boundary condition for patches where the pressure is
- specified. The outflow velocity is obtained by "zeroGradient" and then
- corrected from the flux. If reverse flow is possible or expected use
- the "pressureInletOutletVelocityFvPatchVectorField" BC instead.
+ This boundary condition provides a velocity outlet boundary condition for
+ patches where the pressure is specified. The outflow velocity is obtained
+ by "zeroGradient" and then corrected from the flux:
+
+ \f[
+ U_p = U_c - n*(n.U_c) + \frac{n*\phi_p}{|Sf|}
+ \f]
+
+ where
+
+ \vartable
+ U_p | velocity at the patch [m/s]
+ U_c | velocity in cells adjacent to the patch [m/s]
+ n | patch normal vectors
+ \phi_p | flux at the patch [m3/s or kg/s]
+ Sf | patch face area vectors [m2]
+ \endvartable
+
+ where
+
+ \table
+ Property | Description | Required | Default value
+ phi | name of flux field | no | phi
+ rho | name of density field | no | rho
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type fluxCorrectedVelocity;
+ phi phi;
+ rho rho;
+ }
+ \endverbatim
+
+Note
+ If reverse flow is possible or expected use the
+ pressureInletOutletVelocity condition instead.
+
+SeeAlso
+ Foam::zeroGradientFvPatchField
+ Foam::pressureInletOutletVelocityFvPatchVectorField
SourceFiles
fluxCorrectedVelocityFvPatchVectorField.C
@@ -47,7 +89,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class fluxCorrectedVelocityFvPatch Declaration
+ Class fluxCorrectedVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class fluxCorrectedVelocityFvPatchVectorField
@@ -56,7 +98,10 @@ class fluxCorrectedVelocityFvPatchVectorField
{
// Private data
+ //- Name of flux field
word phiName_;
+
+ //- Name of density field
word rhoName_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.H
index 50f3d136f0..adcb570f93 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/freestream/freestreamFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,34 @@ License
Class
Foam::freestreamFvPatchField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Foam::freestreamFvPatchField
+ This boundary condition provides a free-stream condition. It is a 'mixed'
+ condition derived from the \c inletOutlet condition, whereby the mode of
+ operation switches between fixed (free stream) value and zero gradient
+ based on the sign of the flux.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type freestream;
+ phi phi;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::mixedFvPatchField
+ Foam::inletOutletFvPatchField
SourceFiles
freestreamFvPatchField.C
@@ -43,7 +69,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class freestreamFvPatch Declaration
+ Class freestreamFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H
index 6323b678d7..fa5233308c 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/freestreamPressure/freestreamPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,30 @@ License
Class
Foam::freestreamPressureFvPatchScalarField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Foam::freestreamPressureFvPatchScalarField
+ This boundary condition provides a free-stream condition for pressure.
+ It is a zero-gradient condition that constrains the flux across the patch
+ based on the free-stream velocity.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type freestreamPressure;
+ }
+ \endverbatim
+
+Note
+ This condition is designed to operate with a freestream velocity condition
+
+SeeAlso
+ Foam::zeroGradientFvPatchField
+ Foam::freestreamFvPatchField
SourceFiles
freestreamPressureFvPatchScalarField.C
@@ -44,7 +66,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class freestreamPressureFvPatch Declaration
+ Class freestreamPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class freestreamPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/inletOutlet/inletOutletFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/inletOutlet/inletOutletFvPatchField.H
index 4c7817967b..21aea3aa91 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/inletOutlet/inletOutletFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/inletOutlet/inletOutletFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,43 @@ License
Class
Foam::inletOutletFvPatchField
+Group
+ grpOutletBoundaryConditions
+
Description
- Foam::inletOutletFvPatchField
+ This boundary condition provides a generic outflow condition, with
+ specified inflow for the case of return flow.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ inletValue | inlet value for reverse flow | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type inletOutlet;
+ phi phi;
+ inletValue uniform 0;
+ value uniform 0;
+ }
+ \endverbatim
+
+ The mode of operation is determined by the sign of the flux across the
+ patch faces.
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply zero-gradient condition
+ - negative flux (into of domain): apply the user-specified fixed value
+
+SeeAlso
+ Foam::mixedFvPatchField
+ Foam::zeroGradientFvPatchField
SourceFiles
inletOutletFvPatchField.C
@@ -43,7 +78,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class inletOutletFvPatch Declaration
+ Class inletOutletFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/inletOutletTotalTemperature/inletOutletTotalTemperatureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/inletOutletTotalTemperature/inletOutletTotalTemperatureFvPatchScalarField.H
index 7483a39bd4..430ee1e51f 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/inletOutletTotalTemperature/inletOutletTotalTemperatureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/inletOutletTotalTemperature/inletOutletTotalTemperatureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,43 @@ License
Class
Foam::inletOutletTotalTemperatureFvPatchScalarField
+Group
+ grpOutletBoundaryConditions
+
Description
- Foam::inletOutletTotalTemperatureFvPatchScalarField
+ This boundary condition provides an outflow condition for total
+ temperature for use with supersonic cases, where a user-specified
+ value is applied in the case of reverse flow.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | velocity field name | no | U
+ phi | flux field name | no | phi
+ psi | compressibility field name | no | psi
+ gamma | heat capacity ration (Cp/Cv) | yes |
+ inletValue | reverse flow (inlet) value | yes |
+ T0 | static temperature [K] | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type inletOutletTotalTemperature;
+ U U;
+ phi phi;
+ psi psi;
+ gamma gamma;
+ inletValue uniform 0;
+ T0 uniform 0;
+ value uniform 0;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::inletOutletFvPatchField
SourceFiles
inletOutletTotalTemperatureFvPatchScalarField.C
@@ -43,7 +78,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class inletOutletTotalTemperatureFvPatch Declaration
+ Class inletOutletTotalTemperatureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class inletOutletTotalTemperatureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.H
index 11c0425bed..6dd9f3efb5 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedField/mappedFieldFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,47 @@ License
Class
Foam::mappedFieldFvPatchField
+Group
+ grpGenericBoundaryConditions grpCoupledBoundaryConditions
+
Description
- Self-contained version of mapped. Does not use information on
- patch, instead holds it locally (and possibly duplicate) so use
- normal mapped in preference and only use this if you cannot
- change the underlying patch type to mapped.
+ This boundary condition provides a self-contained version of the \c mapped
+ condition. It does not use information on the patch; instead it holds
+ thr data locally.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ fieldName | name of field to be mapped | no | this field name
+ setAverage | flag to activate setting of average value | yes |
+ average | average value to apply if \c setAverage = yes | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type mappedField;
+ fieldName T; // optional field name
+ setAverage no; // apply an average value
+ average 0; // average to apply if setAverage
+ value uniform 0; // place holder
+ }
+ \endverbatim
+
+Note
+ Since this condition can be applied on a per-field and per-patch basis,
+ it is possible to duplicate the mapping information. If possible, employ
+ the \c mapped condition in preference to avoid this situation, and only
+ employ this condition if it is not possible to change the underlying
+ geometric (poly) patch type to \c mapped.
+
+SeeAlso
+ Foam::mappedPatchBase
+ Foam::mappedPolyPatch
+ Foam::mappedFvPatch
+ Foam::fixedValueFvPatchField
SourceFiles
mappedFieldFvPatchField.C
@@ -48,7 +84,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class mappedFieldFvPatchField Declaration
+ Class mappedFieldFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.H
index 56ab904529..a4b48fce8f 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedInternalValue/mappedFixedInternalValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,9 +24,42 @@ License
Class
Foam::mappedFixedInternalValueFvPatchField
+Group
+ grpGenericBoundaryConditions grpCoupledBoundaryConditions
+
Description
- Recycles the boundary and internal values of a neighbour patch field to
- the boundary and internal values of *this.
+ This boundary condition maps the boundary and internal values of a
+ neighbour patch field to the boundary and internal values of *this.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ fieldName | name of field to be mapped | no | this field name
+ setAverage | flag to activate setting of average value | yes |
+ average | average value to apply if \c setAverage = yes | yes |
+ \endtable
+
+ \verbatim
+ myPatch
+ {
+ type mappedFixedInternalValue;
+ fieldName T;
+ setAverage no;
+ average 0;
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ This boundary condition can only be applied to patches that are of
+ the \c mappedPolyPatch type.
+
+SeeAlso
+ Foam::mappedPatchBase
+ Foam::mappedPolyPatch
+ Foam::mappedFvPatch
+ Foam::mappedFixedValueFvPatchField
SourceFiles
mappedFixedInternalValueFvPatchField.C
@@ -44,7 +77,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class mappedFixedInternalValueFvPatchField Declaration
+ Class mappedFixedInternalValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedPushedInternalValue/mappedFixedPushedInternalValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedPushedInternalValue/mappedFixedPushedInternalValueFvPatchField.H
index a3dc0b67ac..2f9ecedd66 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedPushedInternalValue/mappedFixedPushedInternalValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedPushedInternalValue/mappedFixedPushedInternalValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,9 +24,43 @@ License
Class
Foam::mappedFixedPushedInternalValueFvPatchField
+Group
+ grpGenericBoundaryConditions grpCoupledBoundaryConditions
+
Description
- Recycles the boundary values of a neighbour patch field to the boundary
- and internal values of *this.
+ This boundary condition maps the boundary values of a neighbour patch
+ field to the boundary and internal cell values of *this.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ fieldName | name of field to be mapped | no | this field name
+ setAverage | flag to activate setting of average value | yes |
+ average | average value to apply if \c setAverage = yes | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type mappedFixedPushedInternalValue;
+ fieldName T;
+ setAverage no;
+ average 0;
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ This boundary condition can only be applied to patches that are of
+ the \c mappedPolyPatch type.
+
+SeeAlso
+ Foam::mappedPatchBase
+ Foam::mappedPolyPatch
+ Foam::mappedFvPatch
+ Foam::mappedFixedValueFvPatchField
SourceFiles
mappedFixedPushedInternalValueFvPatchField.C
@@ -44,7 +78,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class mappedFixedPushedInternalValueFvPatchField Declaration
+ Class mappedFixedPushedInternalValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.H
index d60ae3bc3c..dd52f2a2b6 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedFixedValue/mappedFixedValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,27 +24,55 @@ License
Class
Foam::mappedFixedValueFvPatchField
+Group
+ grpGenericBoundaryConditions grpCoupledBoundaryConditions
+
Description
- Recycles the value at a set of cells or patch faces back to *this. Can not
- sample internal faces (since volField not defined on faces).
+ This boundary condition maps the value at a set of cells or patch faces
+ back to *this.
- mode = NEARESTCELL : sample nearest cell
- mode = NEARESTPATCHFACE : sample nearest face on selected patch
- mode = NEARESTFACE : sample nearest face on any patch. Note: does not
- warn if nearest actually is on internal face!
- mode = NEARESTPATCHFACEAMI : sample nearest face on selected patch
- patches can be non-conformal - method uses AMI interpolation
+ The sample mode is set by the underlying mapping engine, provided by the
+ mappedPatchBase class.
+
+ \heading Patch usage
- For NEARESTCELL you have to provide an 'interpolationScheme' entry
- which can be any one of the interpolation schemes (cell, cellPoint, etc.)
- In case of interpolation (so scheme != cell) the limitation is that
- there is only one value per cell. So e.g. if you have a cell with two
- boundary faces and both faces sample into the cell both faces will get
- the same value.
+ \table
+ Property | Description | Required | Default value
+ fieldName | name of field to be mapped | no | this field name
+ setAverage | flag to activate setting of average value | yes |
+ average | average value to apply if \c setAverage = yes | yes |
+ interpolationScheme | type of interpolation scheme | no |
+ \endtable
- See mappedPatchBase for options on sampling.
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type mapped;
+ fieldName T;
+ setAverage no;
+ average 0;
+ interpolationScheme cell;
+ value uniform 0;
+ }
+ \endverbatim
- Optional 'fieldName' entry to supply a different filename
+ When employing the \c nearestCell sample mode, the user must also specify
+ the interpolation scheme using the \c interpolationScheme entry.
+
+ In case of interpolation (where scheme != cell) the limitation is that
+ there is only one value per cell. For example, if you have a cell with two
+ boundary faces and both faces sample into the cell, both faces will get the
+ same value.
+
+Note
+ It is not possible to sample internal faces since volume fields are not
+ defined on faces.
+
+SeeAlso
+ Foam::mappedPatchBase
+ Foam::interpolation
+ Foam::fixedValueFvPatchField
SourceFiles
mappedFixedValueFvPatchField.C
@@ -63,7 +91,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class mappedFixedValueFvPatch Declaration
+ Class mappedFixedValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedFlowRate/mappedFlowRateFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/mappedFlowRate/mappedFlowRateFvPatchVectorField.H
index 45c42233b6..cb06375c10 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/mappedFlowRate/mappedFlowRateFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedFlowRate/mappedFlowRateFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,31 +24,39 @@ License
Class
Foam::mappedFlowRateFvPatchVectorField
+Group
+ grpInletBoundaryConditions grpCoupledBoundaryConditions
+
Description
Describes a volumetric/mass flow normal vector boundary condition by its
magnitude as an integral over its area.
- The inlet mass flux is taken from the neighbor region.
-
- phi is used to determine if the flow is compressible or incompressible.
+ The inlet mass flux is taken from the neighbour region.
The basis of the patch (volumetric or mass) is determined by the
- dimensions of the flux, phi.
- The current density is used to correct the velocity when applying the
- mass basis.
+ dimensions of the flux, phi. The current density is used to correct the
+ velocity when applying the mass basis.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ neigPhi | name of flux field on neighbour mesh | yes |
+ \endtable
Example of the boundary condition specification:
- @verbatim
- inlet
+ \verbatim
+ myPatch
{
type mappedFlowRate;
phi phi;
rho rho;
- neigPhi neigPhiName_; // Volumetric/mass flow rate
- // [m3/s or kg/s]
+ neigPhi phi;
value uniform (0 0 0); // placeholder
}
- @endverbatim
+ \endverbatim
SourceFiles
mappedFlowRateFvPatchVectorField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/mappedVelocityFluxFixedValue/mappedVelocityFluxFixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/mappedVelocityFluxFixedValue/mappedVelocityFluxFixedValueFvPatchField.H
index c1d40666dd..409154eaff 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/mappedVelocityFluxFixedValue/mappedVelocityFluxFixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/mappedVelocityFluxFixedValue/mappedVelocityFluxFixedValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,12 +24,42 @@ License
Class
Foam::mappedVelocityFluxFixedValueFvPatchField
-Description
- Recycles the velocity and flux at a patch to this patch
+Group
+ grpInletBoundaryConditions grpCoupledBoundaryConditions
- mode = NEARESTPATCHFACE : sample nearest face on selected patch
- mode = NEARESTFACE : sample nearest face on any patch. Note: does not
- warn if nearest actually is on internal face!
+Description
+ This boundary condition maps the velocity and flux from a neighbour patch
+ to this patch
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type mappedVelocityFlux;
+ phi phi;
+ value uniform 0; // place holder
+ }
+ \endverbatim
+
+ The underlying sample mode should be set to \c nearestPatchFace or
+ \c nearestFace
+
+Note
+ This boundary condition can only be applied to patches that are of
+ the \c mappedPolyPatch type.
+
+SeeAlso
+ Foam::mappedPatchBase
+ Foam::mappedPolyPatch
+ Foam::mappedFvPatch
+ Foam::fixedValueFvPatchVectorField
SourceFiles
mappedVelocityFluxFixedValueFvPatchField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/movingWallVelocity/movingWallVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/movingWallVelocity/movingWallVelocityFvPatchVectorField.H
index 6da73d51f1..be5b50e6f8 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/movingWallVelocity/movingWallVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/movingWallVelocity/movingWallVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,35 @@ License
Class
Foam::movingWallVelocityFvPatchVectorField
+Group
+ grpWallBoundaryConditions
+
Description
- Foam::movingWallVelocityFvPatchVectorField
+ This boundary condition provides a velocity condition for cases with
+ moving walls. In addition, it should also be applied to 'moving' walls
+ for moving reference frame (MRF) calculations.
+
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | velociy field name | no | U
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type movingWallVelocity;
+ U U;
+ value uniform 0; // initial value
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedValueFvPatchVectorField
+ Foam::MRFZone
SourceFiles
movingWallVelocityFvPatchVectorField.C
@@ -44,7 +71,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class movingWallVelocityFvPatch Declaration
+ Class movingWallVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class movingWallVelocityFvPatchVectorField
@@ -125,7 +152,6 @@ public:
}
-
// Member functions
//- Update the coefficients associated with the patch field
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.C b/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.C
index 644c8b161c..89cf73e8ad 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.C
@@ -41,7 +41,8 @@ multiphaseFixedFluxPressureFvPatchScalarField
fixedGradientFvPatchScalarField(p, iF),
phiHbyAName_("phiHbyA"),
phiName_("phi"),
- rhoName_("rho")
+ rhoName_("rho"),
+ DpName_("Dp")
{}
@@ -57,7 +58,8 @@ multiphaseFixedFluxPressureFvPatchScalarField
fixedGradientFvPatchScalarField(ptf, p, iF, mapper),
phiHbyAName_(ptf.phiHbyAName_),
phiName_(ptf.phiName_),
- rhoName_(ptf.rhoName_)
+ rhoName_(ptf.rhoName_),
+ DpName_(ptf.DpName_)
{}
@@ -72,7 +74,8 @@ multiphaseFixedFluxPressureFvPatchScalarField
fixedGradientFvPatchScalarField(p, iF),
phiHbyAName_(dict.lookupOrDefault("phiHbyA", "phiHbyA")),
phiName_(dict.lookupOrDefault("phi", "phi")),
- rhoName_(dict.lookupOrDefault("rho", "rho"))
+ rhoName_(dict.lookupOrDefault("rho", "rho")),
+ DpName_(dict.lookupOrDefault("Dp", "Dp"))
{
if (dict.found("gradient"))
{
@@ -91,27 +94,29 @@ multiphaseFixedFluxPressureFvPatchScalarField
Foam::multiphaseFixedFluxPressureFvPatchScalarField::
multiphaseFixedFluxPressureFvPatchScalarField
(
- const multiphaseFixedFluxPressureFvPatchScalarField& wbppsf
+ const multiphaseFixedFluxPressureFvPatchScalarField& mfppsf
)
:
- fixedGradientFvPatchScalarField(wbppsf),
- phiHbyAName_(wbppsf.phiHbyAName_),
- phiName_(wbppsf.phiName_),
- rhoName_(wbppsf.rhoName_)
+ fixedGradientFvPatchScalarField(mfppsf),
+ phiHbyAName_(mfppsf.phiHbyAName_),
+ phiName_(mfppsf.phiName_),
+ rhoName_(mfppsf.rhoName_),
+ DpName_(mfppsf.DpName_)
{}
Foam::multiphaseFixedFluxPressureFvPatchScalarField::
multiphaseFixedFluxPressureFvPatchScalarField
(
- const multiphaseFixedFluxPressureFvPatchScalarField& wbppsf,
+ const multiphaseFixedFluxPressureFvPatchScalarField& mfppsf,
const DimensionedField& iF
)
:
- fixedGradientFvPatchScalarField(wbppsf, iF),
- phiHbyAName_(wbppsf.phiHbyAName_),
- phiName_(wbppsf.phiName_),
- rhoName_(wbppsf.rhoName_)
+ fixedGradientFvPatchScalarField(mfppsf, iF),
+ phiHbyAName_(mfppsf.phiHbyAName_),
+ phiName_(mfppsf.phiName_),
+ rhoName_(mfppsf.rhoName_),
+ DpName_(mfppsf.DpName_)
{}
@@ -155,7 +160,7 @@ void Foam::multiphaseFixedFluxPressureFvPatchScalarField::updateCoeffs()
*/
const fvsPatchField& Dpp =
- patch().lookupPatchField("Dp");
+ patch().lookupPatchField(DpName_);
gradient() = (phiHbyAp - phip)/patch().magSf()/Dpp;
@@ -172,6 +177,7 @@ void Foam::multiphaseFixedFluxPressureFvPatchScalarField::write
writeEntryIfDifferent(os, "phiHbyA", "phiHbyA", phiHbyAName_);
writeEntryIfDifferent(os, "phi", "phi", phiName_);
writeEntryIfDifferent(os, "rho", "rho", rhoName_);
+ writeEntryIfDifferent(os, "Dp", "Dp", DpName_);
gradient().writeEntry("gradient", os);
writeEntry("value", os);
}
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.H
index 57f01d78e6..18b9698c0e 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/multiphaseFixedFluxPressure/multiphaseFixedFluxPressureFvPatchScalarField.H
@@ -24,15 +24,50 @@ License
Class
Foam::multiphaseFixedFluxPressureFvPatchScalarField
+Group
+ grpWallBoundaryConditions grpGenericBoundaryConditions
+
Description
- Adjusts the pressure gradient such that the flux on the boundary is that
- specified by the velocity boundary condition.
+ This boundary condition adjusts the pressure gradient such that the flux
+ on the boundary is that specified by the velocity boundary condition.
The predicted flux to be compensated by the pressure gradient is evaluated
- as (phi - phiHbyA), both of which are looked-up from the database as is
- the pressure diffusivity Dp used to calculate the gradient.
+ as \f$(\phi - \phi_{H/A})\f$, both of which are looked-up from the database,
+ as is the pressure diffusivity Dp used to calculate the gradient using:
- The names of the phi, phiHbyA and Dp fields may be optionally specified.
+ \f[
+ \nabla(p) = \frac{\phi_{H/A} - \phi}{|Sf| Dp}
+ \f]
+
+ where
+
+ \vartable
+ \phi | flux
+ Dp | pressure diffusivity
+ Sf | patch face areas [m2]
+ \endvartable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phiHbyA | name of predicted flux field | no | phiHbyA
+ phi | name of flux field | no | phi
+ rho | name of density field | no | rho
+ Dp | name of pressure diffusivity field | no | Dp
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type multiphaseFixedFluxPressure;
+ phiHbyA phiHbyA;
+ phi phi;
+ rho rho;
+ Dp Dp;
+ }
+ \endverbatim
SourceFiles
multiphaseFixedFluxPressureFvPatchScalarField.C
@@ -71,6 +106,9 @@ class multiphaseFixedFluxPressureFvPatchScalarField
// if neccessary
word rhoName_;
+ //- Name of the pressure diffusivity field
+ word DpName_;
+
public:
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.H
index ba84bc1c26..da45cdcb85 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/oscillatingFixedValue/oscillatingFixedValueFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,26 +24,58 @@ License
Class
Foam::oscillatingFixedValueFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Describes an oscillating boundary condition in terms of amplitude and
- frequency.
+ This boundary condition provides an oscillating condition in terms of
+ amplitude and frequency.
+
+ /f[
+ x_p = (1 + a sin(\pi f t))x_{ref} + x_o
+ /f]
+
+ where
+
+ \vartable
+ x_p | patch values
+ x_{ref} | patch reference values
+ x_o | patch offset values
+ a | amplitude
+ f | frequency [1/s]
+ t | time [s]
+ \endvartable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ refValue | reference value | yes |
+ offset | offset value | no | 0.0
+ amplitude | oscillation amplitude | yes |
+ frequency | oscillation frequency | yes |
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
+ myPatch
{
type oscillatingFixedValue;
refValue uniform 5.0;
- offset 0.0; // optional
+ offset 0.0;
amplitude constant 0.5;
frequency constant 10;
}
\endverbatim
+Note
The amplitude and frequency entries are DataEntry types, able to describe
time varying functions. The example above gives the usage for supplying
constant values.
+SeeAlso
+ Foam::DataEntry
+
SourceFiles
oscillatingFixedValueFvPatchField.C
@@ -62,7 +94,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class oscillatingFixedValueFvPatch Declaration
+ Class oscillatingFixedValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/outletInlet/outletInletFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/outletInlet/outletInletFvPatchField.H
index 1002143fd1..d843815a5f 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/outletInlet/outletInletFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/outletInlet/outletInletFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,39 @@ License
Class
Foam::outletInletFvPatchField
+Group
+ grpInletBoundaryConditions
+
Description
- Foam::outletInletFvPatchField
+ This boundary condition provides a generic inflow condition, with
+ specified outflow for the case of return flow.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ inletValue | inlet value | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type outletInlet;
+ phi phi; // name of flux field (default = phi)
+ outletValue uniform 0; // reverse flow (inlet) value
+ value uniform 0; // initial value
+ }
+ \endverbatim
+
+ The mode of operation is determined by the sign of the flux across the
+ patch faces.
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply the user-specified fixed value
+ - negative flux (into of domain): apply zero-gradient condition
SourceFiles
outletInletFvPatchField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/outletMappedUniformInlet/outletMappedUniformInletFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/outletMappedUniformInlet/outletMappedUniformInletFvPatchField.H
index c04b7e2f17..059faeab09 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/outletMappedUniformInlet/outletMappedUniformInletFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/outletMappedUniformInlet/outletMappedUniformInletFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,10 +24,35 @@ License
Class
Foam::outletMappedUniformInletFvPatchField
+Group
+ grpInletBoundaryConditions
+
Description
- Averages the field over the "outlet" patch specified by name
- "outletPatchName" and applies this as the uniform value of the field
- over this patch.
+ This boundary conditon averages the field over the "outlet" patch specified
+ by name "outletPatchName" and applies this as the uniform value of the
+ field over this patch.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ outletPatchName | name of outlet patch | yes |
+ phi | flux field name | no | phi
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type outletMappedUniformInlet;
+ outletPatchName aPatch;
+ phi phi;
+ value uniform 0;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
outletMappedUniformInletFvPatchField.C
@@ -45,7 +70,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class outletMappedUniformInletFvPatch Declaration
+ Class outletMappedUniformInletFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/partialSlip/partialSlipFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/partialSlip/partialSlipFvPatchField.H
index c369143439..b4fd5e7ce7 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/partialSlip/partialSlipFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/partialSlip/partialSlipFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,32 @@ License
Class
Foam::partialSlipFvPatchField
+Group
+ grpWallBoundaryConditions grpGenericBoundaryConditions
+
Description
- Foam::partialSlipFvPatchField
+ This boundary condition provides a partial slip condition. The amount of
+ slip is controlled by a user-supplied field.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ valueFraction | fraction od value used for boundary [0-1] | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type partialSlip;
+ valueFraction uniform 0.1;
+ value uniform 0;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::transformFvPatchField
SourceFiles
partialSlipFvPatchField.C
@@ -43,7 +67,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class partialSlipFvPatch Declaration
+ Class partialSlipFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/phaseHydrostaticPressure/phaseHydrostaticPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/phaseHydrostaticPressure/phaseHydrostaticPressureFvPatchScalarField.H
index 4c14094f49..cb0c472da4 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/phaseHydrostaticPressure/phaseHydrostaticPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/phaseHydrostaticPressure/phaseHydrostaticPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,16 +24,55 @@ License
Class
Foam::phaseHydrostaticPressureFvPatchScalarField
+Group
+ grpGenericBoundaryConditions
+
Description
- Phase hydrostatic pressure boundary condition calculated as
+ This boundary condition provides a phase-based hydrostatic pressure
+ condition, calculated as:
- pRefValue + rho*g.(x - pRefPoint)
+ \f[
+ p_{hyd} = p_{ref} + \rho g (x - x_{ref})
+ \f]
- where rho is provided and assumed uniform
+ where
+ \vartable
+ p_{hyd} | hyrostatic pressure [Pa]
+ p_{ref} | reference pressure [Pa]
+ x_{ref} | reference point in Cartesian co-ordinates
+ \rho | density (assumed uniform)
+ g | acceleration due to gravity [m/s2]
+ \endtable
- applied according to the phase-fraction field provided:
- 1 -> fix value to that provided
- 0 -> zero-gradient
+ The values are assigned according to the phase-fraction field:
+ - 1: apply \$fp_{hyd}\$f
+ - 0: apply a zero-gradient condition
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phaseName | phase field name | no | alpha
+ rho | density field name | no | rho
+ pRefValue | reference pressure [Pa] | yes |
+ pRefPoint | reference pressure location | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type phaseHydrostaticPressure;
+ phaseName alpha1;
+ rho rho;
+ pRefValue 1e5;
+ pRefPoint (0 0 0);
+ value uniform 0; // optional initial value
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::mixedFvPatchScalarField
SourceFiles
phaseHydrostaticPressureFvPatchScalarField.C
@@ -51,7 +90,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class phaseHydrostaticPressureFvPatch Declaration
+ Class phaseHydrostaticPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class phaseHydrostaticPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletOutletVelocity/pressureDirectedInletOutletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletOutletVelocity/pressureDirectedInletOutletVelocityFvPatchVectorField.H
index d9f1a3e2a8..b6e24c73c7 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletOutletVelocity/pressureDirectedInletOutletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletOutletVelocity/pressureDirectedInletOutletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,44 @@ License
Class
Foam::pressureDirectedInletOutletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Velocity inlet/outlet boundary condition for pressure boundary where the
- pressure is specified. zero-gradient is applied for outflow (as defined
- by the flux) and for inflow the velocity is obtained from the flux with
- the specified `inletDirection'.
+ This velocity inlet/outlet boundary condition is applied to pressure
+ boundaries where the pressure is specified. A zero-gradient condtion is
+ applied for outflow (as defined by the flux); for inflow, the velocity
+ is obtained from the flux with the specified inlet direction.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ inletDirection | inlet direction per patch face | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureDirectedInletOutletVelocity;
+ phi phi;
+ rho rho;
+ inletDirection uniform (1 0 0);
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply zero-gradient condition
+ - negative flux (into of domain): derive from the flux with specified
+ direction
+
+SeeAlso
+ Foam::mixedFvPatchVectorField
SourceFiles
pressureDirectedInletOutletVelocityFvPatchVectorField.C
@@ -47,7 +80,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class pressureDirectedInletOutletVelocityFvPatch Declaration
+ Class pressureDirectedInletOutletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class pressureDirectedInletOutletVelocityFvPatchVectorField
@@ -56,8 +89,13 @@ class pressureDirectedInletOutletVelocityFvPatchVectorField
{
// Private data
+ //- Flux field name
word phiName_;
+
+ //- Density field name
word rhoName_;
+
+ //- Inlet direction
vectorField inletDir_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletVelocity/pressureDirectedInletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletVelocity/pressureDirectedInletVelocityFvPatchVectorField.H
index b12dda34fb..c98ad304da 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletVelocity/pressureDirectedInletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureDirectedInletVelocity/pressureDirectedInletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,12 +24,43 @@ License
Class
Foam::pressureDirectedInletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Velocity inlet boundary condition for patches where the pressure is
- specified. The inflow velocity is obtained from the flux with the
- specified "inletDirection" direction. If reverse flow is possible or
- expected use the "pressureDirectedInletOutletVelocityFvPatchVectorField"
- BC instead.
+ This velocity inlet boundary condition is applied to patches where the
+ pressure is specified. The inflow velocity is obtained from the flux with
+ the specified inlet direction" direction.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ inletDirection | inlet direction per patch face | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureDirectedInletVelocity;
+ phi phi;
+ rho rho;
+ inletDirection uniform (1 0 0);
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ If reverse flow is possible or expected use the
+ pressureDirectedInletOutletVelocityFvPatchVectorField condition instead.
+
+
+SeeAlso
+ Foam::fixedValueFvPatchField
+ Foam::pressureDirectedInletOutletVelocityFvPatchVectorField
SourceFiles
pressureDirectedInletVelocityFvPatchVectorField.C
@@ -48,7 +79,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class pressureDirectedInletVelocityFvPatch Declaration
+ Class pressureDirectedInletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class pressureDirectedInletVelocityFvPatchVectorField
@@ -57,8 +88,13 @@ class pressureDirectedInletVelocityFvPatchVectorField
{
// Private data
+ //- Flux field name
word phiName_;
+
+ //- Density field name
word rhoName_;
+
+ //- Inlet direction
vectorField inletDir_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletParSlipVelocity/pressureInletOutletParSlipVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletParSlipVelocity/pressureInletOutletParSlipVelocityFvPatchVectorField.H
index afab477fbc..f1f2f3a9d3 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletParSlipVelocity/pressureInletOutletParSlipVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletParSlipVelocity/pressureInletOutletParSlipVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,13 +24,45 @@ License
Class
Foam::pressureInletOutletParSlipVelocityFvPatchVectorField
-Description
- Velocity inlet/outlet boundary condition for pressure boundary where the
- pressure is specified. zero-gradient is applied for outflow (as defined
- by the flux) and for inflow the velocity is obtained from the flux with
- the specified `inletDirection'.
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
- Slip condition applied tangential to the patch.
+Description
+ This velocity inlet/outlet boundary condition for pressure boundary where
+ the pressure is specified. A zero-gradient is applied for outflow (as
+ defined by the flux); for inflow, the velocity is obtained from the flux
+ with the specified inlet direction.
+
+ A slip condition is applied tangential to the patch.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureInletOutletParSlipVelocity;
+ phi phi;
+ rho rho;
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply zero-gradient condition
+ - negative flux (into of domain): derive from the flux with specified
+ direction
+
+SeeAlso
+ Foam::mixedFvPatchVectorField
+ Foam::pressureDirectedInletOutletVelocityFvPatchVectorField
SourceFiles
pressureInletOutletParSlipVelocityFvPatchVectorField.C
@@ -58,7 +90,10 @@ class pressureInletOutletParSlipVelocityFvPatchVectorField
{
// Private data
+ //- Flux field name
word phiName_;
+
+ //- Density field name
word rhoName_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletVelocity/pressureInletOutletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletVelocity/pressureInletOutletVelocityFvPatchVectorField.H
index 174142e5ec..1ed301b191 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletVelocity/pressureInletOutletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletOutletVelocity/pressureInletOutletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,41 @@ License
Class
Foam::pressureInletOutletVelocityFvPatchVectorField
+Group
+ grpInletletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Velocity inlet/outlet boundary condition patches for where the pressure is
- specified. zero-gradient is applied for outflow (as defined by the flux)
- and for inflow the velocity is obtained from the patch-face normal
- component of the internal-cell value.
+ This velocity inlet/outlet boundary condition is applied to pressure
+ boundaries where the pressure is specified. A zero-gradient condtion is
+ applied for outflow (as defined by the flux); for inflow, the velocity is
+ obtained from the patch-face normal component of the internal-cell value.
+
+ The tangential patch velocity can be optionally specified.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ tangentialVelocity | tangential velocity field | no |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureInletOutletVelocity;
+ phi phi;
+ tangentialVelocity uniform (0 0 0);
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply zero-gradient condition
+ - negative flux (into of domain): derive from the flux in the patch-normal
+ direction
SourceFiles
pressureInletOutletVelocityFvPatchVectorField.C
@@ -47,7 +77,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class pressureInletOutletVelocityFvPatch Declaration
+ Class pressureInletOutletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class pressureInletOutletVelocityFvPatchVectorField
@@ -56,6 +86,7 @@ class pressureInletOutletVelocityFvPatchVectorField
{
// Private data
+ //- Flux field name
word phiName_;
//- Optional tangential velocity component
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletUniformVelocity/pressureInletUniformVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletUniformVelocity/pressureInletUniformVelocityFvPatchVectorField.H
index 69c1d54c56..d22757c672 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletUniformVelocity/pressureInletUniformVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletUniformVelocity/pressureInletUniformVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,10 +24,25 @@ License
Class
Foam::pressureInletUniformVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Velocity inlet boundary condition for patches where the pressure is
- specified. The uniform inflow velocity is obtained by averaging the flux
- over the patch and apply it in the direction normal to the patch faces.
+ This velocity inlet boundary condition is applied to patches where the
+ pressure is specified. The uniform inflow velocity is obtained by
+ averaging the flux over the patch, and then applying it in the direction
+ normal to the patch faces.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureInletUniformVelocity;
+ value uniform 0;
+ }
+ \endverbatim
SourceFiles
pressureInletUniformVelocityFvPatchVectorField.C
@@ -45,7 +60,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class pressureInletUniformVelocityFvPatch Declaration
+ Class pressureInletUniformVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class pressureInletUniformVelocityFvPatchVectorField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletVelocity/pressureInletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletVelocity/pressureInletVelocityFvPatchVectorField.H
index c50d53d590..12b7d8bec5 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureInletVelocity/pressureInletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureInletVelocity/pressureInletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,34 @@ License
Class
Foam::pressureInletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Velocity inlet boundary condition for patches where the pressure is
- specified. The inflow velocity is obtained from the flux with a direction
- normal to the patch faces. If reverse flow is possible or expected use
- the "pressureInletOutletVelocityFvPatchVectorField" BC instead.
+ This velocity inlet boundary condition is applied to patches where the
+ pressure is specified. The inflow velocity is obtained from the flux with
+ a direction normal to the patch faces.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureInletVelocity;
+ phi phi;
+ rho rho;
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ If reverse flow is possible or expected use
+ the pressureInletOutletVelocityFvPatchVectorField condition instead.
+
+SeeAlso
+ Foam::fixedValueFvPatchField
+ Foam::pressureInletOutletVelocityFvPatchVectorField
SourceFiles
pressureInletVelocityFvPatchVectorField.C
@@ -47,7 +70,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class pressureInletVelocityFvPatch Declaration
+ Class pressureInletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class pressureInletVelocityFvPatchVectorField
@@ -56,7 +79,10 @@ class pressureInletVelocityFvPatchVectorField
{
// Private data
+ //- Flux field name
word phiName_;
+
+ //- Density field name
word rhoName_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/pressureNormalInletOutletVelocity/pressureNormalInletOutletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/pressureNormalInletOutletVelocity/pressureNormalInletOutletVelocityFvPatchVectorField.H
index 04351a477a..c138b18f69 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/pressureNormalInletOutletVelocity/pressureNormalInletOutletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/pressureNormalInletOutletVelocity/pressureNormalInletOutletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,11 +24,42 @@ License
Class
Foam::pressureNormalInletOutletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Velocity inlet/outlet boundary condition for patches where the pressure is
- specified. zero-gradient is applied for outflow (as defined by the flux)
- and for inflow the velocity is obtained from the flux with a direction
- normal to the patch faces.
+ This velocity inlet/outlet boundary condition is applied to patches where
+ the pressure is specified. A zero-gradient condition is applied for
+ outflow (as defined by the flux); for inflow, the velocity is obtained from
+ the flux with a direction normal to the patch faces.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type pressureNormalInletOutletVelocity;
+ phi phi;
+ rho rho;
+ value uniform 0;
+ }
+ \endverbatim
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply zero-gradient condition
+ - negative flux (into of domain): derive from the flux and patch-normal
+ direction
+
+SeeAlso
+ Foam::mixedFvPatchVectorField
SourceFiles
pressureNormalInletOutletVelocityFvPatchVectorField.C
@@ -47,7 +78,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class pressureNormalInletOutletVelocityFvPatch Declaration
+ Class pressureNormalInletOutletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class pressureNormalInletOutletVelocityFvPatchVectorField
@@ -56,7 +87,10 @@ class pressureNormalInletOutletVelocityFvPatchVectorField
{
// Private data
+ //- Flux field name
word phiName_;
+
+ //- Density field name
word rhoName_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/rotatingPressureInletOutletVelocity/rotatingPressureInletOutletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/rotatingPressureInletOutletVelocity/rotatingPressureInletOutletVelocityFvPatchVectorField.H
index 0635857518..cc114d7c6b 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/rotatingPressureInletOutletVelocity/rotatingPressureInletOutletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/rotatingPressureInletOutletVelocity/rotatingPressureInletOutletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,12 +24,47 @@ License
Class
Foam::rotatingPressureInletOutletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Velocity inlet/outlet boundary condition in a rotating frame
- for patches where the pressure is specified. zero-gradient is applied for
- outflow (as defined by the flux) and for inflow the velocity is obtained
+ This velocity inlet/outlet boundary condition is applied to patches in a
+ rotating frame where the pressure is specified. A zero-gradient is applied
+ for outflow (as defined by the flux); for inflow, the velocity is obtained
from the flux with a direction normal to the patch faces.
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ tangentialVelocity | tangential velocity field | no |
+ omega | angular velocty of the frame [rad/s] | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type rotatingPressureInletOutletVelocity;
+ phi phi;
+ tangentialVelocity uniform (0 0 0);
+ omega 100;
+ }
+ \endverbatim
+
+ The \c omega entry is a DataEntry type, able to describe time varying
+ functions.
+
+Note
+ Sign conventions:
+ - positive flux (out of domain): apply zero-gradient condition
+ - negative flux (into of domain): derive from the flux in the patch-normal
+ direction
+
+SeeAlso
+ Foam::pressureInletOutletVelocityFvPatchVectorField
+
SourceFiles
rotatingPressureInletOutletVelocityFvPatchVectorField.C
@@ -48,7 +83,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class rotatingPressureInletOutletVelocityFvPatch Declaration
+ Class rotatingPressureInletOutletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class rotatingPressureInletOutletVelocityFvPatchVectorField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/rotatingTotalPressure/rotatingTotalPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/rotatingTotalPressure/rotatingTotalPressureFvPatchScalarField.H
index 68e1d19c8f..22d806c377 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/rotatingTotalPressure/rotatingTotalPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/rotatingTotalPressure/rotatingTotalPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,46 @@ License
Class
Foam::rotatingTotalPressureFvPatchScalarField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Foam::rotatingTotalPressureFvPatchScalarField
+ This boundary condition provides a total pressure condition for patches
+ in a rotating frame.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | velocity field name | no | U
+ phi | flux field name | no | phi
+ rho | density field name | no | none
+ psi | compressibility field name | no | none
+ gamma | ratio of specific heats (Cp/Cv) | yes |
+ p0 | static pressure reference | yes |
+ omega | angular velocty of the frame [rad/s] | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type rotatingTotalPressure;
+ U U;
+ phi phi;
+ rho rho;
+ psi psi;
+ gamma 1.4;
+ p0 uniform 1e5;
+ omega 100;
+ }
+ \endverbatim
+
+ The \c omega entry is a DataEntry type, able to describe time varying
+ functions.
+
+SeeAlso
+ Foam::totalPressureFvPatchScalarField
SourceFiles
rotatingTotalPressureFvPatchScalarField.C
@@ -44,7 +82,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class rotatingTotalPressureFvPatch Declaration
+ Class rotatingTotalPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class rotatingTotalPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/rotatingWallVelocity/rotatingWallVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/rotatingWallVelocity/rotatingWallVelocityFvPatchVectorField.H
index 41f821c6d8..a3d5d5686e 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/rotatingWallVelocity/rotatingWallVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/rotatingWallVelocity/rotatingWallVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,38 @@ License
Class
Foam::rotatingWallVelocityFvPatchVectorField
+Group
+ grpWallBoundaryConditions grpGenericBoundaryConditions
+
Description
- Foam::rotatingWallVelocityFvPatchVectorField
+ This boundary condition provides a rotational velocity condition.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ origin | origin of rotation in Cartesian co-ordinates | yes|
+ axis | axis of rotation | yes |
+ omega | angular velocty of the frame [rad/s] | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type rotatingWallVelocity;
+ origin (0 0 0);
+ axis (0 0 1);
+ omega 100;
+ }
+ \endverbatim
+
+ The \c omega entry is a DataEntry type, able to describe time varying
+ functions.
+
+SeeAlso
+ Foam::DataEntry
+ Foam::fixedValueFvPatchField
SourceFiles
rotatingWallVelocityFvPatchVectorField.C
@@ -44,7 +74,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class rotatingWallVelocityFvPatch Declaration
+ Class rotatingWallVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class rotatingWallVelocityFvPatchVectorField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.H
index 19e740ad8d..ee50d19881 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/slip/slipFvPatchField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,21 @@ License
Class
Foam::slipFvPatchField
+Group
+ grpWallBoundaryConditions grpGenericBoundaryConditions
+
Description
- Foam::slipFvPatchField
+ This boundary condition provides a slip constraint.
+
+ \heading Patch usage
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type slip;
+ }
+ \endverbatim
SourceFiles
slipFvPatchField.C
@@ -43,7 +56,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class slipFvPatch Declaration
+ Class slipFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/supersonicFreestream/supersonicFreestreamFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/supersonicFreestream/supersonicFreestreamFvPatchVectorField.H
index 2115ac392d..402fc365f3 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/supersonicFreestream/supersonicFreestreamFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/supersonicFreestream/supersonicFreestreamFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,18 +24,43 @@ License
Class
Foam::supersonicFreestreamFvPatchVectorField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Supersonic free stream condition.
+ This boundary condition provides a supersonic free-stream condition.
- Supersonic outflow is vented according to ???
+ - supersonic outflow is vented according to ???
+ - supersonic inflow is assumed to occur according to the Prandtl-Meyer
+ expansion process.
+ - subsonic outflow is applied via a zero-gradient condition from inside
+ the domain.
- Supersonic inflow is assumed to occur according to the Prandtl-Meyer
- expansion process.
+ \heading Patch usage
- Subsonic outflow is zero-gradiented from inside the domain.
+ \table
+ Property | Description | Required | Default value
+ UInf | free-stream velocity | yes |
+ pInf | free-stream pressure | yes |
+ TInf | free-stream temperature | yes |
+ gamma | heat capacity ratio (cp/Cv) | yes |
+ \endtable
- N.B. This boundary condition is ill-posed if the free-stream flow is
- normal to the boundary.
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type supersonicFreestream;
+ UInf 500;
+ pInf 1e4;
+ TInf 265;
+ gamma 1.4;
+ }
+ \endverbatim
+
+Note
+ This boundary condition is ill-posed if the free-stream flow is normal
+ to the boundary.
SourceFiles
supersonicFreestreamFvPatchVectorField.C
@@ -54,7 +79,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class supersonicFreestreamFvPatch Declaration
+ Class supersonicFreestreamFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class supersonicFreestreamFvPatchVectorField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/surfaceNormalFixedValue/surfaceNormalFixedValueFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/surfaceNormalFixedValue/surfaceNormalFixedValueFvPatchVectorField.H
index 465d875c68..e0068654fd 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/surfaceNormalFixedValue/surfaceNormalFixedValueFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/surfaceNormalFixedValue/surfaceNormalFixedValueFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,9 +24,35 @@ License
Class
Foam::surfaceNormalFixedValueFvPatchVectorField
+Group
+ grpGenericBoundaryConditions grpInletBoundaryConditions
+
Description
- Describes a surface normal vector boundary condition by its magnitude.
- Note: The value is positive for outward-pointing vectors
+ This boundary condition provides a surface-normal vector boundary condition
+ by its magnitude.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ refValue | reference value | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type surfaceNormalFixedValue;
+ refValue -10; // 10 INTO the domain
+ }
+ \endverbatim
+
+Note
+ Sign conventions:
+ - the value is positive for outward-pointing vectors
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
surfaceNormalFixedValueFvPatchVectorField.C
@@ -45,7 +71,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class surfaceNormalFixedValueFvPatch Declaration
+ Class surfaceNormalFixedValueFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class surfaceNormalFixedValueFvPatchVectorField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/swirlFlowRateInletVelocity/swirlFlowRateInletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/swirlFlowRateInletVelocity/swirlFlowRateInletVelocityFvPatchVectorField.H
index ef2ea8b9c9..a53dd0ca12 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/swirlFlowRateInletVelocity/swirlFlowRateInletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/swirlFlowRateInletVelocity/swirlFlowRateInletVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,32 +24,47 @@ License
Class
Foam::swirlFlowRateInletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Describes a volumetric/mass flow normal vector boundary condition by its
- magnitude as an integral over its area with a swirl component determined
- by the RPM
+ This boundary condition provides a volumetric- OR mass-flow normal vector
+ boundary condition by its magnitude as an integral over its area with a
+ swirl component determined by the angular speed, given in revolutions per
+ minute (RPM)
The basis of the patch (volumetric or mass) is determined by the
- dimensions of the flux, phi.
- The current density is used to correct the velocity when applying the
- mass basis.
+ dimensions of the flux, phi. The current density is used to correct the
+ velocity when applying the mass basis.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ rho | density field name | no | rho
+ flowRate | flow rate profile | yes |
+ rpm | rotational speed profile | yes |
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
+ myPatch
{
type swirlFlowRateInletVelocity;
- flowRate constant 0.2; // Vol/mass flow rate [m3/s or kg/s]
+ flowRate constant 0.2;
rpm constant 100;
}
\endverbatim
- The flowRate and rpm entries are DataEntry types, able to describe time
- varying functions. The example above gives the usage for supplying
- constant values.
-
Note
- - The value is positive inwards
+ - the \c flowRate and \c rpm entries are DataEntry types, able to describe
+ time varying functions. The example above gives the usage for supplying
+ constant values.
+ - the value is positive into the domain
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
swirlFlowRateInletVelocityFvPatchVectorField.C
@@ -67,7 +82,7 @@ SourceFiles
namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class swirlFlowRateInletVelocityFvPatchVectorField Declaration
+ Class swirlFlowRateInletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class swirlFlowRateInletVelocityFvPatchVectorField
@@ -85,7 +100,7 @@ class swirlFlowRateInletVelocityFvPatchVectorField
//- Inlet integral flow rate
autoPtr > flowRate_;
- //- RPM
+ //- Angular speed in revolutions per minute (RPM)
autoPtr > rpm_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.H
index aa2bec48af..c4dc0a1e4f 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/syringePressure/syringePressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,9 +24,12 @@ License
Class
Foam::syringePressureFvPatchScalarField
+Group
+ grpInletBoundaryConditions
+
Description
- Pressure boundary condition obtained from a 0-D model of the cylinder
- of a syringe.
+ This boundary condition provides a pressure condition, obtained from a
+ zero-D model of the cylinder of a syringe.
The syringe cylinder is defined by its initial volume, piston area and
velocity profile specified by regions of constant acceleration, speed
@@ -34,25 +37,44 @@ Description
pressure and compressibility which is assumed constant, i.e. isothermal
expansion/compression.
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ Ap | syringe piston area [m2] | yes |
+ Sp | syringe piston speed [m/s] | yes |
+ VsI | initial syringe volume [m3] | yes |
+ tas | start of piston acceleration [s] | yes |
+ tae | end of piston acceleration [s] | yes |
+ tds | start of piston deceleration [s] | yes |
+ tde | end of piston deceleration [s] | yes |
+ psI | initial syringe pressure [Pa] | yes |
+ psi | gas compressibility [m2/s2] | yes |
+ ams | added (or removed) gas mass [kg] | yes |
+ \endtable
+
Example of the BC specification:
\verbatim
- outlet
- {
- type syringePressure;
- Ap 1.388e-6; // syringe piston area
- Sp 0.01; // syringe piston speed
- VsI 1.388e-8; // Initial syringe volume
- tas 0.001; // Start of piston acceleration
- tae 0.002; // End of piston acceleration
- tds 0.005; // Start of piston deceleration
- tde 0.006; // end of piston deceleration
- psI 1e5; // Initial syringe pressure
- psi 1e-5; // Gas compressibility
- ams 0; // Added (or removed) gas mass
- // Initially 0 but used for restarting.
- }
+ myPatch
+ {
+ type syringePressure;
+ Ap 1.388e-6;
+ Sp 0.01;
+ VsI 1.388e-8;
+ tas 0.001;
+ tae 0.002;
+ tds 0.005;
+ tde 0.006;
+ psI 1e5;
+ psi 1e-5;
+ ams 0;
+ value uniform 0;
+ }
\endverbatim
+SeeAlso
+ Foam::fixedValueFvPatchField
+
SourceFiles
syringePressureFvPatchScalarField.C
@@ -69,7 +91,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class syringePressureFvPatch Declaration
+ Class syringePressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class syringePressureFvPatchScalarField
@@ -115,7 +137,9 @@ class syringePressureFvPatchScalarField
label curTimeIndex_;
- //- return the volume of the syringe at time t
+ // Private Functions
+
+ //- Return the volume of the syringe at time t
scalar Vs(const scalar t) const;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/temperatureJump/temperatureJumpFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/temperatureJump/temperatureJumpFvPatchScalarField.H
index 55364eac5d..0663a1cb86 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/temperatureJump/temperatureJumpFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/temperatureJump/temperatureJumpFvPatchScalarField.H
@@ -24,15 +24,43 @@ License
Class
Foam::temperatureJumpFvPatchScalarField
+Group
+ grpCoupledBoundaryConditions
+
Description
- Introduce a jump in temperature on a cycle patch
- front
+ This boundary condition provides a temperature jump condition across a
+ coupled pair of cyclic patches.
+
+ The jump is specified as a \c DataEntry type, to enable the use of, e.g.
+ contant, polynomial, table values.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ patchType | underlying patch type should be \c cyclic| yes |
+ jump | current jump value | yes |
+ jumpTable | jump data, e.g. \c csvFile | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
{
type temperatureJump;
patchType cyclic;
jumpTable constant 100;
value uniform 300;
}
+ \endverbatim
+
+ The above example shows the use of a constant jump condition.
+
+Note
+ The underlying \c patchType should be set to \c cyclic
+
+SeeAlso
+ Foam::fixedJumpFvPatchField
SourceFiles
temperatureJumpFvPatchScalarField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.H
index 82525ec49a..61228fe07c 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/timeVaryingMappedFixedValue/timeVaryingMappedFixedValueFvPatchField.H
@@ -24,39 +24,50 @@ License
Class
Foam::timeVaryingMappedFixedValueFvPatchField
+Group
+ grpInletBoundaryConditions grpCoupledBoundaryConditions
+
Description
- Foam::timeVaryingMappedFixedValueFvPatchField
+ This boundary conditions interpolates the values from a set of supplied
+ points in space and time. Supplied data should be specified in
+ constant/boundaryData/\ where:
+ - points : pointField with locations
+ - ddd : supplied values at time ddd
+ The points should be more or less on a plane since they get triangulated
+ in 2-D.
- Interpolates from a set of supplied points in space and time. Supplied
- data in constant/boundaryData/:
- - points : pointField with locations
- - ddd : supplied values at time ddd
- Points need to be more or less on a plane since get triangulated in 2D.
+ At startup, this condition generates the triangulation and performs a
+ linear interpolation (triangle it is in and weights to the 3 vertices)
+ for every face centre.
- At startup this bc does the triangulation and determines linear
- interpolation (triangle it is in and weights to the 3 vertices)
- for every face centre. Interpolates linearly inbetween times.
+ Values are interpolated linearly between times.
- @verbatim
- inlet
- {
- type timeVaryingMappedFixedValue;
+ \heading Patch usage
- // Maintain average to that of the supplied values
- setAverage false;
+ \table
+ Property | Description | Required | Default value
+ setAverage | flag to activate setting of average value | yes |
+ perturb | perturb points for regular geometries | no | 1e-5
+ fieldTableName | alternative field name to sample | no| this field name
+ \endtable
- // Optional: change perturbation (default 1e-5) to avoid any ties
- // in triangulating regular geometries.
- //perturb 0.0;
-
- // Optional: use name instead of patchname for location of data
- //fieldTableName samples;
- }
- @endverbatim
+ /verbatim
+ myPatch
+ {
+ type timeVaryingMappedFixedValue;
+ setAverage false;
+ //perturb 0.0;
+ //fieldTableName samples;
+ }
+ /endverbatim
+Note
Switch on debug flag to have it dump the triangulation (in transformed
space) and transform face centres.
+SeeAlso
+ Foam::fixedValueFvPatchField
+
SourceFiles
timeVaryingMappedFixedValueFvPatchField.C
@@ -76,7 +87,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class timeVaryingMappedFixedValueFvPatch Declaration
+ Class timeVaryingMappedFixedValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
@@ -119,6 +130,7 @@ class timeVaryingMappedFixedValueFvPatchField
//- If setAverage: end average value
Type endAverage_;
+
public:
//- Runtime type information
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H
index c95f15771c..05bd6b1800 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/totalPressure/totalPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,102 @@ License
Class
Foam::totalPressureFvPatchScalarField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Foam::totalPressureFvPatchScalarField
+ This boundary condition provides a total pressure condition. Four
+ variants are possible:
+
+ 1. incompressible subsonic:
+ \f[
+ p_T = p_0 + 0.5 |U|^2
+ \f]
+ where
+ \vartable
+ p_T | incompressible total pressure [m2/s2]
+ p_0 | incompressible reference pressure [m2/s2]
+ U | velocity
+ \endvartable
+
+ 2. compressible subsonic:
+ \f[
+ p_T = p_0 + 0.5 \rho |U|^2
+ \f]
+ where
+ \vartable
+ p_T | total pressure [Pa]
+ p_0 | reference pressure [Pa]
+ \rho | density [kg/m3]
+ U | velocity
+ \endvartable
+
+ 3. compressible transonic (\gamma <= 1):
+ \f[
+ p_T = \frac{p_0}{1 + 0.5 \psi |U|^2}
+ \f]
+ where
+ \vartable
+ p_T | total pressure [Pa]
+ p_0 | reference pressure [Pa]
+ G | coefficient given by \f$\frac{\gamma}{1-\gamma}\f$
+ \endvartable
+
+ 4. compressible supersonic (\gamma > 1):
+ \f[
+ p_T = \frac{p_0}{(1 + 0.5 \psi G)^{\frac{1}{G}}}
+ \f]
+ where
+ \vartable
+ \gamma | ratio of specific heats (Cp/Cv)
+ p_T | total pressure [Pa]
+ p_0 | reference pressure [Pa]
+ \psi | compressibility [m2/s2]
+ G | coefficient given by \f$\frac{\gamma}{1-\gamma}\f$
+ \endvartable
+
+ The modes of operation are set via the combination of \c phi, \c rho, and
+ \c psi entries:
+ \table
+ Mode | phi | rho | psi
+ incompressible subsonic | phi | none | none
+ compressible subsonic | phi | rho | none
+ compressible transonic | phi | none | psi
+ compressible supersonic | phi | none | psi
+ \endtable
+
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | velocity field name | no | U
+ phi | flux field name | no | phi
+ rho | density field name | no | none
+ psi | compressibility field name | no | none
+ gamma | ratio of specific heats (Cp/Cv) | yes |
+ p0 | static pressure reference | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type totalPressure;
+ U U;
+ phi phi;
+ rho none;
+ psi none;
+ gamma 1.4;
+ p0 uniform 1e5;
+ }
+ \endverbatim
+
+Note
+ The default boundary behaviour is for subsonic, incompressible flow.
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
totalPressureFvPatchScalarField.C
@@ -43,7 +137,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class totalPressureFvPatch Declaration
+ Class totalPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class totalPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/totalTemperature/totalTemperatureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/totalTemperature/totalTemperatureFvPatchScalarField.H
index 7f6137709b..d793696ade 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/totalTemperature/totalTemperatureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/totalTemperature/totalTemperatureFvPatchScalarField.H
@@ -24,12 +24,38 @@ License
Class
Foam::totalTemperatureFvPatchScalarField
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
+
Description
- Foam::totalTemperatureFvPatchScalarField
+ This boundary condition provides a total temperature condition.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | Velocity field name | no | U
+ phi | Flux field name | no | phi
+ psi | Compressibility field name | no | psi
+ gamma | ratio of specific heats (Cp/Cv) | yes |
+ T0 | reference temperature | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type totalTemperature;
+ T0 uniform 300;
+ }
+ \endverbatim
SourceFiles
totalTemperatureFvPatchScalarField.C
+SeeAlso
+ Foam::fixedValueFvPatchField
+
\*---------------------------------------------------------------------------*/
#ifndef totalTemperatureFvPatchScalarField_H
@@ -43,7 +69,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class totalTemperatureFvPatch Declaration
+ Class totalTemperatureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class totalTemperatureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/translatingWallVelocity/translatingWallVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/translatingWallVelocity/translatingWallVelocityFvPatchVectorField.H
index e19d1265e7..c6e9c70b88 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/translatingWallVelocity/translatingWallVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/translatingWallVelocity/translatingWallVelocityFvPatchVectorField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,8 +24,32 @@ License
Class
Foam::translatingWallVelocityFvPatchVectorField
+Group
+ grpWallBoundaryConditions grpGenericBoundaryConditions
+
Description
- Foam::translatingWallVelocityFvPatchVectorField
+ This boundary condition provides a velocity condition for translational
+ motion on walls.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | translational velocity | yes|
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type translatingWallVelocity;
+ U (100 0 0);
+ }
+ \endverbatim
+
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
translatingWallVelocityFvPatchVectorField.C
@@ -43,7 +67,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class translatingWallVelocityFvPatchField Declaration
+ Class translatingWallVelocityFvPatchField Declaration
\*---------------------------------------------------------------------------*/
class translatingWallVelocityFvPatchVectorField
@@ -52,7 +76,7 @@ class translatingWallVelocityFvPatchVectorField
{
// Private data
- //- Origin of the rotation
+ //- Translational velocity
vector U_;
@@ -124,7 +148,6 @@ public:
}
-
// Member functions
// Access functions
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.H
index a7b3272c13..3917d167bd 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/turbulentInlet/turbulentInletFvPatchField.H
@@ -24,18 +24,50 @@ License
Class
Foam::turbulentInletFvPatchField
+Group
+ grpInletBoundaryConditions
+
Description
- Generate a fluctuating inlet condition by adding a random component
- to a reference (mean) field.
- Input:
- referenceField
- Mean field.
- fluctuationScale
- RMS fluctuation, provided as the fraction of the mean field.
- alpha
- temporal correlation factor;
- the fraction of the new random component added to the previous
- time-step (defaults to 0.1).
+ This boundary condition generates a fluctuating inlet condition by adding
+ a random component to a reference (mean) field.
+
+ \f[
+ x_p = (1 - \alpha) x_p^{n-1} + \alpha (x_{ref} + s C_{RMS} x_{ref})
+ \f]
+
+ where
+
+ \vartable
+ x_p | patch values
+ x_{ref} | refernce patch values
+ n | time level
+ \alpha | fraction of new random component added to previous time value
+ C_{RMS} | RMS coefficient
+ s | fluctuation scale
+ \endvartable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ fluctuationScale | RMS fluctuation scale (fraction of mean) | yes |
+ referenceField | reference (mean) field | yes |
+ alpha | fraction of new random component added to previous| no| 0.1
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type turbulentInlet;
+ fluctuationScale 0.1;
+ referenceField uniform 10;
+ alpha 0.1;
+ }
+ \endverbatim
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
turbulentInletFvPatchField.C
@@ -54,7 +86,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class turbulentInletFvPatch Declaration
+ Class turbulentInletFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
@@ -64,10 +96,19 @@ class turbulentInletFvPatchField
{
// Private data
+ //- Random number generator
Random ranGen_;
+
+ //- Fluctuation scake
Type fluctuationScale_;
+
+ //- Reference field
Field referenceField_;
+
+ //- Fraction of RMS component to apply to last time step values
scalar alpha_;
+
+ //- Current time index (used for updating)
label curTimeIndex_;
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.C b/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.C
index 7d650f6eb7..7689d3d763 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -40,8 +40,8 @@ turbulentIntensityKineticEnergyInletFvPatchScalarField
:
inletOutletFvPatchScalarField(p, iF),
intensity_(0.0),
- UName_("undefined-U"),
- phiName_("undefined-phi")
+ UName_("U"),
+ phiName_("phi")
{
this->refValue() = 0.0;
this->refGrad() = 0.0;
@@ -82,12 +82,15 @@ turbulentIntensityKineticEnergyInletFvPatchScalarField
(
"turbulentIntensityKineticEnergyInletFvPatchScalarField::"
"turbulentIntensityKineticEnergyInletFvPatchScalarField"
- "(const fvPatch& p, const DimensionedField& iF, "
- "const dictionary& dict)"
+ "("
+ "const fvPatch&, "
+ "const DimensionedField&, "
+ "const dictionary&"
+ ")"
) << "Turbulence intensity should be specified as a fraction 0-1 "
"of the mean velocity\n"
- " value given is " << intensity_
- << "\n on patch " << this->patch().name()
+ " value given is " << intensity_ << nl
+ << " on patch " << this->patch().name()
<< " of field " << this->dimensionedInternalField().name()
<< " in file " << this->dimensionedInternalField().objectPath()
<< exit(FatalError);
@@ -157,8 +160,8 @@ void Foam::turbulentIntensityKineticEnergyInletFvPatchScalarField::write
{
fvPatchScalarField::write(os);
os.writeKeyword("intensity") << intensity_ << token::END_STATEMENT << nl;
- os.writeKeyword("U") << UName_ << token::END_STATEMENT << nl;
- os.writeKeyword("phi") << phiName_ << token::END_STATEMENT << nl;
+ writeEntryIfDifferent(os, "U", "U", UName_);
+ writeEntryIfDifferent(os, "phi", "phi", phiName_);
writeEntry("value", os);
}
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.H
index 1663364d10..b2d1f2123e 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/turbulentIntensityKineticEnergyInlet/turbulentIntensityKineticEnergyInletFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,20 +24,50 @@ License
Class
Foam::turbulentIntensityKineticEnergyInletFvPatchScalarField
+Group
+ grpInletBoundaryConditions
+
Description
- Calculate turbulent kinetic energy from the intensity provided as a
- fraction of the mean velocity
+ This boundary condition provides a turbulent kinetic energy condition,
+ based on user-supplied turbulence intensity, defined as a fraction of the
+ mean velocity:
+
+ \f[
+ k_p = 1.5 I |U|^2
+ \f]
+
+ where
+
+ \vartable
+ k_p | kinetic energy at the patch
+ I | turbulence intensity
+ U | velocity field
+ \endvartable
+
+ In the event of reverse flow, a zero-gradient condition is applied.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ intensity | fraction of mean field [0-1] | yes |
+ U | velocity field name | no | U
+ phi | flux field name | no | phi
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
- {
- type turbulentIntensityKineticEnergyInlet;
- intensity 0.05; // 5% turbulence
- value uniform 1; // placeholder
- }
+ myPatch
+ {
+ type turbulentIntensityKineticEnergyInlet;
+ intensity 0.05; // 5% turbulence
+ value uniform 1; // placeholder
+ }
\endverbatim
+SeeAlso
+ Foam::inletOutletFvPatchField
+
SourceFiles
turbulentIntensityKineticEnergyInletFvPatchScalarField.C
@@ -54,7 +84,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class turbulentIntensityKineticEnergyInletFvPatch Declaration
+ Class turbulentIntensityKineticEnergyInletFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class turbulentIntensityKineticEnergyInletFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/uniformDensityHydrostaticPressure/uniformDensityHydrostaticPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/uniformDensityHydrostaticPressure/uniformDensityHydrostaticPressureFvPatchScalarField.H
index b199d3e8eb..ff3c925863 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/uniformDensityHydrostaticPressure/uniformDensityHydrostaticPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/uniformDensityHydrostaticPressure/uniformDensityHydrostaticPressureFvPatchScalarField.H
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -24,12 +24,46 @@ License
Class
Foam::uniformDensityHydrostaticPressureFvPatchScalarField
+Group
+ grpGenericBoundaryConditions
+
Description
- Hydrostatic pressure boundary condition calculated as
+ This boundary condition provides a hydrostatic pressure condition,
+ calculated as:
- pRefValue + rho*g.(x - pRefPoint)
+ \f[
+ p_{hyd} = p_{ref} + \rho g (x - x_{ref})
+ \f]
- where rho is provided and assumed uniform.
+ where
+ \vartable
+ p_{hyd} | hyrostatic pressure [Pa]
+ p_{ref} | reference pressure [Pa]
+ x_{ref} | reference point in Cartesian co-ordinates
+ \rho | density (assumed uniform)
+ g | acceleration due to gravity [m/s2]
+ \endtable
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ rho | uniform density [kg/m3] | yes |
+ pRefValue | reference pressure [Pa] | yes |
+ pRefPoint | reference pressure location | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type uniformDensityHydrostaticPressure;
+ rho rho;
+ pRefValue 1e5;
+ pRefPoint (0 0 0);
+ value uniform 0; // optional initial value
+ }
+ \endverbatim
SourceFiles
uniformDensityHydrostaticPressureFvPatchScalarField.C
@@ -47,7 +81,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class uniformDensityHydrostaticPressureFvPatch Declaration
+ Class uniformDensityHydrostaticPressureFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class uniformDensityHydrostaticPressureFvPatchScalarField
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/uniformFixedValue/uniformFixedValueFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/uniformFixedValue/uniformFixedValueFvPatchField.H
index cd6445babf..072d02f1b6 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/uniformFixedValue/uniformFixedValueFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/uniformFixedValue/uniformFixedValueFvPatchField.H
@@ -24,22 +24,36 @@ License
Class
Foam::uniformFixedValueFvPatchField
+Group
+ grpGenericBoundaryConditions
+
Description
- Enables the specification of a uniform fixed value boundary condition.
+ This boundary condition provides a uniform fixed value condition.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ uniformValue | uniform value | yes |
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
+ myPatch
{
type uniformFixedValue;
uniformValue constant 0.2;
}
\endverbatim
+Note
The uniformValue entry is a DataEntry type, able to describe time
varying functions. The example above gives the usage for supplying a
constant value.
+SeeAlso
+ Foam::DataEntry
+ Foam::fixedValueFvPatchField
SourceFiles
uniformFixedValueFvPatchField.C
@@ -58,7 +72,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class uniformFixedValueFvPatch Declaration
+ Class uniformFixedValueFvPatchField Declaration
\*---------------------------------------------------------------------------*/
template
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H b/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H
index 325ed6e471..b5888fdf86 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/uniformTotalPressure/uniformTotalPressureFvPatchScalarField.H
@@ -24,13 +24,50 @@ License
Class
Foam::uniformTotalPressureFvPatchScalarField
-Description
- A time-varying form of a uniform total pressure boundary condition. The
- variation is specified as an DataEntry (see Foam::DataEntry).
+Group
+ grpInletBoundaryConditions grpOutletBoundaryConditions
-See Also
- Foam::uniformFixedValueFvPatchField.H
- and Foam::totalPressureFvPatchScalarField.H
+Description
+ This boundary condition provides a time-varying form of the uniform total
+ pressure boundary condition.
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ U | velocity field name | no | U
+ phi | flux field name | no | phi
+ rho | density field name | no | none
+ psi | compressibility field name | no | none
+ gamma | ratio of specific heats (Cp/Cv) | yes |
+ pressure | total pressure as a function of time | yes |
+ \endtable
+
+ Example of the boundary condition specification:
+ \verbatim
+ myPatch
+ {
+ type uniformTotalPressure;
+ U U;
+ phi phi;
+ rho rho;
+ psi psi;
+ gamma 1.4;
+ pressure uniform 1e5;
+ }
+ \endverbatim
+
+ The \c pressure entry is specified as a DataEntry type, able to describe
+ time varying functions.
+
+Note
+ The default boundary behaviour is for subsonic, incompressible flow.
+
+
+SeeAlso
+ Foam::DataEntry
+ Foam::uniformFixedValueFvPatchField
+ Foam::totalPressureFvPatchField
SourceFiles
uniformTotalPressureFvPatchScalarField.C
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRate/variableHeightFlowRateFvPatchField.H b/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRate/variableHeightFlowRateFvPatchField.H
index 51e8c87899..858dd6c1ce 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRate/variableHeightFlowRateFvPatchField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRate/variableHeightFlowRateFvPatchField.H
@@ -24,25 +24,42 @@ License
Class
Foam::variableHeightFlowRateFvPatchScalarField
+Group
+ grpInletBoundaryConditions
+
Description
- This boundary condition uses zeroGradient within a specified range of
- values for phase fraction alpha. The range is defined within the
- boundary condition by the lowerBound and upperBound.
+ This boundary condition provides a phase fraction condition based on the
+ local flow conditions, whereby the values are constrained to lay between
+ user-specified upper and lower bounds. The behaviour is described by:
- alpha > upperBound: fixedValue with uniform value of upperBound
- lowerBound <= alpha <= upperBound: zeroGradient
- alpha < lowerBound: fixedValue with uniform value of lowerBound
+ if alpha > upperBound:
+ - apply a fixed value condition, with a uniform level of the upper bound
- Example:
- \verbatim
- inlet
- {
- type clippedZeroGradient;
- lowerBound 0.0;
- upperBound 0.9;
- value uniform 0;
- }
+ if lower bound <= alpha <= upper bound:
+ - apply a zero-gradient condition
+
+ if alpha < lowerBound:
+ - apply a fixed value condition, with a uniform level of the lower bound
+
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ phi | flux field name | no | phi
+ lowerBound | lower bound for clipping | yes |
+ upperBound | upper bound for clipping | yes |
+ \endtable
+
+ Example of the boundary condition specification:
\verbatim
+ myPatch
+ {
+ type variableHeightFlowRate;
+ lowerBound 0.0;
+ upperBound 0.9;
+ value uniform 0;
+ }
+ \endverbatim
SourceFiles
variableHeightFlowRateFvPatchScalarField.C
@@ -60,7 +77,7 @@ namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class variableHeightFlowRateFvPatchScalar Declaration
+ Class variableHeightFlowRateFvPatchScalarField Declaration
\*---------------------------------------------------------------------------*/
class variableHeightFlowRateFvPatchScalarField
@@ -81,6 +98,7 @@ protected:
//- Upper bound for alpha1
scalar upperBound_;
+
public:
//- Runtime scalar information
@@ -156,10 +174,6 @@ public:
//- Write
virtual void write(Ostream&) const;
-
-
- // Member operators
-
};
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.C b/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.C
index b33bbc65f1..9b0a6694e7 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.C
@@ -121,8 +121,10 @@ void Foam::variableHeightFlowRateInletVelocityFvPatchVectorField
}
-void Foam::variableHeightFlowRateInletVelocityFvPatchVectorField
-::write(Ostream& os) const
+void Foam::variableHeightFlowRateInletVelocityFvPatchVectorField::write
+(
+ Ostream& os
+) const
{
fvPatchField::write(os);
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.H b/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.H
index d1bc1ac62f..10e6a2c889 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.H
+++ b/src/finiteVolume/fields/fvPatchFields/derived/variableHeightFlowRateInletVelocity/variableHeightFlowRateInletVelocityFvPatchVectorField.H
@@ -2,16 +2,16 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2012 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\/ 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 2 of the License, or (at your
- option) any later version.
+ 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
@@ -19,38 +19,46 @@ License
for more details.
You should have received a copy of the GNU General Public License
- along with OpenFOAM; if not, write to the Free Software Foundation,
- Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ along with OpenFOAM. If not, see .
Class
Foam::variableHeightFlowRateInletVelocityFvPatchVectorField
+Group
+ grpInletBoundaryConditions
+
Description
- Describes a volumetric/mass flow normal vector boundary condition by its
- magnitude as an integral over its area.
+ This boundary condition provides a velocity boundary condition for
+ multphase flow based on a user-specified volumetric flow rate.
- The basis of the patch (volumetric or mass) is determined by the
- dimensions of the flux, phi.
- The current density is used to correct the velocity when applying the
- mass basis.
+ The flow rate is made proportional to the phase fraction alpha at each
+ face of the patch and alpha is ensured to be bound between 0 and 1.
- The flow rate is made proportional to the phase fraction alpha at each face
- of the patch and alpha is ensured to be bound between 0 and 1.
+ \heading Patch usage
+
+ \table
+ Property | Description | Required | Default value
+ flowRate | volumetric flow rate [m3/s] | yes |
+ \endtable
Example of the boundary condition specification:
\verbatim
- inlet
+ myPatch
{
type variableHeightFlowRateInletVelocity;
- flowRate 0.2; // Volumetric/mass flow rate [m3/s or kg/s]
+ flowRate 0.2;
value uniform (0 0 0); // placeholder
}
\endverbatim
Note
- - The value is positive inwards
- - May not work correctly for transonic inlets
- - Strange behaviour with potentialFoam since the U equation is not solved
+ - the value is positive into the domain
+ - may not work correctly for transonic inlets
+ - strange behaviour with potentialFoam since the momentum equation is
+ not solved
+
+SeeAlso
+ Foam::fixedValueFvPatchField
SourceFiles
variableHeightFlowRateInletVelocityFvPatchVectorField.C
@@ -67,7 +75,7 @@ SourceFiles
namespace Foam
{
/*---------------------------------------------------------------------------*\
- Class variableHeightFlowRateInletVelocityFvPatch Declaration
+ Class variableHeightFlowRateInletVelocityFvPatchVectorField Declaration
\*---------------------------------------------------------------------------*/
class variableHeightFlowRateInletVelocityFvPatchVectorField
@@ -79,6 +87,7 @@ class variableHeightFlowRateInletVelocityFvPatchVectorField
//- Inlet integral flow rate
scalar flowRate_;
+
public:
//- Runtime type information
@@ -174,7 +183,6 @@ public:
//- Write
virtual void write(Ostream&) const;
-
};
diff --git a/src/finiteVolume/fields/fvPatchFields/derived/waveSurfacePressure/waveSurfacePressureFvPatchScalarField.C b/src/finiteVolume/fields/fvPatchFields/derived/waveSurfacePressure/waveSurfacePressureFvPatchScalarField.C
index 56a81e0f61..fe4ddd3357 100644
--- a/src/finiteVolume/fields/fvPatchFields/derived/waveSurfacePressure/waveSurfacePressureFvPatchScalarField.C
+++ b/src/finiteVolume/fields/fvPatchFields/derived/waveSurfacePressure/waveSurfacePressureFvPatchScalarField.C
@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
- \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation
+ \\ / A nd | Copyright (C) 2011-2012 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@@ -29,6 +29,34 @@ License
#include "volFields.H"
#include "surfaceFields.H"
#include "uniformDimensionedFields.H"
+#include "EulerDdtScheme.H"
+#include "CrankNicholsonDdtScheme.H"
+#include "backwardDdtScheme.H"
+
+// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
+
+namespace Foam
+{
+ template<>
+ const char* Foam::NamedEnum
+ <
+ Foam::waveSurfacePressureFvPatchScalarField::timeSchemeType,
+ 3
+ >::names[] =
+ {
+ fv::EulerDdtScheme::typeName.c_str(),
+ fv::CrankNicholsonDdtScheme::typeName.c_str(),
+ fv::backwardDdtScheme