ROOT logo
/**************************************************************************
 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 *                                                                        *
 * Author: The ALICE Off-line Project.                                    *
 * Contributors are mentioned in the code where appropriate.              *
 *                                                                        *
 * Permission to use, copy, modify and distribute this software and its   *
 * documentation strictly for non-commercial purposes is hereby granted   *
 * without fee, provided that the above copyright notice appears in all   *
 * copies and that both the copyright notice and this permission notice   *
 * appear in the supporting documentation. The authors make no claims     *
 * about the suitability of this software for any purpose. It is          *
 * provided "as is" without express or implied warranty.                  *
 **************************************************************************/

/* $Id$ */
//
// Class for fast simulation of the ALICE Muon Spectrometer
// Tracking Efficiency.
// The efficiency depends on trasverse momentum pt, polar angle theta and azimuthal angle phi.
//
// Author: Alessandro de Falco 
// alessandro.de.falco@ca.infn.it
// 

#include <TMath.h>

#include "AliFastMuonTrackingEff.h"
#include "AliMUONFastTracking.h"

ClassImp(AliFastMuonTrackingEff)


AliFastMuonTrackingEff::AliFastMuonTrackingEff() :
    AliFastResponse("Efficiency", "Muon Tracking Efficiency"),
    fBackground(1.),
    fCharge(1.),
    fFastTracking(0)
{
//
// Constructor
}

AliFastMuonTrackingEff::AliFastMuonTrackingEff(const AliFastMuonTrackingEff& eff)
    :AliFastResponse(eff),
    fBackground(1.),
    fCharge(1.),
    fFastTracking(0)
{
// Copy constructor
    eff.Copy(*this);
}

void AliFastMuonTrackingEff::Init()
{
//
// Initialization
    fFastTracking = AliMUONFastTracking::Instance();
    fFastTracking->Init(fBackground);
}



Float_t AliFastMuonTrackingEff::Evaluate(Float_t /*charge*/, Float_t pt, Float_t theta, Float_t phi)
{
//
// Evaluate the efficience for muon with 3-vector (pt, theta, phi)
    Float_t p = pt / TMath::Sin(theta*TMath::Pi()/180.);
    Float_t eff =  fFastTracking->Efficiency(p, theta, phi, Int_t(fCharge));
    return eff;
}


AliFastMuonTrackingEff& AliFastMuonTrackingEff::operator=(const  AliFastMuonTrackingEff& rhs)
{
// Assignment operator
    rhs.Copy(*this);
    return *this;
}

 AliFastMuonTrackingEff.cxx:1
 AliFastMuonTrackingEff.cxx:2
 AliFastMuonTrackingEff.cxx:3
 AliFastMuonTrackingEff.cxx:4
 AliFastMuonTrackingEff.cxx:5
 AliFastMuonTrackingEff.cxx:6
 AliFastMuonTrackingEff.cxx:7
 AliFastMuonTrackingEff.cxx:8
 AliFastMuonTrackingEff.cxx:9
 AliFastMuonTrackingEff.cxx:10
 AliFastMuonTrackingEff.cxx:11
 AliFastMuonTrackingEff.cxx:12
 AliFastMuonTrackingEff.cxx:13
 AliFastMuonTrackingEff.cxx:14
 AliFastMuonTrackingEff.cxx:15
 AliFastMuonTrackingEff.cxx:16
 AliFastMuonTrackingEff.cxx:17
 AliFastMuonTrackingEff.cxx:18
 AliFastMuonTrackingEff.cxx:19
 AliFastMuonTrackingEff.cxx:20
 AliFastMuonTrackingEff.cxx:21
 AliFastMuonTrackingEff.cxx:22
 AliFastMuonTrackingEff.cxx:23
 AliFastMuonTrackingEff.cxx:24
 AliFastMuonTrackingEff.cxx:25
 AliFastMuonTrackingEff.cxx:26
 AliFastMuonTrackingEff.cxx:27
 AliFastMuonTrackingEff.cxx:28
 AliFastMuonTrackingEff.cxx:29
 AliFastMuonTrackingEff.cxx:30
 AliFastMuonTrackingEff.cxx:31
 AliFastMuonTrackingEff.cxx:32
 AliFastMuonTrackingEff.cxx:33
 AliFastMuonTrackingEff.cxx:34
 AliFastMuonTrackingEff.cxx:35
 AliFastMuonTrackingEff.cxx:36
 AliFastMuonTrackingEff.cxx:37
 AliFastMuonTrackingEff.cxx:38
 AliFastMuonTrackingEff.cxx:39
 AliFastMuonTrackingEff.cxx:40
 AliFastMuonTrackingEff.cxx:41
 AliFastMuonTrackingEff.cxx:42
 AliFastMuonTrackingEff.cxx:43
 AliFastMuonTrackingEff.cxx:44
 AliFastMuonTrackingEff.cxx:45
 AliFastMuonTrackingEff.cxx:46
 AliFastMuonTrackingEff.cxx:47
 AliFastMuonTrackingEff.cxx:48
 AliFastMuonTrackingEff.cxx:49
 AliFastMuonTrackingEff.cxx:50
 AliFastMuonTrackingEff.cxx:51
 AliFastMuonTrackingEff.cxx:52
 AliFastMuonTrackingEff.cxx:53
 AliFastMuonTrackingEff.cxx:54
 AliFastMuonTrackingEff.cxx:55
 AliFastMuonTrackingEff.cxx:56
 AliFastMuonTrackingEff.cxx:57
 AliFastMuonTrackingEff.cxx:58
 AliFastMuonTrackingEff.cxx:59
 AliFastMuonTrackingEff.cxx:60
 AliFastMuonTrackingEff.cxx:61
 AliFastMuonTrackingEff.cxx:62
 AliFastMuonTrackingEff.cxx:63
 AliFastMuonTrackingEff.cxx:64
 AliFastMuonTrackingEff.cxx:65
 AliFastMuonTrackingEff.cxx:66
 AliFastMuonTrackingEff.cxx:67
 AliFastMuonTrackingEff.cxx:68
 AliFastMuonTrackingEff.cxx:69
 AliFastMuonTrackingEff.cxx:70
 AliFastMuonTrackingEff.cxx:71
 AliFastMuonTrackingEff.cxx:72
 AliFastMuonTrackingEff.cxx:73
 AliFastMuonTrackingEff.cxx:74
 AliFastMuonTrackingEff.cxx:75
 AliFastMuonTrackingEff.cxx:76
 AliFastMuonTrackingEff.cxx:77
 AliFastMuonTrackingEff.cxx:78
 AliFastMuonTrackingEff.cxx:79
 AliFastMuonTrackingEff.cxx:80