|
|
@ -421,7 +421,7 @@ contains
|
|
|
|
if (ix == 1) then
|
|
|
|
if (ix == 1) then
|
|
|
|
zt(k) = g(dzero,y,z)*(-val(icoeff)) + zt(k)
|
|
|
|
zt(k) = g(dzero,y,z)*(-val(icoeff)) + zt(k)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
icol(icoeff) = (ix-2)*idim*idim+(iy-1)*idim+(iz)
|
|
|
|
call ijk2idx(icol(icoeff),ix-1,iy,iz,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
@ -430,7 +430,7 @@ contains
|
|
|
|
if (iy == 1) then
|
|
|
|
if (iy == 1) then
|
|
|
|
zt(k) = g(x,dzero,z)*(-val(icoeff)) + zt(k)
|
|
|
|
zt(k) = g(x,dzero,z)*(-val(icoeff)) + zt(k)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
icol(icoeff) = (ix-1)*idim*idim+(iy-2)*idim+(iz)
|
|
|
|
call ijk2idx(icol(icoeff),ix,iy-1,iz,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
@ -439,7 +439,7 @@ contains
|
|
|
|
if (iz == 1) then
|
|
|
|
if (iz == 1) then
|
|
|
|
zt(k) = g(x,y,dzero)*(-val(icoeff)) + zt(k)
|
|
|
|
zt(k) = g(x,y,dzero)*(-val(icoeff)) + zt(k)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
icol(icoeff) = (ix-1)*idim*idim+(iy-1)*idim+(iz-1)
|
|
|
|
call ijk2idx(icol(icoeff),ix,iy,iz-1,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
@ -447,7 +447,7 @@ contains
|
|
|
|
! term depending on (x,y,z)
|
|
|
|
! term depending on (x,y,z)
|
|
|
|
val(icoeff)=(2*done)*(a1(x,y,z)+a2(x,y,z)+a3(x,y,z))/sqdeltah &
|
|
|
|
val(icoeff)=(2*done)*(a1(x,y,z)+a2(x,y,z)+a3(x,y,z))/sqdeltah &
|
|
|
|
& + c(x,y,z)
|
|
|
|
& + c(x,y,z)
|
|
|
|
icol(icoeff) = (ix-1)*idim*idim+(iy-1)*idim+(iz)
|
|
|
|
call ijk2idx(icol(icoeff),ix,iy,iz,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
! term depending on (x,y,z+1)
|
|
|
|
! term depending on (x,y,z+1)
|
|
|
@ -455,7 +455,7 @@ contains
|
|
|
|
if (iz == idim) then
|
|
|
|
if (iz == idim) then
|
|
|
|
zt(k) = g(x,y,done)*(-val(icoeff)) + zt(k)
|
|
|
|
zt(k) = g(x,y,done)*(-val(icoeff)) + zt(k)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
icol(icoeff) = (ix-1)*idim*idim+(iy-1)*idim+(iz+1)
|
|
|
|
call ijk2idx(icol(icoeff),ix,iy,iz+1,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
@ -464,7 +464,7 @@ contains
|
|
|
|
if (iy == idim) then
|
|
|
|
if (iy == idim) then
|
|
|
|
zt(k) = g(x,done,z)*(-val(icoeff)) + zt(k)
|
|
|
|
zt(k) = g(x,done,z)*(-val(icoeff)) + zt(k)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
icol(icoeff) = (ix-1)*idim*idim+(iy)*idim+(iz)
|
|
|
|
call ijk2idx(icol(icoeff),ix,iy+1,iz,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
@ -473,7 +473,7 @@ contains
|
|
|
|
if (ix==idim) then
|
|
|
|
if (ix==idim) then
|
|
|
|
zt(k) = g(done,y,z)*(-val(icoeff)) + zt(k)
|
|
|
|
zt(k) = g(done,y,z)*(-val(icoeff)) + zt(k)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
icol(icoeff) = (ix)*idim*idim+(iy-1)*idim+(iz)
|
|
|
|
call ijk2idx(icol(icoeff),ix+1,iy,iz,idim,idim,idim)
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
irow(icoeff) = glob_row
|
|
|
|
icoeff = icoeff+1
|
|
|
|
icoeff = icoeff+1
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|