Go to the documentation of this file.
49 int main(
int argc,
char *argv[])
53 "Reads in a datToFoam mesh file and outputs a points file.\n"
54 "Used in conjunction with blockMesh."
69 std::ifstream plot3dFile(
args[1]);
72 std::getline(plot3dFile,
line);
73 std::getline(plot3dFile,
line);
85 Istring >> punctuation;
91 Info<<
"Number of vertices in i direction = " << iPoints <<
nl
92 <<
"Number of vertices in j direction = " << jPoints <<
endl;
95 const label nPointsij = (iPoints - 1)*(jPoints - 1);
99 for (
direction comp = 0; comp < 2; ++comp)
103 for (label j = 0; j < jPoints; ++j)
105 for (label i = 0; i < iPoints; ++i)
140 pointsWedge[i] = (rotateZ &
points[i]);
141 pointsWedge[i + nPointsij] =
150 const fileName pointsFile(polyMeshPath/
"points");
154 Info<<
"Writing points to: " <<
nl
155 <<
" " << pointsFile <<
endl;
158 pFile << pointsWedge;
Creates a single block of cells from point coordinates, numbers of cells in each direction and an exp...
bool exists(const fileName &name, const bool checkGzip=true, const bool followLink=true)
Does the name exist (as DIRECTORY or FILE) in the file system?
A class for handling words, derived from Foam::string.
A class for handling file names.
dimensioned< Type > cmptMultiply(const dimensioned< Type > &, const dimensioned< Type > &)
static constexpr const zero Zero
Global zero (0)
static Ostream & writeEndDivider(Ostream &os)
Write the standard end file divider.
dimensionedScalar sin(const dimensionedScalar &ds)
static void addNote(const string ¬e)
Add extra notes for the usage information.
Unit conversion functions.
Extract command arguments and options from the supplied argc and argv parameters.
Ostream & endl(Ostream &os)
Add newline and flush stream.
A token holds an item read from Istream.
fileName constantPath() const
Return constant path.
#define forAll(list, i)
Loop across all elements in list.
static void addArgument(const string &argName, const string &usage="")
Append a (mandatory) argument to validArgs.
messageStream Info
Information stream (uses stdout - output is on the master only)
Input from string buffer, using a ISstream.
void exit(const int errNo=1)
Exit : can be called for any error to exit program.
Vector< scalar > vector
A scalar version of the templated Vector.
constexpr scalar degToRad(const scalar deg) noexcept
Conversion from degrees to radians.
Output to file stream, using an OSstream.
Input/output from file streams.
const dimensionedScalar e
Elementary charge.
bool writeHeader(Ostream &os) const
Write header.
bool check(bool checkArgs=argList::argsMandatory(), bool checkOpts=true) const
static void noParallel()
Remove the parallel options.
Foam::argList args(argc, argv)
bool mkDir(const fileName &pathName, mode_t mode=0777)
Make a directory and return an error if it could not be created.
dimensionedScalar cos(const dimensionedScalar &ds)