@@ -67,22 +67,25 @@ Ring::Ring(int rPosId,
6767 int radTileCount{0 }, photTileCount{0 }, argSectorsCount{0 };
6868 // Radiator tiles
6969 for (auto & radiatorTile : radiatorTiles) {
70- radiatorTile = new TGeoArb8 (radZ / 2 );
71- radiatorTile->SetVertex (0 , -radThick / 2 , -radYmin / 2 );
72- radiatorTile->SetVertex (1 , -radThick / 2 , radYmin / 2 );
73- radiatorTile->SetVertex (2 , radThick / 2 , radYmin / 2 );
74- radiatorTile->SetVertex (3 , radThick / 2 , -radYmin / 2 );
75- radiatorTile->SetVertex (4 , -radThick / 2 , -radYmax / 2 );
76- radiatorTile->SetVertex (5 , -radThick / 2 , radYmax / 2 );
77- radiatorTile->SetVertex (6 , radThick / 2 , radYmax / 2 );
78- radiatorTile->SetVertex (7 , radThick / 2 , -radYmax / 2 );
70+ // Local Z is the thin (radial) dimension, looking outward from the IP
71+ // (previously this was local X). The placement rotation below is adjusted
72+ // by +90 deg about Y to keep the tile in the same physical position.
73+ radiatorTile = new TGeoArb8 (radThick / 2 );
74+ radiatorTile->SetVertex (0 , radZ / 2 , -radYmin / 2 );
75+ radiatorTile->SetVertex (1 , -radZ / 2 , -radYmax / 2 );
76+ radiatorTile->SetVertex (2 , -radZ / 2 , radYmax / 2 );
77+ radiatorTile->SetVertex (3 , radZ / 2 , radYmin / 2 );
78+ radiatorTile->SetVertex (4 , radZ / 2 , -radYmin / 2 );
79+ radiatorTile->SetVertex (5 , -radZ / 2 , -radYmax / 2 );
80+ radiatorTile->SetVertex (6 , -radZ / 2 , radYmax / 2 );
81+ radiatorTile->SetVertex (7 , radZ / 2 , radYmin / 2 );
7982
8083 TGeoVolume* radiatorTileVol = new TGeoVolume (Form (" radTile_%d_%d" , rPosId, radTileCount), radiatorTile, medAerogel);
8184 radiatorTileVol->SetLineColor (kOrange - 8 );
8285 radiatorTileVol->SetLineWidth (1 );
8386
8487 auto * rotRadiator = new TGeoRotation (Form (" radTileRotation_%d_%d" , radTileCount, rPosId));
85- rotRadiator->RotateY (- thetaBDeg);
88+ rotRadiator->RotateY (90.0 - thetaBDeg); // +90 compensates the X->Z swap of the tile's local axes
8689 rotRadiator->RotateZ (radTileCount * deltaPhiDeg);
8790
8891 auto * rotTransRadiator = new TGeoCombiTrans (radRad0 * TMath::Cos (radTileCount * TMath::Pi () / (nTilesPhi / 2 )),
@@ -96,22 +99,26 @@ Ring::Ring(int rPosId,
9699
97100 // Photosensor tiles
98101 for (auto & photoTile : photoTiles) {
99- photoTile = new TGeoArb8 (photZ / 2 );
100- photoTile->SetVertex (0 , -photThick / 2 , -photYmin / 2 );
101- photoTile->SetVertex (1 , -photThick / 2 , photYmin / 2 );
102- photoTile->SetVertex (2 , photThick / 2 , photYmin / 2 );
103- photoTile->SetVertex (3 , photThick / 2 , -photYmin / 2 );
104- photoTile->SetVertex (4 , -photThick / 2 , -photYmax / 2 );
105- photoTile->SetVertex (5 , -photThick / 2 , photYmax / 2 );
106- photoTile->SetVertex (6 , photThick / 2 , photYmax / 2 );
107- photoTile->SetVertex (7 , photThick / 2 , -photYmax / 2 );
102+ // Local Z is the thin (radial) dimension, looking outward from the IP
103+ // (previously this was local X, while for running with ACTS we need local Z).
104+ // The placement rotation below is adjusted by +90 deg about Y
105+ // to keep the tile in the same physical position.
106+ photoTile = new TGeoArb8 (photThick / 2 );
107+ photoTile->SetVertex (0 , photZ / 2 , -photYmin / 2 );
108+ photoTile->SetVertex (1 , -photZ / 2 , -photYmax / 2 );
109+ photoTile->SetVertex (2 , -photZ / 2 , photYmax / 2 );
110+ photoTile->SetVertex (3 , photZ / 2 , photYmin / 2 );
111+ photoTile->SetVertex (4 , photZ / 2 , -photYmin / 2 );
112+ photoTile->SetVertex (5 , -photZ / 2 , -photYmax / 2 );
113+ photoTile->SetVertex (6 , -photZ / 2 , photYmax / 2 );
114+ photoTile->SetVertex (7 , photZ / 2 , photYmin / 2 );
108115
109116 TGeoVolume* photoTileVol = new TGeoVolume (Form (" %s_%d_%d" , GeometryTGeo::getRICHSensorPattern (), rPosId, photTileCount), photoTile, medSi);
110117 photoTileVol->SetLineColor (kOrange - 8 );
111118 photoTileVol->SetLineWidth (1 );
112119
113120 auto * rotPhoto = new TGeoRotation (Form (" photoTileRotation_%d_%d" , photTileCount, rPosId));
114- rotPhoto->RotateY (- thetaBDeg);
121+ rotPhoto->RotateY (90.0 - thetaBDeg); // +90 compensates the X->Z swap of the tile's local axes
115122 rotPhoto->RotateZ (photTileCount * deltaPhiDeg);
116123 auto * rotTransPhoto = new TGeoCombiTrans (photR0 * TMath::Cos (photTileCount * TMath::Pi () / (nTilesPhi / 2 )),
117124 photR0 * TMath::Sin (photTileCount * TMath::Pi () / (nTilesPhi / 2 )),
0 commit comments