This module defines a list of simple constants used throughout LightKrylov.
It also provides some utility functions related to let LightKrylov be aware
of any MPI-related information (e.g. rank of the current MPI process, dimension
of the MPI communicator, etc).
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| real(kind=dp), | public, | parameter | :: | atol_dp | = | 10.0_dp**(-precision(1.0_dp)) |
Absolute tolerance for double precision computations. |
| real(kind=sp), | public, | parameter | :: | atol_sp | = | 10.0_sp**(-precision(1.0_sp)) |
Absolute tolerance for single precision computations. |
| integer, | public, | parameter | :: | dp | = | selected_real_kind(15, 307) |
Double precision data type. |
| complex(kind=dp), | public, | parameter | :: | one_cdp | = | cmplx(1.0_dp, 0.0_dp, kind=dp) |
Complex-valued double precision one. |
| complex(kind=sp), | public, | parameter | :: | one_csp | = | cmplx(1.0_sp, 0.0_sp, kind=sp) |
Complex-valued single precision one. |
| complex(kind=sp), | public, | parameter | :: | one_im_cdp | = | cmplx(0.0_dp, 1.0_dp, kind=dp) |
Complex-valued double precision imaginary unit. |
| complex(kind=sp), | public, | parameter | :: | one_im_csp | = | cmplx(0.0_sp, 1.0_sp, kind=sp) |
Complex-valued single precision imaginary unit. |
| real(kind=dp), | public, | parameter | :: | one_rdp | = | 1.0_dp |
Real-valued double precision one. |
| real(kind=sp), | public, | parameter | :: | one_rsp | = | 1.0_sp |
Real-valued single precision one. |
| real(kind=dp), | public, | parameter | :: | rtol_dp | = | sqrt(atol_dp) |
Relative tolerance for double precision computations. |
| real(kind=sp), | public, | parameter | :: | rtol_sp | = | sqrt(atol_sp) |
Relative tolerance for single precision computations. |
| integer, | public, | parameter | :: | sp | = | selected_real_kind(6, 37) |
Single precision data type. |
| complex(kind=dp), | public, | parameter | :: | zero_cdp | = | cmplx(0.0_dp, 0.0_dp, kind=dp) |
Complex-valued double precision zero. |
| complex(kind=sp), | public, | parameter | :: | zero_csp | = | cmplx(0.0_sp, 0.0_sp, kind=sp) |
Complex-value single precision zero. |
| real(kind=dp), | public, | parameter | :: | zero_rdp | = | 0.0_dp |
Real-valued double precision zero. |
| real(kind=sp), | public, | parameter | :: | zero_rsp | = | 0.0_sp |
Real-valued single precision zero. |
Utility function to get the dimension of the communicator known to LightKrylov.
Utility function to get the rank of the current MPI process.
Utility function to determine whether the current MPI process can do I/O.
Utility function to inform LightKrylov of the MPI-communicator's dimension.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | c_size |
Dimension of the MPI communicator. |
Utility function to set the rank of the process doing I/O.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | rk |
Desired rank for the IO process. |
Utility function to set the rank of an MPI process.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | rank |
Desired rank identification. |