Logo ROOT   6.08/07
Reference Guide
Volume.h
Go to the documentation of this file.
1 // @(#)root/tmva $Id$
2 // Author: Andreas Hoecker, Joerg Stelzer, Helge Voss, Kai Voss
3 
4 /**********************************************************************************
5  * Project: TMVA - a Root-integrated toolkit for multivariate data analysis *
6  * Package: TMVA *
7  * Class : Volume *
8  * Web : http://tmva.sourceforge.net *
9  * *
10  * Description: *
11  * Volume for BinarySearchTree *
12  * *
13  * Authors (alphabetical): *
14  * Andreas Hoecker <Andreas.Hocker@cern.ch> - CERN, Switzerland *
15  * Helge Voss <Helge.Voss@cern.ch> - MPI-K Heidelberg, Germany *
16  * Kai Voss <Kai.Voss@cern.ch> - U. of Victoria, Canada *
17  * *
18  * Copyright (c) 2005: *
19  * CERN, Switzerland *
20  * U. of Victoria, Canada *
21  * MPI-K Heidelberg, Germany *
22  * *
23  * Redistribution and use in source and binary forms, with or without *
24  * modification, are permitted according to the terms listed in LICENSE *
25  * (http://tmva.sourceforge.net/LICENSE) *
26  **********************************************************************************/
27 
28 #ifndef ROOT_TMVA_Volume
29 #define ROOT_TMVA_Volume
30 
31 //////////////////////////////////////////////////////////////////////////
32 // //
33 // Volume //
34 // //
35 // Volume for BinarySearchTree //
36 // //
37 // volume element: cubic variable space beteen upper and lower bonds of //
38 // nvar-dimensional variable space //
39 // //
40 //////////////////////////////////////////////////////////////////////////
41 
42 #include <vector>
43 #ifndef ROOT_Rtypes
44 #include "Rtypes.h"
45 #endif
46 //#include "time.h"
47 
48 namespace TMVA {
49 
50  class Volume {
51 
52  public:
53 
54  // constructors
55  Volume( std::vector<Float_t>* l, std::vector<Float_t>* u = 0);
56  Volume( std::vector<Double_t>* l = 0, std::vector<Double_t>* u = 0);
57  Volume( Volume& );
58  Volume( Float_t* l , Float_t* u , Int_t nvar );
59  Volume( Double_t* l , Double_t* u , Int_t nvar );
60  Volume( Float_t l , Float_t u );
61  Volume( Double_t l , Double_t u );
62 
63  // destructor
64  virtual ~Volume( void );
65 
66  // destruct the volue
67  void Delete ( void );
68  // "scale" the volume by multiplying each upper and lower boundary by "f"
69  void Scale ( Double_t f );
70  // "scale" the volume by symmetrically blowing up the interval in each dimension
71  void ScaleInterval( Double_t f );
72  void Print ( void ) const;
73 
74  // allow direct access for better speed
75  std::vector<Double_t> *fLower; // vector with lower volume dimensions
76  std::vector<Double_t> *fUpper; // vector with upper volume dimensions
77 
78  private:
79 
80  Bool_t fOwnerShip; // flag if "boundary vector" is owned by the volume of not
81  };
82 
83 } // namespace TMVA
84 
85 #endif
std::vector< Double_t > * fLower
Definition: Volume.h:75
void Delete(void)
Definition: Volume.cxx:127
float Float_t
Definition: RtypesCore.h:53
std::vector< Double_t > * fUpper
Definition: Volume.h:76
void ScaleInterval(Double_t f)
Definition: Volume.cxx:141
int Int_t
Definition: RtypesCore.h:41
bool Bool_t
Definition: RtypesCore.h:59
virtual ~Volume(void)
Definition: Volume.cxx:120
Bool_t fOwnerShip
Definition: Volume.h:80
void Print(void) const
Definition: Volume.cxx:152
void Scale(Double_t f)
Definition: Volume.cxx:134
Volume(std::vector< Float_t > *l, std::vector< Float_t > *u=0)
Definition: Volume.cxx:53
TLine * l
Definition: textangle.C:4
double f(double x)
double Double_t
Definition: RtypesCore.h:55
Abstract ClassifierFactory template that handles arbitrary types.