CUDSS.jl documentation
Installation
julia> ]
+Home · CUDSS.jl CUDSS.jl documentation
For more details on using cuDSS, refer to the official cuDSS documentation.
Installation
julia> ]
pkg> add https://github.com/exanauts/CUDSS.jl.git
pkg> test CUDSS
Types
CUDSS.CudssMatrix
— Typematrix = CudssMatrix(v::CuVector)
matrix = CudssMatrix(A::CuMatrix)
-matrix = CudssMatrix(A::CuSparseMatrixCSR, struture::Union{Char, String}, view::Char; index::Char='O')
CudssMatrix
is a wrapper for CuVector
, CuMatrix
and CuSparseMatrixCSR
. CudssMatrix
is used to pass matrix of the linear system, as well as solution and right-hand side.
structure
specifies the stucture for sparse matrices:
'G'
or "G"
: General matrix – LDU factorization;'S'
or "S"
: Real symmetric matrix – LDLᵀ factorization;'H'
or "H"
: Complex Hermitian matrix – LDLᴴ factorization;"SPD"
: Symmetric positive-definite matrix – LLᵀ factorization;"HPD"
: Hermitian positive-definite matrix – LLᴴ factorization.
view
specifies matrix view for sparse matrices:
'L'
: Lower-triangular matrix and all values above the main diagonal are ignored;'U'
: Upper-triangular matrix and all values below the main diagonal are ignored;'F'
: Full matrix.
index
specifies indexing base for sparse matrix indices:
'Z'
: 0-based indexing;'O'
: 1-based indexing.
sourceCUDSS.CudssConfig
— Typeconfig = CudssConfig()
CudssConfig
stores configuration settings for the solver.
sourceCUDSS.CudssData
— Typedata = CudssData()
CudssData
holds internal data (e.g., LU factors arrays).
sourceCUDSS.CudssSolver
— Typesolver = CudssSolver(A::CuSparseMatrixCSR, structure::Union{Char, String}, view::Char; index::Char='O')
-solver = CudssSolver(matrix::CudssMatrix, config::CudssConfig, data::CudssData)
CudssSolver
contains all structures required to solve linear systems with cuDSS. One constructor of CudssSolver
takes as input the same parameters as CudssMatrix
.
structure
specifies the stucture for sparse matrices:
'G'
or "G"
: General matrix – LDU factorization;'S'
or "S"
: Real symmetric matrix – LDLᵀ factorization;'H'
or "H"
: Complex Hermitian matrix – LDLᴴ factorization;"SPD"
: Symmetric positive-definite matrix – LLᵀ factorization;"HPD"
: Hermitian positive-definite matrix – LLᴴ factorization.
view
specifies matrix view for sparse matrices:
'L'
: Lower-triangular matrix and all values above the main diagonal are ignored;'U'
: Upper-triangular matrix and all values below the main diagonal are ignored;'F'
: Full matrix.
index
specifies indexing base for sparse matrix indices:
'Z'
: 0-based indexing;'O'
: 1-based indexing.
CudssSolver
can be also constructed from the three structures CudssMatrix
, CudssConfig
and CudssData
if needed.
sourceFunctions
CUDSS.cudss_set
— Functioncudss_set(matrix::CudssMatrix, v::CuVector)
+matrix = CudssMatrix(A::CuSparseMatrixCSR, struture::Union{Char, String}, view::Char; index::Char='O')
CudssMatrix
is a wrapper for CuVector
, CuMatrix
and CuSparseMatrixCSR
. CudssMatrix
is used to pass matrix of the linear system, as well as solution and right-hand side.
structure
specifies the stucture for sparse matrices:
'G'
or "G"
: General matrix – LDU factorization;'S'
or "S"
: Real symmetric matrix – LDLᵀ factorization;'H'
or "H"
: Complex Hermitian matrix – LDLᴴ factorization;"SPD"
: Symmetric positive-definite matrix – LLᵀ factorization;"HPD"
: Hermitian positive-definite matrix – LLᴴ factorization.
view
specifies matrix view for sparse matrices:
'L'
: Lower-triangular matrix and all values above the main diagonal are ignored;'U'
: Upper-triangular matrix and all values below the main diagonal are ignored;'F'
: Full matrix.
index
specifies indexing base for sparse matrix indices:
'Z'
: 0-based indexing;'O'
: 1-based indexing.
sourceCUDSS.CudssConfig
— Typeconfig = CudssConfig()
CudssConfig
stores configuration settings for the solver.
sourceCUDSS.CudssData
— Typedata = CudssData()
CudssData
holds internal data (e.g., LU factors arrays).
sourceCUDSS.CudssSolver
— Typesolver = CudssSolver(A::CuSparseMatrixCSR, structure::Union{Char, String}, view::Char; index::Char='O')
+solver = CudssSolver(matrix::CudssMatrix, config::CudssConfig, data::CudssData)
CudssSolver
contains all structures required to solve linear systems with cuDSS. One constructor of CudssSolver
takes as input the same parameters as CudssMatrix
.
structure
specifies the stucture for sparse matrices:
'G'
or "G"
: General matrix – LDU factorization;'S'
or "S"
: Real symmetric matrix – LDLᵀ factorization;'H'
or "H"
: Complex Hermitian matrix – LDLᴴ factorization;"SPD"
: Symmetric positive-definite matrix – LLᵀ factorization;"HPD"
: Hermitian positive-definite matrix – LLᴴ factorization.
view
specifies matrix view for sparse matrices:
'L'
: Lower-triangular matrix and all values above the main diagonal are ignored;'U'
: Upper-triangular matrix and all values below the main diagonal are ignored;'F'
: Full matrix.
index
specifies indexing base for sparse matrix indices:
'Z'
: 0-based indexing;'O'
: 1-based indexing.
CudssSolver
can be also constructed from the three structures CudssMatrix
, CudssConfig
and CudssData
if needed.
sourceFunctions
CUDSS.cudss_set
— Functioncudss_set(matrix::CudssMatrix, v::CuVector)
cudss_set(matrix::CudssMatrix, A::CuMatrix)
cudss_set(matrix::CudssMatrix, A::CuSparseMatrixCSR)
cudss_set(data::CudssSolver, param::String, value)
cudss_set(config::CudssConfig, param::String, value)
-cudss_set(data::CudssData, param::String, value)
The available configuration parameters are:
"reordering_alg"
: Algorithm for the reordering phase;"factorization_alg"
: Algorithm for the factorization phase;"solve_alg"
: Algorithm for the solving phase;"matching_type"
: Type of matching;"solve_mode"
: Potential modificator on the system matrix (transpose or adjoint);"ir_n_steps"
: Number of steps during the iterative refinement;"ir_tol"
: Iterative refinement tolerance;"pivot_type"
: Type of pivoting ('C', 'R' or 'N');"pivot_threshold"
: Pivoting threshold which is used to determine if digonal element is subject to pivoting;"pivot_epsilon"
: Pivoting epsilon, absolute value to replace singular diagonal elements;"max_lu_nnz"
: Upper limit on the number of nonzero entries in LU factors for non-symmetric matrices.
The available data parameter is:
"user_perm"
: User permutation to be used instead of running the reordering algorithms.
sourceCUDSS.cudss_get
— Functionvalue = cudss_get(data::CudssSolver, param::String)
+cudss_set(data::CudssData, param::String, value)
The available configuration parameters are:
"reordering_alg"
: Algorithm for the reordering phase;"factorization_alg"
: Algorithm for the factorization phase;"solve_alg"
: Algorithm for the solving phase;"matching_type"
: Type of matching;"solve_mode"
: Potential modificator on the system matrix (transpose or adjoint);"ir_n_steps"
: Number of steps during the iterative refinement;"ir_tol"
: Iterative refinement tolerance;"pivot_type"
: Type of pivoting ('C', 'R' or 'N');"pivot_threshold"
: Pivoting threshold which is used to determine if digonal element is subject to pivoting;"pivot_epsilon"
: Pivoting epsilon, absolute value to replace singular diagonal elements;"max_lu_nnz"
: Upper limit on the number of nonzero entries in LU factors for non-symmetric matrices.
The available data parameter is:
"user_perm"
: User permutation to be used instead of running the reordering algorithms.
sourceCUDSS.cudss_get
— Functionvalue = cudss_get(data::CudssSolver, param::String)
value = cudss_get(config::CudssConfig, param::String)
-value = cudss_get(data::CudssData, param::String)
The available configuration parameters are:
"reordering_alg"
: Algorithm for the reordering phase;"factorization_alg"
: Algorithm for the factorization phase;"solve_alg"
: Algorithm for the solving phase;"matching_type"
: Type of matching;"solve_mode"
: Potential modificator on the system matrix (transpose or adjoint);"ir_n_steps"
: Number of steps during the iterative refinement;"ir_tol"
: Iterative refinement tolerance;"pivot_type"
: Type of pivoting ('C'
, 'R'
or 'N'
);"pivot_threshold"
: Pivoting threshold which is used to determine if digonal element is subject to pivoting;"pivot_epsilon"
: Pivoting epsilon, absolute value to replace singular diagonal elements;"max_lu_nnz"
: Upper limit on the number of nonzero entries in LU factors for non-symmetric matrices.
The available data parameters are:
"info"
: Device-side error information;"lu_nnz"
: Number of non-zero entries in LU factors;"npivots"
: Number of pivots encountered during factorization;"inertia"
: Tuple of positive and negative indices of inertia for symmetric and hermitian non positive-definite matrix types;"perm_reorder"
: Reordering permutation;"perm_row"
: Final row permutation (which includes effects of both reordering and pivoting);"perm_col"
: Final column permutation (which includes effects of both reordering and pivoting);"diag"
: Diagonal of the factorized matrix.
The data parameters "info"
, "lu_nnz"
and "perm_reorder"
require the phase "analyse"
performed by cudss
. The data parameters "npivots"
, "inertia"
and "diag"
require the phases "analyse"
and "factorization"
performed by cudss
. The data parameters "perm_row"
and "perm_col"
are available but not yet functional.
sourceCUDSS.cudss
— Functioncudss(phase::String, solver::CudssSolver, x::CuVector, b::CuVector)
+value = cudss_get(data::CudssData, param::String)
The available configuration parameters are:
"reordering_alg"
: Algorithm for the reordering phase;"factorization_alg"
: Algorithm for the factorization phase;"solve_alg"
: Algorithm for the solving phase;"matching_type"
: Type of matching;"solve_mode"
: Potential modificator on the system matrix (transpose or adjoint);"ir_n_steps"
: Number of steps during the iterative refinement;"ir_tol"
: Iterative refinement tolerance;"pivot_type"
: Type of pivoting ('C'
, 'R'
or 'N'
);"pivot_threshold"
: Pivoting threshold which is used to determine if digonal element is subject to pivoting;"pivot_epsilon"
: Pivoting epsilon, absolute value to replace singular diagonal elements;"max_lu_nnz"
: Upper limit on the number of nonzero entries in LU factors for non-symmetric matrices.
The available data parameters are:
"info"
: Device-side error information;"lu_nnz"
: Number of non-zero entries in LU factors;"npivots"
: Number of pivots encountered during factorization;"inertia"
: Tuple of positive and negative indices of inertia for symmetric and hermitian non positive-definite matrix types;"perm_reorder"
: Reordering permutation;"perm_row"
: Final row permutation (which includes effects of both reordering and pivoting);"perm_col"
: Final column permutation (which includes effects of both reordering and pivoting);"diag"
: Diagonal of the factorized matrix.
The data parameters "info"
, "lu_nnz"
and "perm_reorder"
require the phase "analyse"
performed by cudss
. The data parameters "npivots"
, "inertia"
and "diag"
require the phases "analyse"
and "factorization"
performed by cudss
. The data parameters "perm_row"
and "perm_col"
are available but not yet functional.
sourceCUDSS.cudss
— Functioncudss(phase::String, solver::CudssSolver, x::CuVector, b::CuVector)
cudss(phase::String, solver::CudssSolver, X::CuMatrix, B::CuMatrix)
-cudss(phase::String, solver::CudssSolver, X::CudssMatrix, B::CudssMatrix)
The available phases are "analysis"
, "factorization"
, "refactorization"
and "solve"
. The phases "solve_fwd"
, "solve_diag"
and "solve_bwd"
are available but not yet functional.
sourceSettings
This document was generated with Documenter.jl version 1.2.1 on Monday 4 December 2023. Using Julia version 1.9.4.
+cudss(phase::String, solver::CudssSolver, X::CudssMatrix, B::CudssMatrix)
The available phases are "analysis"
, "factorization"
, "refactorization"
and "solve"
. The phases "solve_fwd"
, "solve_diag"
and "solve_bwd"
are available but not yet functional.