edrixs 0.2.0__tar.gz → 0.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {edrixs-0.2.0 → edrixs-0.3.0}/PKG-INFO +27 -7
- {edrixs-0.2.0 → edrixs-0.3.0}/README.rst +24 -4
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/index.rst +3 -0
- edrixs-0.3.0/docs/source/reference/models.rst +15 -0
- edrixs-0.3.0/docs/source/reference/solvers.rst +17 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/release-history.rst +59 -7
- edrixs-0.3.0/docs/source/user/backend.rst +97 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/backends/dense.rst +9 -4
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/backends/fortran.rst +8 -3
- edrixs-0.3.0/docs/source/user/backends/petsc.rst +140 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/backends/scipy.rst +16 -5
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/conventions.rst +88 -29
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/installation.rst +24 -4
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/introduction.rst +55 -22
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/nio_siam_xas_rixs.rst +3 -0
- edrixs-0.3.0/docs/source/user/whatisedrixs.rst +39 -0
- edrixs-0.3.0/edrixs/_numba_operator_kernels.py +264 -0
- edrixs-0.3.0/edrixs/_operator_builder.py +250 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/_solvers_helpers.py +0 -42
- edrixs-0.3.0/edrixs/_version.py +21 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/dense_backend/__init__.py +0 -2
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/dense_backend/dense_backend.py +11 -8
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/fortran_backend/__init__.py +0 -2
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/fortran_backend/fortran_backend.py +16 -15
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/fortran_backend/options.py +1 -1
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/models.py +8 -7
- edrixs-0.3.0/edrixs/petsc_backend/hash_basis_methods.py +184 -0
- edrixs-0.3.0/edrixs/petsc_backend/lanczos.py +81 -0
- edrixs-0.3.0/edrixs/petsc_backend/options.py +177 -0
- edrixs-0.3.0/edrixs/petsc_backend/petsc_backend.py +832 -0
- edrixs-0.3.0/edrixs/petsc_backend/petsc_shifted_pminres.py +177 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/scipy_backend/options.py +5 -3
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/scipy_backend/scipy_backend.py +28 -23
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/solvers.py +54 -86
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/utils.py +6 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs.egg-info/PKG-INFO +27 -7
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs.egg-info/SOURCES.txt +10 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/setup.cfg +1 -1
- {edrixs-0.2.0 → edrixs-0.3.0}/setup.py +3 -3
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_backend_options.py +20 -3
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_basis_representation_routes.py +4 -2
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_dense_backend.py +67 -19
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_ed_krylov.py +5 -3
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_ed_shift.py +53 -40
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_filled_core.py +5 -3
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_fortran_backend.py +23 -4
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_fortran_backend_mpi.py +8 -3
- edrixs-0.3.0/tests/test_lazy_operators.py +195 -0
- edrixs-0.3.0/tests/test_model_operator_routes.py +139 -0
- edrixs-0.3.0/tests/test_numba_cache.py +39 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_operator_route_consistency.py +6 -6
- edrixs-0.3.0/tests/test_petsc_backend.py +302 -0
- edrixs-0.3.0/tests/test_petsc_coo.py +107 -0
- edrixs-0.3.0/tests/test_petsc_filled_core.py +203 -0
- edrixs-0.3.0/tests/test_petsc_operator_lifetime.py +330 -0
- edrixs-0.3.0/tests/test_petsc_preallocation.py +97 -0
- edrixs-0.3.0/tests/test_rixs_solve_reuse.py +207 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_scipy_backend.py +20 -17
- edrixs-0.3.0/tests/test_scipy_examples.py +53 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_scipy_operator_construction.py +2 -2
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_solver_helpers.py +0 -13
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_solvers_dispatch.py +15 -26
- edrixs-0.2.0/docs/source/reference/models.rst +0 -16
- edrixs-0.2.0/docs/source/reference/solvers.rst +0 -4
- edrixs-0.2.0/docs/source/user/backend.rst +0 -62
- edrixs-0.2.0/docs/source/user/backends/petsc.rst +0 -27
- edrixs-0.2.0/docs/source/user/whatisedrixs.rst +0 -9
- edrixs-0.2.0/edrixs/_operator_builder.py +0 -501
- edrixs-0.2.0/edrixs/_version.py +0 -520
- edrixs-0.2.0/edrixs/petsc_backend/hash_basis_methods.py +0 -28
- edrixs-0.2.0/edrixs/petsc_backend/options.py +0 -19
- edrixs-0.2.0/edrixs/petsc_backend/petsc_backend.py +0 -86
- edrixs-0.2.0/tests/test_model_operator_routes.py +0 -106
- edrixs-0.2.0/tests/test_petsc_backend.py +0 -70
- edrixs-0.2.0/tests/test_rixs_solve_reuse.py +0 -107
- {edrixs-0.2.0 → edrixs-0.3.0}/AUTHORS.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/CONTRIBUTING.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/LICENSE +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/MANIFEST.in +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/Makefile +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/make.bat +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/_ext/backend_options_directive.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/conf.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/angular_momentum.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/basis_transform.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/coulomb_utensor.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/fit_hyb.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/fock_basis.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/index.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/iostream.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/manybody_operator.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/photon_transition.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/plot_spectrum.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/poles.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/rixs_utils.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/soc.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/utils.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/reference/wannier_ham.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/devcontainer.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/examples.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/index.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/nio_l23_xas.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/papers.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/docs/source/user/usedocker.rst +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/__init__.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/_backend_options.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/angular_momentum.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Co.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Cr.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Cu.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Fe.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Ir.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Mn.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Ni.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Os.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Pu.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Re.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Sm.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/Ti.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/U.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/atom_data/V.json +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/basis_transform.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/coulomb_utensor.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/dense_backend/options.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/fit_hyb.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/fock_basis.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/fortran_backend/iostream_fortran.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/iostream.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/manybody_operator.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/petsc_backend/__init__.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/photon_transition.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/plot_spectrum.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/poles.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/rixs_utils.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/scipy_backend/__init__.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/scipy_backend/hash_basis_methods.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/scipy_backend/krylov.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/scripts.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/soc.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs/wannier_ham.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs.egg-info/dependency_links.txt +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs.egg-info/entry_points.txt +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs.egg-info/requires.txt +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/edrixs.egg-info/top_level.txt +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/pyproject.toml +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/requirements.txt +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/arpack.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/ed_driver.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/ed_main.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/fock.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/full_diag.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/ham.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/io.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/lanczos.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/linsys.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/m_constants.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/m_control.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/m_global.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/m_types.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/opavg_driver.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/opavg_main.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/pyapi.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/rixs_driver.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/rixs_main.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/spmv.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/utils.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/xas_driver.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/src/xas_main.f90 +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_angular_momentum.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_basis_transform.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_coulomb_utensor.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_fock_basis.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_legacy_solver_deprecations.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_manybody_operator.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_model_siam_2d1p.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_scipy_krylov.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_soc.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_utils.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_utils_extra.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/tests/test_wannier_ham.py +0 -0
- {edrixs-0.2.0 → edrixs-0.3.0}/versioneer.py +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: edrixs
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: An open source toolkit for simulating RIXS spectra based on ED
|
|
5
|
-
Home-page: https://github.com/
|
|
5
|
+
Home-page: https://github.com/EDRIXS/edrixs
|
|
6
6
|
Author: Brookhaven National Lab
|
|
7
|
-
Author-email:
|
|
7
|
+
Author-email: mdean@bnl.gov
|
|
8
8
|
License: GPL-3.0-or-later
|
|
9
9
|
Classifier: License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
|
|
10
10
|
Classifier: Development Status :: 2 - Pre-Alpha
|
|
@@ -35,11 +35,31 @@ Dynamic: summary
|
|
|
35
35
|
edrixs
|
|
36
36
|
===============================
|
|
37
37
|
|
|
38
|
-
|
|
39
|
-
:target: https://pypi.python.org/pypi/edrixs
|
|
38
|
+
|ci| |conda| |pypi| |docs| |doi| |binder|
|
|
40
39
|
|
|
41
|
-
.. image:: https://
|
|
42
|
-
|
|
40
|
+
.. |ci| image:: https://github.com/EDRIXS/edrixs/actions/workflows/ci-test.yml/badge.svg?branch=master&event=push
|
|
41
|
+
:target: https://github.com/EDRIXS/edrixs/actions/workflows/ci-test.yml?query=branch%3Amaster+event%3Apush
|
|
42
|
+
:alt: CI status
|
|
43
|
+
|
|
44
|
+
.. |conda| image:: https://img.shields.io/conda/vn/conda-forge/edrixs.svg
|
|
45
|
+
:target: https://anaconda.org/conda-forge/edrixs
|
|
46
|
+
:alt: Conda-forge version
|
|
47
|
+
|
|
48
|
+
.. |pypi| image:: https://img.shields.io/pypi/v/edrixs.svg
|
|
49
|
+
:target: https://pypi.org/project/edrixs/
|
|
50
|
+
:alt: PyPI version
|
|
51
|
+
|
|
52
|
+
.. |docs| image:: https://img.shields.io/badge/docs-online-blue.svg
|
|
53
|
+
:target: https://edrixs.github.io/edrixs/
|
|
54
|
+
:alt: Documentation
|
|
55
|
+
|
|
56
|
+
.. |doi| image:: https://img.shields.io/badge/DOI-10.1016%2Fj.cpc.2019.04.018-blue.svg
|
|
57
|
+
:target: https://doi.org/10.1016/j.cpc.2019.04.018
|
|
58
|
+
:alt: Paper DOI
|
|
59
|
+
|
|
60
|
+
.. |binder| image:: https://mybinder.org/badge_logo.svg
|
|
61
|
+
:target: https://mybinder.org/v2/gh/edrixs/edrixs.git/master?urlpath=lab
|
|
62
|
+
:alt: Launch Binder
|
|
43
63
|
|
|
44
64
|
EDRIXS is an open source toolkit for simulating XAS and RIXS spectra based on exact diagonalization of model Hamiltonians.
|
|
45
65
|
It was started as part of the `COMSCOPE project <https://www.bnl.gov/comscope/>`_ in the
|
|
@@ -2,11 +2,31 @@
|
|
|
2
2
|
edrixs
|
|
3
3
|
===============================
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
:target: https://pypi.python.org/pypi/edrixs
|
|
5
|
+
|ci| |conda| |pypi| |docs| |doi| |binder|
|
|
7
6
|
|
|
8
|
-
.. image:: https://
|
|
9
|
-
|
|
7
|
+
.. |ci| image:: https://github.com/EDRIXS/edrixs/actions/workflows/ci-test.yml/badge.svg?branch=master&event=push
|
|
8
|
+
:target: https://github.com/EDRIXS/edrixs/actions/workflows/ci-test.yml?query=branch%3Amaster+event%3Apush
|
|
9
|
+
:alt: CI status
|
|
10
|
+
|
|
11
|
+
.. |conda| image:: https://img.shields.io/conda/vn/conda-forge/edrixs.svg
|
|
12
|
+
:target: https://anaconda.org/conda-forge/edrixs
|
|
13
|
+
:alt: Conda-forge version
|
|
14
|
+
|
|
15
|
+
.. |pypi| image:: https://img.shields.io/pypi/v/edrixs.svg
|
|
16
|
+
:target: https://pypi.org/project/edrixs/
|
|
17
|
+
:alt: PyPI version
|
|
18
|
+
|
|
19
|
+
.. |docs| image:: https://img.shields.io/badge/docs-online-blue.svg
|
|
20
|
+
:target: https://edrixs.github.io/edrixs/
|
|
21
|
+
:alt: Documentation
|
|
22
|
+
|
|
23
|
+
.. |doi| image:: https://img.shields.io/badge/DOI-10.1016%2Fj.cpc.2019.04.018-blue.svg
|
|
24
|
+
:target: https://doi.org/10.1016/j.cpc.2019.04.018
|
|
25
|
+
:alt: Paper DOI
|
|
26
|
+
|
|
27
|
+
.. |binder| image:: https://mybinder.org/badge_logo.svg
|
|
28
|
+
:target: https://mybinder.org/v2/gh/edrixs/edrixs.git/master?urlpath=lab
|
|
29
|
+
:alt: Launch Binder
|
|
10
30
|
|
|
11
31
|
EDRIXS is an open source toolkit for simulating XAS and RIXS spectra based on exact diagonalization of model Hamiltonians.
|
|
12
32
|
It was started as part of the `COMSCOPE project <https://www.bnl.gov/comscope/>`_ in the
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
models
|
|
2
|
+
======
|
|
3
|
+
|
|
4
|
+
Model constructors define the physical problem without building many-body
|
|
5
|
+
operators or running solvers. They return eight values: seven inputs describing
|
|
6
|
+
the Hamiltonians, Fock bases, and transition operators, plus a scalar ``shift``
|
|
7
|
+
equal to the filled core's shell-level energy.
|
|
8
|
+
|
|
9
|
+
Pass the first seven outputs to ``get_ops``. For dense, SciPy, or PETSc
|
|
10
|
+
diagonalization, optionally pass ``shift`` to ``ed`` to reduce numerical errors.
|
|
11
|
+
The returned eigenvalues retain their original energy reference, so the shift
|
|
12
|
+
does not change the physics. Fortran ED ignores a nonzero shift with a warning.
|
|
13
|
+
|
|
14
|
+
.. automodule:: edrixs.models
|
|
15
|
+
:members:
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
solvers
|
|
2
|
+
=======
|
|
3
|
+
|
|
4
|
+
``build_op`` returns a zero-argument ``functools.partial`` with a ``.backend``
|
|
5
|
+
attribute. Numerical ``get_ops`` returns these factories for both Hamiltonians
|
|
6
|
+
and each transition component. ``ed`` and ``rixs`` dispatch using
|
|
7
|
+
``hmat_i.backend``; ``xas`` uses ``hmat_n.backend``. The backend receives the
|
|
8
|
+
factories unchanged. All staged backend solvers require factories.
|
|
9
|
+
Dense, SciPy, and PETSc ED construct all inputs at calculation start.
|
|
10
|
+
PETSc XAS and RIXS accept ``matrix_lifetime`` in ``backend_kws``.
|
|
11
|
+
Fortran disk handles are callable, returning themselves; native Fortran manages
|
|
12
|
+
actual matrix construction.
|
|
13
|
+
|
|
14
|
+
Call a numerical factory explicitly to obtain a concrete matrix for arithmetic.
|
|
15
|
+
|
|
16
|
+
.. automodule:: edrixs.solvers
|
|
17
|
+
:members:
|
|
@@ -2,8 +2,63 @@
|
|
|
2
2
|
Release History
|
|
3
3
|
===============
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
This page summarizes the user-visible changes in each tagged release. See the
|
|
6
|
+
`GitHub releases page <https://github.com/EDRIXS/edrixs/releases>`_ for the
|
|
7
|
+
complete release notes and downloadable artifacts.
|
|
8
|
+
|
|
9
|
+
v0.3.0 (2026-11-29)
|
|
10
|
+
--------------------
|
|
11
|
+
|
|
12
|
+
PETSc backend and deferred operators
|
|
13
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
14
|
+
|
|
15
|
+
* Provide a PETSc/SLEPc backend with distributed operator construction, ED,
|
|
16
|
+
XAS, and RIXS, shipped as part of the packaged installation.
|
|
17
|
+
* Return labeled matrix factories from ``build_op`` and numerical ``get_ops``.
|
|
18
|
+
Call a factory explicitly for matrix arithmetic. ``ed``, ``xas``, and ``rixs``
|
|
19
|
+
now dispatch using ``.backend`` labels and no longer accept ``backend=``.
|
|
20
|
+
* Construct matrices inside the numerical backends. Dense and SciPy eagerly
|
|
21
|
+
materialize inputs at calculation start, as does PETSc ED. PETSc XAS and
|
|
22
|
+
RIXS accept ``matrix_lifetime`` with ``'retain'`` (default) and
|
|
23
|
+
``'recompute'`` policies for reusing matrices or releasing and rebuilding
|
|
24
|
+
them between operations.
|
|
25
|
+
* Support the energy-reference shift in PETSc diagonalization.
|
|
26
|
+
|
|
27
|
+
Numerical methods
|
|
28
|
+
~~~~~~~~~~~~~~~~~~
|
|
29
|
+
|
|
30
|
+
* Use unitary Givens rotations in the shifted PMINRES solver, avoiding
|
|
31
|
+
breakdown from complex cancellation in well-conditioned problems.
|
|
32
|
+
* Warn instead of raising when a PETSc RIXS linear solve misses its
|
|
33
|
+
tolerance, reporting the solver state and continuing.
|
|
34
|
+
* Increase the staged SciPy ED ``maxiter`` default from 200 to 1000 and the
|
|
35
|
+
staged Fortran RIXS ``linsys_max`` default from 1000 to 5000.
|
|
36
|
+
|
|
37
|
+
Compatibility and migration
|
|
38
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
39
|
+
|
|
40
|
+
* ``build_op`` and numerical ``get_ops`` now return factories rather than
|
|
41
|
+
matrices. Call a factory to obtain a matrix for arithmetic. Public ``ed``,
|
|
42
|
+
``xas``, and ``rixs`` require labeled factories or Fortran disk handles and
|
|
43
|
+
reject the removed ``backend`` keyword. Backend-specific staged solvers also
|
|
44
|
+
require factories. See :ref:`lazy-operators`.
|
|
45
|
+
|
|
46
|
+
Documentation and packaging
|
|
47
|
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
48
|
+
|
|
49
|
+
* Combine the overview and reading guide into a "Start here" page and clarify
|
|
50
|
+
model inputs, custom Hamiltonians, and calculation conventions.
|
|
51
|
+
* Update the SciPy examples for the deferred-operator API and remove
|
|
52
|
+
superseded RIXS examples. Warn that ``CT_imp_bath_core_hole`` is intended
|
|
53
|
+
for the legacy solvers.
|
|
54
|
+
* Fix version metadata in source distributions, use PEP 440-compliant versions
|
|
55
|
+
for development builds, and make PyPI publication retries safe.
|
|
56
|
+
|
|
57
|
+
`Release notes <https://github.com/EDRIXS/edrixs/releases/tag/v0.3.0>`__ |
|
|
58
|
+
`Changes since v0.2.0 <https://github.com/EDRIXS/edrixs/compare/v0.2.0...v0.3.0>`__
|
|
59
|
+
|
|
60
|
+
v0.2.0 (2026-10-08)
|
|
61
|
+
--------------------
|
|
7
62
|
|
|
8
63
|
New calculation interface
|
|
9
64
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
@@ -17,7 +72,6 @@ New calculation interface
|
|
|
17
72
|
* Make SciPy the default backend, with sparse operator construction and Krylov
|
|
18
73
|
methods for ED, XAS, and RIXS. Dense calculations and native Fortran/MPI
|
|
19
74
|
solvers are also available through the staged interface.
|
|
20
|
-
* A PETSc-based backend is under development
|
|
21
75
|
* Add compact Fock-basis specifications with interchangeable combinadic and
|
|
22
76
|
explicit basis construction. Operator construction uses Numba by default;
|
|
23
77
|
``use_numba=False`` selects Python construction.
|
|
@@ -45,7 +99,6 @@ Compatibility and migration
|
|
|
45
99
|
* Reject isotropic RIXS polarization; specify incoming and outgoing
|
|
46
100
|
polarization channels explicitly. Isotropic XAS remains supported.
|
|
47
101
|
|
|
48
|
-
|
|
49
102
|
Documentation and packaging
|
|
50
103
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
51
104
|
|
|
@@ -56,9 +109,8 @@ Documentation and packaging
|
|
|
56
109
|
* Correct the CMake extension name used by packaging, automate Docker Hub
|
|
57
110
|
release publishing, and update installation guidance and dependencies.
|
|
58
111
|
|
|
59
|
-
|
|
60
|
-
`
|
|
61
|
-
complete release notes and downloadable artifacts.
|
|
112
|
+
`Release notes <https://github.com/EDRIXS/edrixs/releases/tag/v0.2.0>`__ |
|
|
113
|
+
`Changes since v0.1.3 <https://github.com/EDRIXS/edrixs/compare/v0.1.3...v0.2.0>`__
|
|
62
114
|
|
|
63
115
|
v0.1.3 (2026-09-08)
|
|
64
116
|
--------------------
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
.. _backend:
|
|
2
|
+
|
|
3
|
+
*******
|
|
4
|
+
Backend
|
|
5
|
+
*******
|
|
6
|
+
|
|
7
|
+
The :ref:`introduction` describes the four stages of a calculation. Stages two
|
|
8
|
+
to four -- building operators, diagonalizing, and assembling spectra --
|
|
9
|
+
delegate their numerical work to a backend selected with ``backend`` when
|
|
10
|
+
calling ``build_op`` or ``get_ops``:
|
|
11
|
+
|
|
12
|
+
* ``'dense'`` builds full NumPy matrices and uses exact dense
|
|
13
|
+
diagonalization and explicit eigenstate sums. It is intended for small
|
|
14
|
+
problems, reference calculations, and pedagogy.
|
|
15
|
+
* ``'scipy'`` builds SciPy CSR matrices and uses LOBPCG, Lanczos, and GMRES.
|
|
16
|
+
It is the default backend.
|
|
17
|
+
* ``'fortran'`` uses the native MPI solvers and communicates through files in
|
|
18
|
+
the current working directory. We provide the function
|
|
19
|
+
:func:`edrixs.get_ops_disk <edrixs.solvers.get_ops_disk>` to load the setup
|
|
20
|
+
from disk if desired.
|
|
21
|
+
* ``'petsc'`` uses distributed PETSc matrices, SLEPc eigensolvers, and PETSc
|
|
22
|
+
Krylov solvers. It is intended for larger Hilbert spaces and MPI runs.
|
|
23
|
+
|
|
24
|
+
Backend-specific numerical controls belong in a ``backend_kws`` mapping. The
|
|
25
|
+
mapping is specific to both the backend *and the operation*.
|
|
26
|
+
|
|
27
|
+
.. _lazy-operators:
|
|
28
|
+
|
|
29
|
+
Preparing and using operators
|
|
30
|
+
=============================
|
|
31
|
+
|
|
32
|
+
Choose the backend when preparing operators, then pass the returned objects
|
|
33
|
+
directly to the solvers::
|
|
34
|
+
|
|
35
|
+
hmat_i, hmat_n, trans_ops = edrixs.get_ops(*problem, backend='scipy')
|
|
36
|
+
eval_i, evec_i = edrixs.ed(hmat_i, shift=shift, num_evals=3)
|
|
37
|
+
|
|
38
|
+
Here ``problem`` and ``shift`` come from a model constructor as shown in
|
|
39
|
+
:ref:`physical-model`. You do not repeat the backend choice in ``ed``, ``xas``,
|
|
40
|
+
or ``rixs``. The operators carry that choice in their ``.backend`` labels;
|
|
41
|
+
prepare all operators for a calculation with the same backend.
|
|
42
|
+
|
|
43
|
+
For dense, SciPy, and PETSc calculations, these objects are instructions for
|
|
44
|
+
building a matrix, rather than matrices already occupying memory. In Python
|
|
45
|
+
they are callables (functions you can call with no arguments), also called
|
|
46
|
+
*operator factories*. The solvers call them when needed, and each call builds
|
|
47
|
+
a fresh matrix. This lets the backend release large matrices and reconstruct
|
|
48
|
+
them later. PETSc offers a memory-versus-computation choice through
|
|
49
|
+
``matrix_lifetime``; see :doc:`backends/petsc`.
|
|
50
|
+
|
|
51
|
+
Fortran instead uses handles to solver input files. Pass those handles to the
|
|
52
|
+
same solver functions; see :doc:`backends/fortran` for its file-based workflow.
|
|
53
|
+
|
|
54
|
+
For matrix arithmetic or direct access to matrix methods, call the factory
|
|
55
|
+
explicitly::
|
|
56
|
+
|
|
57
|
+
number_op = edrixs.build_op(number_coefficients, None, basis, backend='dense')
|
|
58
|
+
number_matrix = number_op()
|
|
59
|
+
|
|
60
|
+
Numerical precision
|
|
61
|
+
===================
|
|
62
|
+
|
|
63
|
+
XAS and RIXS thermally average over the retained initial eigenstates. Request
|
|
64
|
+
enough eigenpairs from ``ed`` to keep every thermally populated state in the
|
|
65
|
+
ground-state manifold, including complete degenerate or nearly degenerate
|
|
66
|
+
multiplets; otherwise the Boltzmann average is incomplete.
|
|
67
|
+
|
|
68
|
+
EDRIXS uses established numerical linear-algebra packages, but floating-point
|
|
69
|
+
and iterative solvers are not exact. If numerical accuracy is a concern,
|
|
70
|
+
repeat the calculation with varied solver settings and check that the result
|
|
71
|
+
is unchanged. Relevant settings include ``tol`` or ``eigval_tol``,
|
|
72
|
+
``maxiter``, ``blocksize`` or ``ncv``, ``nkryl``, and the RIXS ``linsys_*``
|
|
73
|
+
options documented below.
|
|
74
|
+
|
|
75
|
+
.. _backend-options:
|
|
76
|
+
|
|
77
|
+
Backend settings reference
|
|
78
|
+
==========================
|
|
79
|
+
|
|
80
|
+
Choose the backend whose solver and matrix settings you need:
|
|
81
|
+
|
|
82
|
+
* :doc:`backends/scipy`
|
|
83
|
+
* :doc:`backends/dense`
|
|
84
|
+
* :doc:`backends/fortran`
|
|
85
|
+
* :doc:`backends/petsc`
|
|
86
|
+
|
|
87
|
+
These references apply to the staged ``get_ops`` / ``ed`` / ``xas`` / ``rixs``
|
|
88
|
+
interface. The legacy ``ed_*_fort``, ``xas_*_fort``, and ``rixs_*_fort``
|
|
89
|
+
functions retain their existing explicit parameters.
|
|
90
|
+
|
|
91
|
+
.. toctree::
|
|
92
|
+
:hidden:
|
|
93
|
+
|
|
94
|
+
backends/scipy
|
|
95
|
+
backends/dense
|
|
96
|
+
backends/fortran
|
|
97
|
+
backends/petsc
|
|
@@ -1,16 +1,21 @@
|
|
|
1
1
|
.. _dense-backend-options:
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
Dense
|
|
5
|
-
|
|
3
|
+
**********************
|
|
4
|
+
Dense backend settings
|
|
5
|
+
**********************
|
|
6
6
|
|
|
7
7
|
:doc:`Back to the backend overview <../backend>`
|
|
8
8
|
|
|
9
9
|
About this backend
|
|
10
10
|
==================
|
|
11
11
|
|
|
12
|
-
The ``dense`` backend
|
|
12
|
+
The ``dense`` backend uses NumPy
|
|
13
13
|
`ndarray objects <https://numpy.org/doc/stable/reference/arrays.ndarray.html>`__.
|
|
14
|
+
``build_op`` and ``get_ops`` return labeled factories; the matrices are built
|
|
15
|
+
when a factory is called explicitly or by the dense backend at the start of
|
|
16
|
+
each calculation. Each argument is called independently, including repeated
|
|
17
|
+
references. Backend-specific solvers also require factories.
|
|
18
|
+
|
|
14
19
|
It uses SciPy's
|
|
15
20
|
`dense Hermitian eigensolver <https://docs.scipy.org/doc/scipy/reference/generated/scipy.linalg.eigh.html>`__
|
|
16
21
|
for ED. XAS explicitly sums over all intermediate eigenstates, while RIXS
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
.. _fortran-backend-options:
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
Fortran
|
|
5
|
-
|
|
3
|
+
************************
|
|
4
|
+
Fortran backend settings
|
|
5
|
+
************************
|
|
6
6
|
|
|
7
7
|
:doc:`Back to the backend overview <../backend>`
|
|
8
8
|
|
|
@@ -45,6 +45,11 @@ current working directory, call :func:`~edrixs.solvers.get_ops_disk`. It
|
|
|
45
45
|
returns ``hmat_i``, ``hmat_n``, and ``trans_ops`` handles without rewriting
|
|
46
46
|
the problem files.
|
|
47
47
|
|
|
48
|
+
Both ``get_ops(..., backend='fortran')`` and ``get_ops_disk()`` return disk
|
|
49
|
+
handles with ``.backend == 'fortran'``. Pass them directly to public ``ed``,
|
|
50
|
+
``xas``, and ``rixs``. The handles are callable and return themselves; the
|
|
51
|
+
Fortran backends call them while native Fortran manages matrix construction.
|
|
52
|
+
|
|
48
53
|
``ed``
|
|
49
54
|
======
|
|
50
55
|
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
.. _petsc-backend-options:
|
|
2
|
+
|
|
3
|
+
**********************
|
|
4
|
+
PETSc backend settings
|
|
5
|
+
**********************
|
|
6
|
+
|
|
7
|
+
:doc:`Back to the backend overview <../backend>`
|
|
8
|
+
|
|
9
|
+
About this backend
|
|
10
|
+
==================
|
|
11
|
+
|
|
12
|
+
PETSc supplies distributed vectors and matrices together with scalable linear
|
|
13
|
+
solvers and preconditioners; its concise
|
|
14
|
+
`architecture overview <https://petsc.org/release/overview/nutshell/>`__
|
|
15
|
+
introduces the ``Vec``, ``Mat``, ``KSP``, and ``PC`` objects. Python programs
|
|
16
|
+
access them through the official
|
|
17
|
+
`petsc4py API <https://petsc.org/release/petsc4py/reference/petsc4py.PETSc.html>`__.
|
|
18
|
+
For eigenvalue problems, SLEPc builds on PETSc and exposes its ``EPS`` solver
|
|
19
|
+
through the
|
|
20
|
+
`SLEPc eigenvalue guide <https://slepc.upv.es/release/documentation/manual/eps.html>`__
|
|
21
|
+
and the
|
|
22
|
+
`slepc4py EPS API <https://slepc.upv.es/release/slepc4py/reference/slepc4py.SLEPc.EPS.html>`__.
|
|
23
|
+
|
|
24
|
+
EDRIXS constructs distributed PETSc ``Mat`` objects, obtains low-energy
|
|
25
|
+
eigenpairs with SLEPc's Krylov--Schur method, and evaluates XAS and RIXS with
|
|
26
|
+
distributed Lanczos and KSP solves. Importing EDRIXS does not import PETSc;
|
|
27
|
+
``petsc4py`` and ``slepc4py`` are loaded only when this backend is used.
|
|
28
|
+
|
|
29
|
+
``build_op`` and ``get_ops`` return factories labeled with
|
|
30
|
+
``.backend == 'petsc'``. Calling a factory assembles its distributed matrix;
|
|
31
|
+
public ``ed``, ``xas``, and ``rixs`` read the labels and pass the factories to
|
|
32
|
+
the PETSc backend. All MPI ranks in the matrix communicator must participate
|
|
33
|
+
in construction and solver calls. See :ref:`lazy-operators`.
|
|
34
|
+
|
|
35
|
+
Options are specific to the stage where they are supplied.
|
|
36
|
+
|
|
37
|
+
Matrix lifetime
|
|
38
|
+
===============
|
|
39
|
+
|
|
40
|
+
PETSc ``xas`` and ``rixs`` accept ``matrix_lifetime`` in ``backend_kws``:
|
|
41
|
+
|
|
42
|
+
* ``'retain'`` (default) builds each required factory on first use, keeps its
|
|
43
|
+
matrix for reuse during the calculation, and destroys it before returning.
|
|
44
|
+
* ``'recompute'`` builds a matrix for each operation and destroys it immediately
|
|
45
|
+
afterward, rebuilding it for later uses. This reduces peak memory usage at the
|
|
46
|
+
cost of more CPU time. This can be useful for the largest jobs.
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
``build_op`` and ``get_ops``
|
|
50
|
+
============================
|
|
51
|
+
|
|
52
|
+
.. backend-options:: petsc get_ops
|
|
53
|
+
|
|
54
|
+
Two matrix construction options are available. ``assembly_method='row'`` is
|
|
55
|
+
the default and inserts entries by row in bounded chunks.
|
|
56
|
+
``assembly_method='coo'`` counts contributions in a first pass, then generates
|
|
57
|
+
them again into exact-sized coordinate and value arrays for bulk PETSc COO
|
|
58
|
+
assembly. PETSc combines duplicate coordinates and communicates remote entries.
|
|
59
|
+
Both options produce AIJ (CSR) matrices before optional ``mat_type`` conversion;
|
|
60
|
+
COO describes the assembly interface, rather than the final storage format.
|
|
61
|
+
Both options support the same solver lifetime policies.
|
|
62
|
+
COO avoids the Python row-insertion loop but requires full local entry buffers
|
|
63
|
+
and PETSc's COO mappings, so compare assembly time and peak memory for your
|
|
64
|
+
problem. ``assembly_chunk_cols`` bounds individual kernel calls for both
|
|
65
|
+
methods; COO still collects all local contributions before insertion.
|
|
66
|
+
|
|
67
|
+
``nnz_guess_per_row`` controls PETSc matrix preallocation. Leaving it unset
|
|
68
|
+
uses an estimate from the retained one- and two-body coefficients. With multiple
|
|
69
|
+
MPI ranks, the hint is applied separately to the local-column and remote-column
|
|
70
|
+
blocks of each rank's matrix rows. With one rank it applies to the sequential
|
|
71
|
+
matrix. Larger hints reserve more memory but can avoid reallocations during
|
|
72
|
+
row assembly; they do not change the matrix values. COO computes its pattern
|
|
73
|
+
directly and ignores this hint. A
|
|
74
|
+
``mat_type`` such as ``'aijcusparse'`` can select an accelerated matrix format;
|
|
75
|
+
see PETSc's `matrix type overview
|
|
76
|
+
<https://petsc.org/release/manual/mat/#basic-matrix-operations>`__.
|
|
77
|
+
|
|
78
|
+
``ed``
|
|
79
|
+
======
|
|
80
|
+
|
|
81
|
+
Pass the final model output as ``ed(hmat_i, shift=shift)`` to subtract the
|
|
82
|
+
filled-core shell energy from the factory-created distributed Hamiltonian before
|
|
83
|
+
diagonalization. Returned eigenvalues retain the original energy reference.
|
|
84
|
+
With a nonzero ``shift``, ``eigval_tol`` is an absolute residual tolerance for
|
|
85
|
+
the shifted problem, avoiding division by a near-zero centered eigenvalue.
|
|
86
|
+
With ``shift=0``, it is a relative residual tolerance, scaled by the eigenvalue
|
|
87
|
+
magnitude.
|
|
88
|
+
|
|
89
|
+
ED calls its factory once and destroys the matrix before returning.
|
|
90
|
+
``matrix_lifetime`` is not accepted for ED.
|
|
91
|
+
|
|
92
|
+
.. backend-options:: petsc ed
|
|
93
|
+
|
|
94
|
+
The eigensolver uses SLEPc ``EPS`` with a Hermitian problem type and requests
|
|
95
|
+
the smallest-real eigenpairs. ``ncv`` sets the Krylov subspace size described
|
|
96
|
+
by `EPS.setDimensions
|
|
97
|
+
<https://slepc.upv.es/release/slepc4py/reference/slepc4py.SLEPc.EPS.html#slepc4py.SLEPc.EPS.setDimensions>`__.
|
|
98
|
+
|
|
99
|
+
``xas``
|
|
100
|
+
=======
|
|
101
|
+
|
|
102
|
+
XAS accepts ``matrix_lifetime`` in ``backend_kws``. The default ``'retain'``
|
|
103
|
+
builds required transition components and the intermediate Hamiltonian on first
|
|
104
|
+
use and keeps them until calculation exit. With ``'recompute'``, each transition
|
|
105
|
+
component is destroyed after its application, and the intermediate Hamiltonian
|
|
106
|
+
is rebuilt and destroyed for each nonzero seed's Lanczos calculation. At most
|
|
107
|
+
one factory-created matrix is alive at a time in this mode. Components with
|
|
108
|
+
zero polarization coefficients and Hamiltonians for zero seeds are skipped.
|
|
109
|
+
Both policies destroy factory-created matrices before returning, including on
|
|
110
|
+
failure; initial-state eigenvectors remain owned by the caller.
|
|
111
|
+
|
|
112
|
+
XAS and RIXS center factory-created distributed matrices using the lowest retained initial
|
|
113
|
+
energy and the first incident energy, which should lie near resonance. RIXS
|
|
114
|
+
also centers the final Hamiltonian. Spectra are evaluated on these relative
|
|
115
|
+
energies before restoring the original reference in returned pole dictionaries.
|
|
116
|
+
Factory-created Hamiltonians are shifted in place.
|
|
117
|
+
|
|
118
|
+
.. backend-options:: petsc xas
|
|
119
|
+
|
|
120
|
+
``rixs``
|
|
121
|
+
========
|
|
122
|
+
|
|
123
|
+
.. backend-options:: petsc rixs
|
|
124
|
+
|
|
125
|
+
The default solver is ``shifted_pminres``. ``linsys_tol`` sets KSP's absolute
|
|
126
|
+
tolerance, ``atol``, and the default relative tolerance is zero. Other KSP
|
|
127
|
+
types retain PETSc's default relative tolerance unless overridden through
|
|
128
|
+
its options database.
|
|
129
|
+
|
|
130
|
+
EDRIXS calls KSP's ``setFromOptions()`` after applying ``backend_kws``.
|
|
131
|
+
Corresponding PETSc options-database entries, such as ``ksp_atol``, ``ksp_rtol``,
|
|
132
|
+
``ksp_max_it``, and ``ksp_type``, take precedence over these settings.
|
|
133
|
+
|
|
134
|
+
``ksp_type`` accepts a PETSc KSP type such as ``'gmres'``; the available
|
|
135
|
+
algorithms and their tradeoffs are listed in the `KSP solver table
|
|
136
|
+
<https://petsc.org/release/manual/ksp/#tab-kspdefaults>`__.
|
|
137
|
+
|
|
138
|
+
To select GMRES instead of the default shifted PMINRES, pass::
|
|
139
|
+
|
|
140
|
+
backend_kws={'ksp_type': 'gmres', 'linsys_tol': 1e-10}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
.. _scipy-backend-options:
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
SciPy
|
|
5
|
-
|
|
3
|
+
**********************
|
|
4
|
+
SciPy backend settings
|
|
5
|
+
**********************
|
|
6
6
|
|
|
7
7
|
:doc:`Back to the backend overview <../backend>`
|
|
8
8
|
|
|
@@ -11,8 +11,15 @@ About this backend
|
|
|
11
11
|
|
|
12
12
|
The ``scipy`` backend builds operators as SciPy
|
|
13
13
|
`CSR matrices <https://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.csr_matrix.html>`__.
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
``build_op`` and ``get_ops`` return labeled factories that construct these
|
|
15
|
+
matrices when called. Pass the factories to public ``ed``, ``xas``, and ``rixs``;
|
|
16
|
+
the primary Hamiltonian's ``.backend`` label selects SciPy. The backend calls
|
|
17
|
+
each supplied factory at calculation start, including repeated arguments.
|
|
18
|
+
See :ref:`lazy-operators`.
|
|
19
|
+
|
|
20
|
+
The backend-specific ``ed_scipy``, ``xas_scipy``, and ``rixs_scipy`` functions
|
|
21
|
+
also require factories. These can return NumPy arrays, SciPy sparse matrices,
|
|
22
|
+
or a matrix-free
|
|
16
23
|
`LinearOperator <https://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.linalg.LinearOperator.html>`__.
|
|
17
24
|
ED uses SciPy's
|
|
18
25
|
`LOBPCG eigensolver <https://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.linalg.lobpcg.html>`__;
|
|
@@ -54,3 +61,7 @@ eigensolver tolerance accepted by ``ed``.
|
|
|
54
61
|
========
|
|
55
62
|
|
|
56
63
|
.. backend-options:: scipy rixs
|
|
64
|
+
|
|
65
|
+
``linsys_tol`` sets GMRES's relative tolerance, passed as ``rtol`` (or ``tol``
|
|
66
|
+
in older SciPy). With the ``rtol`` API, EDRIXS sets the absolute tolerance
|
|
67
|
+
``atol`` to zero.
|