[cig-commits] r20581 - in seismo/3D/SPECFEM3D/trunk/src: decompose_mesh_SCOTCH shared
dkomati1 at geodynamics.org
dkomati1 at geodynamics.org
Thu Aug 16 10:15:44 PDT 2012
Author: dkomati1
Date: 2012-08-16 10:15:43 -0700 (Thu, 16 Aug 2012)
New Revision: 20581
Modified:
seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/decompose_mesh_SCOTCH.f90
seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/part_decompose_mesh_SCOTCH.f90
seismo/3D/SPECFEM3D/trunk/src/shared/prepare_assemble_MPI.f90
Log:
changed ngnod or ngnode to NGNOD for clarity and to use the same convention as in all the other routines of the code
Modified: seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/decompose_mesh_SCOTCH.f90
===================================================================
--- seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/decompose_mesh_SCOTCH.f90 2012-08-16 17:07:05 UTC (rev 20580)
+++ seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/decompose_mesh_SCOTCH.f90 2012-08-16 17:15:43 UTC (rev 20581)
@@ -66,7 +66,7 @@
integer :: nb_edges
integer :: ispec, inode
- integer :: ngnod
+ integer :: NGNOD
integer :: max_neighbour ! Real maximum number of neighbours per element
integer :: sup_neighbour ! Majoration of the maximum number of neighbours per element
@@ -123,7 +123,7 @@
integer(long) :: nspec_long
! sets number of nodes per element
- ngnod = esize
+ NGNOD = esize
! reads node coordinates
open(unit=98, file=localpath_name(1:len_trim(localpath_name))//'/nodes_coords_file',&
@@ -661,12 +661,12 @@
nsize = maxval(used_nodes_elmnts(:))
! debug check size limit
- if( ngnod * nsize - (ngnod + (ngnod/2 - 1)*nfaces) > 2147483647 ) then
- print *,'size exceeds integer 4-byte limit: ',sup_neighbour,ngnod,nsize,nfaces
+ if( NGNOD * nsize - (NGNOD + (NGNOD/2 - 1)*nfaces) > 2147483647 ) then
+ print *,'size exceeds integer 4-byte limit: ',sup_neighbour,NGNOD,nsize,nfaces
print*,'bit size fortran: ',bit_size(sup_neighbour)
endif
- sup_neighbour = ngnod * nsize - (ngnod + (ngnod/2 - 1)*nfaces)
+ sup_neighbour = NGNOD * nsize - (NGNOD + (NGNOD/2 - 1)*nfaces)
print*, ' nsize = ',nsize, 'sup_neighbour = ', sup_neighbour
@@ -889,7 +889,7 @@
call write_partition_database(IIN_database, ipart, nspec_local, nspec, elmnts, &
glob2loc_elmnts, glob2loc_nodes_nparts, &
- glob2loc_nodes_parts, glob2loc_nodes, part, mat, ngnod, 1)
+ glob2loc_nodes_parts, glob2loc_nodes, part, mat, NGNOD, 1)
!debug
!print*, ipart,": nspec_local=",nspec_local, " nnodes_local=", nnodes_loc
@@ -911,7 +911,7 @@
write(IIN_database) nspec_local
call write_partition_database(IIN_database, ipart, nspec_local, nspec, elmnts, &
glob2loc_elmnts, glob2loc_nodes_nparts, &
- glob2loc_nodes_parts, glob2loc_nodes, part, mat, ngnod, 2)
+ glob2loc_nodes_parts, glob2loc_nodes, part, mat, NGNOD, 2)
! writes out absorbing/free-surface boundaries
call write_boundaries_database(IIN_database, ipart, nspec, nspec2D_xmin, nspec2D_xmax, nspec2D_ymin, &
Modified: seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/part_decompose_mesh_SCOTCH.f90
===================================================================
--- seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/part_decompose_mesh_SCOTCH.f90 2012-08-16 17:07:05 UTC (rev 20580)
+++ seismo/3D/SPECFEM3D/trunk/src/decompose_mesh_SCOTCH/part_decompose_mesh_SCOTCH.f90 2012-08-16 17:15:43 UTC (rev 20581)
@@ -960,7 +960,7 @@
subroutine write_partition_database(IIN_database, iproc, nspec_local, nspec, elmnts, &
glob2loc_elmnts, glob2loc_nodes_nparts, &
glob2loc_nodes_parts, glob2loc_nodes, &
- part, num_modele, ngnod, num_phase)
+ part, num_modele, NGNOD, num_phase)
! include './constants_decompose_mesh_SCOTCH.h'
@@ -975,10 +975,10 @@
integer, dimension(:), pointer :: glob2loc_nodes_nparts
integer, dimension(:), pointer :: glob2loc_nodes_parts
integer, dimension(:), pointer :: glob2loc_nodes
- integer, intent(in) :: ngnod
+ integer, intent(in) :: NGNOD
integer :: i,j,k
- integer, dimension(0:ngnod-1) :: loc_nodes
+ integer, dimension(0:NGNOD-1) :: loc_nodes
if ( num_phase == 1 ) then
! counts number of spectral elements in this partition
@@ -994,8 +994,8 @@
do i = 0, nspec-1
if ( part(i) == iproc ) then
- do j = 0, ngnod-1
- do k = glob2loc_nodes_nparts(elmnts(i*ngnod+j)), glob2loc_nodes_nparts(elmnts(i*ngnod+j)+1)-1
+ do j = 0, NGNOD-1
+ do k = glob2loc_nodes_nparts(elmnts(i*NGNOD+j)), glob2loc_nodes_nparts(elmnts(i*NGNOD+j)+1)-1
if ( glob2loc_nodes_parts(k) == iproc ) then
loc_nodes(j) = glob2loc_nodes(k)
@@ -1007,9 +1007,9 @@
! format:
! # ispec_local # material_index_1 # material_index_2 # corner_id1 # corner_id2 # ... # corner_id8
!write(IIN_database,*) glob2loc_elmnts(i)+1, num_modele(1,i+1), &
- ! num_modele(2,i+1),(loc_nodes(k)+1, k=0,ngnod-1)
+ ! num_modele(2,i+1),(loc_nodes(k)+1, k=0,NGNOD-1)
write(IIN_database) glob2loc_elmnts(i)+1, num_modele(1,i+1), &
- num_modele(2,i+1),(loc_nodes(k)+1, k=0,ngnod-1)
+ num_modele(2,i+1),(loc_nodes(k)+1, k=0,NGNOD-1)
end if
end do
end if
Modified: seismo/3D/SPECFEM3D/trunk/src/shared/prepare_assemble_MPI.f90
===================================================================
--- seismo/3D/SPECFEM3D/trunk/src/shared/prepare_assemble_MPI.f90 2012-08-16 17:07:05 UTC (rev 20580)
+++ seismo/3D/SPECFEM3D/trunk/src/shared/prepare_assemble_MPI.f90 2012-08-16 17:15:43 UTC (rev 20581)
@@ -26,7 +26,7 @@
subroutine prepare_assemble_MPI (nelmnts,knods, &
- ibool,npoin,ngnode, &
+ ibool,npoin,NGNOD, &
ninterface, max_interface_size, &
my_nelmnts_neighbours, my_interfaces, &
ibool_interfaces_asteroid, &
@@ -43,10 +43,10 @@
! spectral element indexing
! ( nelmnts = number of spectral elements
-! ngnode = number of element corners (8)
+! NGNOD = number of element corners (8)
! knods = corner indices array )
- integer, intent(in) :: nelmnts,ngnode
- integer, dimension(ngnode,nelmnts), intent(in) :: knods
+ integer, intent(in) :: nelmnts,NGNOD
+ integer, dimension(NGNOD,nelmnts), intent(in) :: knods
! global number of points
integer, intent(in) :: npoin
@@ -70,7 +70,7 @@
logical, dimension(:),allocatable :: mask_ibool_asteroid
integer :: ixmin, ixmax, iymin, iymax, izmin, izmax
- integer, dimension(ngnode) :: n
+ integer, dimension(NGNOD) :: n
integer :: e1, e2, e3, e4
integer :: ispec,k,ix,iy,iz,ier,itype,iglob
integer :: npoin_interface_asteroid
@@ -93,7 +93,7 @@
! type of interface: (1) corner point, (2) edge, (4) face
itype = my_interfaces(2,ispec_interface,num_interface)
! gets spectral element corner indices (defines all nodes of face/edge)
- do k = 1, ngnode
+ do k = 1, NGNOD
n(k) = knods(k,ispec)
end do
@@ -104,7 +104,7 @@
e4 = my_interfaces(6,ispec_interface,num_interface)
! gets i,j,k ranges for interface type
- call get_edge(ngnode, n, itype, e1, e2, e3, e4, &
+ call get_edge(NGNOD, n, itype, e1, e2, e3, e4, &
ixmin, ixmax, iymin, iymax, izmin, izmax)
! counts number and stores indices of (global) points on MPI interface
@@ -141,7 +141,7 @@
!----
!
-subroutine get_edge ( ngnode, n, itype, e1, e2, e3, e4, &
+subroutine get_edge ( NGNOD, n, itype, e1, e2, e3, e4, &
ixmin, ixmax, iymin, iymax, izmin, izmax )
! returns range of local (GLL) point indices i,j,k depending on given type
@@ -152,8 +152,8 @@
include "constants.h"
! corner node indices per spectral element (8)
- integer, intent(in) :: ngnode
- integer, dimension(ngnode), intent(in) :: n
+ integer, intent(in) :: NGNOD
+ integer, dimension(NGNOD), intent(in) :: n
! interface type & nodes
integer, intent(in) :: itype, e1, e2, e3, e4
More information about the CIG-COMMITS
mailing list