FairRoot/PandaRoot
|
Go to the source code of this file.
Functions | |
for (Int_t i=0;i< 16;i++) | |
gROOT | Macro ("$VMCWORKDIR/gconfig/rootlogon.C") |
gSystem | Load ("libGeoBase") |
gSystem | Load ("libParBase") |
gSystem | Load ("libBase") |
gSystem | Load ("libPndData") |
gSystem | Load ("libPassive") |
geoFace | setMediaFile ("../../geometry/media_pnd.geo") |
geoFace | readMedia () |
geoFace | print () |
gGeoMan | SetTopVolume (top) |
trrotBox | RegisterYourself () |
SubunitVol3 | AddNode (BoxVol3, b, trrotBox) |
SubunitVol9 | AddNode (BoxVol4, b, trrotBox) |
if (b==1||b==2) | |
CrystalVol | SetLineColor (5) |
trrotQuar | SetName (name) |
trrotQuar | ReflectX (1) |
top | AddNode (QuarterVol, 1, trrotQuar) |
for (Int_t q=1;q<=3;q++) | |
gGeoMan | CloseGeometry () |
top | Write () |
fi | Close () |
Variables | |
const Double_t | kSpaceInSub = 0.024 |
const Double_t | kSpaceSubGlue = 0.036 |
const Double_t | kAlveoleThickness = 0.018 |
const Int_t | kNumOfQuarters = 1 |
const Int_t | kNumOfBoxes = 4 |
const Int_t | kNumOfCrystals = 4 |
Double_t | tr = 2.6 |
Double_t | b1 = 2.6000-0.5*tr |
Double_t | b2 = b1 |
Double_t | dz = 10.000 |
Double_t | vert [20] = -0.5*tr |
Double_t | vert0 [20] |
Double_t | vertBox [20] |
Double_t | vertSub [20] |
Double_t | vertQuar [20] |
Double_t | spacesQuar = 0.0 |
TString | outfile = "../../geometry/emc_module4_StraightGeo.root" |
TFile * | fi = new TFile(outfile,"RECREATE") |
FairGeoLoader * | geoLoad = new FairGeoLoader("TGeo","FairGeoLoader") |
FairGeoInterface * | geoFace = geoLoad->getGeoInterface() |
FairGeoMedia * | Media = geoFace->getMedia() |
FairGeoBuilder * | geobuild =geoLoad->getGeoBuilder() |
FairGeoMedium * | CbmMediumAir = Media->getMedium("air") |
FairGeoMedium * | CbmMediumPWO = Media->getMedium("PWO") |
FairGeoMedium * | CbmMediumCarbon = Media->getMedium("carbon") |
FairGeoMedium * | CbmMediumAluminium = Media->getMedium("aluminium") |
Int_t | nmed =geobuild->createMedium(CbmMediumAir) |
TGeoManager * | gGeoMan = (TGeoManager*)gROOT->FindObject("FAIRGeom") |
Double_t | sizeOfQuar = 42.752 |
TGeoVolume * | top = new TGeoVolumeAssembly("Emc4") |
TGeoTranslation | trQuar = new TGeoTranslation(0.5*sizeOfQuar,0.5*sizeOfQuar,0.) |
TGeoTranslation | trSub |
TGeoTranslation | trBox |
TGeoTranslation | trCrystal |
TGeoRotation | rotQuar = new TGeoRotation() |
TGeoRotation | rotSub |
TGeoRotation | rotBox |
TGeoRotation | rotCrystal |
TGeoShape * | QuarterShape |
TGeoShape * | SubunitShape |
TGeoShape * | BoxShape |
TGeoShape * | CrystalShape = new TGeoArb8(name,dz,vert) |
TGeoVolume * | QuarterVol |
TGeoVolume * | SubunitVol |
TGeoVolume * | SubunitVol1 |
TGeoVolume * | SubunitVol2 |
TGeoVolume * | SubunitVol3 |
TGeoVolume * | SubunitVol4 |
TGeoVolume * | SubunitVol5 |
TGeoVolume * | SubunitVol6 |
TGeoVolume * | SubunitVol7 |
TGeoVolume * | SubunitVol8 |
TGeoVolume * | SubunitVol9 |
TGeoVolume * | BoxVol |
TGeoVolume * | BoxVol1 |
TGeoVolume * | BoxVol2 |
TGeoVolume * | BoxVol3 |
TGeoVolume * | BoxVol4 |
TGeoVolume * | CrystalVol = new TGeoVolume(name,CrystalShape,gGeoMan->GetMedium(medium)) |
TString | name = "CrystalShape" |
TString | name1 |
TString | name2 |
TString | name3 |
TString | name4 |
TString | name5 |
TString | name6 |
TString | name7 |
TString | name8 |
TString | name9 |
cout << "-----------------------------------------------> Quarter VOLUME<<endl;name="QuarterShape";QuarterShape=newTGeoArb8(name,dz,vertQuar);name="Quarter4Vol";TStringmedium="air";QuarterVol=newTGeoVolumeAssembly(name);name="SubunitShape";SubunitShape=newTGeoArb8(name,dz,vertSub);TStringmedium="air";name="SubunitVol";name1="SubunitVol1";name2="SubunitVol2";name3="SubunitVol3";name4="SubunitVol4";name5="SubunitVol5";name6="SubunitVol6";name7="SubunitVol7";name8="SubunitVol8";name9="SubunitVol9";SubunitVol=newTGeoVolumeAssembly(name);SubunitVol1=newTGeoVolumeAssembly(name1);SubunitVol2=newTGeoVolumeAssembly(name2);SubunitVol3=newTGeoVolumeAssembly(name3);SubunitVol4=newTGeoVolumeAssembly(name4);SubunitVol5=newTGeoVolumeAssembly(name5);SubunitVol6=newTGeoVolumeAssembly(name6);SubunitVol7=newTGeoVolumeAssembly(name7);SubunitVol8=newTGeoVolumeAssembly(name8);SubunitVol9=newTGeoVolumeAssembly(name9);name="BoxShape";BoxShape=newTGeoArb8(name,dz,vertBox);TStringmedium="air";name="BoxVol";BoxVol=newTGeoVolumeAssembly(name);name1="BoxVol1";name2="BoxVol2";name3="BoxVol3";name4="BoxVol4";BoxVol1=newTGeoVolumeAssembly(name1);BoxVol2=newTGeoVolumeAssembly(name2);BoxVol3=newTGeoVolumeAssembly(name3);BoxVol4=newTGeoVolumeAssembly(name4);for(Int_tb=0;b <kNumOfBoxes;b++){cout <<""<<endl;cout <<"---------------->BOXnumber:" <<b<<endl;if(b==0){trBox=newTGeoTranslation(tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}if(b==1){trBox=newTGeoTranslation(-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}if(b==2){trBox=newTGeoTranslation(tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}if(b==3){trBox=newTGeoTranslation(-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}TGeoCombiTrans*trrotBox=newTGeoCombiTrans(trBox,rotBox);name="BoxVol";name+=b;trrotBox-> SetName(name);trrotBox-> RegisterYourself();SubunitVol-> AddNode(BoxVol,b,trrotBox);if(b==1){name+=b;trrotBox-> SetName(name);trrotBox-> RegisterYourself();SubunitVol1-> AddNode(BoxVol,b,trrotBox);}if(b==2){name+=b;trrotBox-> SetName(name);trrotBox-> RegisterYourself();SubunitVol2-> AddNode(BoxVol1,b,trrotBox);}if(b==0){name+=b;trrotBox-> | SetName (name) |
TString | medium ="PWO" |
Double_t | ShiftToZeroSub = kSpaceInSub + kAlveoleThickness |
Double_t | kSubShift =10.688 |
Double_t | FrontFaceToOffPoint =305 |
Int_t | jj =0 |
TGeoCombiTrans * | trrotQuar = new TGeoCombiTrans(trQuar,rotQuar) |
SubunitVol3 AddNode | ( | BoxVol3 | , |
b | , | ||
trrotBox | |||
) |
SubunitVol9 AddNode | ( | BoxVol4 | , |
b | , | ||
trrotBox | |||
) |
top AddNode | ( | QuarterVol | , |
1 | , | ||
trrotQuar | |||
) |
fi Close | ( | ) |
gGeoMan CloseGeometry | ( | ) |
for | ( | ) |
Definition at line 54 of file createRootGeoFileBwEnd_StraightGeo.C.
References Double_t, i, and kSpaceInSub.
for | ( | Int_t | q = 1; q<=3; q++ | ) |
gSystem Load | ( | "libGeoBase" | ) |
gSystem Load | ( | "libParBase" | ) |
gSystem Load | ( | "libBase" | ) |
gSystem Load | ( | "libPndData" | ) |
gSystem Load | ( | "libPassive" | ) |
gROOT Macro | ( | "$VMCWORKDIR/gconfig/rootlogon.C" | ) |
geoFace readMedia | ( | ) |
trrotQuar ReflectX | ( | 1 | ) |
trrotBox RegisterYourself | ( | ) |
CrystalVol SetLineColor | ( | 5 | ) |
geoFace setMediaFile | ( | "../../geometry/media_pnd.geo" | ) |
top Write | ( | ) |
Definition at line 22 of file createRootGeoFileBwEnd_StraightGeo.C.
Definition at line 23 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoShape* BoxShape |
Definition at line 182 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* BoxVol |
Definition at line 196 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* BoxVol1 |
Definition at line 197 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* BoxVol2 |
Definition at line 198 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* BoxVol3 |
Definition at line 199 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* BoxVol4 |
Definition at line 200 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoMedium* CbmMediumAir = Media->getMedium("air") |
Definition at line 150 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoMedium* CbmMediumAluminium = Media->getMedium("aluminium") |
Definition at line 153 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoMedium* CbmMediumCarbon = Media->getMedium("carbon") |
Definition at line 152 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoMedium* CbmMediumPWO = Media->getMedium("PWO") |
Definition at line 151 of file createRootGeoFileBwEnd_StraightGeo.C.
Definition at line 183 of file createRootGeoFileBwEnd_StraightGeo.C.
CrystalVol = new TGeoVolume(name,CrystalShape,gGeoMan->GetMedium(medium)) |
Definition at line 201 of file createRootGeoFileBwEnd_StraightGeo.C.
dz = 10.000 |
Definition at line 25 of file createRootGeoFileBwEnd_StraightGeo.C.
TFile* fi = new TFile(outfile,"RECREATE") |
Definition at line 139 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t FrontFaceToOffPoint =305 |
Definition at line 437 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoBuilder* geobuild =geoLoad->getGeoBuilder() |
Definition at line 148 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoInterface* geoFace = geoLoad->getGeoInterface() |
Definition at line 142 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoLoader* geoLoad = new FairGeoLoader("TGeo","FairGeoLoader") |
Definition at line 141 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoManager* gGeoMan = (TGeoManager*)gROOT->FindObject("FAIRGeom") |
Definition at line 160 of file createRootGeoFileBwEnd_StraightGeo.C.
Int_t jj =0 |
Definition at line 439 of file createRootGeoFileBwEnd_StraightGeo.C.
const Double_t kAlveoleThickness = 0.018 |
Definition at line 13 of file createRootGeoFileBwEnd_StraightGeo.C.
const Int_t kNumOfBoxes = 4 |
Definition at line 16 of file createRootGeoFileBwEnd_StraightGeo.C.
const Int_t kNumOfCrystals = 4 |
Definition at line 17 of file createRootGeoFileBwEnd_StraightGeo.C.
const Int_t kNumOfQuarters = 1 |
Definition at line 15 of file createRootGeoFileBwEnd_StraightGeo.C.
const Double_t kSpaceInSub = 0.024 |
Definition at line 10 of file createRootGeoFileBwEnd_StraightGeo.C.
const Double_t kSpaceSubGlue = 0.036 |
Definition at line 11 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t kSubShift =10.688 |
Definition at line 435 of file createRootGeoFileBwEnd_StraightGeo.C.
FairGeoMedia* Media = geoFace->getMedia() |
Definition at line 147 of file createRootGeoFileBwEnd_StraightGeo.C.
TString medium ="PWO" |
Definition at line 367 of file createRootGeoFileBwEnd_StraightGeo.C.
name = "CrystalShape" |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name1 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name2 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name3 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name4 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name5 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name6 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name7 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name8 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
TString name9 |
Definition at line 203 of file createRootGeoFileBwEnd_StraightGeo.C.
nmed =geobuild->createMedium(CbmMediumAir) |
Definition at line 155 of file createRootGeoFileBwEnd_StraightGeo.C.
TString outfile = "../../geometry/emc_module4_StraightGeo.root" |
Definition at line 138 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoShape* QuarterShape |
Definition at line 180 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* QuarterVol |
Definition at line 185 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoRotation rotBox |
Definition at line 177 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoRotation rotCrystal |
Definition at line 178 of file createRootGeoFileBwEnd_StraightGeo.C.
rotQuar = new TGeoRotation() |
Definition at line 175 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoRotation rotSub |
Definition at line 176 of file createRootGeoFileBwEnd_StraightGeo.C.
cout<< "-----------------------------------------------> Quarter VOLUME<<endl;name="QuarterShape";QuarterShape=newTGeoArb8(name,dz,vertQuar);name="Quarter4Vol";TStringmedium="air";QuarterVol=newTGeoVolumeAssembly(name);name="SubunitShape";SubunitShape=newTGeoArb8(name,dz,vertSub);TStringmedium="air";name="SubunitVol";name1="SubunitVol1";name2="SubunitVol2";name3="SubunitVol3";name4="SubunitVol4";name5="SubunitVol5";name6="SubunitVol6";name7="SubunitVol7";name8="SubunitVol8";name9="SubunitVol9";SubunitVol=newTGeoVolumeAssembly(name);SubunitVol1=newTGeoVolumeAssembly(name1);SubunitVol2=newTGeoVolumeAssembly(name2);SubunitVol3=newTGeoVolumeAssembly(name3);SubunitVol4=newTGeoVolumeAssembly(name4);SubunitVol5=newTGeoVolumeAssembly(name5);SubunitVol6=newTGeoVolumeAssembly(name6);SubunitVol7=newTGeoVolumeAssembly(name7);SubunitVol8=newTGeoVolumeAssembly(name8);SubunitVol9=newTGeoVolumeAssembly(name9);name="BoxShape";BoxShape=newTGeoArb8(name,dz,vertBox);TStringmedium="air";name="BoxVol";BoxVol=newTGeoVolumeAssembly(name);name1="BoxVol1";name2="BoxVol2";name3="BoxVol3";name4="BoxVol4";BoxVol1=newTGeoVolumeAssembly(name1);BoxVol2=newTGeoVolumeAssembly(name2);BoxVol3=newTGeoVolumeAssembly(name3);BoxVol4=newTGeoVolumeAssembly(name4);for(Int_tb=0;b<kNumOfBoxes;b++){cout<<""<<endl;cout<<"---------------->BOXnumber:"<<b<<endl;if(b==0){trBox=newTGeoTranslation(tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}if(b==1){trBox=newTGeoTranslation(-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}if(b==2){trBox=newTGeoTranslation(tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}if(b==3){trBox=newTGeoTranslation(-tr-kSpaceInSub-kAlveoleThickness-0.5*kSpaceInBox,tr+kSpaceInSub+kAlveoleThickness+0.5*kSpaceInBox,0.);rotBox=newTGeoRotation();rotBox.RotateX(0.);rotBox.RotateY(0.);}TGeoCombiTrans*trrotBox=newTGeoCombiTrans(trBox,rotBox);name="BoxVol";name+=b;trrotBox->SetName(name);trrotBox->RegisterYourself();SubunitVol->AddNode(BoxVol,b,trrotBox);if(b==1){name+=b;trrotBox->SetName(name);trrotBox->RegisterYourself();SubunitVol1->AddNode(BoxVol,b,trrotBox);}if(b==2){name+=b;trrotBox->SetName(name);trrotBox->RegisterYourself();SubunitVol2->AddNode(BoxVol1,b,trrotBox);}if(b==0){name+=b;trrotBox-> SetName(name) |
Definition at line 327 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t ShiftToZeroSub = kSpaceInSub + kAlveoleThickness |
Definition at line 434 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t sizeOfQuar = 42.752 |
Definition at line 163 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t spacesQuar = 0.0 |
Definition at line 104 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoShape* SubunitShape |
Definition at line 181 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol |
Definition at line 186 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol1 |
Definition at line 187 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol2 |
Definition at line 188 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol3 |
Definition at line 189 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol4 |
Definition at line 190 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol5 |
Definition at line 191 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol6 |
Definition at line 192 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol7 |
Definition at line 193 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol8 |
Definition at line 194 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* SubunitVol9 |
Definition at line 195 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoVolume* top = new TGeoVolumeAssembly("Emc4") |
Definition at line 166 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t tr = 2.6 |
Definition at line 20 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoTranslation trBox |
Definition at line 172 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoTranslation trCrystal |
Definition at line 173 of file createRootGeoFileBwEnd_StraightGeo.C.
trQuar = new TGeoTranslation(0.5*sizeOfQuar,0.5*sizeOfQuar,0.) |
Definition at line 170 of file createRootGeoFileBwEnd_StraightGeo.C.
Definition at line 538 of file createRootGeoFileBwEnd_StraightGeo.C.
TGeoTranslation trSub |
Definition at line 171 of file createRootGeoFileBwEnd_StraightGeo.C.
vert[15] = -0.5*tr |
Definition at line 25 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t vert0[20] |
Definition at line 26 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t vertBox[20] |
Definition at line 26 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t vertQuar[20] |
Definition at line 26 of file createRootGeoFileBwEnd_StraightGeo.C.
Double_t vertSub[20] |
Definition at line 26 of file createRootGeoFileBwEnd_StraightGeo.C.