]>
Commit | Line | Data |
---|---|---|
11141716 | 1 | /************************************************************************** |
2 | * Copyright(c) 1998-1999, 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 | /* | |
17 | $Log$ | |
18 | */ | |
19 | ||
20 | #include "AliLhcProcessBB.h" | |
21 | #include "AliLHC.h" | |
22 | #include "AliLhcIRegion.h" | |
23 | #include "AliLhcBeam.h" | |
24 | ||
25 | ClassImp(AliLhcProcessBB) | |
26 | ||
27 | AliLhcProcessBB::AliLhcProcessBB(AliLHC* lhc, const char* name, const char* title) | |
28 | :AliLhcProcess(lhc,name,title) | |
29 | { | |
30 | // Constructor | |
31 | } | |
32 | ||
33 | ||
34 | AliLhcProcessBB::~AliLhcProcessBB() | |
35 | { | |
36 | // Destructor | |
37 | ||
38 | } | |
39 | ||
40 | void AliLhcProcessBB::Init() | |
41 | { | |
42 | // Initialization | |
43 | printf("\n Initializing Process %s", GetName()); | |
44 | printf("\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^"); | |
45 | fIRegions = fAccelerator->IRegions(); | |
46 | fBeam1 = fAccelerator->Beam(0); | |
47 | fBeam2 = fAccelerator->Beam(1); | |
48 | } | |
49 | ||
50 | void AliLhcProcessBB::Evolve(Float_t dt) | |
51 | { | |
52 | printf("\n Here process %s %f:", GetName(), dt); | |
53 | TIter next(fIRegions); | |
54 | AliLhcIRegion *region; | |
55 | // | |
56 | // Loop over generators and initialize | |
57 | while((region = (AliLhcIRegion*)next())) { | |
58 | Float_t rate = region->Luminosity()*fCrossSection; | |
59 | Float_t loss = rate*dt; | |
60 | fBeam1->RemoveParticles(loss); | |
61 | fBeam2->RemoveParticles(loss); | |
62 | } | |
63 | } | |
64 | ||
65 | ||
66 | AliLhcProcessBB& AliLhcProcessBB::operator=(const AliLhcProcessBB & rhs) | |
67 | { | |
68 | // Assignment operator | |
69 | return *this; | |
70 | } | |
71 | ||
72 |