Line data Source code
1 : /**************************************************************************
2 : * Copyright(c) 2007-2009, ALICE Experiment at CERN, All rights reserved. *
3 : * *
4 : * Author: The ALICE Off-line Project. *
5 : * Contributors are mentioned in the code where appropriate. *
6 : * *
7 : * Permission to use, copy, modify and distribute this software and its *
8 : * documentation strictly for non-commercial purposes is hereby granted *
9 : * without fee, provided that the above copyright notice appears in all *
10 : * copies and that both the copyright notice and this permission notice *
11 : * appear in the supporting documentation. The authors make no claims *
12 : * about the suitability of this software for any purpose. It is *
13 : * provided "as is" without express or implied warranty. *
14 : **************************************************************************/
15 :
16 : #include "AliMeanVertex.h"
17 :
18 : /* $Id$ */
19 :
20 : /*****************************************************************************
21 : * *
22 : * This class contains the coordinates of the mean primary vertex position *
23 : * computed by AliITSMeanVertex *
24 : * *
25 : *****************************************************************************/
26 :
27 172 : ClassImp(AliMeanVertex)
28 :
29 : //--------------------------------------------------------------------------
30 : AliMeanVertex::AliMeanVertex() :
31 0 : AliESDVertex(),
32 0 : fTotTracklets(0.),
33 0 : fAverTracklets(0.),
34 0 : fSigmaOnAverTrack(0.) {
35 : //
36 : // Default Constructor, set everything to 0
37 : //
38 0 : for(Int_t i=0;i<3;i++){
39 0 : fErrW[i]=0.;
40 : }
41 0 : }
42 :
43 : //--------------------------------------------------------------------------
44 : AliMeanVertex::AliMeanVertex(Double_t pos[3],Double_t err[3],Double_t cov[6],Int_t nevents, Float_t notracklets, Float_t avertracklets, Float_t signotrackl) :
45 0 : AliESDVertex(pos,cov,0.,nevents,"MeanVertex"),
46 0 : fTotTracklets(notracklets),
47 0 : fAverTracklets(avertracklets),
48 0 : fSigmaOnAverTrack(signotrackl) {
49 : //
50 : // Standard Constructor
51 : //
52 0 : for(Int_t i=0;i<3;i++){
53 0 : fErrW[i]=err[i];
54 : }
55 0 : }
56 :
57 : //--------------------------------------------------------------------------
58 : void AliMeanVertex::GetErrorsOnPosition(Double_t err[3]) const {
59 : //
60 : // Return errors on vertex average position (weighted mean on several events)
61 : //
62 0 : err[0] = fErrW[0];
63 0 : err[1] = fErrW[1];
64 0 : err[2] = fErrW[2];
65 :
66 0 : return;
67 : }
|