OpenLB 1.7
|
This class allows calculation and display of various time data including remaining runtime data in cpu and in user time. More...
#include <sys/time.h>
#include <iostream>
#include <iomanip>
#include <stdio.h>
#include "io/ostreamManager.h"
#include "io/xmlReader.h"
#include "core/unitConverter.h"
Go to the source code of this file.
Classes | |
class | olb::util::Timer< T > |
How to use in Code: More... | |
Namespaces | |
namespace | olb |
Top level namespace for all of OpenLB. | |
namespace | olb::util |
Functions | |
template<typename T , typename DESCRIPTOR > | |
Timer< T > * | olb::util::createTimer (XMLreader ¶m, const UnitConverter< T, DESCRIPTOR > &converter, size_t numLatticePoints) |
This class allows calculation and display of various time data including remaining runtime data in cpu and in user time.
Output is possible during computation and as a summary after computation. Time can be measured independently from in-computation-calls which allows time statistics without touching the overall computation time of the LBM-algorithm. Moreover it is possible to determine a performance number, the Mega DESCRIPTOR Updates per second (MLUPs). The template type T denotes the internal representation of time differences (in ms, s and for cpu-time). Reasonable values are eg. double and long. Some thoughts about data range: Actually, only positive numbers should occur (=> unsigned). The chosen data format should be capable of representing at least 7 days ( = 604.800.000 ms) of computation time. The biggest signed long32 number ist 2.147.483.647 (~3 1/2 weeks), great! For everything above, use double with it's floating point arithmetic.
Definition in file timer.h.