Go to the documentation of this file.
94 const word getClassType(
const word& pType)
124 void createFieldFiles
128 const word& regionPrefix,
136 Info<<
" Generating field files" <<
nl <<
endl;
141 const_cast<word&
>(IOdictionary::typeName) =
142 getClassType(fieldTypes[i]);
156 "$FOAM_CASE/system" + regionPath +
"caseProperties"
159 field.add(
"dimensions", fieldDimensions[i]);
161 string iField(
"${:initialConditions." + fieldNames[i] +
'}');
162 field.add(
"internalField", iField.c_str());
172 field.add(
"boundaryField", boundaryField);
182 field2.remove(
"#include");
183 field2.remove(
"initialConditions");
184 field2.remove(
"boundaryConditions");
200 fieldOut.regIOobject::writeObject
210 int main(
int argc,
char *argv[])
214 "Create a 0/ directory with fields appropriate for the chosen"
215 " solver and turbulence model."
222 "Read case set-up templates from specified location"
256 "${WM_PROJECT_DIR}/etc/caseDicts/createZeroDirectoryTemplates"
261 baseDir.toAbsolute();
266 <<
"templateDir " << baseDir <<
nl
267 <<
"Does not point to a folder containing case set-up templates"
292 const label nRegion =
solver.nRegion();
293 for (label regionI = 0; regionI < nRegion; regionI++)
316 solver.regionType(regionI),
317 solver.fieldNames(regionI),
318 solver.fieldTypes(regionI),
319 solver.fieldDimensions(regionI),
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Defines the attributes of an object for which implicit objectRegistry management is supported,...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A class for handling words, derived from Foam::string.
A class for handling file names.
static word defaultRegion
Return the default region name.
T getOrDefault(const word &optName, const T &deflt) const
Get a value from the named option if present, or return default.
static void addNote(const string ¬e)
Add extra notes for the usage information.
Class to store solver template specifications.
Ostream & endl(Ostream &os)
Add newline and flush stream.
#define forAll(list, i)
Loop across all elements in list.
dictionary generateBoundaryField(const word ®ionPrefix, const word &fieldName, const boundaryTemplates &bcTemplates) const
Generate boundary field (dictionary)
Base class for solution control classes.
messageStream Info
Information stream (uses stdout - output is on the master only)
runTime controlDict().readEntry("adjustTimeStep"
The IOstreamOption is a simple container for options an IOstream can normally have.
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
void checkPatches(const word ®ionPrefix, const boundaryTemplates &bcTemplates) const
Check patches.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Input from string buffer, using a ISstream.
static int disableFunctionEntries
Enable or disable use of function entries and variable expansions.
Class to hold information related to the simaulation case.
errorManipArg< error, int > exit(error &err, const int errNo=1)
Foam::string str() const
Get the string - as Foam::string rather than std::string.
const word & system() const
Return system name.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
Traits class for primitives.
Output to string buffer, using a OSstream.
static const word null
An empty word.
Generic GeometricField class.
static void addOption(const word &optName, const string ¶m="", const string &usage="", bool advanced=false)
Add an option to validOptions with usage information.
Foam::argList args(argc, argv)
Class to store boundary template specifications.
localIOdictionary is derived from IOdictionary but excludes parallel master reading.
bool isDir(const fileName &name, const bool followLink=true)
Does the name exist as a DIRECTORY in the file system?