#ifdef STATISTICS

/*
 * $Id$
 *
 * [ Description ]
 * 
 */

#include "Behavioural/include/Statistics.h"

namespace morpheo              {
namespace behavioural          {

  uint32_t Statistics::compute_cycle_begin (uint32_t num_statistics)
  {
    return _parameters_statistics._nb_cycle_before_begin + num_statistics*_parameters_statistics._period_save;
  };

  uint32_t Statistics::compute_cycle_end   (uint32_t num_statistics, uint32_t nb_cycle)
  {
    if (num_statistics == (_nb_statistics-1)) // Last ?
      return compute_cycle_begin(num_statistics  ) + nb_cycle;
    else
      return compute_cycle_begin(num_statistics+1) - 1;
  };

}; // end namespace behavioural          
}; // end namespace morpheo              

#endif
