]>
Commit | Line | Data |
---|---|---|
4347b38f | 1 | /************************************************************************** |
2 | * Copyright(c) 2004, 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 | **************************************************************************/ | |
4347b38f | 15 | /* $Id$ */ |
c2fc1258 | 16 | /** @file AliFMD3.cxx |
17 | @author Christian Holm Christensen <cholm@nbi.dk> | |
18 | @date Sun Mar 26 18:26:12 2006 | |
19 | @brief Concrete implementation of AliFMDDetector for FMD3 | |
20 | */ | |
ba224443 | 21 | //____________________________________________________________________ |
4347b38f | 22 | // |
1a1fdef7 | 23 | // Concrete implementation of AliFMDDetector |
4347b38f | 24 | // |
088f8e79 | 25 | // This implements the geometry for FMD3. |
26 | // This has 2 rings. | |
27 | // The support of the FMD3 is a carbon-fibre cone, attached to the ITS | |
28 | // support via flanges. The cone also supports the beam-pipe. | |
4347b38f | 29 | // |
e802be3e | 30 | #include "AliFMD3.h" // ALIFMD3_H |
31 | #include "AliLog.h" // ALILOG_H | |
32 | #include "AliFMDRing.h" // ALIFMDRING_H | |
1a1fdef7 | 33 | #include <TMath.h> // ROOT_TMath |
4347b38f | 34 | |
1a1fdef7 | 35 | //==================================================================== |
925e6570 | 36 | ClassImp(AliFMD3) |
1a1fdef7 | 37 | #if 0 |
38 | ; // This is here to keep Emacs for indenting the next line | |
39 | #endif | |
4347b38f | 40 | |
41 | //____________________________________________________________________ | |
1a1fdef7 | 42 | AliFMD3::AliFMD3(AliFMDRing* inner, AliFMDRing* outer) |
43 | : AliFMDDetector(3, inner, outer) | |
4347b38f | 44 | { |
088f8e79 | 45 | // Constructor. |
1a1fdef7 | 46 | SetInnerZ(-62.8); |
47 | SetOuterZ(-75.2); | |
48 | SetNoseZ(); | |
49 | SetNoseLowR(); | |
50 | SetNoseHighR(); | |
51 | SetNoseLength(); | |
52 | SetBackLowR(); | |
53 | SetBackHighR(); | |
54 | SetBackLength(); | |
55 | SetBeamThickness(); | |
56 | SetBeamWidth(); | |
57 | SetConeLength(); | |
58 | SetFlangeR(); | |
59 | SetNBeam(); | |
60 | SetNFlange(); | |
4347b38f | 61 | } |
62 | ||
63 | //____________________________________________________________________ | |
1a1fdef7 | 64 | void |
65 | AliFMD3::Init() | |
4347b38f | 66 | { |
088f8e79 | 67 | // Initialize |
1a1fdef7 | 68 | AliFMDDetector::Init(); |
69 | SetInnerHoneyHighR(GetOuterHoneyHighR()); | |
70 | Double_t zdist = fConeLength - fBackLength - fNoseLength; | |
71 | Double_t tdist = fBackHighR - fNoseHighR; | |
72 | Double_t innerZh = fInnerZ - fInner->GetRingDepth() - fHoneycombThickness; | |
73 | Double_t outerZh = fOuterZ - fOuter->GetRingDepth() - fHoneycombThickness; | |
74 | Double_t minZ = TMath::Min(fNoseZ - fConeLength, outerZh); | |
75 | fAlpha = tdist / zdist; | |
76 | fZ = fNoseZ + (minZ - fNoseZ) / 2; | |
77 | fInnerHoneyHighR = ConeR(innerZh + fHoneycombThickness,"O") - 1; | |
78 | fOuterHoneyHighR = GetBackLowR(); | |
4347b38f | 79 | } |
80 | ||
ba224443 | 81 | //____________________________________________________________________ |
1a1fdef7 | 82 | Double_t |
83 | AliFMD3::ConeR(Double_t z, Option_t* opt) const | |
ba224443 | 84 | { |
1a1fdef7 | 85 | // Calculate the cone radius at Z |
86 | if (fAlpha < 0) { | |
088f8e79 | 87 | AliWarning(Form("alpha not set: %lf", fAlpha)); |
1a1fdef7 | 88 | return -1; |
ba224443 | 89 | } |
1a1fdef7 | 90 | if (z > fNoseZ) { |
088f8e79 | 91 | AliWarning(Form("z=%lf is before start of cone %lf", z, fNoseZ)); |
1a1fdef7 | 92 | return -1; |
ba224443 | 93 | } |
1a1fdef7 | 94 | if (z < fOuterZ - fOuter->GetRingDepth() - fHoneycombThickness) { |
088f8e79 | 95 | AliWarning(Form("z=%lf is after end of cone %lf", z, |
96 | fOuterZ - fOuter->GetRingDepth() - fHoneycombThickness)); | |
1a1fdef7 | 97 | return -1; |
98 | } | |
99 | Double_t e = fBeamThickness / TMath::Cos(TMath::ATan(fAlpha)); | |
100 | if (opt[0] == 'I' || opt[1] == 'i') e *= -1; | |
101 | if (z > fNoseZ - fNoseLength) return fNoseHighR + e; | |
102 | if (z < fNoseZ - fConeLength + fBackLength) return fBackHighR + e; | |
103 | Double_t r = fNoseHighR + fAlpha * TMath::Abs(z - fNoseZ + fNoseLength) + e; | |
104 | return r; | |
ba224443 | 105 | } |
106 | ||
4347b38f | 107 | |
108 | //____________________________________________________________________ | |
109 | // | |
110 | // EOF | |
111 | // |