KaliVeda  1.12/06
Heavy-Ion Analysis Toolkit
KVIDZAGrid.h
Go to the documentation of this file.
1 /***************************************************************************
2  KVIDZAGrid.h - description
3  -------------------
4  begin : Nov 24 2004
5  copyright : (C) 2004 by J.D. Frankland
6  email : frankland@ganil.fr
7 
8 $Id: KVIDZAGrid.h,v 1.14 2009/04/01 09:38:10 franklan Exp $
9 ***************************************************************************/
10 
11 #ifndef KVIDZAGrid_H
12 #define KVIDZAGrid_H
13 
14 #include "KVIDGrid.h"
15 #include "TObjArray.h"
16 
17 class KVIDZALine;
18 
65 class KVIDZAGrid: public KVIDGrid {
66 
67 protected:
68 
71 
72  void SetZmax(Int_t z)
73  {
74  fZMax = z;
75  };
76 
85 
91 
94 
95  virtual Bool_t FindFourEmbracingLines(Double_t x, Double_t y, const Char_t* position);
96  void init();
97 
98 public:
99 
100  enum {
111  kICODE10
112  };
113 
114 public:
115  KVIDZAGrid();
116  KVIDZAGrid(const KVIDZAGrid&);
117  virtual ~ KVIDZAGrid();
118 #if ROOT_VERSION_CODE >= ROOT_VERSION(3,4,0)
119  virtual void Copy(TObject&) const;
120 #else
121  virtual void Copy(TObject&);
122 #endif
123 
124  void RemoveLine(Int_t Z, Int_t A = -1); // *MENU*
125  void RemoveZLines(const Char_t* ZList); // *MENU*
126 
127  void SetVarXVarY(char* VarX, char* VarY)
128  {
129  SetVarX(VarX);
130  SetVarY(VarY);
131  };
132  void AddParameter(char* Name, char* Value)
133  {
134  fPar->SetValue(Name, Value);
135  };
136 
137  virtual void Initialize();// *MENU*
138  void DrawLinesWithWidth();// *MENU={Hierarchy="View.../DrawLinesWithWidth"}*
139 
140  virtual void CalculateLineWidths();
141  Int_t GetZmax() const
142  {
143  return (Int_t)fZMax;
144  };
145  virtual KVIDZALine* GetZLine(Int_t z, Int_t&) const;
147  {
148  return fZMaxLine;
149  };
150  virtual KVIDZALine* GetZALine(Int_t z, Int_t a, Int_t&) const;
151 
152  virtual void IdentZA(Double_t x, Double_t y, Int_t& Z, Double_t& A);
154  {
155  return TClass::GetClass("KVIDZALine");
156  };
157  virtual void IdentZ(Double_t x, Double_t y, Double_t& Z);
159  {
162  return fICode;
163  };
164 
165  virtual void Identify(Double_t x, Double_t y, KVIdentificationResult*) const;
166 
167  inline KVIDLine* GetClosestLine() const
168  {
169  return fClosest;
170  };
172  {
173  return fDistanceClosest;
174  };
175  inline UChar_t GetIndexClosest() const
176  {
177  return fIdxClosest;
178  };
179 
181 
182  KVIDGraph* MakeSubsetGraph(Int_t Zmin, Int_t Zmax, const Char_t* /*graph_class*/ = ""); //*MENU*
183  KVIDGraph* MakeSubsetGraph(TList*, TClass* /*graph_class*/ = 0);
184 
185  void ReCheckQuality(Int_t& Z, Double_t& A);
186 
187  void SetManualWidth(Double_t manual_width = .3, Double_t manual_width_scaling = 0.05); //*MENU*
188 
189  ClassDef(KVIDZAGrid, 2) //Base class for 2D Z & A identification grids
190 };
191 
192 class KVIDZGrid : public KVIDZAGrid {
193 public:
194  KVIDZGrid() {};
195  virtual ~KVIDZGrid() {};
196 
197  ClassDef(KVIDZGrid, 3) //FOR BACKWARDS COMPATIBILITY ONLY. OBSOLETE.
198 };
199 #endif
int Int_t
unsigned short UShort_t
unsigned char UChar_t
char Char_t
bool Bool_t
double Double_t
#define ClassDef(name, id)
Base class for particle identification in a 2D map.
Definition: KVIDGraph.h:31
virtual void SetVarX(const char *v)
Definition: KVIDGraph.h:506
KVNameValueList * fPar
parameters associated to grid
Definition: KVIDGraph.h:44
virtual void SetVarY(const char *v)
Definition: KVIDGraph.h:510
Abstract base class for 2D identification grids in e.g. (dE,E) maps.
Definition: KVIDGrid.h:73
Base class for lines/cuts used for particle identification in 2D data maps.
Definition: KVIDLine.h:143
Identification grid with lines corresponding to different nuclear isotopes (KVIDZALine)
Definition: KVIDZAGrid.h:65
void SetVarXVarY(char *VarX, char *VarY)
Definition: KVIDZAGrid.h:127
KVIDLine * GetClosestLine() const
Definition: KVIDZAGrid.h:167
Double_t dsups
Definition: KVIDZAGrid.h:87
Double_t fDistanceClosest
distance from point to closest line
Definition: KVIDZAGrid.h:82
Int_t Zsups
Definition: KVIDZAGrid.h:89
KVIDLine * fLsup
Definition: KVIDZAGrid.h:79
Double_t wsup
Definition: KVIDZAGrid.h:88
virtual void CalculateLineWidths()
Definition: KVIDZAGrid.cpp:294
Int_t Zinf
Definition: KVIDZAGrid.h:89
void init()
initialisation
Definition: KVIDZAGrid.cpp:87
Int_t Ainfi
Definition: KVIDZAGrid.h:90
KVIDLine * fClosest
closest line to last-identified point
Definition: KVIDZAGrid.h:75
Int_t Ainf
Definition: KVIDZAGrid.h:90
void AddParameter(char *Name, char *Value)
Definition: KVIDZAGrid.h:132
void ReCheckQuality(Int_t &Z, Double_t &A)
virtual KVIDZALine * GetZLine(Int_t z, Int_t &) const
Definition: KVIDZAGrid.cpp:158
virtual void Copy(TObject &) const
Copy this to 'obj'.
Definition: KVIDZAGrid.cpp:71
KVIDLine * fLinf
Definition: KVIDZAGrid.h:80
Int_t Zsup
Definition: KVIDZAGrid.h:89
Int_t Asups
Definition: KVIDZAGrid.h:90
void DrawLinesWithWidth()
Definition: KVIDZAGrid.cpp:466
void RemoveZLines(const Char_t *ZList)
Remove and destroy identifiers.
Definition: KVIDZAGrid.cpp:138
Int_t kinfi
Definition: KVIDZAGrid.h:86
virtual void IdentZ(Double_t x, Double_t y, Double_t &Z)
virtual TClass * DefaultIDLineClass()
Definition: KVIDZAGrid.h:153
virtual void Identify(Double_t x, Double_t y, KVIdentificationResult *) const
Double_t GetDistanceClosestLine() const
Definition: KVIDZAGrid.h:171
Int_t Asup
Definition: KVIDZAGrid.h:90
Int_t ksup
Definition: KVIDZAGrid.h:86
KVIDZALine * fZMaxLine
line with biggest Z and A
Definition: KVIDZAGrid.h:70
Int_t ksups
used by IdentZA and IdentZ
Definition: KVIDZAGrid.h:86
UChar_t GetIndexClosest() const
Definition: KVIDZAGrid.h:175
Int_t GetZmax() const
Definition: KVIDZAGrid.h:141
Double_t winf
Definition: KVIDZAGrid.h:88
Double_t dinf
Definition: KVIDZAGrid.h:87
Int_t kinf
Definition: KVIDZAGrid.h:86
virtual void Initialize()
void SetZmax(Int_t z)
Definition: KVIDZAGrid.h:72
KVIDLine * fLsups
Definition: KVIDZAGrid.h:78
Double_t wsups
Definition: KVIDZAGrid.h:88
UShort_t fZMax
largest Z of lines in grid
Definition: KVIDZAGrid.h:69
Double_t dsup
Definition: KVIDZAGrid.h:87
KVIDZAGrid()
default ctor.
Definition: KVIDZAGrid.cpp:33
virtual void IdentZA(Double_t x, Double_t y, Int_t &Z, Double_t &A)
Definition: KVIDZAGrid.cpp:649
Int_t fIdxClosest
index of closest line in main list fIdentifiers
Definition: KVIDZAGrid.h:83
virtual ~ KVIDZAGrid()
Int_t Zinfi
Definition: KVIDZAGrid.h:89
Int_t fICode
code de retour
Definition: KVIDZAGrid.h:84
Double_t winfi
Definition: KVIDZAGrid.h:88
KVIDLine * fLinfi
Definition: KVIDZAGrid.h:81
Int_t Zint
Z of line used to identify particle.
Definition: KVIDZAGrid.h:93
void SetManualWidth(Double_t manual_width=.3, Double_t manual_width_scaling=0.05)
KVIDZALine * GetZmaxLine() const
Definition: KVIDZAGrid.h:146
KVIDGraph * MakeSubsetGraph(Int_t Zmin, Int_t Zmax, const Char_t *="")
virtual void MakeEDeltaEZGrid(Int_t Zmin, Int_t Zmax, Int_t npoints=20, Double_t gamma = 2);//*MENU*
Int_t GetQualityCode() const
Definition: KVIDZAGrid.h:158
Double_t dinfi
Definition: KVIDZAGrid.h:87
virtual Bool_t FindFourEmbracingLines(Double_t x, Double_t y, const Char_t *position)
Definition: KVIDZAGrid.cpp:525
Int_t Aint
mass of line used to identify particle
Definition: KVIDZAGrid.h:92
void RemoveLine(Int_t Z, Int_t A=-1)
Remove and destroy identifier.
Definition: KVIDZAGrid.cpp:108
virtual KVIDZALine * GetZALine(Int_t z, Int_t a, Int_t &) const
Definition: KVIDZAGrid.cpp:219
Base class for identification ridge lines corresponding to different nuclear species.
Definition: KVIDZALine.h:32
virtual ~KVIDZGrid()
Definition: KVIDZAGrid.h:195
Full result of one attempted particle identification.
void SetValue(const Char_t *name, value_type value)
static TClass * GetClass(Bool_t load=kTRUE, Bool_t silent=kFALSE)
RooCmdArg Name(const char *name)