Belle II Software  release-08-01-10
ARICHGeoCooling.cc
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 
9 //basf2
10 #include <arich/dbobjects/ARICHGeoCooling.h>
11 #include <framework/logging/Logger.h>
12 #include <iostream>
13 #include <iomanip>
14 
15 //root
16 #include <TVector3.h>
17 
18 using namespace std;
19 using namespace Belle2;
20 
21 void ARICHGeoCooling::print(const std::string& title) const
22 {
23 
24  ARICHGeoBase::print(title);
25 
26  cout << "Outer radius of merger PCB assembly envelope : " << getEnvelopeOuterRadius() << endl
27  << "Inner radius of merger PCB assembly envelope : " << getEnvelopeInnerRadius() << endl
28  << "Thickness of merger PCB assembly envelope : " << getEnvelopeThickness() << endl;
29  cout << "X0 merger PCB assembly envelope : " << getEnvelopeCenterPosition().X() << endl
30  << "Y0 merger PCB assembly envelope : " << getEnvelopeCenterPosition().Y() << endl
31  << "Z0 merger PCB assembly envelope : " << getEnvelopeCenterPosition().Z() << endl;
32  cout << "material name of cooling pipe : " << getCoolingPipeMaterialName() << endl
33  << "Size of cooling system pipe : inner radius in mm : " << getRmin() << endl
34  << "Size of cooling system pipe : outer radius in mm : " << getRmax() << endl;
35  cout << "Material name of cooling test plates : " << getCoolingTestPlateMaterialName() << endl
36  << "Size of cooling test plates (x) : " << getCoolingTestPlateslengths().X() << endl
37  << "Size of cooling test plates (y) : " << getCoolingTestPlateslengths().Y() << endl
38  << "Size of cooling test plates (z) : " << getCoolingTestPlateslengths().Z() << endl
39  << "Radius of cold tubes : " << getColdTubeR() << endl
40  << "Depth of the cold tube in the cooling plate : " << getDepthColdTubeInPlate() << endl
41  << "Distance from center of the cold tube to edge of cooling plate : " << getColdTubeSpacing() << endl
42  << "number of cold tubes in one plate : " << getColdTubeNumber() << endl;
43  cout << "material name of cold tube : " << getColdTubeMaterialName() << endl
44  << "outer radius of subtracted tubes for cold tube : " << getColdTubeSubtractedR() << endl
45  << "cold tube wall thickness : " << getColdTubeWallThickness() << endl;
46 
47  cout << setw(20) << " #" << setw(25) << "coolingTestPlatePosR" << setw(25) << "coolingTestPlatePosPhi" << setw(
48  25) << "coolingTestPlatePosZ0" << endl;
49  for (unsigned i = 0; i < getCoolingTestPlatePosR().size(); i++) {
50  cout << setw(20) << i
51  << setw(25) << getCoolingTestPlatePosR().at(i)
52  << setw(25) << getCoolingTestPlatePosPhi().at(i)
53  << setw(25) << getCoolingTestPlatePosZ0().at(i) << endl;
54  }
55 
56  cout << setw(20) << " #" << setw(20) << "coolingGeometryID" << setw(20) << "coolingL" << setw(20) << "coolingPosPhi" << setw(
57  20) << "coolingPosR" << setw(25) << "coolinRotationAngle" << endl;
58  for (unsigned i = 0; i < getCoolingGeometryID().size(); i++) {
59  cout << setw(20) << i
60  << setw(20) << getCoolingGeometryID().at(i)
61  << setw(20) << getCoolingL().at(i)
62  << setw(20) << getCoolingPosPhi().at(i)
63  << setw(20) << getCoolingPosR().at(i)
64  << setw(25) << getCoolinRotationAngle().at(i) << endl;
65  }
66 
67 }
68 
69 void ARICHGeoCooling::checkCoolingSystemDataConsistency() const
70 {
71 
72  B2ASSERT("Data of the cooling system positions is inconsisten : getCoolingGeometryID().size() != getCoolingL().size()",
73  getCoolingGeometryID().size() == getCoolingL().size());
74  B2ASSERT("Data of the cooling system positions is inconsisten : getCoolingL().size() != getCoolingPosPhi().size()",
75  getCoolingL().size() == getCoolingPosPhi().size());
76  B2ASSERT("Data of the cooling system positions is inconsisten : getCoolingPosPhi().size() != getCoolingPosR().size()",
77  getCoolingPosPhi().size() == getCoolingPosR().size());
78  B2ASSERT("Data of the cooling system positions is inconsisten : getCoolingPosR().size() != getCoolinRotationAngle().size()",
79  getCoolingPosR().size() == getCoolinRotationAngle().size());
80  B2ASSERT("Data of the cooling system positions is inconsisten : getCoolingTestPlatePosR().size() != getCoolingTestPlatePosPhi().size()",
81  getCoolingTestPlatePosR().size() == getCoolingTestPlatePosPhi().size());
82 }
Abstract base class for different kinds of events.