diff --git a/README.md b/README.md index 217ff776..8a43f486 100644 --- a/README.md +++ b/README.md @@ -138,6 +138,8 @@ Optional: size: The size information. (by default is one) Example : 1, =sum(ao_num); (ao_num,3) + ATTENTION : The module and the value are separed by a "." not a "_". + For exemple (determinants.n_det) ezfio_name: The name for the EZFIO lib (by default is ) ezfio_dir: Will be the folder of EZFIO. diff --git a/configure b/configure index b810f600..6ecd08ec 100755 --- a/configure +++ b/configure @@ -158,7 +158,7 @@ def check_output(*popenargs, **kwargs): >>> check_output(['/usr/bin/python', '--version']) Python 2.6.2 """ - process = subprocess.Popen(stdout=subprocess.PIPE, *popenargs, **kwargs) + process = subprocess.Popen(stdout=subprocess.PIPE,stderr=subprocess.PIPE, *popenargs, **kwargs) output, unused_err = process.communicate() retcode = process.poll() if retcode: @@ -190,7 +190,7 @@ def checking(d_dependency): def check_availability(binary): """ - If avalabie return the path who can can't find the + If avalable return the path who can find the binary else return 0 """ @@ -198,7 +198,19 @@ def checking(d_dependency): check_python() try: - return check_output(["which", binary]) + a = check_output(["which", binary]) + + if binary == "irpf90": + version = check_output("bash irpf90 -v".split()) + + from distutils.version import LooseVersion + if LooseVersion(version) < LooseVersion("1.6.7"): + return 0 + else: + return a + + return a + except subprocess.CalledProcessError: default_path = d_info[binary].default_path if os.path.exists(default_path): @@ -208,7 +220,7 @@ def checking(d_dependency): def get_list_descendant(d_dependency, l_installed, l_needed): """ - Descendant – a node reachable by repeated proceeding from parent to child. + Descendant : a node reachable by repeated proceeding from parent to child. """ d_need_genealogy = dict() @@ -265,7 +277,7 @@ def installation(l_install_descendant): def create_rule_ninja(): l_rules = [ - "rule download", " command = wget ${url} -O ${out} -o /dev/null", + "rule download", " command = wget --no-check-certificate ${url} -O ${out} -o /dev/null", " description = Downloading ${descr}", "" ] @@ -423,8 +435,8 @@ def create_ninja_and_rc(l_installed): 'export IRPF90={0}'.format(find_path("irpf90", l_installed)), 'export NINJA={0}'.format(find_path("ninja", l_installed)), 'export QP_PYTHON={0}'.format(":".join(l_python)), "", - 'export PYTHONPATH="${PYTHONPATH}":"${QP_PYTHON}"', - 'export PATH="${PATH}":"${QP_PYTHON}":"${QP_ROOT}"/bin:"${QP_ROOT}"/ocaml', + 'export PYTHONPATH="${QP_PYTHON}":"${PYTHONPATH}"', + 'export PATH="${QP_PYTHON}":"${QP_ROOT}"/bin:"${QP_ROOT}"/ocaml:"${PATH}"', 'export LD_LIBRARY_PATH="${QP_ROOT}"/lib:"${LD_LIBRARY_PATH}"', 'export LIBRARY_PATH="${QP_ROOT}"/lib:"${LIBRARY_PATH}"', "" 'source ${HOME}/.opam/opam-init/init.sh > /dev/null 2> /dev/null || true', diff --git a/install/scripts/check_irp_version.sh b/install/scripts/check_irp_version.sh new file mode 100755 index 00000000..245a15d9 --- /dev/null +++ b/install/scripts/check_irp_version.sh @@ -0,0 +1,25 @@ +#!/bin/bash +# This script should be included + +# pro: +# +# solid way to compare fancy version strings: +# support any length of sub-parts (ie: 1.3alpha.2.dev2 > 1.1 ?) +# support alpha-betical sort (ie: 1.alpha < 1.beta2) +# support big size version (ie: 1.10003939209329320932 > 1.2039209378273789273 ?) +# can easily be modified to support n arguments. (leaved as an exercise ;) ) +# usually very usefull with 3 arguments: (ie: 1.2 < my_version < 2.7 ) +# cons: +# +# uses a lot of various calls to different programs. So it's not that efficient. +# uses a pretty recent version of sort and it might not be available on your system. (check with man sort) + +function version_gt() { test "$(echo "$@" | tr " " "\n" | sort -V | tail -n 1)" == "$1"; } + +irp_cur_version=`irpf90 -v` +irp_need_version=1.6.7 + +if version_gt $irp_cur_version $irp_need_version; then + echo "OK" +fi +echo "FAIL" \ No newline at end of file diff --git a/scripts/compilation/cache_compile.py b/scripts/compilation/cache_compile.py index 77e799b8..37f9b14b 100755 --- a/scripts/compilation/cache_compile.py +++ b/scripts/compilation/cache_compile.py @@ -18,9 +18,8 @@ p = re.compile(ur'-I IRPF90_temp/\S*\s+') mod = re.compile(ur'module\s+(?P\S+).+end\s?module\s+(?P=mod)?', re.MULTILINE | re.IGNORECASE) -tmpdir_root = os.environ.get("TMPDIR",failobj="/dev/shm") -TMPDIR = os.path.join(tmpdir_root,os.environ["USER"],"qp_compiler") - +tmpdir_root = os.environ.get("TMPDIR", failobj="/dev/shm") +TMPDIR = os.path.join(tmpdir_root, os.environ["USER"], "qp_compiler") def return_filename_to_cache(command): diff --git a/scripts/compilation/qp_create_ninja.py b/scripts/compilation/qp_create_ninja.py index 5b99e38d..9c54afe2 100755 --- a/scripts/compilation/qp_create_ninja.py +++ b/scripts/compilation/qp_create_ninja.py @@ -711,7 +711,7 @@ def create_build_ninja_module(path_module): f.write("\n".join(l_string)) -def create_build_ninja_global(): +def create_build_ninja_global(l_module): l_string = ["rule update_build_ninja_root", " command = {0} update".format(__file__), @@ -723,7 +723,7 @@ def create_build_ninja_global(): ""] l_string += ["rule make_clean", - " command = cd {0} ; clean_modules.sh *".format(QP_SRC), + " command = module_handler.py clean {0}".format(" ".join([m.rel for m in l_module])), " description = Cleaning all modules", ""] l_string += ["build dummy_target: update_build_ninja_root", @@ -832,7 +832,7 @@ if __name__ == "__main__": d_binaries = get_dict_binaries(l_module, mode="development") l_module = d_binaries.keys() - create_build_ninja_global() + create_build_ninja_global(l_module) for module_to_compile in l_module: diff --git a/scripts/ezfio_interface/ei_handler.py b/scripts/ezfio_interface/ei_handler.py index c92ac572..855758c6 100755 --- a/scripts/ezfio_interface/ei_handler.py +++ b/scripts/ezfio_interface/ei_handler.py @@ -44,6 +44,8 @@ Optional: size: The size information. (by default is one) Example : 1, =sum(ao_num); (ao_num,3) + ATTENTION : The module and the value are separed by a "." not a "_". + For exemple (determinants.n_det) ezfio_name: The name for the EZFIO lib (by default is ) ezfio_dir: Will be the folder of EZFIO. @@ -228,6 +230,8 @@ def get_dict_config_file(module_obj): # pvd = provider pvd = section.lower() + d[pvd]["module"] = module_obj + # Create the dictionary who containt the value per default d_default = {"ezfio_name": pvd, "ezfio_dir": module_obj.lower, @@ -255,7 +259,7 @@ def get_dict_config_file(module_obj): sys.exit(1) try: - interface = map(str.lower, config_file.get(section, "interface").split(",")) + interface = [i.lower().strip() for i in config_file.get(section, "interface").split(",")] except ConfigParser.NoOptionError: error("doc", pvd, module_obj.path) sys.exit(1) @@ -317,7 +321,7 @@ def create_ezfio_provider(dict_ezfio_cfg): ez_p.set_doc(dict_info['doc']) ez_p.set_ezfio_dir(dict_info['ezfio_dir']) ez_p.set_ezfio_name(dict_info['ezfio_name']) - ez_p.set_output("output_%s" % dict_info['ezfio_dir']) + ez_p.set_output("output_%s" % dict_info['module'].lower) # (nuclei.nucl_num,pseudo.klocmax) => (nucl_num,klocmax) ez_p.set_size(re.sub(r'\w+\.', "", dict_info['size'])) diff --git a/scripts/module/module_handler.py b/scripts/module/module_handler.py index d0bcca00..ddaf976d 100755 --- a/scripts/module/module_handler.py +++ b/scripts/module/module_handler.py @@ -1,13 +1,12 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- """ -Create the NEEDED_MODULE - aka the genealogy (children module, subchildren module and so on), -of a NEEDED_CHILDREN_MODULES file +Module utilitary Usage: - module_handler.py print_descendant [] - module_handler.py create_png [] + module_handler.py print_descendant [...] + module_handler.py create_png [...] + module_handler.py clean [...] Options: print_descendant Print the genealogy of the NEEDED_CHILDREN_MODULES @@ -19,16 +18,22 @@ Options: import os import sys import os.path -from collections import namedtuple try: from docopt import docopt + from qp_path import QP_SRC except ImportError: print "source .quantum_package.rc" raise # Canot cache for namedtuple are not hashable +def is_module(path_module): + return os.path.isfile(os.path.join(QP_SRC, + path_module, + "NEEDED_CHILDREN_MODULES")) + + def get_dict_child(l_root_abs=None): """Loop over MODULE in QP_ROOT/src, open all the NEEDED_CHILDREN_MODULES and create a dict[MODULE] = [sub module needed, ...] @@ -36,8 +41,7 @@ def get_dict_child(l_root_abs=None): d_ref = dict() if not l_root_abs: - qp_root = os.environ['QP_ROOT'] - l_root_abs = [os.path.join(qp_root, 'src')] + l_root_abs = [QP_SRC] for root_abs in l_root_abs: for module_rel in os.listdir(root_abs): @@ -201,19 +205,48 @@ if __name__ == '__main__': arguments = docopt(__doc__) - if not arguments['']: + if not arguments['']: dir_ = os.getcwd() + l_module = [os.path.basename(dir_)] else: - path_file = os.path.abspath(arguments['']) - path_file = os.path.expanduser(path_file) - path_file = os.path.expandvars(path_file) - dir_ = os.path.dirname(path_file) + l_module = arguments[''] + + for module in l_module: + if not is_module(module): + print "{0} is not a volide module. Abort".format(module) + print "No NEEDED_CHILDREN_MODULES in it" + sys.exit(1) - path_file = os.path.basename(dir_) m = ModuleHandler() if arguments['print_descendant']: - print " ".join(sorted(m.l_module)) + + for module in l_module: + print " ".join(sorted(m.l_descendant_unique([module]))) if arguments["create_png"]: - m.create_png([path_file]) + m.create_png(l_module) + + if arguments["clean"]: + for module in l_module: + module_abs = os.path.realpath(os.path.join(QP_SRC, module)) + + import shutil + + for f in ['IRPF90_temp', 'IRPF90_man']: + try: + shutil.rmtree(os.path.join(module_abs, f)) + except: + pass + + for symlink in m.l_descendant_unique([module]): + try: + os.unlink(os.path.join(module_abs,symlink)) + except: + pass + + for f in ["irpf90_entities", "tags", "irpf90.make", "Makefile"]: + try: + os.remove(os.path.join(module_abs,f)) + except: + pass diff --git a/scripts/module/qp_install_module.py b/scripts/module/qp_install_module.py index 03460052..a4f6e176 100755 --- a/scripts/module/qp_install_module.py +++ b/scripts/module/qp_install_module.py @@ -5,8 +5,8 @@ Usage: qp_install_module.py create -n [...] qp_install_module.py download -n [...] qp_install_module.py install ... - qp_install_module.py list (--installed|--avalaible-local|--avalaible-remote) - qp_install_module.py uninstall ... + qp_install_module.py list (--installed|--avalaible-local) + qp_install_module.py uninstall ... [--and_ancestor] Options: @@ -22,6 +22,8 @@ try: from module_handler import ModuleHandler, get_dict_child from module_handler import get_l_module_descendant from update_README import Doc_key, Needed_key + from qp_path import QP_ROOT, QP_SRC, QP_PLUGINS + except ImportError: print "source .quantum_package.rc" raise @@ -59,15 +61,13 @@ def save_new_module(path, l_child): if __name__ == '__main__': arguments = docopt(__doc__) - qp_root_src = os.path.join(os.environ['QP_ROOT'], "src") - qp_root_plugin = os.path.join(os.environ['QP_ROOT'], "plugins") if arguments["list"]: if arguments["--installed"]: - l_repository = [qp_root_src] - if arguments["--avalaible-local"]: - l_repository = [qp_root_plugin] + l_repository = [QP_SRC] + elif arguments["--avalaible-local"]: + l_repository = [QP_PLUGINS] m_instance = ModuleHandler(l_repository) @@ -75,11 +75,11 @@ if __name__ == '__main__': print "* {0}".format(module) elif arguments["create"]: - m_instance = ModuleHandler([qp_root_src]) + m_instance = ModuleHandler([QP_SRC]) l_children = arguments[""] - path = os.path.join(qp_root_src, arguments[""]) + path = os.path.join(QP_SRC, arguments[""]) print "You will create the module:" print path @@ -88,6 +88,7 @@ if __name__ == '__main__': if children not in m_instance.dict_descendant: print "This module ({0}) is not a valide module.".format(children) print "Run `list` flag for the list of module avalaible" + print "Maybe you need to install some module first" print "Aborting..." sys.exit(1) @@ -104,7 +105,7 @@ if __name__ == '__main__': elif arguments["download"]: pass -# d_local = get_dict_child([qp_root_src]) +# d_local = get_dict_child([QP_SRC]) # d_remote = get_dict_child(arguments[""]) # # d_child = d_local.copy() @@ -119,8 +120,8 @@ if __name__ == '__main__': elif arguments["install"]: - d_local = get_dict_child([qp_root_src]) - d_plugin = get_dict_child([qp_root_plugin]) + d_local = get_dict_child([QP_SRC]) + d_plugin = get_dict_child([QP_PLUGINS]) d_child = d_local.copy() d_child.update(d_plugin) @@ -143,31 +144,43 @@ if __name__ == '__main__': print "Installation...", for module_to_cp in l_module_to_cp: - src = os.path.join(qp_root_plugin, module_to_cp) - des = os.path.join(qp_root_src, module_to_cp) + src = os.path.join(QP_PLUGINS, module_to_cp) + des = os.path.join(QP_SRC, module_to_cp) try: os.symlink(src, des) except OSError: - print "Your src directory is broken. Please remove %s"%des + print "Your src directory is broken. Please remove %s" % des raise print "Done" print "You can now compile as usual" elif arguments["uninstall"]: - d_local = get_dict_child([qp_root_src]) + m_instance = ModuleHandler([QP_SRC]) + d_descendant = m_instance.dict_descendant + + d_local = get_dict_child([QP_SRC]) l_name = arguments[""] - l_failed = [ name for name in l_name if name not in d_local ] + l_failed = [name for name in l_name if name not in d_local] if l_failed: print "Modules not installed:" for name in sorted(l_failed): - print "* %s"%name + print "* %s" % name sys.exit(1) else: + if arguments["--and_ancestor"]: + + l_name_to_remove = l_name + [module for module in m_instance.l_module for name in l_name if name in d_descendant[module]] + print "You will remove all of:" + print l_name_to_remove + + else: + l_name_to_remove = l_name + def unlink(x): try: - os.unlink(os.path.join(qp_root_src,x)) + os.unlink(os.path.join(QP_SRC, x)) except OSError: - print "%s is a core module which can not be renmoved"%x - map(unlink,l_name) + print "%s is a core module which can not be renmoved" % x + map(unlink, l_name_to_remove) diff --git a/scripts/utility/qp_path.py b/scripts/utility/qp_path.py index 39058557..f997ec21 100644 --- a/scripts/utility/qp_path.py +++ b/scripts/utility/qp_path.py @@ -11,5 +11,6 @@ except: sys.exit(1) else: QP_SRC = os.path.join(QP_ROOT, "src") + QP_PLUGINS = os.path.join(QP_ROOT, "plugins") QP_EZFIO = os.path.join(QP_ROOT, "install", "EZFIO") QP_OCAML = os.path.join(QP_ROOT, "ocaml") diff --git a/src/Determinants/EZFIO.cfg b/src/Determinants/EZFIO.cfg index a124f030..c0c94f5a 100644 --- a/src/Determinants/EZFIO.cfg +++ b/src/Determinants/EZFIO.cfg @@ -55,58 +55,58 @@ default: 0.999 [n_states_diag] type: integer doc: n_states_diag -interface: ezfio, provider +interface: ezfio,provider [n_int] -interface: ezfio, provider +interface: ezfio doc: n_int type: N_int_number [bit_kind] -interface: ezfio, provider +interface: ezfio doc: bit_kind type: Bit_kind [mo_label] -interface: ezfio, provider +interface: ezfio,provider doc: o_label type: character*(64) [n_det] -interface: ezfio, provider +interface: ezfio doc: n_det type: integer [psi_coef] -interface: ezfio, provider +interface: ezfio doc: psi_coef type: double precision size: (determinants.n_det,determinants.n_states) [psi_det] -interface: ezfio, provider +interface: ezfio doc: psi_det type: integer*8 size: (determinants.n_int*determinants.bit_kind/8,2,determinants.n_det) [det_num] -interface: ezfio, provider +interface: ezfio,provider doc: det_num type: integer [det_occ] -interface: ezfio, provider +interface: ezfio,provider doc: det_occ type: integer size: (electrons.elec_alpha_num,determinants.det_num,2) [det_coef] -interface: ezfio, provider +interface: ezfio,provider doc: det_coef type: double precision size: (determinants.det_num) [expected_s2] -interface: ezfio, provider +interface: ezfio,provider doc: expcted_s2 type: double precision diff --git a/src/Determinants/README.rst b/src/Determinants/README.rst index f0497d7f..44ab99d7 100644 --- a/src/Determinants/README.rst +++ b/src/Determinants/README.rst @@ -205,10 +205,22 @@ Documentation degree : Degree of excitation +`det_coef `_ + det_coef + + `det_connections `_ Build connection proxy between determinants +`det_num `_ + det_num + + +`det_occ `_ + det_occ + + `det_search_key `_ Return an integer*8 corresponding to a determinant index for searching @@ -480,6 +492,10 @@ Documentation Maximum degree of excitation in the wf +`mo_label `_ + o_label + + `mono_elec_ref_bitmask_energy `_ Energy of the reference bitmask used in Slater rules @@ -505,15 +521,15 @@ Documentation determinants. idx_cas gives the indice of the CAS determinant in psi_det. -`n_det_max `_ +`n_det_max `_ Max number of determinants in the wave function -`n_det_max_jacobi `_ +`n_det_max_jacobi `_ Maximum number of determinants diagonalized by Jacobi -`n_det_max_property `_ +`n_det_max_property `_ Max number of determinants in the wave function when you select for a given property @@ -537,7 +553,7 @@ Documentation Number of single excitation bitmasks -`n_states `_ +`n_states `_ Number of states to consider @@ -585,7 +601,7 @@ Documentation rho(alpha) - rho(beta) -`only_single_double_dm `_ +`only_single_double_dm `_ If true, The One body DM is calculated with ignoring the Double<->Doubles extra diag elements @@ -762,7 +778,7 @@ Documentation Reads the determinants from the EZFIO file -`read_wf `_ +`read_wf `_ If true, read the wave function from the EZFIO file @@ -787,7 +803,7 @@ Documentation Undocumented -`s2_eig `_ +`s2_eig `_ Force the wave function to be an eigenfunction of S^2 @@ -862,7 +878,7 @@ Documentation convergence of the correlation energy of SC2 iterations -`threshold_generators `_ +`threshold_generators `_ Thresholds on generators (fraction of the norm) diff --git a/src/MOs/EZFIO.cfg b/src/MOs/EZFIO.cfg new file mode 100644 index 00000000..2dd45480 --- /dev/null +++ b/src/MOs/EZFIO.cfg @@ -0,0 +1,31 @@ +[mo_tot_num] +type: integer +doc: Total number of molecular orbitals and the size of the keys corresponding +interface: ezfio +ezfio_dir: mo_basis + +[mo_coef] +type: double precision +doc: coefficient of the ith ao on the jth mo +interface: ezfio +size: (ao_basis.ao_num,mo_basis.mo_tot_num) +ezfio_dir: mo_basis + +[mo_label] +type: character*(64) +doc: Label characterizing the MOS (local, canonical, natural, etc) +interface: ezfio +ezfio_dir: mo_basis + +[mo_occ] +type: double precision +doc: MO occupation numbers +interface: ezfio +size: (mo_basis.mo_tot_num) +ezfio_dir: mo_basis + +[ao_md5] +type: character*(32) +doc: Ao_md5 +interface: ezfio +ezfio_dir: mo_basis \ No newline at end of file diff --git a/src/MOs/mos.ezfio_config b/src/MOs/mos.ezfio_config deleted file mode 100644 index b0971eb8..00000000 --- a/src/MOs/mos.ezfio_config +++ /dev/null @@ -1,7 +0,0 @@ -mo_basis - mo_tot_num integer - mo_coef double precision (ao_basis_ao_num,mo_basis_mo_tot_num) - mo_label character*(64) - mo_occ double precision (mo_basis_mo_tot_num) - ao_md5 character*(32) - diff --git a/src/MOs/mos.irp.f b/src/MOs/mos.irp.f index 634773a8..016b48ad 100644 --- a/src/MOs/mos.irp.f +++ b/src/MOs/mos.irp.f @@ -26,7 +26,6 @@ END_PROVIDER BEGIN_PROVIDER [ double precision, mo_coef, (ao_num_align,mo_tot_num) ] -&BEGIN_PROVIDER [ character*(64), mo_label ] implicit none BEGIN_DOC ! Molecular orbital coefficients on AO basis set @@ -55,17 +54,28 @@ END_PROVIDER enddo enddo deallocate(buffer) - call ezfio_has_mo_basis_mo_label(exists) - if (exists) then - call ezfio_get_mo_basis_mo_label(mo_label) - else - mo_label = 'no_label' - endif else ! Orthonormalized AO basis mo_coef = 0. endif - +END_PROVIDER + +BEGIN_PROVIDER [ character*(64), mo_label ] + implicit none + BEGIN_DOC + ! Molecular orbital coefficients on AO basis set + ! mo_coef(i,j) = coefficient of the ith ao on the jth mo + ! mo_label : Label characterizing the MOS (local, canonical, natural, etc) + END_DOC + + logical :: exists + PROVIDE ezfio_filename + call ezfio_has_mo_basis_mo_label(exists) + if (exists) then + call ezfio_get_mo_basis_mo_label(mo_label) + else + mo_label = 'no_label' + endif END_PROVIDER BEGIN_PROVIDER [ double precision, mo_coef_transp, (mo_tot_num_align,ao_num) ] diff --git a/src/Nuclei/EZFIO.cfg b/src/Nuclei/EZFIO.cfg new file mode 100644 index 00000000..81c168ff --- /dev/null +++ b/src/Nuclei/EZFIO.cfg @@ -0,0 +1,22 @@ +[nucl_num] +doc: Number of nuclei +type: integer +interface: ezfio, provider + +[nucl_label] +doc: Nuclear labels +type: character*(32) +size: (nuclei.nucl_num) +interface: ezfio, provider + +[nucl_charge] +doc: Nuclear charges +type:double precision +size: (nuclei.nucl_num) +interface: ezfio, provider + +[nucl_coord] +doc: Nuclear coordinates in the format (:, {x,y,z}) +type: double precision +size: (nuclei.nucl_num,3) +interface: ezfio \ No newline at end of file diff --git a/src/Nuclei/nuclei.ezfio_config b/src/Nuclei/nuclei.ezfio_config deleted file mode 100644 index 07be4d29..00000000 --- a/src/Nuclei/nuclei.ezfio_config +++ /dev/null @@ -1,6 +0,0 @@ -nuclei - nucl_num integer - nucl_label character*(32) (nuclei_nucl_num) - nucl_charge double precision (nuclei_nucl_num) - nucl_coord double precision (nuclei_nucl_num,3) - diff --git a/src/Nuclei/nuclei.irp.f b/src/Nuclei/nuclei.irp.f index ec1fb7d4..a8def602 100644 --- a/src/Nuclei/nuclei.irp.f +++ b/src/Nuclei/nuclei.irp.f @@ -1,57 +1,14 @@ - BEGIN_PROVIDER [ integer, nucl_num ] -&BEGIN_PROVIDER [ integer, nucl_num_aligned ] +BEGIN_PROVIDER [ integer, nucl_num_aligned ] implicit none BEGIN_DOC - ! Number of nuclei + ! Number of nuclei algined END_DOC PROVIDE ezfio_filename - nucl_num = 0 - logical :: has - call ezfio_has_nuclei_nucl_num(has) - if (has) then - call ezfio_get_nuclei_nucl_num(nucl_num) - else - print *, irp_here - stop 1 - endif - ASSERT (nucl_num > 0) integer :: align_double nucl_num_aligned = align_double(nucl_num) END_PROVIDER -BEGIN_PROVIDER [ double precision, nucl_charge, (nucl_num) ] - implicit none - BEGIN_DOC - ! Nuclear charges - END_DOC - PROVIDE ezfio_filename - nucl_charge = -1.d0 - logical :: has - call ezfio_has_nuclei_nucl_charge(has) - if (has) then - call ezfio_get_nuclei_nucl_charge(nucl_charge) - else - print *, irp_here - stop 1 - endif - ASSERT (minval(nucl_charge) >= 0.d0) -END_PROVIDER - -BEGIN_PROVIDER [ character*(32), nucl_label, (nucl_num) ] - implicit none - BEGIN_DOC - ! Nuclear labels - END_DOC - PROVIDE ezfio_filename - nucl_label = "" - logical :: has - call ezfio_has_nuclei_nucl_label(has) - if (has) then - call ezfio_get_nuclei_nucl_label(nucl_label) - endif -END_PROVIDER - BEGIN_PROVIDER [ double precision, nucl_coord, (nucl_num_aligned,3) ] implicit none