FairRoot/PandaRoot
PndCAParam.cxx
Go to the documentation of this file.
1 // @(#) $Id: PndCAParam.cxx,v 1.4 2011/10/01 00:23:44 perev Exp $
2 // **************************************************************************
3 // This file is property of and copyright by the ALICE HLT Project *
4 // ALICE Experiment at CERN, All rights reserved. *
5 // *
6 // Primary Authors: Sergey Gorbunov <sergey.gorbunov@kip.uni-heidelberg.de> *
7 // Ivan Kisel <kisel@kip.uni-heidelberg.de> *
8 // for The ALICE HLT Project. *
9 // *
10 // Developed by: Igor Kulakov <I.Kulakov@gsi.de> *
11 // Maksym Zyzak <M.Zyzak@gsi.de> *
12 // *
13 // Permission to use, copy, modify and distribute this software and its *
14 // documentation strictly for non-commercial purposes is hereby granted *
15 // without fee, provided that the above copyright notice appears in all *
16 // copies and that both the copyright notice and this permission notice *
17 // appear in the supporting documentation. The authors make no claims *
18 // about the suitability of this software for any purpose. It is *
19 // provided "as is" without express or implied warranty. *
20 // *
21 //***************************************************************************
22 
23 
24 #include "PndCAParam.h"
25 #include "PndCAMath.h"
26 #include "PndCATrackParam.h"
27 #include "PndCATrackParamVector.h"
28 
29 #include <iostream>
30 //#include "debug.h"
31 
33  : fNStations(0), fStations(0)
34 {
35 }
36 
37 // std::ostream &operator<<( std::ostream &out, const PndCAParam &p )
38 // {
39 // // write settings to the file
40 // int iSl = 0;
41 // float tmp=0;
42 // out << iSl << std::endl;
43 // out << p.fNStations << std::endl;
44 // out << tmp << std::endl;
45 // out << tmp << std::endl;
46 // out << tmp << std::endl;
47 // out << tmp << std::endl;
48 // out << tmp << std::endl;
49 // out << tmp << std::endl;
50 // out << tmp << std::endl;
51 // out << tmp << std::endl;
52 // out << tmp << std::endl;
53 // out << tmp << std::endl;
54 // out << tmp << std::endl;
55 // out << tmp << std::endl;
56 // out << tmp << std::endl;
57 // out << tmp << std::endl;
58 // out << p.fBz << std::endl;
59 //
60 // return out;
61 // }
62 
63 std::istringstream &operator>>( std::istringstream &in, PndCAParam &p )
64 {
65  // Read settings from the file
66  in >> p.fNStations;
67  in >> p.fBz;
68  p.fVtxFieldValue = p.cBz();
69  if(p.fStations) delete [] p.fStations;
71  for(int i=0; i<p.fNStations; i++)
72  {
73  int inttmp;
74  in >> inttmp;
75  in >> p.fStations[i].r;
76  in >> p.fStations[i].xOverX0;
77  in >> p.fStations[i].xTimesRho;
78 
79  float beta;
80  in >> beta;
81  p.fStations[i].f.sin = sin(beta);
82  p.fStations[i].f.cos = cos(beta);
83 
84  in >> inttmp;
85  p.fStations[i].NDF = inttmp;
86  in >> inttmp;
87  p.fStations[i].CellLength = inttmp;
88  }
89 
90  p.fMaxZ = 75+20;
91  p.fMaxR = 41;
92  p.fMinR = 0;
93  p.fMinZ = -75+20;
94 
95  return in;
96 }
97 
Double_t p
Definition: anasim.C:58
friend F32vec4 cos(const F32vec4 &a)
Definition: P4_F32vec4.h:112
Int_t i
Definition: run_full.C:25
float xTimesRho
Definition: PndCAStation.h:23
friend F32vec4 sin(const F32vec4 &a)
Definition: P4_F32vec4.h:111
float fBz
Definition: PndCAParam.h:80
PndCAStripInfo f
Definition: PndCAStation.h:21
float fMinR
Definition: PndCAParam.h:84
int fNStations
Definition: PndCAParam.h:78
float fMaxR
Definition: PndCAParam.h:84
float fMinZ
Definition: PndCAParam.h:84
float fMaxZ
Definition: PndCAParam.h:84
float cBz() const
Definition: PndCAParam.h:49
PndCAFieldValue fVtxFieldValue
Definition: PndCAParam.h:82
TBuffer & operator>>(TBuffer &buf, PndAnaPidSelector *&obj)
PndCAStation * fStations
Definition: PndCAParam.h:79