]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STRUCT/AliPIPEv0.cxx
New structure of beam pipe and heating jacket.
[u/mrichter/AliRoot.git] / STRUCT / AliPIPEv0.cxx
CommitLineData
4c039060 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$
b43eb0dc 18Revision 1.7 2000/02/23 16:25:24 fca
19AliVMC and AliGeant3 classes introduced
20ReadEuclid moved from AliRun to AliModule
21
b13db077 22Revision 1.6 1999/09/29 09:24:30 fca
23Introduction of the Copyright and cvs Log
24
4c039060 25*/
26
fe4da5cc 27////////////////////////////////////////////////
28// Beam pipe class /
29////////////////////////////////////////////////
30
fe4da5cc 31#include "AliPIPEv0.h"
32#include "AliRun.h"
fe4da5cc 33#include "TSystem.h"
34
35ClassImp(AliPIPEv0)
36
37//_____________________________________________________________________________
b8032157 38AliPIPEv0::AliPIPEv0()
fe4da5cc 39{
b43eb0dc 40// Constructor
fe4da5cc 41}
42
43//_____________________________________________________________________________
44AliPIPEv0::AliPIPEv0(const char *name, const char *title)
45 : AliPIPE(name,title)
46{
b43eb0dc 47// Constructor
fe4da5cc 48}
49
50
51//___________________________________________
52void AliPIPEv0::CreateGeometry()
53{
54 printf("Create PIPEv0 geometry\n ");
55//Begin_Html
56/*
1439f98e 57<img src="picts/pipe.gif">
fe4da5cc 58*/
59//End_Html
60
61
62//Begin_Html
63/*
1439f98e 64<img src="picts/tree_pipe.gif">
fe4da5cc 65*/
66//End_Html
67
b43eb0dc 68 const char *kPipeName = "$(ALICE_ROOT)/Euclid/bpipeb.euc";
69 const char *kPumpName = "$(ALICE_ROOT)/Euclid/bpumpa.euc";
fe4da5cc 70 char *filtmp;
71 char topvol[5];
72 printf("Create PIPEv0 geometry ");
73
74 Int_t idrotm[2099];
75
fe4da5cc 76//
77// The peam pipe up to the Front Absorber
b43eb0dc 78 filtmp=gSystem->ExpandPathName(kPipeName);
fe4da5cc 79 FILE *file = fopen(filtmp,"r");
80 delete [] filtmp;
81 if(file) {
82 fclose(file);
83 printf(" Reading PIPE \n");
b43eb0dc 84 ReadEuclid(kPipeName,topvol);
fe4da5cc 85 } else {
b43eb0dc 86 printf(" THE GEOM FILE %s DOES NOT EXIST !\n",kPipeName);
fe4da5cc 87 exit(1);
88 }
89//
90// The Ion Pump
b43eb0dc 91 filtmp=gSystem->ExpandPathName(kPumpName);
fe4da5cc 92 file = fopen(filtmp,"r");
93 delete [] filtmp;
94 if(file) {
95 fclose(file);
96 printf(" Reading PUMP \n");
b43eb0dc 97 ReadEuclid(kPumpName,topvol);
fe4da5cc 98 } else {
b43eb0dc 99 printf(" THE GEOM FILE %s DOES NOT EXIST !\n",kPumpName);
fe4da5cc 100 exit(1);
101 }
102//
103// --- Place the PIPE ghost volume (QBPM) in its mother volume (ALIC)
104// and make it invisible
105//
106 AliMatrix(idrotm[2001],90.,0.,90.,90.,180.,0.);
107
cfce8870 108 gMC->Gspos("QBPM",1,"ALIC",0,0,0,idrotm[2001],"ONLY");
fe4da5cc 109//
110// PLACE ION PUMP (QIPM) AT Z=-385.
111//
cfce8870 112 gMC->Gspos("QIPM",1,"ALIC",0,0,-385,idrotm[2001],"ONLY");
fe4da5cc 113
cfce8870 114 gMC->Gsatt("QIPM", "SEEN", 0);
115 gMC->Gsatt("QBPM", "SEEN", 0);
116 gMC->Gsatt("QB20", "SEEN", 0);
fe4da5cc 117}
118
119
120//___________________________________________
b8032157 121void AliPIPEv0::DrawModule()
fe4da5cc 122{
b43eb0dc 123// Set drawing options
124 ;
fe4da5cc 125}
126
127//___________________________________________
128void AliPIPEv0::CreateMaterials()
129{
b43eb0dc 130// Create materials and media from Euclid file
fe4da5cc 131 printf("Create PIPEv0 materials\n");
b43eb0dc 132 const char *kName = "$(ALICE_ROOT)/Euclid/pipe.tme";
fe4da5cc 133 char *filtmp;
b43eb0dc 134 filtmp=gSystem->ExpandPathName(kName);
fe4da5cc 135 FILE *file = fopen(filtmp,"r");
136 delete [] filtmp;
137 if(file) {
138 fclose(file);
b43eb0dc 139 ReadEuclidMedia(kName);
fe4da5cc 140 } else {
b43eb0dc 141 printf(" THE MEDIA FILE %s DOES NOT EXIST !\n",kName);
fe4da5cc 142 exit(1);
143 }
144}
145
146
147
148
149
150
151
152
153
154
155
156
157
158