50int main(
int argc,
char *argv[])
54 "Solver for the magnetic field generated by permanent magnets."
57 argList::addBoolOption
60 "Do not write the magnetic field intensity field"
63 argList::addBoolOption
66 "Do not write the magnetic flux density field"
69 argList::addBoolOption
72 "Write the paramagnetic particle force field"
82 #include "createFields.H"
86 Info<<
"Calculating the magnetic field potential" <<
endl;
90 while (
simple.correctNonOrthogonal())
107 fvc::reconstruct(fvc::snGrad(
psi)*
mesh.magSf())
113 <<
"Creating field H for time "
122 <<
"Creating field HdotGradH for time "
143 <<
"Creating field B for time "
154 constant::electromagnetic::mu0
static const Foam::dimensionedScalar B("", Foam::dimless, 18.678)
Functions used by OpenFOAM that are specific to POSIX compliant operating systems and need to be repl...
bool found(const word &optName) const
Return true if the named option is found.
const volScalarField & psi
volScalarField H(IOobject("H", runTime.timeName(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE), mesh, dimensionedScalar(dimLength, Zero))
GeometricField< vector, fvPatchField, volMesh > volVectorField
messageStream Info
Information stream (stdout output on master, null elsewhere)
Ostream & endl(Ostream &os)
Add newline and flush stream.
constexpr char nl
The newline '\n' character (0x0a)
const dictionary & simple
Foam::argList args(argc, argv)
surfaceScalarField murf(IOobject("murf", runTime.timeName(), mesh), mesh, dimensionedScalar("one", dimless, 1.0))
surfaceScalarField Mrf(IOobject("Mrf", runTime.timeName(), mesh), mesh, dimensionedScalar(dimensionSet(0, 1, 0, 0, 0, 1, 0), Zero))