aboutsummaryrefslogtreecommitdiff
path: root/src/EHFinder_Init.F90
diff options
context:
space:
mode:
authordiener <diener@2a26948c-0e4f-0410-aee8-f1d3e353619c>2002-09-18 17:00:29 +0000
committerdiener <diener@2a26948c-0e4f-0410-aee8-f1d3e353619c>2002-09-18 17:00:29 +0000
commit26b15c6673c77ca751ef5f58451077b25398b179 (patch)
tree63bfdc3a850d9d40b0859a7cb0ed030f74aacc13 /src/EHFinder_Init.F90
parent77f5a1b8207a8ed1dee33c012dabec320f96372c (diff)
Removed a lot of commented code.
Added code to obtain reduction handles. git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinAnalysis/EHFinder/trunk@50 2a26948c-0e4f-0410-aee8-f1d3e353619c
Diffstat (limited to 'src/EHFinder_Init.F90')
-rw-r--r--src/EHFinder_Init.F9076
1 files changed, 9 insertions, 67 deletions
diff --git a/src/EHFinder_Init.F90 b/src/EHFinder_Init.F90
index 2e4ebad..df6cbc4 100644
--- a/src/EHFinder_Init.F90
+++ b/src/EHFinder_Init.F90
@@ -15,7 +15,6 @@ subroutine EHFinder_Init(CCTK_ARGUMENTS)
DECLARE_CCTK_ARGUMENTS
DECLARE_CCTK_FUNCTIONS
-! CCTK_INT, dimension(0:63) :: eh_check
CCTK_INT :: i, j, k
CCTK_REAL :: last_time
@@ -29,9 +28,6 @@ subroutine EHFinder_Init(CCTK_ARGUMENTS)
if ( CCTK_EQUALS( initial_f, 'sphere' ) ) then
f = sqrt(x**2+y**2+z**2) - initial_rad ! + &
-! 0.5d0 * sin ( 5d0 * ( sqrt(x**2+y**2+z**2) - initial_rad ) )
-! f = x**2+y**2+z**2 - initial_rad**2
-! f = sqrt(x**2+y**2+z**2)**3 - initial_rad**3
end if
if ( CCTK_EQUALS( initial_f, 'ellipsoid' ) ) then
f = sqrt(x**2/initial_a**2+y**2/initial_b**2+z**2/initial_c**2) - 1.0
@@ -52,68 +48,14 @@ subroutine EHFinder_Init(CCTK_ARGUMENTS)
ngy = cctk_nghostzones(2)
ngz = cctk_nghostzones(3)
-! where ( f .lt. -shell_width*delta )
-! eh_mask = -1
-! f = 0
-! end where
-!
-! if ( cctk_bbox(1) .eq. 1 ) then
-! where ( eh_mask(1,:,:) .ge. 0 ) eh_mask(1,:,:) = eh_mask(1,:,:) + ixl
-! end if
-! if ( cctk_bbox(2) .eq. 1 ) then
-! where ( eh_mask(nx,:,:) .ge. 0 ) eh_mask(nx,:,:) = eh_mask(nx,:,:) + ixr
-! end if
-! if ( cctk_bbox(3) .eq. 1 ) then
-! where ( eh_mask(:,1,:) .ge. 0 ) eh_mask(:,1,:) = eh_mask(:,1,:) + iyl
-! end if
-! if ( cctk_bbox(4) .eq. 1 ) then
-! where ( eh_mask(:,ny,:) .ge. 0 ) eh_mask(:,ny,:) = eh_mask(:,ny,:) + iyr
-! end if
-! if ( cctk_bbox(5) .eq. 1 ) then
-! where ( eh_mask(:,:,1) .ge. 0 ) eh_mask(:,:,1) = eh_mask(:,:,1) + izl
-! end if
-! if ( cctk_bbox(6) .eq. 1 ) then
-! where ( eh_mask(:,:,nz) .ge. 0 ) eh_mask(:,:,nz) = eh_mask(:,:,nz) + izr
-! end if
-!
-! where ( eh_mask(2:nx-1,2:ny-1,2:nz-1) .ge. 0 )
-! where ( eh_mask(1:nx-2,2:ny-1,2:nz-1) .lt. 0 )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + ixl
-! end where
-! where ( eh_mask(3:nx,2:ny-1,2:nz-1) .lt. 0 )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + ixr
-! end where
-! where ( eh_mask(2:nx-1,1:ny-2,2:nz-1) .lt. 0 )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + iyl
-! end where
-! where ( eh_mask(2:nx-1,3:ny,2:nz-1) .lt. 0 )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + iyr
-! end where
-! where ( eh_mask(2:nx-1,2:ny-1,1:nz-2) .lt. 0 )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + izl
-! end where
-! where ( eh_mask(2:nx-1,2:ny-1,3:nz) .lt. 0 )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + izr
-! end where
-! end where
-!
-! where ( ( eh_mask(2:nx-1,2:ny-1,2:nz-1) .ge. 0 ) .and. &
-! ( eh_mask(3:nx,2:ny-1,2:nz-1) .lt. 0 ) )
-! eh_mask(2:nx-1,2:ny-1,2:nz-1) = eh_mask(2:nx-1,2:ny-1,2:nz-1) + ixr
-! end where
-!
-! eh_check = 0
-! do k=1,nz
-! do j=1,ny
-! do i=1,nx
-! eh_check(eh_mask(i,j,k)) = eh_check(eh_mask(i,j,k)) + 1
-! end do
-! end do
-! end do
-!
-! do i=0,63
-! print*,i,eh_check(i)
-! end do
-
+ call CCTK_ReductionArrayHandle ( max_handle, 'maximum' )
+ if ( max_handle .lt. 0 ) then
+ call CCTK_WARN(0,'Could not obtain a handle for maximum reduction')
+ end if
+ call CCTK_ReductionArrayHandle ( min_handle, 'minimum' )
+ if ( min_handle .lt. 0 ) then
+ call CCTK_WARN(0,'Could not obtain a handle for minimum reduction')
+ end if
+
return
end subroutine EHFinder_Init