61 axis0min, axis1min, axis0max, axis1max)
63 if (axis0 ==
kPhi && axis1 ==
kRho) {
64 G4Exception(
"G4TwistTubsFlatSide::G4TwistTubsFlatSide()",
66 "Should swap axis0 and axis1!");
94 G4int i = (handedness < 0 ? 0 : 1);
108 fSurfaceArea = 0.5*DPhi * (EndOuterRadius[i]*EndOuterRadius[i]
109 - EndInnerRadius[i]*EndInnerRadius[i] ) ;
168 for (i=0; i<2; i++) {
169 distance[i] = kInfinity;
172 gxx[i].
set(kInfinity, kInfinity, kInfinity);
184 if (std::fabs(p.
z()) == 0.) {
213 isvalid[0], 0, validate, &gp, &gv);
217 distance[0] = - (p.
z() / v.
z());
225 if (distance[0] >= 0) isvalid[0] =
true;
230 if (distance[0] >= 0) isvalid[0] =
true;
234 if (distance[0] >= 0) isvalid[0] =
true;
238 isvalid[0], 1, validate, &gp, &gv);
241 G4cerr <<
"ERROR - G4TwistTubsFlatSide::DistanceToSurface(p,v)" <<
G4endl;
277 for (i=0; i<2; i++) {
278 distance[i] = kInfinity;
280 gxx[i].
set(kInfinity, kInfinity, kInfinity);
293 distance[0] = std::fabs(p.
z());
294 xx.
set(p.
x(), p.
y(), 0);
370 areacode = tmpareacode;
407 std::ostringstream message;
408 message <<
"Feature NOT implemented !" <<
G4endl
410 <<
" fAxis[1] = " <<
fAxis[1];
411 G4Exception(
"G4TwistTubsFlatSide::GetAreaCode()",
"GeomSolids0001",
421 void G4TwistTubsFlatSide::SetCorners()
453 std::ostringstream message;
454 message <<
"Feature NOT implemented !" <<
G4endl
456 <<
" fAxis[1] = " <<
fAxis[1];
457 G4Exception(
"G4TwistTubsFlatSide::SetCorners()",
"GeomSolids0001",
465 void G4TwistTubsFlatSide::SetBoundaries()
475 direction = direction.
unit();
481 direction = direction.
unit();
487 direction = direction.
unit();
493 direction = direction.
unit();
497 std::ostringstream message;
498 message <<
"Feature NOT implemented !" <<
G4endl
500 <<
" fAxis[1] = " <<
fAxis[1];
501 G4Exception(
"G4TwistTubsFlatSide::SetBoundaries()",
"GeomSolids0001",
525 for ( i = 0 ; i<
n ; i++ ) {
527 r = rmin + i*(rmax-rmin)/(n-1) ;
532 for ( j = 0 ; j<k ; j++ )
534 phi = phimin + j*(phimax-phimin)/(k-1) ;
536 nnode =
GetNode(i,j,k,n,iside) ;
539 xyz[nnode][0] = p.
x() ;
540 xyz[nnode][1] = p.
y() ;
541 xyz[nnode][2] = p.
z() ;
543 if ( i<n-1 && j<k-1 ) {
545 nface =
GetFace(i,j,k,n,iside) ;