Changed naming scheme for as_bld/ilu_bld/ilu0|k|t_fact.
stopcriterion
Salvatore Filippone 17 years ago
parent 72f98f8f3a
commit 1e3c3ab33b

@ -10,19 +10,19 @@ MODOBJS=mld_prec_type.o mld_prec_mod.o
MPFOBJS=mld_daggrmat_raw_asb.o mld_daggrmat_smth_asb.o \
mld_zaggrmat_raw_asb.o mld_zaggrmat_smth_asb.o
MPCOBJS=mld_slud_impl.o mld_zslud_impl.o
F90OBJS=mld_das_bld.o mld_dslu_bld.o mld_dumf_bld.o mld_dilu_fct.o\
F90OBJS=mld_das_bld.o mld_dslu_bld.o mld_dumf_bld.o mld_dilu0_fact.o\
mld_dmlprec_bld.o mld_dsp_renum.o mld_dbjac_bld.o mld_dilu_bld.o \
mld_dprecbld.o mld_dprecfree.o mld_dprecset.o mld_dprecinit.o\
mld_dbaseprec_bld.o mld_ddiag_bld.o mld_daggrmap_bld.o \
mld_dprec_aply.o mld_dmlprec_aply.o mld_dslud_bld.o\
mld_dbaseprec_aply.o mld_dbjac_aply.o mld_das_aply.o mld_daggrmat_asb.o \
mld_zas_bld.o mld_zslu_bld.o mld_zumf_bld.o mld_zilu_fct.o\
mld_zas_bld.o mld_zslu_bld.o mld_zumf_bld.o mld_zilu0_fact.o\
mld_zmlprec_bld.o mld_zsp_renum.o mld_zbjac_bld.o mld_zilu_bld.o \
mld_zprecbld.o mld_zprecfree.o mld_zprecset.o mld_zprecinit.o \
mld_zbaseprec_bld.o mld_zdiag_bld.o mld_zaggrmap_bld.o \
mld_zprec_aply.o mld_zmlprec_aply.o mld_zslud_bld.o\
mld_zbaseprec_aply.o mld_zbjac_aply.o mld_zas_aply.o mld_zaggrmat_asb.o\
mld_diluk_fct.o mld_ziluk_fct.o mld_dilut_fct.o mld_zilut_fct.o \
mld_diluk_fact.o mld_ziluk_fact.o mld_dilut_fact.o mld_zilut_fact.o \
$(MPFOBJS)
COBJS=mld_slu_impl.o mld_umf_impl.o mld_zslu_impl.o mld_zumf_impl.o
OBJS=$(F90OBJS) $(COBJS) $(MPFOBJS) $(MPCOBJS) $(MODOBJS)

@ -111,6 +111,49 @@ subroutine mld_das_bld(a,desc_a,p,upd,info)
select case (ptype)
case(mld_bjac_)
!
! Block Jacobi
!
data_ = psb_no_comm_
if (debug_level >= psb_debug_outer_) &
& write(debug_unit,*) me,' ',trim(name),&
& 'Calling desccpy'
if (upd == 'F') then
call psb_cdcpy(desc_a,p%desc_data,info)
If(debug_level >= psb_debug_outer_) &
& write(debug_unit,*) me,' ',trim(name),&
& ' done cdcpy'
if(info /= 0) then
info=4010
ch_err='psb_cdcpy'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
if (debug_level >= psb_debug_outer_) &
& write(debug_unit,*) me,' ',trim(name),&
& 'Early return: P>=3 N_OVR=0'
endif
call psb_sp_all(0,0,blck,1,info)
if(info /= 0) then
info=4010
ch_err='psb_sp_all'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
blck%fida = 'COO'
blck%infoa(psb_nnz_) = 0
call mld_bjac_bld(a,p,upd,info,blck=blck)
if (info /= 0) then
info=4010
ch_err='mld_bjac_bld'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
case(mld_as_)
!
! Additive Schwarz

@ -34,11 +34,11 @@
!!$ POSSIBILITY OF SUCH DAMAGE.
!!$
!!$
! File: mld_dilu_fct.f90
! File: mld_dilu0_fact.f90
!
! Subroutine: mld_dilu_fct
! Subroutine: mld_dilu0_fact
! Version: real
! Contains: mld_dilu_fctint, ilu_copyin
! Contains: mld_dilu0_factint, ilu_copyin
!
! This routine computes either the ILU(0) or the MILU(0) factorization of the
! local part of the matrix stored into a. These factorizations are used to
@ -97,10 +97,10 @@
! greater than 0. If the overlap is 0 or the matrix has been reordered
! (see mld_bjac_bld), then blck is empty.
!
subroutine mld_dilu_fct(ialg,a,l,u,d,info,blck)
subroutine mld_dilu0_fact(ialg,a,l,u,d,info,blck)
use psb_base_mod
use mld_prec_mod, mld_protect_name => mld_dilu_fct
use mld_prec_mod, mld_protect_name => mld_dilu0_fact
implicit none
@ -117,7 +117,7 @@ subroutine mld_dilu_fct(ialg,a,l,u,d,info,blck)
type(psb_dspmat_type), pointer :: blck_
character(len=20) :: name, ch_err
name='mld_dilu_fct'
name='mld_dilu0_fact'
info = 0
call psb_erractionsave(err_act)
@ -148,11 +148,11 @@ subroutine mld_dilu_fct(ialg,a,l,u,d,info,blck)
!
! Compute the ILU(0) or the MILU(0) factorization, depending on ialg
!
call mld_dilu_fctint(ialg,m,a%m,a,blck_%m,blck_,&
call mld_dilu0_factint(ialg,m,a%m,a,blck_%m,blck_,&
& d,l%aspk,l%ia1,l%ia2,u%aspk,u%ia1,u%ia2,l1,l2,info)
if(info.ne.0) then
info=4010
ch_err='mld_dilu_fctint'
ch_err='mld_dilu0_factint'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -201,9 +201,9 @@ subroutine mld_dilu_fct(ialg,a,l,u,d,info,blck)
contains
!
! Subroutine: mld_dilu_fctint
! Subroutine: mld_dilu0_factint
! Version: real
! Note: internal subroutine of mld_dilu_fct.
! Note: internal subroutine of mld_dilu0_fact.
!
! This routine computes either the ILU(0) or the MILU(0) factorization of the
! local part of the matrix stored into a. These factorizations are used to build
@ -274,7 +274,7 @@ contains
! info - integer, output.
! Error code.
!
subroutine mld_dilu_fctint(ialg,m,ma,a,mb,b,&
subroutine mld_dilu0_factint(ialg,m,ma,a,mb,b,&
& d,laspk,lia1,lia2,uaspk,uia1,uia2,l1,l2,info)
implicit none
@ -295,7 +295,7 @@ contains
integer :: int_err(5)
character(len=20) :: name, ch_err
name='mld_dilu_fctint'
name='mld_dilu0_factint'
if(psb_get_errstatus().ne.0) return
info=0
call psb_erractionsave(err_act)
@ -467,12 +467,12 @@ contains
return
end if
return
end subroutine mld_dilu_fctint
end subroutine mld_dilu0_factint
!
! Subroutine: ilu_copyin
! Version: real
! Note: internal subroutine of mld_dilu_fct
! Note: internal subroutine of mld_dilu0_fact
!
! This routine copies a row of a sparse matrix A, stored in the psb_dspmat_type
! data structure a, into the arrays laspk and uaspk and into the scalar variable
@ -486,7 +486,7 @@ contains
! copied into laspk, dia, uaspk row by row, through successive calls to
! ilu_copyin.
!
! The routine is used by mld_dilu_fctin in the computation of the ILU(0)/MILU(0)
! The routine is used by mld_dilu0_factin in the computation of the ILU(0)/MILU(0)
! factorization of a local sparse matrix.
!
! TODO: modify the routine to allow copying into output L and U that are
@ -514,7 +514,7 @@ contains
! Pointer to the last occupied entry of laspk.
! lia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the lower triangle
! copied in laspk row by row (see mld_dilu_fctint), according
! copied in laspk row by row (see mld_dilu0_factint), according
! to the CSR storage format.
! laspk - real(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
@ -525,7 +525,7 @@ contains
! Pointer to the last occupied entry of uaspk.
! uia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the upper triangle
! copied in uaspk row by row (see mld_dilu_fctint), according
! copied in uaspk row by row (see mld_dilu0_factint), according
! to the CSR storage format.
! uaspk - real(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
@ -642,4 +642,4 @@ contains
return
end subroutine ilu_copyin
end subroutine mld_dilu_fct
end subroutine mld_dilu0_fact

@ -57,7 +57,7 @@
! SIAM, 2003, Chapter 10.
!
! Note that that this routine handles the ILU(0) factorization separately,
! through mld_ilu_fct, for performance reasons.
! through mld_ilu0_fact, for performance reasons.
!
!
! Arguments:
@ -198,12 +198,12 @@ subroutine mld_dilu_bld(a,p,upd,info,blck)
case(0:)
! Fill-in >= 0
call mld_ilut_fct(p%iprcparm(mld_sub_fill_in_),p%dprcparm(mld_fact_thrs_),&
call mld_ilut_fact(p%iprcparm(mld_sub_fill_in_),p%dprcparm(mld_fact_thrs_),&
& a, p%av(mld_l_pr_),p%av(mld_u_pr_),p%d,info,blck=blck)
end select
if(info/=0) then
info=4010
ch_err='mld_ilut_fct'
ch_err='mld_ilut_fact'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -221,24 +221,24 @@ subroutine mld_dilu_bld(a,p,upd,info,blck)
! Fill-in 0
! Separate implementation of ILU(0) for better performance.
! There seems to be a problem with the separate implementation of MILU(0),
! contained into mld_ilu_fct. This must be investigated. For the time being,
! contained into mld_ilu0_fact. This must be investigated. For the time being,
! resort to the implementation of MILU(k) with k=0.
if (p%iprcparm(mld_sub_solve_) == mld_ilu_n_) then
call mld_ilu_fct(p%iprcparm(mld_sub_solve_),a,p%av(mld_l_pr_),p%av(mld_u_pr_),&
call mld_ilu0_fact(p%iprcparm(mld_sub_solve_),a,p%av(mld_l_pr_),p%av(mld_u_pr_),&
& p%d,info,blck=blck)
else
call mld_iluk_fct(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
call mld_iluk_fact(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
& a,p%av(mld_l_pr_),p%av(mld_u_pr_),p%d,info,blck=blck)
endif
case(1:)
! Fill-in >= 1
! The same routine implements both ILU(k) and MILU(k)
call mld_iluk_fct(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
call mld_iluk_fact(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
& a,p%av(mld_l_pr_),p%av(mld_u_pr_),p%d,info,blck=blck)
end select
if (info/=0) then
info=4010
ch_err='mld_iluk_fct'
ch_err='mld_iluk_fact'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if

@ -34,11 +34,11 @@
!!$ POSSIBILITY OF SUCH DAMAGE.
!!$
!!$
! File: mld_diluk_fct.f90
! File: mld_diluk_fact.f90
!
! Subroutine: mld_diluk_fct
! Subroutine: mld_diluk_fact
! Version: real
! Contains: mld_diluk_fctint, iluk_copyin, iluk_fact, iluk_copyout.
! Contains: mld_diluk_factint, iluk_copyin, iluk_fact, iluk_copyout.
!
! This routine computes either the ILU(k) or the MILU(k) factorization of the
! local part of the matrix stored into a. These factorizations are used to
@ -94,10 +94,10 @@
! greater than 0. If the overlap is 0 or the matrix has been reordered
! (see mld_bjac_bld), then blck does not contain any row.
!
subroutine mld_diluk_fct(fill_in,ialg,a,l,u,d,info,blck)
subroutine mld_diluk_fact(fill_in,ialg,a,l,u,d,info,blck)
use psb_base_mod
use mld_prec_mod, mld_protect_name => mld_diluk_fct
use mld_prec_mod, mld_protect_name => mld_diluk_fact
implicit none
@ -114,7 +114,7 @@ subroutine mld_diluk_fct(fill_in,ialg,a,l,u,d,info,blck)
type(psb_dspmat_type), pointer :: blck_
character(len=20) :: name, ch_err
name='mld_diluk_fct'
name='mld_diluk_fact'
info = 0
call psb_erractionsave(err_act)
@ -143,11 +143,11 @@ subroutine mld_diluk_fct(fill_in,ialg,a,l,u,d,info,blck)
!
! Compute the ILU(k) or the MILU(k) factorization, depending on ialg
!
call mld_diluk_fctint(fill_in,ialg,m,a,blck_,&
call mld_diluk_factint(fill_in,ialg,m,a,blck_,&
& d,l%aspk,l%ia1,l%ia2,u%aspk,u%ia1,u%ia2,l1,l2,info)
if (info /= 0) then
info=4010
ch_err='mld_diluk_fctint'
ch_err='mld_diluk_factint'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -196,9 +196,9 @@ subroutine mld_diluk_fct(fill_in,ialg,a,l,u,d,info,blck)
contains
!
! Subroutine: mld_diluk_fctint
! Subroutine: mld_diluk_factint
! Version: real
! Note: internal subroutine of mld_diluk_fct
! Note: internal subroutine of mld_diluk_fact
!
! This routine computes either the ILU(k) or the MILU(k) factorization of the
! local part of the matrix stored into a. These factorizations are used to build
@ -262,7 +262,7 @@ contains
! info - integer, output.
! Error code.
!
subroutine mld_diluk_fctint(fill_in,ialg,m,a,b,&
subroutine mld_diluk_factint(fill_in,ialg,m,a,b,&
& d,laspk,lia1,lia2,uaspk,uia1,uia2,l1,l2,info)
use psb_base_mod
@ -283,7 +283,7 @@ contains
real(kind(1.d0)), allocatable :: row(:)
type(psb_int_heap) :: heap
type(psb_dspmat_type) :: trw
character(len=20), parameter :: name='mld_diluk_fctint'
character(len=20), parameter :: name='mld_diluk_factint'
character(len=20) :: ch_err
if (psb_get_errstatus() /= 0) return
@ -413,19 +413,19 @@ contains
return
end if
return
end subroutine mld_diluk_fctint
end subroutine mld_diluk_factint
!
! Subroutine: iluk_copyin
! Version: real
! Note: internal subroutine of mld_diluk_fct
! Note: internal subroutine of mld_diluk_fact
!
! This routine copies a row of a sparse matrix A, stored in the sparse matrix
! structure a, into the array row and stores into a heap the column indices of
! the nonzero entries of the copied row. The output array row is such that it
! contains a full row of A, i.e. it contains also the zero entries of the row.
! This is useful for the elimination step performed by iluk_fact after the call
! to iluk_copyin (see mld_iluk_fctint).
! to iluk_copyin (see mld_iluk_factint).
! The routine also sets to zero the entries of the array rowlevs corresponding
! to the nonzero entries of the copied row (see the description of the arguments
! below).
@ -435,7 +435,7 @@ contains
! copied, row by row, into the array row, through successive calls to
! ilu_copyin.
!
! This routine is used by mld_diluk_fctint in the computation of the
! This routine is used by mld_diluk_factint in the computation of the
! ILU(k)/MILU(k) factorization of a local sparse matrix.
!
!
@ -454,7 +454,7 @@ contains
! The output matrix will contain a clipped copy taken from
! a(1:m,jmin:jmax).
! row - real(kind(1.d0)), dimension(:), input/output.
! In input it is the null vector (see mld_iluk_fctint and
! In input it is the null vector (see mld_iluk_factint and
! iluk_copyout). In output it contains the row extracted
! from the matrix A. It actually contains a full row, i.e.
! it contains also the zero entries of the row.
@ -570,13 +570,13 @@ contains
!
! Subroutine: iluk_fact
! Version: real
! Note: internal subroutine of mld_diluk_fct
! Note: internal subroutine of mld_diluk_fact
!
! This routine does an elimination step of the ILU(k) factorization on a
! single matrix row (see the calling routine mld_iluk_fctint).
! single matrix row (see the calling routine mld_iluk_factint).
!
! This step is also the base for a MILU(k) elimination step on the row (see
! iluk_copyout). This routine is used by mld_diluk_fctint in the computation
! iluk_copyout). This routine is used by mld_diluk_factint in the computation
! of the ILU(k)/MILU(k) factorization of a local sparse matrix.
!
! NOTE: it turns out we only need to keep track of the fill levels for
@ -612,12 +612,12 @@ contains
! uia1 - integer, dimension(:), input.
! The column indices of the nonzero entries of the part of the U
! factor above the current row, stored in uaspk row by row (see
! iluk_copyout, called by mld_diluk_fctint), according to the CSR
! iluk_copyout, called by mld_diluk_factint), according to the CSR
! storage format.
! uia2 - integer, dimension(:), input.
! The indices identifying the first nonzero entry of each row of
! the U factor above the current row, stored in uaspk row by row
! (see iluk_copyout, called by mld_diluk_fctint), according to
! (see iluk_copyout, called by mld_diluk_factint), according to
! the CSR storage format.
! uaspk - real(kind(1.d0)), dimension(:), input.
! The entries of the U factor above the current row (except the
@ -726,7 +726,7 @@ contains
!
! Subroutine: iluk_copyout
! Version: real
! Note: internal subroutine of mld_diluk_fct
! Note: internal subroutine of mld_diluk_fact
!
! This routine copies a matrix row, computed by iluk_fact by applying an
! elimination step of the ILU(k) factorization, into the arrays laspk, uaspk,
@ -742,10 +742,10 @@ contains
! row entries discarded because their fill levels are too high are added to
! the diagonal entry of the row;
! - the row entries are stored in laspk and uaspk according to the CSR format;
! - the arrays row and rowlevs are re-initialized for future use in mld_iluk_fct
! - the arrays row and rowlevs are re-initialized for future use in mld_iluk_fact
! (see also iluk_copyin and iluk_fact).
!
! This routine is used by mld_diluk_fctint in the computation of the
! This routine is used by mld_diluk_factint in the computation of the
! ILU(k)/MILU(k) factorization of a local sparse matrix.
!
!
@ -784,12 +784,12 @@ contains
! Pointer to the last occupied entry of uaspk.
! lia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the L factor,
! copied in laspk row by row (see mld_diluk_fctint), according
! copied in laspk row by row (see mld_diluk_factint), according
! to the CSR storage format.
! lia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
! of the L factor, copied in laspk row by row (see
! mld_diluk_fctint), according to the CSR storage format.
! mld_diluk_factint), according to the CSR storage format.
! laspk - real(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
! L factor are copied.
@ -798,7 +798,7 @@ contains
! row is copied (only d(i) is used by the routine).
! uia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the U factor
! copied in uaspk row by row (see mld_diluk_fctint), according
! copied in uaspk row by row (see mld_diluk_factint), according
! to the CSR storage format.
! uia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
@ -828,7 +828,7 @@ contains
! Local variables
integer :: j,isz,err_act,int_err(5),idxp
character(len=20), parameter :: name='mld_diluk_fctint'
character(len=20), parameter :: name='mld_diluk_factint'
character(len=20) :: ch_err
if (psb_get_errstatus() /= 0) return
@ -966,4 +966,4 @@ contains
end subroutine iluk_copyout
end subroutine mld_diluk_fct
end subroutine mld_diluk_fact

@ -34,11 +34,11 @@
!!$ POSSIBILITY OF SUCH DAMAGE.
!!$
!!$
! File: mld_dilut_fct.f90
! File: mld_dilut_fact.f90
!
! Subroutine: mld_dilut_fct
! Subroutine: mld_dilut_fact
! Version: real
! Contains: mld_dilut_fctint, ilut_copyin, ilut_fact, ilut_copyout
! Contains: mld_dilut_factint, ilut_copyin, ilut_fact, ilut_copyout
!
! This routine computes the ILU(k,t) factorization of the local part of the
! matrix stored into a. This factorization is used to build the 'base
@ -90,10 +90,10 @@
! greater than 0. If the overlap is 0 or the matrix has been reordered
! (see mld_bjac_bld), then blck does not contain any row.
!
subroutine mld_dilut_fct(fill_in,thres,a,l,u,d,info,blck)
subroutine mld_dilut_fact(fill_in,thres,a,l,u,d,info,blck)
use psb_base_mod
use mld_prec_mod, mld_protect_name => mld_dilut_fct
use mld_prec_mod, mld_protect_name => mld_dilut_fact
implicit none
@ -112,7 +112,7 @@ subroutine mld_dilut_fct(fill_in,thres,a,l,u,d,info,blck)
type(psb_dspmat_type), pointer :: blck_
character(len=20) :: name, ch_err
name='mld_dilut_fct'
name='mld_dilut_fact'
info = 0
call psb_erractionsave(err_act)
@ -146,11 +146,11 @@ subroutine mld_dilut_fct(fill_in,thres,a,l,u,d,info,blck)
!
! Compute the ILU(k,t) factorization
!
call mld_dilut_fctint(fill_in,thres,m,a,blck_,&
call mld_dilut_factint(fill_in,thres,m,a,blck_,&
& d,l%aspk,l%ia1,l%ia2,u%aspk,u%ia1,u%ia2,l1,l2,info)
if (info /= 0) then
info=4010
ch_err='mld_dilut_fctint'
ch_err='mld_dilut_factint'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -199,9 +199,9 @@ subroutine mld_dilut_fct(fill_in,thres,a,l,u,d,info,blck)
contains
!
! Subroutine: mld_dilut_fctint
! Subroutine: mld_dilut_factint
! Version: real
! Note: internal subroutine of mld_dilut_fct
! Note: internal subroutine of mld_dilut_fact
!
! This routine computes the ILU(k,t) factorization of the local part of the
! matrix stored into a. These factorization is used to build the 'base
@ -263,7 +263,7 @@ contains
! info - integer, output.
! Error code.
!
subroutine mld_dilut_fctint(fill_in,thres,m,a,b,&
subroutine mld_dilut_factint(fill_in,thres,m,a,b,&
& d,laspk,lia1,lia2,uaspk,uia1,uia2,l1,l2,info)
use psb_base_mod
@ -286,7 +286,7 @@ contains
real(kind(1.d0)), allocatable :: row(:)
type(psb_int_heap) :: heap
type(psb_dspmat_type) :: trw
character(len=20), parameter :: name='mld_dilut_fctint'
character(len=20), parameter :: name='mld_dilut_factint'
character(len=20) :: ch_err
if (psb_get_errstatus() /= 0) return
@ -394,12 +394,12 @@ contains
return
end if
return
end subroutine mld_dilut_fctint
end subroutine mld_dilut_factint
!
! Subroutine: ilut_copyin
! Version: real
! Note: internal subroutine of mld_dilut_fct
! Note: internal subroutine of mld_dilut_fact
!
! This routine performs the following tasks:
! - copying a row of a sparse matrix A, stored in the sparse matrix structure a,
@ -411,14 +411,14 @@ contains
! - computing the 2-norm of the row.
! The output array row is such that it contains a full row of A, i.e. it contains
! also the zero entries of the row. This is useful for the elimination step
! performed by ilut_fact after the call to ilut_copyin (see mld_ilut_fctint).
! performed by ilut_fact after the call to ilut_copyin (see mld_ilut_factint).
!
! If the sparse matrix is in CSR format, a 'straight' copy is performed;
! otherwise psb_sp_getblk is used to extract a block of rows, which is then
! copied, row by row, into the array row, through successive calls to
! ilut_copyin.
!
! This routine is used by mld_dilut_fctint in the computation of the ILU(k,t)
! This routine is used by mld_dilut_factint in the computation of the ILU(k,t)
! factorization of a local sparse matrix.
!
!
@ -452,7 +452,7 @@ contains
! nrmi - real(kind(1.d0)), output.
! The 2-norm of the current row.
! row - real(kind(1.d0)), dimension(:), input/output.
! In input it is the null vector (see mld_ilut_fctint and
! In input it is the null vector (see mld_ilut_factint and
! ilut_copyout). In output it contains the row extracted
! from the matrix A. It actually contains a full row, i.e.
! it contains also the zero entries of the row.
@ -491,7 +491,7 @@ contains
integer, parameter :: nrb=16
real(kind(1.d0)) :: dmaxup
real(kind(1.d0)), external :: dnrm2
character(len=20), parameter :: name='mld_dilut_fctint'
character(len=20), parameter :: name='mld_dilut_factint'
if (psb_get_errstatus() /= 0) return
info = 0
@ -609,14 +609,14 @@ contains
!
! Subroutine: ilut_fact
! Version: real
! Note: internal subroutine of mld_dilut_fct
! Note: internal subroutine of mld_dilut_fact
!
! This routine does an elimination step of the ILU(k,t) factorization on a single
! matrix row (see the calling routine mld_ilut_fctint). Actually, only the dropping
! matrix row (see the calling routine mld_ilut_factint). Actually, only the dropping
! rule based on the threshold is applied here. The dropping rule based on the
! fill-in is applied by ilut_copyout.
!
! The routine is used by mld_dilut_fctint in the computation of the ILU(k,t)
! The routine is used by mld_dilut_factint in the computation of the ILU(k,t)
! factorization of a local sparse matrix.
!
!
@ -645,12 +645,12 @@ contains
! uia1 - integer, dimension(:), input.
! The column indices of the nonzero entries of the part of the U
! factor above the current row, stored in uaspk row by row (see
! ilut_copyout, called by mld_dilut_fctint), according to the CSR
! ilut_copyout, called by mld_dilut_factint), according to the CSR
! storage format.
! uia2 - integer, dimension(:), input.
! The indices identifying the first nonzero entry of each row of
! the U factor above the current row, stored in uaspk row by row
! (see ilut_copyout, called by mld_dilut_fctint), according to
! (see ilut_copyout, called by mld_dilut_factint), according to
! the CSR storage format.
! uaspk - real(kind(1.d0)), dimension(:), input.
! The entries of the U factor above the current row (except the
@ -766,7 +766,7 @@ contains
!
! Subroutine: ilut_copyout
! Version: real
! Note: internal subroutine of mld_dilut_fct
! Note: internal subroutine of mld_dilut_fact
!
! This routine copies a matrix row, computed by ilut_fact by applying an
! elimination step of the ILU(k,t) factorization, into the arrays laspk,
@ -784,10 +784,10 @@ contains
! - the inverse of the diagonal entries of U is actually stored into d; this
! is then managed in the solve stage associated to the ILU(k,t) factorization;
! - the row entries are stored in laspk and uaspk according to the CSR format;
! - the array row is re-initialized for future use in mld_ilut_fct(see also
! - the array row is re-initialized for future use in mld_ilut_fact(see also
! ilut_copyin and ilut_fact).
!
! This routine is used by mld_dilut_fctint in the computation of the ILU(k,t)
! This routine is used by mld_dilut_factint in the computation of the ILU(k,t)
! factorization of a local sparse matrix.
!
!
@ -828,12 +828,12 @@ contains
! Pointer to the last occupied entry of uaspk.
! lia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the L factor,
! copied in laspk row by row (see mld_dilut_fctint), according
! copied in laspk row by row (see mld_dilut_factint), according
! to the CSR storage format.
! lia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
! of the L factor, copied in laspk row by row (see
! mld_dilut_fctint), according to the CSR storage format.
! mld_dilut_factint), according to the CSR storage format.
! laspk - real(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
! L factor are copied.
@ -842,7 +842,7 @@ contains
! row is copied (only d(i) is used by the routine).
! uia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the U factor
! copied in uaspk row by row (see mld_dilut_fctint), according
! copied in uaspk row by row (see mld_dilut_factint), according
! to the CSR storage format.
! uia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
@ -1154,4 +1154,4 @@ contains
end subroutine ilut_copyout
end subroutine mld_dilut_fct
end subroutine mld_dilut_fact

@ -490,8 +490,8 @@ module mld_prec_mod
end subroutine mld_zumf_bld
end interface
interface mld_ilu_fct
subroutine mld_dilu_fct(ialg,a,l,u,d,info,blck)
interface mld_ilu0_fact
subroutine mld_dilu0_fact(ialg,a,l,u,d,info,blck)
use psb_base_mod
integer, intent(in) :: ialg
integer, intent(out) :: info
@ -499,8 +499,8 @@ module mld_prec_mod
type(psb_dspmat_type),intent(inout) :: l,u
type(psb_dspmat_type),intent(in), optional, target :: blck
real(kind(1.d0)), intent(inout) :: d(:)
end subroutine mld_dilu_fct
subroutine mld_zilu_fct(ialg,a,l,u,d,info,blck)
end subroutine mld_dilu0_fact
subroutine mld_zilu0_fact(ialg,a,l,u,d,info,blck)
use psb_base_mod
integer, intent(in) :: ialg
integer, intent(out) :: info
@ -508,11 +508,11 @@ module mld_prec_mod
type(psb_zspmat_type),intent(inout) :: l,u
type(psb_zspmat_type),intent(in), optional, target :: blck
complex(kind(1.d0)), intent(inout) :: d(:)
end subroutine mld_zilu_fct
end subroutine mld_zilu0_fact
end interface
interface mld_iluk_fct
subroutine mld_diluk_fct(fill_in,ialg,a,l,u,d,info,blck)
interface mld_iluk_fact
subroutine mld_diluk_fact(fill_in,ialg,a,l,u,d,info,blck)
use psb_base_mod
integer, intent(in) :: fill_in,ialg
integer, intent(out) :: info
@ -520,8 +520,8 @@ module mld_prec_mod
type(psb_dspmat_type),intent(inout) :: l,u
type(psb_dspmat_type),intent(in), optional, target :: blck
real(kind(1.d0)), intent(inout) :: d(:)
end subroutine mld_diluk_fct
subroutine mld_ziluk_fct(fill_in,ialg,a,l,u,d,info,blck)
end subroutine mld_diluk_fact
subroutine mld_ziluk_fact(fill_in,ialg,a,l,u,d,info,blck)
use psb_base_mod
integer, intent(in) :: fill_in,ialg
integer, intent(out) :: info
@ -529,11 +529,11 @@ module mld_prec_mod
type(psb_zspmat_type),intent(inout) :: l,u
type(psb_zspmat_type),intent(in), optional, target :: blck
complex(kind(1.d0)), intent(inout) :: d(:)
end subroutine mld_ziluk_fct
end subroutine mld_ziluk_fact
end interface
interface mld_ilut_fct
subroutine mld_dilut_fct(fill_in,thres,a,l,u,d,info,blck)
interface mld_ilut_fact
subroutine mld_dilut_fact(fill_in,thres,a,l,u,d,info,blck)
use psb_base_mod
integer, intent(in) :: fill_in
real(kind(1.d0)), intent(in) :: thres
@ -542,8 +542,8 @@ module mld_prec_mod
type(psb_dspmat_type),intent(inout) :: l,u
type(psb_dspmat_type),intent(in), optional, target :: blck
real(kind(1.d0)), intent(inout) :: d(:)
end subroutine mld_dilut_fct
subroutine mld_zilut_fct(fill_in,thres,a,l,u,d,info,blck)
end subroutine mld_dilut_fact
subroutine mld_zilut_fact(fill_in,thres,a,l,u,d,info,blck)
use psb_base_mod
integer, intent(in) :: fill_in
real(kind(1.d0)), intent(in) :: thres
@ -552,7 +552,7 @@ module mld_prec_mod
type(psb_zspmat_type),intent(inout) :: l,u
type(psb_zspmat_type),intent(in), optional, target :: blck
complex(kind(1.d0)), intent(inout) :: d(:)
end subroutine mld_zilut_fct
end subroutine mld_zilut_fact
end interface
interface mld_asmat_bld

@ -112,6 +112,49 @@ subroutine mld_zas_bld(a,desc_a,p,upd,info)
select case (ptype)
case(mld_bjac_)
!
! Block Jacobi
!
data_ = psb_no_comm_
if (debug_level >= psb_debug_outer_) &
& write(debug_unit,*) me,' ',trim(name),&
& 'Calling desccpy'
if (upd == 'F') then
call psb_cdcpy(desc_a,p%desc_data,info)
If(debug_level >= psb_debug_outer_) &
& write(debug_unit,*) me,' ',trim(name),&
& ' done cdcpy'
if(info /= 0) then
info=4010
ch_err='psb_cdcpy'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
if (debug_level >= psb_debug_outer_) &
& write(debug_unit,*) me,' ',trim(name),&
& 'Early return: P>=3 N_OVR=0'
endif
call psb_sp_all(0,0,blck,1,info)
if(info /= 0) then
info=4010
ch_err='psb_sp_all'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
blck%fida = 'COO'
blck%infoa(psb_nnz_) = 0
call mld_bjac_bld(a,p,upd,info,blck=blck)
if (info /= 0) then
info=4010
ch_err='mld_bjac_bld'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
case(mld_as_)
!
! Additive Schwarz

@ -34,11 +34,11 @@
!!$ POSSIBILITY OF SUCH DAMAGE.
!!$
!!$
! File: mld_dilu_fct.f90
! File: mld_dilu0_fact.f90
!
! Subroutine: mld_zilu_fct
! Subroutine: mld_zilu0_fact
! Version: complex
! Contains: mld_zilu_fctint, ilu_copyin
! Contains: mld_zilu0_factint, ilu_copyin
!
! This routine computes either the ILU(0) or the MILU(0) factorization of the
! local part of the matrix stored into a. These factorizations are used to
@ -97,10 +97,10 @@
! greater than 0. If the overlap is 0 or the matrix has been reordered
! (see mld_bjac_bld), then blck is empty.
!
subroutine mld_zilu_fct(ialg,a,l,u,d,info,blck)
subroutine mld_zilu0_fact(ialg,a,l,u,d,info,blck)
use psb_base_mod
use mld_prec_mod, mld_protect_name => mld_zilu_fct
use mld_prec_mod, mld_protect_name => mld_zilu0_fact
implicit none
! Arguments
@ -116,7 +116,7 @@ subroutine mld_zilu_fct(ialg,a,l,u,d,info,blck)
type(psb_zspmat_type), pointer :: blck_
character(len=20) :: name, ch_err
name='mld_zilu_fct'
name='mld_zilu0_fact'
info = 0
call psb_erractionsave(err_act)
@ -147,11 +147,11 @@ subroutine mld_zilu_fct(ialg,a,l,u,d,info,blck)
!
! Compute the ILU(0) or the MILU(0) factorization, depending on ialg
!
call mld_zilu_fctint(ialg,m,a%m,a,blck_%m,blck_,&
call mld_zilu0_factint(ialg,m,a%m,a,blck_%m,blck_,&
& d,l%aspk,l%ia1,l%ia2,u%aspk,u%ia1,u%ia2,l1,l2,info)
if(info.ne.0) then
info=4010
ch_err='mld_zilu_fctint'
ch_err='mld_zilu0_factint'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -200,9 +200,9 @@ subroutine mld_zilu_fct(ialg,a,l,u,d,info,blck)
contains
!
! Subroutine: mld_zilu_fctint
! Subroutine: mld_zilu0_factint
! Version: complex
! Note: internal subroutine of mld_zilu_fct
! Note: internal subroutine of mld_zilu0_fact
!
! This routine computes either the ILU(0) or the MILU(0) factorization of the
! local part of the matrix stored into a. These factorizations are used to build
@ -272,7 +272,7 @@ contains
! info - integer, output.
! Error code.
!
subroutine mld_zilu_fctint(ialg,m,ma,a,mb,b,&
subroutine mld_zilu0_factint(ialg,m,ma,a,mb,b,&
& d,laspk,lia1,lia2,uaspk,uia1,uia2,l1,l2,info)
implicit none
@ -293,7 +293,7 @@ contains
integer :: int_err(5)
character(len=20) :: name, ch_err
name='mld_zilu_fctint'
name='mld_zilu0_factint'
if(psb_get_errstatus().ne.0) return
info=0
call psb_erractionsave(err_act)
@ -465,12 +465,12 @@ contains
return
end if
return
end subroutine mld_zilu_fctint
end subroutine mld_zilu0_factint
!
! Subroutine: ilu_copyin
! Version: complex
! Note: internal subroutine of mld_zilu_fct
! Note: internal subroutine of mld_zilu0_fact
!
! This routine copies a row of a sparse matrix A, stored in the psb_dspmat_type
! data structure a, into the arrays laspk and uaspk and into the scalar variable
@ -484,7 +484,7 @@ contains
! copied into laspk, dia, uaspk row by row, through successive calls to
! ilu_copyin.
!
! The routine is used by mld_zilu_fctin in the computation of the ILU(0)/MILU(0)
! The routine is used by mld_zilu0_factin in the computation of the ILU(0)/MILU(0)
! factorization of a local sparse matrix.
!
! TODO: modify the routine to allow copying into output L and U that are
@ -512,7 +512,7 @@ contains
! Pointer to the last occupied entry of laspk.
! lia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the lower triangle
! copied in laspk row by row (see mld_zilu_fctint), according
! copied in laspk row by row (see mld_zilu0_factint), according
! to the CSR storage format.
! laspk - complex(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
@ -523,7 +523,7 @@ contains
! Pointer to the last occupied entry of uaspk.
! uia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the upper triangle
! copied in uaspk row by row (see mld_zilu_fctint), according
! copied in uaspk row by row (see mld_zilu0_factint), according
! to the CSR storage format.
! uaspk - complex(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
@ -640,4 +640,4 @@ contains
return
end subroutine ilu_copyin
end subroutine mld_zilu_fct
end subroutine mld_zilu0_fact

@ -57,7 +57,7 @@
! SIAM, 2003, Chapter 10.
!
! Note that that this routine handles the ILU(0) factorization separately,
! through mld_ilu_fct, for performance reasons.
! through mld_ilu0_fact, for performance reasons.
!
!
! Arguments:
@ -198,12 +198,12 @@ subroutine mld_zilu_bld(a,p,upd,info,blck)
case(0:)
! Fill-in >= 0
call mld_ilut_fct(p%iprcparm(mld_sub_fill_in_),p%dprcparm(mld_fact_thrs_),&
call mld_ilut_fact(p%iprcparm(mld_sub_fill_in_),p%dprcparm(mld_fact_thrs_),&
& a, p%av(mld_l_pr_),p%av(mld_u_pr_),p%d,info,blck=blck)
end select
if(info/=0) then
info=4010
ch_err='mld_ilut_fct'
ch_err='mld_ilut_fact'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -221,24 +221,24 @@ subroutine mld_zilu_bld(a,p,upd,info,blck)
! Fill-in 0
! Separate implementation of ILU(0) for better performance.
! There seems to be a problem with the separate implementation of MILU(0),
! contained into mld_ilu_fct. This must be investigated. For the time being,
! contained into mld_ilu0_fact. This must be investigated. For the time being,
! resort to the implementation of MILU(k) with k=0.
if (p%iprcparm(mld_sub_solve_) == mld_ilu_n_) then
call mld_ilu_fct(p%iprcparm(mld_sub_solve_),a,p%av(mld_l_pr_),p%av(mld_u_pr_),&
call mld_ilu0_fact(p%iprcparm(mld_sub_solve_),a,p%av(mld_l_pr_),p%av(mld_u_pr_),&
& p%d,info,blck=blck)
else
call mld_iluk_fct(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
call mld_iluk_fact(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
& a,p%av(mld_l_pr_),p%av(mld_u_pr_),p%d,info,blck=blck)
endif
case(1:)
! Fill-in >= 1
! The same routine implements both ILU(k) and MILU(k)
call mld_iluk_fct(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
call mld_iluk_fact(p%iprcparm(mld_sub_fill_in_),p%iprcparm(mld_sub_solve_),&
& a,p%av(mld_l_pr_),p%av(mld_u_pr_),p%d,info,blck=blck)
end select
if (info/=0) then
info=4010
ch_err='mld_iluk_fct'
ch_err='mld_iluk_fact'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if

@ -34,11 +34,11 @@
!!$ POSSIBILITY OF SUCH DAMAGE.
!!$
!!$
! File: mld_ziluk_fct.f90
! File: mld_ziluk_fact.f90
!
! Subroutine: mld_ziluk_fct
! Subroutine: mld_ziluk_fact
! Version: complex
! Contains: mld_ziluk_fctint, iluk_copyin, iluk_fact, iluk_copyout
! Contains: mld_ziluk_factint, iluk_copyin, iluk_fact, iluk_copyout
!
! This routine computes either the ILU(k) or the MILU(k) factorization of the
! local part of the matrix stored into a. These factorizations are used to
@ -93,10 +93,10 @@
! greater than 0. If the overlap is 0 or the matrix has been reordered
! (see mld_bjac_bld), then blck does not contain any row.
!
subroutine mld_ziluk_fct(fill_in,ialg,a,l,u,d,info,blck)
subroutine mld_ziluk_fact(fill_in,ialg,a,l,u,d,info,blck)
use psb_base_mod
use mld_prec_mod, mld_protect_name => mld_ziluk_fct
use mld_prec_mod, mld_protect_name => mld_ziluk_fact
implicit none
! Arguments
@ -112,7 +112,7 @@ subroutine mld_ziluk_fct(fill_in,ialg,a,l,u,d,info,blck)
type(psb_zspmat_type), pointer :: blck_
character(len=20) :: name, ch_err
name='mld_ziluk_fct'
name='mld_ziluk_fact'
info = 0
call psb_erractionsave(err_act)
@ -141,11 +141,11 @@ subroutine mld_ziluk_fct(fill_in,ialg,a,l,u,d,info,blck)
!
! Compute the ILU(k) or the MILU(k) factorization, depending on ialg
!
call mld_ziluk_fctint(fill_in,ialg,m,a,blck_,&
call mld_ziluk_factint(fill_in,ialg,m,a,blck_,&
& d,l%aspk,l%ia1,l%ia2,u%aspk,u%ia1,u%ia2,l1,l2,info)
if (info /= 0) then
info=4010
ch_err='mld_ziluk_fctint'
ch_err='mld_ziluk_factint'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -194,9 +194,9 @@ subroutine mld_ziluk_fct(fill_in,ialg,a,l,u,d,info,blck)
contains
!
! Subroutine: mld_ziluk_fctint
! Subroutine: mld_ziluk_factint
! Version: complex
! Note: internal subroutine of mld_ziluk_fct
! Note: internal subroutine of mld_ziluk_fact
!
! This routine computes either the ILU(k) or the MILU(k) factorization of the
! local part of the matrix stored into a. These factorizations are used to build
@ -260,7 +260,7 @@ contains
! info - integer, output.
! Error code.
!
subroutine mld_ziluk_fctint(fill_in,ialg,m,a,b,&
subroutine mld_ziluk_factint(fill_in,ialg,m,a,b,&
& d,laspk,lia1,lia2,uaspk,uia1,uia2,l1,l2,info)
use psb_base_mod
@ -282,7 +282,7 @@ contains
type(psb_int_heap) :: heap
logical,parameter :: debug=.false.
type(psb_zspmat_type) :: trw
character(len=20), parameter :: name='mld_ziluk_fctint'
character(len=20), parameter :: name='mld_ziluk_factint'
character(len=20) :: ch_err
if (psb_get_errstatus() /= 0) return
@ -412,19 +412,19 @@ contains
return
end if
return
end subroutine mld_ziluk_fctint
end subroutine mld_ziluk_factint
!
! Subroutine: iluk_copyin
! Version: complex
! Note: internal subroutine of mld_ziluk_fct
! Note: internal subroutine of mld_ziluk_fact
!
! This routine copies a row of a sparse matrix A, stored in the sparse matrix
! structure a, into the array row and stores into a heap the column indices of
! the nonzero entries of the copied row. The output array row is such that it
! contains a full row of A, i.e. it contains also the zero entries of the row.
! This is useful for the elimination step performed by iluk_fact after the call
! to iluk_copyin (see mld_iluk_fctint).
! to iluk_copyin (see mld_iluk_factint).
! The routine also sets to zero the entries of the array rowlevs corresponding
! to the nonzero entries of the copied row (see the description of the arguments
! below).
@ -434,7 +434,7 @@ contains
! copied, row by row, into the array row, through successive calls to
! ilu_copyin.
!
! This routine is used by mld_ziluk_fctint in the computation of the
! This routine is used by mld_ziluk_factint in the computation of the
! ILU(k)/MILU(k) factorization of a local sparse matrix.
!
!
@ -453,7 +453,7 @@ contains
! The output matrix will contain a clipped copy taken from
! a(1:m,jmin:jmax).
! row - complex(kind(1.d0)), dimension(:), input/output.
! In input it is the null vector (see mld_iluk_fctint and
! In input it is the null vector (see mld_iluk_factint and
! iluk_copyout). In output it contains the row extracted
! from the matrix A. It actually contains a full row, i.e.
! it contains also the zero entries of the row.
@ -569,13 +569,13 @@ contains
!
! Subroutine: iluk_fact
! Version: complex
! Note: internal subroutine of mld_ziluk_fct
! Note: internal subroutine of mld_ziluk_fact
!
! This routine does an elimination step of the ILU(k) factorization on a
! single matrix row (see the calling routine mld_iluk_fctint).
! single matrix row (see the calling routine mld_iluk_factint).
!
! This step is also the base for a MILU(k) elimination step on the row (see
! iluk_copyout). This routine is used by mld_ziluk_fctint in the computation
! iluk_copyout). This routine is used by mld_ziluk_factint in the computation
! of the ILU(k)/MILU(k) factorization of a local sparse matrix.
!
! NOTE: it turns out we only need to keep track of the fill levels for
@ -611,12 +611,12 @@ contains
! uia1 - integer, dimension(:), input.
! The column indices of the nonzero entries of the part of the U
! factor above the current row, stored in uaspk row by row (see
! iluk_copyout, called by mld_ziluk_fctint), according to the CSR
! iluk_copyout, called by mld_ziluk_factint), according to the CSR
! storage format.
! uia2 - integer, dimension(:), input.
! The indices identifying the first nonzero entry of each row of
! the U factor above the current row, stored in uaspk row by row
! (see iluk_copyout, called by mld_ziluk_fctint), according to
! (see iluk_copyout, called by mld_ziluk_factint), according to
! the CSR storage format.
! uaspk - complex(kind(1.d0)), dimension(:), input.
! The entries of the U factor above the current row (except the
@ -724,7 +724,7 @@ contains
!
! Subroutine: iluk_copyout
! Version: complex
! Note: internal subroutine of mld_ziluk_fct
! Note: internal subroutine of mld_ziluk_fact
!
! This routine copies a matrix row, computed by iluk_fact by applying an
! elimination step of the ILU(k) factorization, into the arrays laspk, uaspk,
@ -740,10 +740,10 @@ contains
! row entries discarded because their fill levels are too high are added to
! the diagonal entry of the row;
! - the row entries are stored in laspk and uaspk according to the CSR format;
! - the arrays row and rowlevs are re-initialized for future use in mld_iluk_fct
! - the arrays row and rowlevs are re-initialized for future use in mld_iluk_fact
! (see also iluk_copyin and iluk_fact).
!
! This routine is used by mld_ziluk_fctint in the computation of the
! This routine is used by mld_ziluk_factint in the computation of the
! ILU(k)/MILU(k) factorization of a local sparse matrix.
!
!
@ -782,12 +782,12 @@ contains
! Pointer to the last occupied entry of uaspk.
! lia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the L factor,
! copied in laspk row by row (see mld_ziluk_fctint), according
! copied in laspk row by row (see mld_ziluk_factint), according
! to the CSR storage format.
! lia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
! of the L factor, copied in laspk row by row (see
! mld_ziluk_fctint), according to the CSR storage format.
! mld_ziluk_factint), according to the CSR storage format.
! laspk - complex(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
! L factor are copied.
@ -796,7 +796,7 @@ contains
! row is copied (only d(i) is used by the routine).
! uia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the U factor
! copied in uaspk row by row (see mld_ziluk_fctint), according
! copied in uaspk row by row (see mld_ziluk_factint), according
! to the CSR storage format.
! uia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
@ -826,7 +826,7 @@ contains
! Local variables
integer :: j,isz,err_act,int_err(5),idxp
character(len=20), parameter :: name='mld_ziluk_fctint'
character(len=20), parameter :: name='mld_ziluk_factint'
character(len=20) :: ch_err
if (psb_get_errstatus() /= 0) return
@ -964,4 +964,4 @@ contains
end subroutine iluk_copyout
end subroutine mld_ziluk_fct
end subroutine mld_ziluk_fact

@ -34,11 +34,11 @@
!!$ POSSIBILITY OF SUCH DAMAGE.
!!$
!!$
! File: mld_zilut_fct.f90
! File: mld_zilut_fact.f90
!
! Subroutine: mld_zilut_fct
! Subroutine: mld_zilut_fact
! Version: real
! Contains: mld_zilut_fctint, ilut_copyin, ilut_fact, ilut_copyout
! Contains: mld_zilut_factint, ilut_copyin, ilut_fact, ilut_copyout
!
! This routine computes the ILU(k,t) factorization of the local part of the
! matrix stored into a. This factorization is used to build the 'base
@ -90,10 +90,10 @@
! greater than 0. If the overlap is 0 or the matrix has been reordered
! (see mld_bjac_bld), then blck does not contain any row.
!
subroutine mld_zilut_fct(fill_in,thres,a,l,u,d,info,blck)
subroutine mld_zilut_fact(fill_in,thres,a,l,u,d,info,blck)
use psb_base_mod
use mld_prec_mod, mld_protect_name => mld_zilut_fct
use mld_prec_mod, mld_protect_name => mld_zilut_fact
implicit none
! Arguments
@ -111,7 +111,7 @@ subroutine mld_zilut_fct(fill_in,thres,a,l,u,d,info,blck)
type(psb_zspmat_type), pointer :: blck_
character(len=20) :: name, ch_err
name='mld_zilut_fct'
name='mld_zilut_fact'
info = 0
call psb_erractionsave(err_act)
@ -145,11 +145,11 @@ subroutine mld_zilut_fct(fill_in,thres,a,l,u,d,info,blck)
!
! Compute the ILU(k,t) factorization
!
call mld_zilut_fctint(fill_in,thres,m,a,blck_,&
call mld_zilut_factint(fill_in,thres,m,a,blck_,&
& d,l%aspk,l%ia1,l%ia2,u%aspk,u%ia1,u%ia2,l1,l2,info)
if (info /= 0) then
info=4010
ch_err='mld_zilut_fctint'
ch_err='mld_zilut_factint'
call psb_errpush(info,name,a_err=ch_err)
goto 9999
end if
@ -198,9 +198,9 @@ subroutine mld_zilut_fct(fill_in,thres,a,l,u,d,info,blck)
contains
!
! Subroutine: mld_zilut_fctint
! Subroutine: mld_zilut_factint
! Version: real
! Note: internal subroutine of mld_zilut_fct
! Note: internal subroutine of mld_zilut_fact
!
! This routine computes the ILU(k,t) factorization of the local part of the
! matrix stored into a. These factorization is used to build the 'base
@ -262,7 +262,7 @@ contains
! info - integer, output.
! Error code.
!
subroutine mld_zilut_fctint(fill_in,thres,m,a,b,&
subroutine mld_zilut_factint(fill_in,thres,m,a,b,&
& d,laspk,lia1,lia2,uaspk,uia1,uia2,l1,l2,info)
use psb_base_mod
@ -285,7 +285,7 @@ contains
complex(kind(1.d0)), allocatable :: row(:)
type(psb_int_heap) :: heap
type(psb_zspmat_type) :: trw
character(len=20), parameter :: name='mld_zilut_fctint'
character(len=20), parameter :: name='mld_zilut_factint'
if (psb_get_errstatus() /= 0) return
info = 0
@ -392,12 +392,12 @@ contains
return
end if
return
end subroutine mld_zilut_fctint
end subroutine mld_zilut_factint
!
! Subroutine: ilut_copyin
! Version: complex
! Note: internal subroutine of mld_zilut_fct
! Note: internal subroutine of mld_zilut_fact
!
! This routine performs the following tasks:
! - copying a row of a sparse matrix A, stored in the sparse matrix structure a,
@ -409,14 +409,14 @@ contains
! - computing the 2-norm of the row.
! The output array row is such that it contains a full row of A, i.e. it contains
! also the zero entries of the row. This is useful for the elimination step
! performed by ilut_fact after the call to ilut_copyin (see mld_ilut_fctint).
! performed by ilut_fact after the call to ilut_copyin (see mld_ilut_factint).
!
! If the sparse matrix is in CSR format, a 'straight' copy is performed;
! otherwise psb_sp_getblk is used to extract a block of rows, which is then
! copied, row by row, into the array row, through successive calls to
! ilut_copyin.
!
! This routine is used by mld_zilut_fctint in the computation of the ILU(k,t)
! This routine is used by mld_zilut_factint in the computation of the ILU(k,t)
! factorization of a local sparse matrix.
!
!
@ -450,7 +450,7 @@ contains
! nrmi - real(kind(1.d0)), output.
! The 2-norm of the current row.
! row - complex(kind(1.d0)), dimension(:), input/output.
! In input it is the null vector (see mld_ilut_fctint and
! In input it is the null vector (see mld_ilut_factint and
! ilut_copyout). In output it contains the row extracted
! from the matrix A. It actually contains a full row, i.e.
! it contains also the zero entries of the row.
@ -490,7 +490,7 @@ contains
integer, parameter :: nrb=16
real(kind(1.d0)) :: dmaxup
real(kind(1.d0)), external :: dznrm2
character(len=20), parameter :: name='mld_zilut_fctint'
character(len=20), parameter :: name='mld_zilut_factint'
if (psb_get_errstatus() /= 0) return
info = 0
@ -608,14 +608,14 @@ contains
!
! Subroutine: ilut_fact
! Version: complex
! Note: internal subroutine of mld_zilut_fct
! Note: internal subroutine of mld_zilut_fact
!
! This routine does an elimination step of the ILU(k,t) factorization on a single
! matrix row (see the calling routine mld_ilut_fctint). Actually, only the dropping
! matrix row (see the calling routine mld_ilut_factint). Actually, only the dropping
! rule based on the threshold is applied here. The dropping rule based on the
! fill-in is applied by ilut_copyout.
!
! The routine is used by mld_zilut_fctint in the computation of the ILU(k,t)
! The routine is used by mld_zilut_factint in the computation of the ILU(k,t)
! factorization of a local sparse matrix.
!
!
@ -644,12 +644,12 @@ contains
! uia1 - integer, dimension(:), input.
! The column indices of the nonzero entries of the part of the U
! factor above the current row, stored in uaspk row by row (see
! ilut_copyout, called by mld_zilut_fctint), according to the CSR
! ilut_copyout, called by mld_zilut_factint), according to the CSR
! storage format.
! uia2 - integer, dimension(:), input.
! The indices identifying the first nonzero entry of each row of
! the U factor above the current row, stored in uaspk row by row
! (see ilut_copyout, called by mld_zilut_fctint), according to
! (see ilut_copyout, called by mld_zilut_factint), according to
! the CSR storage format.
! uaspk - complex(kind(1.d0)), dimension(:), input.
! The entries of the U factor above the current row (except the
@ -764,7 +764,7 @@ contains
!
! Subroutine: ilut_copyout
! Version: complex
! Note: internal subroutine of mld_zilut_fct
! Note: internal subroutine of mld_zilut_fact
!
! This routine copies a matrix row, computed by ilut_fact by applying an
! elimination step of the ILU(k,t) factorization, into the arrays laspk,
@ -782,10 +782,10 @@ contains
! - the inverse of the diagonal entries of U is actually stored into d; this
! is then managed in the solve stage associated to the ILU(k,t) factorization;
! - the row entries are stored in laspk and uaspk according to the CSR format;
! - the array row is re-initialized for future use in mld_ilut_fct(see also
! - the array row is re-initialized for future use in mld_ilut_fact(see also
! ilut_copyin and ilut_fact).
!
! This routine is used by mld_zilut_fctint in the computation of the ILU(k,t)
! This routine is used by mld_zilut_factint in the computation of the ILU(k,t)
! factorization of a local sparse matrix.
!
!
@ -826,12 +826,12 @@ contains
! Pointer to the last occupied entry of uaspk.
! lia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the L factor,
! copied in laspk row by row (see mld_zilut_fctint), according
! copied in laspk row by row (see mld_zilut_factint), according
! to the CSR storage format.
! lia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
! of the L factor, copied in laspk row by row (see
! mld_zilut_fctint), according to the CSR storage format.
! mld_zilut_factint), according to the CSR storage format.
! laspk - complex(kind(1.d0)), dimension(:), input/output.
! The array where the entries of the row corresponding to the
! L factor are copied.
@ -840,7 +840,7 @@ contains
! row is copied (only d(i) is used by the routine).
! uia1 - integer, dimension(:), input/output.
! The column indices of the nonzero entries of the U factor
! copied in uaspk row by row (see mld_zilut_fctint), according
! copied in uaspk row by row (see mld_zilut_factint), according
! to the CSR storage format.
! uia2 - integer, dimension(:), input/output.
! The indices identifying the first nonzero entry of each row
@ -1152,4 +1152,4 @@ contains
end subroutine ilut_copyout
end subroutine mld_zilut_fct
end subroutine mld_zilut_fact
Loading…
Cancel
Save