FreeFOAM The Cross-Platform CFD Toolkit
Hosted by SourceForge:
Get FreeFOAM at SourceForge.net.
            Fast, secure and Free Open Source software downloads

ensightCaseTail.H

Go to the documentation of this file.
00001 if (Pstream::master())
00002 {
00003     ensightCaseFile << nl << "TIME" << nl
00004         << "time set:                      " << 1 << nl
00005         << "number of steps:               " << nTimeSteps << nl
00006         << "filename start number:         " << 0 << nl
00007         << "filename increment:            " << 1 << nl;
00008 
00009     ensightCaseFile << "time values:" << nl;
00010 
00011     ensightCaseFile.setf(ios_base::scientific, ios_base::floatfield);
00012     ensightCaseFile.precision(5);
00013 
00014     label count = 0;
00015     scalar Tcorr = 0.0;
00016     if (Times[0].value() < 0)
00017     {
00018         Tcorr = - Times[0].value();
00019         Info << "Correcting time values. Adding " << Tcorr << endl;
00020     }
00021 
00022     for (int n=startTime; n<endTime; n++)
00023     {
00024         ensightCaseFile << setw(12) << Times[n].value() + Tcorr << " ";
00025 
00026         if (++count % 6 == 0)
00027         {
00028             ensightCaseFile << nl;
00029         }
00030     }
00031 
00032     ensightCaseFile << nl;
00033 }
00034 
00035 // ************************ vim: set sw=4 sts=4 et: ************************ //
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines