Skip to content

Commit

Permalink
Better phi parameterisation for closed tube
Browse files Browse the repository at this point in the history
Co-authored-by: Andre Sailer <[email protected]>
  • Loading branch information
Marko Petric and andresailer committed Mar 26, 2021
1 parent eb5d540 commit 6702117
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion DDCore/src/Shapes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ Cone& Cone::setDimensions(double z, double rmin1, double rmax1, double rmin2, do
void Tube::make(const string& nam, double rmin, double rmax, double z, double start_phi, double end_phi) {
// Check if it is a full tube
if(fabs(end_phi-start_phi-2*M_PI)<10e-6){
_assign(new TGeoTubeSeg(nam.c_str(), rmin, rmax, z, 0, 360.),nam,TUBE_TAG,true);
_assign(new TGeoTubeSeg(nam.c_str(), rmin, rmax, z, start_phi/units::deg, start_phi/units::deg+360.),nam,TUBE_TAG,true);
}else{
_assign(new TGeoTubeSeg(nam.c_str(), rmin, rmax, z, start_phi/units::deg, end_phi/units::deg),nam,TUBE_TAG,true);
}
Expand Down

0 comments on commit 6702117

Please sign in to comment.