Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: Add various settings parameters for PwCalculation #869

Merged
merged 2 commits into from
Dec 2, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
54 changes: 54 additions & 0 deletions docs/source/howto/calculations/pw.rst
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,60 @@ Similar to the pseudopotentials themselves, these can easily be retrieved for an
Be sure to specify the ``unit`` as ``Ry`` as that is the unit that ``pw.x`` will expect.


How to run an initialization-only calculation
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Specify ``ONLY_INITIALIZATION: True`` in the ``settings`` input:

.. code-block:: python
builder = load_code('pw').get_builder()
builder.settings = Dict({'ONLY_INITIALIZATION': True})
If this setting is specified, the plugin will write the file ``aiida.EXIT`` in the working directory of the calculation.
This will cause Quantum ESPRESSO to just run the preamble of the code and then shutdown cleanly.


How to run a gamma-only calculation
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Specify ``GAMMA_ONLY: True`` in the ``settings`` input:

.. code-block:: python
builder = load_code('pw').get_builder()
builder.settings = Dict({'GAMMA_ONLY': True})
How to fix the coordinates of atoms
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Quantum ESPRESSO pw.x allows to optionally fix the coordinates of atoms during relaxation and molecular-dynamics simulations.
This functionality is enabled in ``PwCalculation`` through the ``FIXED_COORDS`` setting which is a list of length equal to the number of sites in the input structure.
Each element is a list of length three containing booleans, where ``True`` means that the position of the site in that direction should be fixed.
For example:

.. code-block:: python
builder = load_code('pw').get_builder()
builder.settings = Dict({'FIXED_COORDS': [[False, False, False], [False, False, True]]})
will fix the position of the second site along the z-axis only.
All other coordinates are allowed to change.


How to retrieve additional files
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

The ``PwCalculation`` plugin will retrieve the most important and common output files by default.
To retrieve additional output files, specify the list of files in the ``ADDITIONAL_RETRIEVE_LIST`` key in the ``settings`` input:

.. code-block:: python
builder = load_code('pw').get_builder()
builder.settings = Dict({'ADDITIONAL_RETRIEVE_LIST': ['custom-file.txt', 'some-other.xml']})
.. |starting_magnetization| replace:: ``starting_magnetization``
.. _starting_magnetization: https://www.quantum-espresso.org/Doc/INPUT_PW.html#idm287

Expand Down