]> git.uio.no Git - u/mrichter/AliRoot.git/blame - FMD/flow/AliFMDFlowTrue.h
coding conventions and compilation warnings
[u/mrichter/AliRoot.git] / FMD / flow / AliFMDFlowTrue.h
CommitLineData
39eefe19 1// -*- mode: C++ -*-
97e94238 2/* Copyright (C) 2007 Christian Holm Christensen <cholm@nbi.dk>
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public License
6 * as published by the Free Software Foundation; either version 2.1 of
7 * the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
17 * USA
18 */
39eefe19 19/** @file
20 @brief Declaration and implementation of classes to deal with a
21 well-known event plane @f$ \Psi_R@f$. */
97e94238 22//____________________________________________________________________
23//
24// AliFMDFlowTrueBin:
25// A specialised AliFMDFlowBin of flow in case the event plane is
26// well-known.
27// AliFMDFlowTrue1D:
28// A specialised AliFMDFlowBinned1D histogram in case the event
29// plane is well-known.
30//
31#ifndef ALIFMDFLOWTRUE_H
32#define ALIFMDFLOWTRUE_H
39eefe19 33#include <flow/AliFMDFlowStat.h>
34#include <flow/AliFMDFlowBin.h>
35#include <flow/AliFMDFlowBinned1D.h>
36
37
38/** @defgroup x_true Classes for handling Flow when the event plane is
39 known. */
40/** @class TrueBin flow/True.h <flow/True.h>
41 @brief A specialised Bin of flow in case the event plane is
42 well-known.
43 @ingroup x_true */
97e94238 44class AliFMDFlowTrueBin : public AliFMDFlowBin
39eefe19 45{
97e94238 46public:
9b98d361 47 /** Default constructor - do not use */
48 AliFMDFlowTrueBin() {}
39eefe19 49 /** Constructor */
50 AliFMDFlowTrueBin(UShort_t order) :
51 AliFMDFlowBin(order, 1),
52 fPsiR(0),
53 fResReal()
54 {}
55 /** Set the well-known event plane angle @f$ \Psi_R@f$ for this
56 event.
57 @param psi @f$ \Psi_R@f$ */
58 void SetPsi(Double_t psi) { fPsiR = psi; }
59 /** Should be called at the end of an event */
60 virtual void End();
61 /** Add a contribution @f$ \cos(n(\varphi-\Psi_R))@f$ where
62 @f$ \Psi_R@f$ is the previously set, well-known event plane
63 angle.
9b98d361 64 @param w Weight
39eefe19 65 @param phi @f$ \varphi@f$ */
9b98d361 66 void AddToHarmonic(Double_t phi, Double_t w);
39eefe19 67 /** Get the value in this bin
68 @param t Which type of correction
69 @return the value of the harmonic */
97e94238 70 virtual Double_t Value(CorType t=kNone) const;
39eefe19 71 /** Get the value in this bin
72 @param e2 On return, the square error.
73 @param t Which type of correction
74 @return the value of the harmonic */
97e94238 75 Double_t Value(Double_t& e2, CorType t=kNone) const;
39eefe19 76 /** Get the value in this bin
77 @param e2 On return, the square error.
78 @param t Which type of correction
79 @return the value of the harmonic */
97e94238 80 Double_t Correction(Double_t& e2, CorType t=kNone) const;
39eefe19 81 /** Print to standard out. */
824e71c1 82 void Print(Option_t* option="s") const;
9b98d361 83 /** get the event plane */
84 Double_t Psi() const { return fPsiR; }
97e94238 85protected:
39eefe19 86 /** The well-known event plane */
97e94238 87 Double_t fPsiR; // The well-known event plane
39eefe19 88 /** True resolution */
97e94238 89 AliFMDFlowStat fResReal; // True resolution
39eefe19 90 /** define for ROOT I/O */
91 ClassDef(AliFMDFlowTrueBin,1);
92
93};
94/** @brief A "histogram" of objects of class TrueBin in case the
95 event plane angle @f$ \Psi_R@f$ is well known.
96 @ingroup x_true */
97struct AliFMDFlowTrue1D : public AliFMDFlowBinned1D
98{
97e94238 99public:
9b98d361 100 /** Default constructor - do not use */
101 AliFMDFlowTrue1D() {}
39eefe19 102 /** Constructor */
9b98d361 103 AliFMDFlowTrue1D(const char* name, const char* title,
104 UShort_t order, const AliFMDFlowAxis& xaxis);
39eefe19 105 /** Set the well-known event plane angle @f$ \Psi_R@f$ for this
106 event.
107 @param psi @f$ \Psi_R@f$ */
108 void SetPsi(Double_t psi);
109 /** Print to standard out */
110 virtual void Print(Option_t* option="") const;
111 /** define for ROOT I/O */
112 ClassDef(AliFMDFlowTrue1D,1);
113};
114
115
116#endif
117//
118// EOF
119//