10
0
mirror of https://github.com/LCPQ/quantum_package synced 2024-09-27 03:51:01 +02:00
quantum_package/src
2018-12-25 19:24:43 +01:00
..
ao_basis Fixing travis 2018-12-21 01:12:51 +01:00
ao_one_e_integrals Marcon demission! (#78) 2018-12-19 14:34:00 +01:00
ao_two_e_erf_integrals poule au pot (#80) 2018-12-21 18:16:18 +01:00
ao_two_e_integrals poule au pot (#80) 2018-12-21 18:16:18 +01:00
aux_quantities added print_wf 2018-12-22 13:28:32 +01:00
becke_numerical_grid minor modifs in README.rst 2018-12-22 14:44:19 +01:00
bitmask minor modifs in README.rst 2018-12-22 14:44:19 +01:00
cis Added tests for CIS and CISD 2018-12-25 18:40:39 +01:00
cisd Added tests for CIS and CISD 2018-12-25 18:40:39 +01:00
davidson poule au pot (#80) 2018-12-21 18:16:18 +01:00
davidson_dressed Removed uppercases in filenames 2018-12-18 16:52:15 +01:00
davidson_undressed Renaming in lowercase 2018-12-18 16:11:25 +01:00
density_for_dft some cleaning and more explicit README 2018-12-23 23:50:31 +01:00
determinants some cleaning and more explicit README 2018-12-23 23:50:31 +01:00
dft_keywords some cleaning and more explicit README 2018-12-23 23:50:31 +01:00
dft_utils_in_r some cleaning and more explicit README 2018-12-23 23:50:31 +01:00
dft_utils_one_e added pot_ao.irp.f 2018-12-24 00:04:09 +01:00
dft_utils_two_body gitignore files 2018-12-25 19:24:43 +01:00
dressing Removed threshold_selectors 2018-12-19 16:03:21 +01:00
dummy poule au pot (#80) 2018-12-21 18:16:18 +01:00
electrons Renaming in lowercase 2018-12-18 16:11:25 +01:00
ezfio_files Updated tests 2018-12-25 10:55:40 +01:00
fci gitignore files 2018-12-25 19:24:43 +01:00
generators_cas Added files 2018-12-18 17:06:21 +01:00
generators_full Added files 2018-12-18 17:06:21 +01:00
hartree_fock gitignore files 2018-12-25 19:24:43 +01:00
iterations Renaming in lowercase 2018-12-18 16:11:25 +01:00
kohn_sham gitignore files 2018-12-25 19:24:43 +01:00
kohn_sham_rs gitignore files 2018-12-25 19:24:43 +01:00
mo_basis Merge with manu (#79) 2018-12-21 00:55:43 +01:00
mo_guess Renaming in lowercase 2018-12-18 16:11:25 +01:00
mo_one_e_integrals Merge with manu (#79) 2018-12-21 00:55:43 +01:00
mo_two_e_erf_integrals poule au pot (#80) 2018-12-21 18:16:18 +01:00
mo_two_e_integrals poule au pot (#80) 2018-12-21 18:16:18 +01:00
mpi Renaming in lowercase 2018-12-18 16:11:25 +01:00
mrpt_utils Removed uppercases in filenames 2018-12-18 16:52:15 +01:00
nuclei Merge with manu (#79) 2018-12-21 00:55:43 +01:00
perturbation Removed threshold_selectors 2018-12-19 16:03:21 +01:00
pseudo Renaming in lowercase 2018-12-18 16:11:25 +01:00
psiref_cas Renaming in lowercase 2018-12-18 16:11:25 +01:00
psiref_utils Renaming in lowercase 2018-12-18 16:11:25 +01:00
scf_utils Fixed slow SCF 2018-12-25 17:50:46 +01:00
selectors_cassd Renaming in lowercase 2018-12-18 16:11:25 +01:00
selectors_full Removed threshold_selectors 2018-12-19 16:03:21 +01:00
selectors_utils Renaming in lowercase 2018-12-18 16:11:25 +01:00
single_ref_method Renaming in lowercase 2018-12-18 16:11:25 +01:00
slave gitignore files 2018-12-25 19:24:43 +01:00
tools added print_wf 2018-12-22 13:28:32 +01:00
utils config files 2018-12-21 00:45:50 +01:00
zmq Renaming in lowercase 2018-12-18 16:11:25 +01:00
README.rst QPACKAGE_ROOT => QP_ROOT =D 2015-06-08 14:49:10 +02:00

======================
Programming guidelines
======================

Each module (directory) contains the following:

* A ``README.rst`` file to document the current module.
* An ``ASSUMPTIONS.rst`` file. This file should document all the implicit
  assumptions used in the module. For example, if the atomic orbitals are
  assumed to be normalized, this should be mentioned in the
  ``AOs/ASSUMPTIONS.rst`` file.
* A ``NEEDED_MODULES`` file which contains the list of modules on which the
  current module depends
* A set of ``.irp.f`` files containing provider, subroutines and functions
* A ``Makefile`` that should compile
* Optionally some ``*.ezfio_config`` configuration files for the EZFIO
  library

A new module may be created by invoking the ``create_module.sh`` script.

Every subroutine, function or provider should be documented using the
BEGIN_DOC ... END_DOC block. The documentation should be written in
ReStructured Text format to enable the automatic generation of the Sphinx
documentation.

When the current module depends on other modules, the list of modules should
be added in the ``NEEDED_MODULES`` file.


Creating a new module
=====================

Every new module should be created using the interactive ``create_module.sh``
script located in the ``${QP_ROOT}/scripts`` directory. This will create
all the required files with correct templates.


Makefiles
=========

Use the structure of Makefiles provided by the ``create_module.sh`` script. If
you need to re-create the Makefile, you can use the ``create_Makefile.sh``
script in the current module directory.

If you need to add some Fortran or C files that should not be tracked by IRPF90,
you have to add them manually to the Makefile in the ``SRC`` variable.
You also need to add the corresponding ``*.o`` file prefixed by ``IRPF90_temp/``.
For example

.. code-block:: Makefile

  SRC=map_module.f90
  OBJ=IRPF90_temp/map_module.o



Input data
==========

Every program is supposed to use an EZFIO database containing all the
persistent data. This database can be modified in using the generated Fortran
functions or the generated Python module.

The definition of the data needed by the module should be put in the
``*.ezfio_config`` file.

Input data can also be read from the standard input to enable the use of
a program with a pipe, but the read statements should be present **only** in
the main program.


Output data
===========

Print to stdout statements should only appear in programs, not in providers,
subroutines or functions. This enables the possibility easily use the programs
with pipes.

To print, you should write in an output file provided by the ``Output``
module. Every module has its own output file. Before printing something,
a timestamp should be put in the output with the ``write_time`` function.
This allows an external script to read all the pieces of the output files
and put them in a sequential order. The format of the output should be
in ReStructured Text for easy transformation of the output data to pdf,
HTML, man, etc.


Creating a shell script
=======================

Shell scripts should be located in the ``${QP_ROOT}/scripts`` directory.
Relative paths should be avoided as much as possible, and the result of commands
should be always checked. For example, when creating a directory the existence
of the directory has to be checked.


Documentation
=============

.. Do not edit this section. It was auto-generated from the
.. NEEDED_MODULES file.



Needed Modules
==============

.. Do not edit this section. It was auto-generated from the
.. NEEDED_MODULES file.

* `Utils <http://github.com/LCPQ/quantum_package/tree/master/src/Utils>`_