Performs some statistical calculations. More...

`#include <Statistics.hh>`

## Public Member Functions | |

Statistics () | |

Constructor. | |

virtual | ~Statistics () |

Destructor. | |

void | reset () |

Clear the collected statistical data. | |

void | solution (int depth) |

A solution has been found. | |

void | infeasible (int depth) |

An infeasible subproblem has been encountered. | |

## Private Member Functions | |

double | getTime () |

Get current user time in seconds. | |

## Private Attributes | |

double | startTime |

The time when the calculation was started. | |

int | numSolutions |

The number of solutions found. |

Performs some statistical calculations.

Definition at line 32 of file Statistics.hh.

double bande::Statistics::getTime | ( | ) | ` [private]` |

Get current user time in seconds.

The time will be reported as a floating point number, allowing for fractions of a second. Only the CPU time dedicated to this process will count, so that the time as returned by this function will pass slower the more other processes occupy the CPU. As the returned value is intended for difference calculation, the initial offset is irrelevant.

**Returns:**- the current user time as a floating point number.

Definition at line 43 of file Statistics.cc.

Referenced by reset(), and solution().

void bande::Statistics::infeasible | ( | int | depth |
) | ` [inline]` |

An infeasible subproblem has been encountered.

**Parameters:**-
*depth*the depth in the search tree at which the infeasibility has been detected.

Definition at line 61 of file Statistics.hh.

Referenced by bande::BranchControl::branch().

void bande::Statistics::reset | ( | ) | ` [inline]` |

Clear the collected statistical data.

Collection of statistics will start from scratch, the clock will start to tick immediately.

Definition at line 51 of file Statistics.hh.

References getTime(), numSolutions, and startTime.

Referenced by bande::BranchControl::run(), and Statistics().

void bande::Statistics::solution | ( | int | depth |
) |

A solution has been found.

**Parameters:**-
*depth*the depth in the search tree at which the solution has been found.

Definition at line 55 of file Statistics.cc.

References getTime(), numSolutions, and startTime.

Referenced by bande::BranchControl::branch().

The documentation for this class was generated from the following files:

Generated on Fri Aug 21 08:17:19 2009 for bande by 1.6.0