mirror of
https://github.com/TREX-CoE/qmckl.git
synced 2024-08-25 06:31:45 +02:00
Merge branch 'master' of github.com:TREX-CoE/qmckl
This commit is contained in:
commit
527b96e3df
47
configure.ac
47
configure.ac
@ -106,6 +106,52 @@ AC_CHECK_LIB([pthread], [pthread_create])
|
|||||||
# CFLAGS="${CFLAGS} ${OPENMP_CFLAGS}"
|
# CFLAGS="${CFLAGS} ${OPENMP_CFLAGS}"
|
||||||
#fi
|
#fi
|
||||||
|
|
||||||
|
# CHAMELEON
|
||||||
|
AC_ARG_WITH(chameleon,
|
||||||
|
AS_HELP_STRING([--without-chameleon],
|
||||||
|
[Do not use Chameleon. Default: auto-detect]), [
|
||||||
|
case "$with_chameleon" in
|
||||||
|
no)
|
||||||
|
: ;;
|
||||||
|
yes)
|
||||||
|
PKG_CHECK_MODULES([LIBCHAMELEON],[chameleon >= 1.0.0],
|
||||||
|
[PKG_CFLAGS="$PKG_CFLAGS $LIBCHAMELEON_CFLAGS"
|
||||||
|
PKG_LIBS="$PKG_LIBS $LIBCHAMELEON_LIBS"]
|
||||||
|
,[
|
||||||
|
|
||||||
|
## something went wrong.
|
||||||
|
## try to find the package without pkg-config
|
||||||
|
|
||||||
|
## check that the library is actually new enough.
|
||||||
|
## by testing for a 1.0.0+ function which we use
|
||||||
|
AC_CHECK_LIB(chameleon,CHAMELEON_finalize,[LIBCHAMELEON_LIBS="-lchameleon"])
|
||||||
|
])
|
||||||
|
AH_TEMPLATE(HAVE_CHAMELEON,[Chameleon support is available])
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
if test ! -d "$withval" ; then
|
||||||
|
AC_MSG_ERROR([--with-chameleon path does not point to a directory])
|
||||||
|
fi
|
||||||
|
LIBCHAMELEON_LIBS="-L$with_chameleon/lib -lchameleon -lchameleon_starpu -lhqr -lcoreblas"
|
||||||
|
LIBCHAMELEON_CFLAGS="-I$with_chameleon/include $CFLAGS"
|
||||||
|
LIBCHAMELEON_CPPFLAGS="-I$with_chameleon/include $CPPFLAGS"
|
||||||
|
esac
|
||||||
|
])
|
||||||
|
|
||||||
|
if test "x$LIBCHAMELEON_LIBS" != "x" ; then
|
||||||
|
LIBS="$LIBS $LIBCHAMELEON_LIBS"
|
||||||
|
CFLAGS="$CFLAGS $LIBCHAMELEON_CFLAGS"
|
||||||
|
CPPFLAGS="$CPPFLAGS $LIBCHAMELEON_CPPFLAGS"
|
||||||
|
AC_CHECK_HEADERS([chameleon.h], [], [AC_MSG_ERROR("chamelon.h not found")])
|
||||||
|
AC_DEFINE_UNQUOTED([HAVE_CHAMELEON],1,[CHAMELEON support is available])
|
||||||
|
fi
|
||||||
|
|
||||||
|
#AS_IF([test "x$with_chameleon" != "xno"], [
|
||||||
|
#])
|
||||||
|
|
||||||
|
AC_MSG_NOTICE([CHAMELEON library support: ${with_CHAMELEON:=auto} ${LIBCHAMELEON_PATH} ${LIBCHAMELEON_LIBS}])
|
||||||
|
|
||||||
|
|
||||||
# TREXIO
|
# TREXIO
|
||||||
|
|
||||||
AC_ARG_WITH(trexio, [AS_HELP_STRING([--without-trexio],[disable support for TREXIO])],
|
AC_ARG_WITH(trexio, [AS_HELP_STRING([--without-trexio],[disable support for TREXIO])],
|
||||||
@ -281,6 +327,7 @@ FC..............: ${FC}
|
|||||||
FCLAGS..........: ${FCFLAGS}
|
FCLAGS..........: ${FCFLAGS}
|
||||||
LDFLAGS:........: ${LDFLAGS}
|
LDFLAGS:........: ${LDFLAGS}
|
||||||
LIBS............: ${LIBS}
|
LIBS............: ${LIBS}
|
||||||
|
USE CHAMELEON...: ${with_chameleon}
|
||||||
|
|
||||||
Package features:
|
Package features:
|
||||||
${ARGS}
|
${ARGS}
|
||||||
|
@ -443,8 +443,7 @@ subroutine adjugate4(a,LDA,B,LDB,na,det_l)
|
|||||||
|
|
||||||
double precision :: C(4,4)
|
double precision :: C(4,4)
|
||||||
|
|
||||||
call cofactor4(A,LDA,B,4_8,na,det_l)
|
call cofactor4(A,LDA,C,4_8,na,det_l)
|
||||||
|
|
||||||
B(1,1) = C(1,1)
|
B(1,1) = C(1,1)
|
||||||
B(1,2) = C(2,1)
|
B(1,2) = C(2,1)
|
||||||
B(1,3) = C(3,1)
|
B(1,3) = C(3,1)
|
||||||
|
@ -1828,7 +1828,7 @@ integer function qmckl_compute_det_inv_matrix_alpha_f(context, &
|
|||||||
|
|
||||||
res = qmckl_adjugate(context, &
|
res = qmckl_adjugate(context, &
|
||||||
alpha_num, matA, LDA, &
|
alpha_num, matA, LDA, &
|
||||||
det_adj_matrix_alpha(1, 1, iwalk, idet), &
|
det_adj_matrix_alpha(1:alpha_num, 1:alpha_num, iwalk, idet), &
|
||||||
int(size(det_adj_matrix_alpha,1),8), &
|
int(size(det_adj_matrix_alpha,1),8), &
|
||||||
det_l)
|
det_l)
|
||||||
|
|
||||||
|
@ -438,34 +438,20 @@ integer function qmckl_compute_kinetic_energy_f(context, walk_num, &
|
|||||||
do idet = 1, det_num_alpha
|
do idet = 1, det_num_alpha
|
||||||
do iwalk = 1, walk_num
|
do iwalk = 1, walk_num
|
||||||
! Alpha part
|
! Alpha part
|
||||||
tmp_e = 0.0d0
|
|
||||||
do imo = 1, alpha_num
|
do imo = 1, alpha_num
|
||||||
do ielec = 1, alpha_num
|
do ielec = 1, alpha_num
|
||||||
mo_id = mo_index_alpha(imo, iwalk, idet)
|
mo_id = mo_index_alpha(imo, iwalk, idet)
|
||||||
e_kin(iwalk) = e_kin(iwalk) - 0.5d0 * det_inv_matrix_alpha(imo, ielec, iwalk, idet) * &
|
e_kin(iwalk) = e_kin(iwalk) - 0.5d0 * det_inv_matrix_alpha(imo, ielec, iwalk, idet) * &
|
||||||
mo_vgl(mo_id, ielec, 5)
|
mo_vgl(mo_id, ielec, 5)
|
||||||
!print *,"det alpha = ",det_inv_matrix_alpha(imo,ielec,iwalk,idet)
|
|
||||||
!print *,mo_vgl(mo_id,ielec,5)
|
|
||||||
!!print *," det val = ",det_value_alpha(iwalk,idet)
|
|
||||||
!tmp_e = tmp_e - 0.5d0 * det_inv_matrix_alpha(imo, ielec, iwalk, idet) * &
|
|
||||||
! mo_vgl(mo_id, ielec, 5)
|
|
||||||
end do
|
end do
|
||||||
!print *,"e_kin = ",tmp_e
|
|
||||||
end do
|
end do
|
||||||
! Beta part
|
! Beta part
|
||||||
tmp_e = 0.0d0
|
|
||||||
do imo = 1, beta_num
|
do imo = 1, beta_num
|
||||||
do ielec = 1, beta_num
|
do ielec = 1, beta_num
|
||||||
mo_id = mo_index_beta(imo, iwalk, idet)
|
mo_id = mo_index_beta(imo, iwalk, idet)
|
||||||
e_kin(iwalk) = e_kin(iwalk) - 0.5d0 * det_inv_matrix_beta(imo, ielec, iwalk, idet) * &
|
e_kin(iwalk) = e_kin(iwalk) - 0.5d0 * det_inv_matrix_beta(imo, ielec, iwalk, idet) * &
|
||||||
mo_vgl(mo_id, alpha_num + ielec, 5)
|
mo_vgl(mo_id, alpha_num + ielec, 5)
|
||||||
!print *,"det beta = ",det_inv_matrix_beta(imo,ielec,iwalk,idet)
|
|
||||||
!print *,mo_vgl(mo_id,alpha_num+ielec,5)
|
|
||||||
!!print *," det val = ",det_value_alpha(iwalk,idet)
|
|
||||||
!tmp_e = tmp_e - 0.5d0 * det_inv_matrix_beta(imo, ielec, iwalk, idet) * &
|
|
||||||
! mo_vgl(mo_id, alpha_num + ielec, 5)
|
|
||||||
end do
|
end do
|
||||||
!print *,"e_kin = ",tmp_e
|
|
||||||
end do
|
end do
|
||||||
end do
|
end do
|
||||||
end do
|
end do
|
||||||
|
Loading…
Reference in New Issue
Block a user