Import Geant4 9.6.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 17:01:34 +02:00
parent b1eb5424d2
commit e2d2f9810a
10384 changed files with 698580 additions and 628834 deletions
@@ -24,8 +24,7 @@
// ********************************************************************
//
//
// $Id: G4TwistTrapFlatSide.cc,v 1.7 2010-07-12 15:25:37 gcosmo Exp $
// GEANT4 tag $Name: not supported by cvs2svn $
// $Id$
//
//
// --------------------------------------------------------------------
@@ -484,7 +483,7 @@ void G4TwistTrapFlatSide::SetBoundaries()
//=====================================================================
//* GetFacets() -------------------------------------------------------
void G4TwistTrapFlatSide::GetFacets( G4int m, G4int n, G4double xyz[][3],
void G4TwistTrapFlatSide::GetFacets( G4int k, G4int n, G4double xyz[][3],
G4int faces[][4], G4int iside )
{
@@ -496,7 +495,7 @@ void G4TwistTrapFlatSide::GetFacets( G4int m, G4int n, G4double xyz[][3],
G4double xmin,xmax ;
// calculate the (n-1)*(m-1) vertices
// calculate the (n-1)*(k-1) vertices
G4int i,j ;
@@ -504,33 +503,33 @@ void G4TwistTrapFlatSide::GetFacets( G4int m, G4int n, G4double xyz[][3],
y = -fDy + i*(2*fDy)/(n-1) ;
for ( j = 0 ; j<m ; j++ ) {
for ( j = 0 ; j<k ; j++ ) {
xmin = GetBoundaryMin(y) ;
xmax = GetBoundaryMax(y) ;
x = xmin + j*(xmax-xmin)/(m-1) ;
x = xmin + j*(xmax-xmin)/(k-1) ;
nnode = GetNode(i,j,m,n,iside) ;
nnode = GetNode(i,j,k,n,iside) ;
p = SurfacePoint(x,y,true) ; // surface point in global coordinate system
xyz[nnode][0] = p.x() ;
xyz[nnode][1] = p.y() ;
xyz[nnode][2] = p.z() ;
if ( i<n-1 && j<m-1 ) {
if ( i<n-1 && j<k-1 ) {
nface = GetFace(i,j,m,n,iside) ;
nface = GetFace(i,j,k,n,iside) ;
if (fHandedness < 0) { // lower side
faces[nface][0] = GetEdgeVisibility(i,j,m,n,0,1) * ( GetNode(i ,j ,m,n,iside)+1) ;
faces[nface][1] = GetEdgeVisibility(i,j,m,n,1,1) * ( GetNode(i+1,j ,m,n,iside)+1) ;
faces[nface][2] = GetEdgeVisibility(i,j,m,n,2,1) * ( GetNode(i+1,j+1,m,n,iside)+1) ;
faces[nface][3] = GetEdgeVisibility(i,j,m,n,3,1) * ( GetNode(i ,j+1,m,n,iside)+1) ;
faces[nface][0] = GetEdgeVisibility(i,j,k,n,0,1) * ( GetNode(i ,j ,k,n,iside)+1) ;
faces[nface][1] = GetEdgeVisibility(i,j,k,n,1,1) * ( GetNode(i+1,j ,k,n,iside)+1) ;
faces[nface][2] = GetEdgeVisibility(i,j,k,n,2,1) * ( GetNode(i+1,j+1,k,n,iside)+1) ;
faces[nface][3] = GetEdgeVisibility(i,j,k,n,3,1) * ( GetNode(i ,j+1,k,n,iside)+1) ;
} else { // upper side
faces[nface][0] = GetEdgeVisibility(i,j,m,n,0,-1) * ( GetNode(i ,j ,m,n,iside)+1) ;
faces[nface][1] = GetEdgeVisibility(i,j,m,n,1,-1) * ( GetNode(i ,j+1,m,n,iside)+1) ;
faces[nface][2] = GetEdgeVisibility(i,j,m,n,2,-1) * ( GetNode(i+1,j+1,m,n,iside)+1) ;
faces[nface][3] = GetEdgeVisibility(i,j,m,n,3,-1) * ( GetNode(i+1,j ,m,n,iside)+1) ;
faces[nface][0] = GetEdgeVisibility(i,j,k,n,0,-1) * ( GetNode(i ,j ,k,n,iside)+1) ;
faces[nface][1] = GetEdgeVisibility(i,j,k,n,1,-1) * ( GetNode(i ,j+1,k,n,iside)+1) ;
faces[nface][2] = GetEdgeVisibility(i,j,k,n,2,-1) * ( GetNode(i+1,j+1,k,n,iside)+1) ;
faces[nface][3] = GetEdgeVisibility(i,j,k,n,3,-1) * ( GetNode(i+1,j ,k,n,iside)+1) ;
}
}