Changeset 40 for trunk/src/histogram.h


Ignore:
Timestamp:
Feb 20, 2004, 3:03:25 PM (19 years ago)
Author:
Jari Häkkinen
Message:

Removed .icc files.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/histogram.h

    r13 r40  
     1// $Id$
     2
     3#ifndef _THEP_CPPTOOLS_HISTOGRAM_
     4#define _THEP_CPPTOOLS_HISTOGRAM_
     5
    16#include <fstream>
    27#include <iostream>
     
    49#include <gsl/gsl_histogram.h>
    510
    6 
    7 #ifndef _THEP_CPPTOOLS_HISTOGRAM_
    8 #define _THEP_CPPTOOLS_HISTOGRAM_
    911
    1012namespace thep_cpp_tools
     
    3638       Returns the intensity corresponding to bin \a n.
    3739     */
    38     inline double get_intensity( const size_t& n ) const;
     40    inline double get_intensity( const size_t& n ) const
     41      { return gsl_histogram_get(h_,n); }
    3942
    4043
     
    4245       Returns the range corresponding to bin \a n
    4346     */
    44     inline void get_range( const size_t& n, double& min, double& max ) const;
     47    inline void get_range( const size_t& n, double& min, double& max ) const
     48      { gsl_histogram_get_range(h_,n,&min,&max); }
    4549
    4650
     
    4852       Returns the number of bins in the distribution.
    4953     */
    50     inline size_t get_bins() const;
     54    inline size_t get_bins() const { return gsl_histogram_bins(h_); }
    5155
    5256
     
    6165       the histogram.
    6266     */
    63     inline double get_probability( const double& r );
     67    inline double get_probability( const double& r )
     68      { return gsl_histogram_pdf_sample(p_,r); }
    6469
    6570
     
    8691  };
    8792
    88   #include "histogram.h"
    8993
    9094}
Note: See TracChangeset for help on using the changeset viewer.