HYDRA_development_version
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
hmdctrackfitpar.cc
Go to the documentation of this file.
1 //*-- AUTHOR : J. Markert
2 //_HADES_CLASS_DESCRIPTION
3 ////////////////////////////////////////////////////////////////////////////
4 // HMdcTrackFitPar
5 //
6 // Container class for Dubna track fitter parameters
7 //
8 ////////////////////////////////////////////////////////////////////////////
9 using namespace std;
10 #include "hmdctrackfitpar.h"
11 #include "hparamlist.h"
12 #include <iostream>
13 #include <iomanip>
14 #include <stdlib.h>
15 
17 
18 HMdcTrackFitPar::HMdcTrackFitPar(const Char_t* name,const Char_t* title,
19  const Char_t* context)
20  : HParCond(name,title,context)
21 {
22  //
23  clear();
24 }
26 {
27  // destructor
28 }
30 {
31  cutWeight = -99;
32  tofFlag = -99;
33  doTargScan = -99;
34 
35  minTimeOffset = -99;
36  maxTimeOffset = -99;
37  minCellsNum = -99;
38  chi2CutFlag = -99;
39  totalChi2Cut = -99;
40  chi2PerNdfCut = -99;
41 
42  useTukeyFlag = -99;
43  cnWs = -99;
44  cn2s = -99;
45  cn4s = -99;
46  minSig2 = -99;
47  maxNFilterIter= -99;
48  minWeight = -99;
49  maxChi2 = -99;
50 
51  minTOffsetIter= -99;
52 
53  funCt1 = -99;
54  stepD1 = -99;
55  funCt2 = -99;
56  stepD2 = -99;
57  stepD3 = -99;
58 
59 
60  status=kFALSE;
61  resetInputVersions();
62  changed=kFALSE;
63 }
65 {
66  // prints the parameters of HMdcTrackFitPar to the screen.
67  printf("############################################################################################\n");
68  printf("HMdcTrackFitPar:\n");
69  printf("cutWeight = %f \n" ,cutWeight );
70  printf("tofFlag = %i \n" ,tofFlag );
71  printf("doTargScan = %i \n" ,doTargScan );
72 
73  printf("minTimeOffset = %f \n" ,minTimeOffset );
74  printf("maxTimeOffset = %f \n" ,maxTimeOffset );
75  printf("minCellsNum = %i \n" ,minCellsNum );
76  printf("chi2CutFlag = %i \n" ,chi2CutFlag );
77  printf("totalChi2Cut = %f \n" ,totalChi2Cut );
78  printf("chi2PerNdfCut = %f \n" ,chi2PerNdfCut );
79 
80  printf("useTukeyFlag = %i \n" ,useTukeyFlag );
81  printf("cnWs = %f \n" ,cnWs );
82  printf("cn2s = %f \n" ,cn2s );
83  printf("cn4s = %f \n" ,cn4s );
84  printf("minSig2 = %f \n" ,minSig2 );
85  printf("maxNFilterIter = %i \n" ,maxNFilterIter);
86  printf("minWeight = %f \n" ,minWeight );
87  printf("maxChi2 = %f \n" ,maxChi2 );
88 
89  printf("minTOffsetIter = %f \n" ,minTOffsetIter);
90 
91  printf("funCt1 = %f \n" ,funCt1 );
92  printf("stepD1 = %f \n" ,stepD1 );
93  printf("funCt2 = %f \n" ,funCt2 );
94  printf("stepD2 = %f \n" ,stepD2 );
95  printf("stepD3 = %f \n" ,stepD3 );
96  printf("############################################################################################\n");
97 }
99 {
100  // Puts all params of HMdcTrackFitPar to the parameter list of
101  // HParamList (which ist used by the io);
102  if (!l) return;
103  l->add("cutWeight" ,cutWeight );
104  l->add("tofFlag" ,tofFlag );
105  l->add("doTargScan" ,doTargScan );
106 
107  l->add("minTimeOffset" ,minTimeOffset );
108  l->add("maxTimeOffset" ,maxTimeOffset );
109  l->add("minCellsNum" ,minCellsNum );
110  l->add("chi2CutFlag" ,chi2CutFlag );
111  l->add("totalChi2Cut" ,totalChi2Cut );
112  l->add("chi2PerNdfCut" ,chi2PerNdfCut );
113 
114  l->add("useTukeyFlag" ,useTukeyFlag );
115  l->add("cnWs" ,cnWs );
116  l->add("cn2s" ,cn2s );
117  l->add("cn4s" ,cn4s );
118  l->add("minSig2" ,minSig2 );
119  l->add("maxNFilterIter",maxNFilterIter);
120  l->add("minWeight" ,minWeight );
121  l->add("maxChi2" ,maxChi2 );
122 
123  l->add("minTOffsetIter",minTOffsetIter);
124 
125  l->add("funCt1" ,funCt1 );
126  l->add("stepD1" ,stepD1 );
127  l->add("funCt2" ,funCt2 );
128  l->add("stepD2" ,stepD2 );
129  l->add("stepD3" ,stepD3 );
130 
131 }
133 {
134  if (!l) return kFALSE;
135 
136  if(!(l->fill("cutWeight" ,&cutWeight ))) return kFALSE;
137  if(!(l->fill("tofFlag" ,&tofFlag ))) return kFALSE;
138  if(!(l->fill("doTargScan" ,&doTargScan ))) return kFALSE;
139 
140  if(!(l->fill("minTimeOffset" ,&minTimeOffset ))) return kFALSE;
141  if(!(l->fill("maxTimeOffset" ,&maxTimeOffset ))) return kFALSE;
142  if(!(l->fill("minCellsNum" ,&minCellsNum ))) return kFALSE;
143  if(!(l->fill("chi2CutFlag" ,&chi2CutFlag ))) return kFALSE;
144  if(!(l->fill("totalChi2Cut" ,&totalChi2Cut ))) return kFALSE;
145  if(!(l->fill("chi2PerNdfCut" ,&chi2PerNdfCut ))) return kFALSE;
146 
147  if(!(l->fill("useTukeyFlag" ,&useTukeyFlag ))) return kFALSE;
148  if(!(l->fill("cnWs" ,&cnWs ))) return kFALSE;
149  if(!(l->fill("cn2s" ,&cn2s ))) return kFALSE;
150  if(!(l->fill("cn4s" ,&cn4s ))) return kFALSE;
151  cn2s = cn4s*cn4s/cnWs;
152  if(!(l->fill("minSig2" ,&minSig2 ))) return kFALSE;
153  if(!(l->fill("maxNFilterIter",&maxNFilterIter))) return kFALSE;
154  if(!(l->fill("minWeight" ,&minWeight ))) return kFALSE;
155  if(!(l->fill("maxChi2" ,&maxChi2 ))) return kFALSE;
156 
157  if(!(l->fill("minTOffsetIter",&minTOffsetIter))) return kFALSE;
158 
159  if(!(l->fill("funCt1" ,&funCt1 ))) return kFALSE;
160  if(!(l->fill("stepD1" ,&stepD1 ))) return kFALSE;
161  if(!(l->fill("funCt2" ,&funCt2 ))) return kFALSE;
162  if(!(l->fill("stepD2" ,&stepD2 ))) return kFALSE;
163  if(!(l->fill("stepD3" ,&stepD3 ))) return kFALSE;
164 
165 
166  return kTRUE;
167 }
ClassImp(HMdcTrackFitPar) HMdcTrackFitPar
void add(HParamObj &)
Definition: hparamlist.cc:415
Bool_t getParams(HParamList *)
void putParams(HParamList *)
Bool_t fill(const Text_t *, Text_t *, const Int_t)
Definition: hparamlist.cc:561