1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
18 Revision 1.3 2000/11/30 07:12:50 alibrary
19 Introducing new Rndm and QA classes
21 Revision 1.2 2000/10/02 15:17:54 morsch
22 Unused includes removed.
24 Revision 1.1 2000/06/09 20:24:00 morsch
25 Same class as previously in AliSimpleGen.cxx
26 All coding rule violations except RS3 corrected (AM)
32 // Simple particle gun.
33 // Momentum, phi and theta of the partice as well as the particle type can be set.
34 // andreas.morsch@cern.ch
37 <img src="picts/AliGeneratorClass.gif">
40 <font size=+2 color=red>
41 <p>The responsible person for this module is
42 <a href="mailto:andreas.morsch@cern.ch">Andreas Morsch</a>.
48 ///////////////////////////////////////////////////////////////////
50 #include "AliGenFixed.h"
56 //_____________________________________________________________________________
57 AliGenFixed::AliGenFixed()
61 // Default constructor
66 //_____________________________________________________________________________
67 AliGenFixed::AliGenFixed(Int_t npart)
71 // Standard constructor
74 fTitle="Fixed Particle Generator";
75 // Generate Proton by default
79 //_____________________________________________________________________________
80 void AliGenFixed::Generate()
83 // Generate one trigger
85 Float_t polar[3]= {0,0,0};
86 Float_t p[3] = {fPMin*TMath::Cos(fPhiMin)*TMath::Sin(fThetaMin),
87 fPMin*TMath::Sin(fPhiMin)*TMath::Sin(fThetaMin),
88 fPMin*TMath::Cos(fThetaMin)};
91 for(i=0;i<fNpart;i++) {
92 gAlice->SetTrack(fTrackIt,-1,fIpart,p,fOrigin.GetArray(),polar,0,kPPrimary,nt);
96 //_____________________________________________________________________________
97 void AliGenFixed::SetSigma(Float_t sx, Float_t sy, Float_t sz)
100 // Set the interaction point sigma
102 printf("Vertex smearing not implemented for fixed generator\n");