Skip to main content

@anchor LinearSolversApplicationMainPage

LinearSolversApplication

The LinearSolversApplication is a thin wrapper for the Eigen linear algebra library.

Direct sparse solvers

The application provides the following direct sparse solvers:

Python class solver_type Matrix kind Domain Dependencies
SparseLUSolver sparse_lu Square Real None
SparseQRSolver sparse_qr Rectangular Real None
SparseCGSolver sparse_cg SPD* Real None
PardisoLLTSolver pardiso_llt SPD* Real Intel® MKL
PardisoLDLTSolver pardiso_ldlt SPD* Real Intel® MKL
PardisoLUSolver pardiso_lu Square Real Intel® MKL
ComplexSparseLUSolver sparse_lu_complex Square Complex None
ComplexPardisoLLTSolver pardiso_llt_complex SPD* Complex Intel® MKL
ComplexPardisoLDLTSolver pardiso_ldlt_complex SPD* Complex Intel® MKL
ComplexPardisoLUSolver pardiso_lu_complex Square Complex Intel® MKL
CholmodSolver cholmod SPD* Real SuiteSparse
UmfPackSolver umfpack Square Real SuiteSparse
ComplexUmfPackSolver umfpack_complex Square Complex SuiteSparse
SPQRSolver spqr Rectangular Real SuiteSparse
ComplexSPQRSolver spqr_complex Rectangular Complex SuiteSparse

*SPD = Symmetric Positive Definite

Example:

{
    "solver_type": "eigen_sparse_lu"
}

Direct dense solvers

The application provides the following direct solvers for dense systems of equations:

Python class solver_type Matrix requirements Domain Dependencies
DenseColPivHouseholderQRSolver** dense_col_piv_householder_qr None Real None
DenseHouseholderQRSolver** dense_householder_qr None Real None
DenseLLTSolver** dense_llt SPD* Real None
DensePartialPivLUSolver** dense_partial_piv_lu Invertible Real None
ComplexDenseColPivHouseholderQRSolver complex_dense_col_piv_householder_qr None Complex None
ComplexDenseHouseholderQRSolver complex_dense_householder_qr None Complex None
ComplexDensePartialPivLUSolver complex_dense_partial_piv_lu Invertible Complex None

*SPD = Symmetric Positive Definite

**Can also be used to solve equation systems with multiple right hand sides.

Generalized eigensystem solvers

The application provides the following generalized eigensystem Ax=λBx solver for sparse matrices.

Python class solver_type Matrix kind A Matrix kind B Domain Dependencies
EigensystemSolver eigen_eigensystem Symmetric SPD* Real None
SpectraSymGEigsShiftSolver spectra_sym_g_eigs_shift Symmetric SPD* Real None
FEASTGeneralEigensystemSolver** feast General General Real Intel® MKL
ComplexFEASTGeneralEigensystemSolver** feast_complex General General Complex Intel® MKL

*SPD = Symmetric Positive Definite **A special version for symmetric matrices can be triggered in the solver settings.

EigensystemSolver and SpectraSymGEigsShiftSolver compute the smallest eigenvalues and corresponding eigenvectors of the system. MKL routines are used automatically if they are available.

SpectraSymGEigsShiftSolver interfaces a solver from the Spectra library, and has a shift mode that can be used to compute the smallest eigenvalues > shift.

Example:

{
    "solver_type": "spectra_sym_g_eigs_shift",
    "number_of_eigenvalues": 3,
    "max_iteration": 1000,
    "echo_level": 1
}

If the application is compiled with MKL, FEAST 4.0 can be used to solve the generalized eigenvalue problem for real and complex systems (symmetric or unsymmetric). The cmake switch USE_EIGEN_FEAST must be set to ON with

-DUSE_EIGEN_FEAST=ON \

Example:

{
    "solver_type": "feast",
    "symmetric": true,
    "number_of_eigenvalues": 3,
    "search_lowest_eigenvalues": true,
    "e_min" : 0.0,
    "e_max" : 0.2
}

Build instructions

  1. Set the required definitions for cmake

    As any other app:

    Windows: in configure.bat

    set KRATOS_APPLICATIONS=%KRATOS_APPLICATIONS%%KRATOS_APP_DIR%\LinearSolversApplication;
    

    Linux: in configure.sh

    add_app ${KRATOS_APP_DIR}/LinearSolversApplication
    
  2. Build Kratos

  3. Setup the ProjectParameters.json

    "linear_solver_settings": {
        "solver_type" : "LinearSolversApplication.sparse_lu"
    }
    
  4. Run the simulation

Enable MKL (optional)

In case you have installed MKL (see below), you can also use the Pardiso solvers.

  1. Run the MKL setup script before building Kratos:

    Windows:

    call "C:\Program Files (x86)\Intel\oneAPI\mkl\latest\env\vars.bat" intel64 lp64
    

    Linux:

    source /opt/intel/oneapi/setvars.sh intel64
    
  2. Add the following flag to CMake to your configure script:

    Windows:

    -DUSE_EIGEN_MKL=ON ^
    

    Linux:

    -DUSE_EIGEN_MKL=ON \
    
  3. Build Kratos

  4. Usage:

    Windows:

    call "C:\Program Files (x86)\Intel\oneAPI\mkl\latest\env\vars.bat" intel64 lp64
    

    Linux:

    Set the environment before using MKL

    source /opt/intel/oneapi/setvars.sh intel64
    

Install MKL on Ubuntu with apt

Intel MKL can be installed with apt on Ubuntu. A guide can be found in here. For example to install the MKL 2022 version

sudo bash
# <type your user password when prompted.  this will put you in a root shell>
# If they are not installed, you can install using the following command:
sudo apt update
sudo apt -y install cmake pkg-config build-essential
# use wget to fetch the Intel repository public key
wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
# add to your apt sources keyring so that archives signed with this key will be trusted.
sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
# remove the public key
rm GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
# Configure apt client to use Intel repository
sudo add-apt-repository "deb https://apt.repos.intel.com/oneapi all main"
# Install all MKL related dependencies. You can install full HPC with: sudo apt install intel-hpckit
sudo apt install intel-oneapi-mkl-devel
# Exit
exit

To enable the MKL environment (needs to be done before build/run) use

source /opt/intel/oneapi/setvars.sh intel64

Enable SuiteSparse (optional)

SuiteSparse is a collection of open-source sparse matrix algorithms, including efficient implementations of various factorizations. Kratos currently provides wrappers for CHOLMOD, UMFPACK, and SPQR.

Install the SuiteSparse package on your system, and set the USE_EIGEN_SUITESPARSE flag in your CMake configuration to ON. One way of doing this is appending the list of arguments you pass to CMake in your configure script with:

-DUSE_EIGEN_SUITESPARSE:BOOL=ON

Installing SuiteSparse

  • Arch Linux

    • SuiteSparse is available through your package manager.
    • sudo pacman -S suitesparse
  • Debian (and derivatives, including Ubuntu)

    • SuiteSparse is available through your package manager.
    • sudo apt install libsuitesparse-dev
  • Fedora (and derivatives, including RHEL)

    • SuiteSparse is available through your package manager.
    • sudo dnf install suitesparse-devel
  • MacOS

    • SuiteSparse is available on Homebrew for both Intel and Apple Silicon machines.
    • brew install suite-sparse
  • Windows

    • SuiteSparse is available through vcpkg and MSYS2 package managers.
    • vcpkg install suitesparse suitesparse-spqr suitesparse-umfpack (remember to add to build script -DCMAKE_TOOLCHAIN_FILE="vcpkg_path\vcpkg\scripts\buildsystems\vcpkg.cmake")
    • pacman -S mingw-w64-x86_64-suitesparse

Metadata

Release files for KratosLinearSolversApplication 10.4.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for KratosLinearSolversApplication 10.4.4
File
kratoslinearsolversapplication-10.4.4-py3-none-any.whl Python 3 none any Details
kratoslinearsolversapplication-10.4.4-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp314-cp314-manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.28+ x86-64 Details
kratoslinearsolversapplication-10.4.4-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp313-cp313-manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ x86-64 Details
kratoslinearsolversapplication-10.4.4-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp312-cp312-manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.28+ x86-64 Details
kratoslinearsolversapplication-10.4.4-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp311-cp311-manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.28+ x86-64 Details
kratoslinearsolversapplication-10.4.4-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp310-cp310-manylinux_2_28_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.28+ x86-64 Details
kratoslinearsolversapplication-10.4.4-cp39-cp39-win_amd64.whl CPython 3.9 CPython 3.9 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp39-cp39-manylinux_2_28_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.28+ x86-64 Details
kratoslinearsolversapplication-10.4.4-cp38-cp38-win_amd64.whl CPython 3.8 CPython 3.8 Windows x86-64 Details
kratoslinearsolversapplication-10.4.4-cp38-cp38-manylinux_2_28_x86_64.whl CPython 3.8 CPython 3.8 Linux glibc 2.28+ x86-64 Details

Total release size: 52.5 MB

Release files / kratoslinearsolversapplication-10.4.4-py3-none-any.whl

Download URL kratoslinearsolversapplication-10.4.4-py3-none-any.whl
Size 25.0 MB
Tags Python 3
SHA-256 checksum
How to use checksums
287e0fbdaf60c9feb4401272e2f17f6730bb04d727f5f57d209a29fc3a31e0c8
BLAKE2b-256 checksum
How to use checksums
62709137f2cec6c596cd75cf6d39881a1ccd5d47ef09b64290916ba15d559651
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Release files / kratoslinearsolversapplication-10.4.4-cp314-cp314-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp314-cp314-win_amd64.whl
Size 957.3 kB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
739338194c116c0eedf1d4d115b160d722e05be538717b5c6d5c549e7a3bbaaa
BLAKE2b-256 checksum
How to use checksums
dbdead560c4aef07430e0ba8e553932bada77169fab6d0c9d4663c0dbebe99ba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp314-cp314-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp314-cp314-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.14 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
989b8aba0d7259bba4d9b747d3a50ff38cb4ac40748d39e38f772d9933bf9c2f
BLAKE2b-256 checksum
How to use checksums
974e0751a25ba6ea9e962d46dcef8fca429d4ed7932dd52da5f14d2a3c6cf6ee
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp313-cp313-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp313-cp313-win_amd64.whl
Size 928.5 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
4fda64258071be1d6026b46118b2057f4818ea3b42c4fc2f7c18afa73bdce681
BLAKE2b-256 checksum
How to use checksums
12580a6260e625542be29d6f98acfba2ec2e4c1778d33f19181bf841227f9fb8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp313-cp313-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp313-cp313-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.13 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
7efc72bb25124670a5dde2fc98bd1997957d27c27fdb0e9c2336391553ae7638
BLAKE2b-256 checksum
How to use checksums
37667227e7d2afb0274fe2262839cec62de4b697be4780d7cb02cba70745f293
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp312-cp312-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp312-cp312-win_amd64.whl
Size 928.5 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
304bb579d67b74a6f7757d4fcec867de2b2f24955ff8971c649681e0955e532b
BLAKE2b-256 checksum
How to use checksums
1fa88e2aafecf1e5b5cb2b80ae1375b19b9fbf69d0ad84ab349775a1a819e5b3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp312-cp312-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp312-cp312-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.12 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
fda6b33d856dd580c1d1d515aef20b1562a430d95582ccf75a9f302f7b9598b0
BLAKE2b-256 checksum
How to use checksums
16c0d276b02da9d61d7097b8882c5888532346e5ab70493fb117f83cacb91104
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp311-cp311-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp311-cp311-win_amd64.whl
Size 926.6 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
223aff6037e1e50bcb791ef90934f92ea2f189c2fd55dd99ac315ea2ecadf5ef
BLAKE2b-256 checksum
How to use checksums
d81ac37497222e85118a1bfee65b2adb3460385ef1f032260f719813fe820457
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp311-cp311-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp311-cp311-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
cd86b563ef9a1602140f7db4e2dcd8d3ed1c08de4f9a8aec3c04bdd5d66e5e6f
BLAKE2b-256 checksum
How to use checksums
467e11e7454538fc3ba07657c9f514b262b992a17e76e8b2c93209c08b1bb09d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp310-cp310-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp310-cp310-win_amd64.whl
Size 926.3 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
d3f3bf6231887dc3132551249845ef699c91d2d75d794e04cc2428145b624b14
BLAKE2b-256 checksum
How to use checksums
bf79738859bda1d4a3126b5280fb81e760c11ab9506925e98f926a049a41ecf0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp310-cp310-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp310-cp310-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.10 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
2c0731c71a1c314601c330805cc46b3ae8b0ce4f3b598dd5b4cd6a4088b5c969
BLAKE2b-256 checksum
How to use checksums
166b5a4cd2847331a74d7850ff4d32b9ce7aa999a8142a1cc44679a4bf2e44ff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp39-cp39-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp39-cp39-win_amd64.whl
Size 922.0 kB
Tags CPython 3.9 Windows x86-64
SHA-256 checksum
How to use checksums
665c357f4b96b617fe5408f333c42e3e1d03b1a3ba7cf620461783a81d885b01
BLAKE2b-256 checksum
How to use checksums
7d2d0c3cf2127fe86586e714d432f4569664d53b3e5ce834d6855602e95f0b78
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp39-cp39-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp39-cp39-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.9 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
4fcacc603ffc583e270f9ea6444eecdbc89a90e6b2b01826ba3e36481ead7dfa
BLAKE2b-256 checksum
How to use checksums
5182f153812286d48d63d4271e9183e13fa80be269142fc7f859782e2d67a73d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp38-cp38-win_amd64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp38-cp38-win_amd64.whl
Size 926.3 kB
Tags CPython 3.8 Windows x86-64
SHA-256 checksum
How to use checksums
985ea5699facaabdce98d1ace10339bedea6e6af5f0e663aaa3c1e868b3aef93
BLAKE2b-256 checksum
How to use checksums
f4d14fa9f16f962378a44684ff723fd70f4bd3141c3522c88fae82361eb8a71c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / kratoslinearsolversapplication-10.4.4-cp38-cp38-manylinux_2_28_x86_64.whl

Download URL kratoslinearsolversapplication-10.4.4-cp38-cp38-manylinux_2_28_x86_64.whl
Size 3.0 MB
Tags CPython 3.8 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
d95f376839c72e6f8d1fc385be2b6628bc2c15556d3ce926dd8bfcd8fb02b042
BLAKE2b-256 checksum
How to use checksums
29a3dbd1270c827b03f943b6bdc493735a370ae1c7f4c5ad74e6f362801b17ad
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release history Release notifications | RSS feed

This release

10.4.4 This release

15 release files

10.2.2

6 release files

10.2.0

5 release files

9.5.2

10 release files

9.5.1

10 release files

9.5

10 release files

9.4.6

4 release files

9.4.5

8 release files

9.4.4

8 release files

9.4.3

8 release files

9.4.2

8 release files

9.4.1

8 release files

9.4

8 release files

9.3.2

8 release files

9.3.1

8 release files

9.3

8 release files

9.2.2

5 release files

9.2.1

10 release files

9.2.0

10 release files

9.1.4

9 release files

9.1.2

9 release files

9.1.1

4 release files

9.1.0

9 release files

9.0.3

5 release files

9.0.2

9 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page