Replace tabs by 4 spaces in applications/solvers/solidMechanics
[foam-extend-3.2.git] / applications / solvers / solidMechanics / elasticSolidFoam / createHistory.H
blobd6322c6da047bf6d80c3b894edbb00dd58692765
1 OFstream * filePtr(NULL);
2 word historyPatchName(mesh.solutionDict().subDict("solidMechanics").lookup("historyPatch"));
3 label historyPatchID = mesh.boundaryMesh().findPatchID(historyPatchName);
4 if(historyPatchID == -1)
5   {
6     Warning << "history patch " << historyPatchName
7         << " not found. Force-displacement will not be written"
8         << endl;
9   }
10  else if(Pstream::master())
11   {
12     Info << "Force-displacement for patch " << historyPatchName
13         << " will be written to forceDisp.dat"
14         << endl;
15     mkDir("history");
16     filePtr = new OFstream("history"/historyPatchName+"_forceDisp.dat");
17     OFstream& forceDispFile = *filePtr;
18     forceDispFile << "#Disp(mm)\tForce(N)" << endl;
19   }