|
TDLS 0.4.0
Tiny Device-callable Linear Solvers
|
Index of every entry of an arrowhead matrix in its storage. More...
#include <storage_map.hpp>
Static Public Member Functions | |
| static TDLS_HOST_DEVICE constexpr bool | valid (const ArrowheadShape &s) noexcept |
| Whether a shape suits this storage and coupling: positive sizes, coupled rows inside the border (diagonal coupling) or coupling_row = 0 (dense coupling), a border and a coupling_row multiple of the block (Bsr), a dimension and a number of stored entries below 2^31. The checks cannot overflow, whatever the shape. | |
| static TDLS_HOST_DEVICE constexpr long long | wide_size (const ArrowheadShape &s) noexcept |
| Number of stored entries, in 64-bit arithmetic (the overflow check of valid()). | |
| TDLS_HOST_DEVICE static TDLS_FORCE_INLINE_GPU constexpr int | size (const ArrowheadShape &s) noexcept |
| Number of stored entries. | |
| TDLS_HOST_DEVICE static TDLS_FORCE_INLINE_GPU constexpr int | abb (const ArrowheadShape &s, const int r, const int c) noexcept |
| Border-border entry (r, c), r and c < border. | |
| TDLS_HOST_DEVICE static TDLS_FORCE_INLINE_GPU constexpr int | abk (const ArrowheadShape &s, const int k, const int r, const int i) noexcept |
| Coupling entry of border row r and unknown i of block k (dense coupling). | |
| TDLS_HOST_DEVICE static TDLS_FORCE_INLINE_GPU constexpr int | abk_diag (const ArrowheadShape &s, const int k, const int i) noexcept |
| Coupling entry of border row coupling_row + i and unknown i of block k (diagonal coupling). | |
| TDLS_HOST_DEVICE static TDLS_FORCE_INLINE_GPU constexpr int | akb (const ArrowheadShape &s, const int k, const int i, const int c) noexcept |
| Entry of row i of block k in border column c. | |
| TDLS_HOST_DEVICE static TDLS_FORCE_INLINE_GPU constexpr int | d (const ArrowheadShape &s, const int k, const int i, const int j) noexcept |
| Entry (i, j) of the diagonal block k. | |
| static TDLS_HOST_DEVICE constexpr bool | in_pattern (const ArrowheadShape &s, const int r, const int c) noexcept |
| Whether entry (r, c) of the full matrix belongs to the pattern. | |
| static TDLS_HOST_DEVICE constexpr void | csr_pattern (const ArrowheadShape &s, int *ptr, int *idx) noexcept |
| Writes the canonical compressed index arrays of the pattern: CSR (row pointers, column indices) under the row-major layout, CSC (column pointers, row indices) under the column-major one, minor indices in increasing order. Meaningful for the Csr storage. | |
| static TDLS_HOST_DEVICE constexpr void | bsr_pattern (const ArrowheadShape &s, int *ptr, int *idx) noexcept |
Writes the canonical block compressed index arrays, in square blocks of block entries: BSR by block rows under the row-major layout, BSC by block columns under the column-major one, minor block indices in increasing order. Meaningful for the Bsr storage. | |
Static Public Attributes | |
| static constexpr bool | diag = Coupling == ArrowheadCoupling::Diagonal |
| Whether the couplings are diagonal. | |
| static constexpr bool | col = Layout == MatrixLayout::ColMajor |
| Whether the matrix is stored by columns. | |
Index of every entry of an arrowhead matrix in its storage.
| Storage | storage of the matrix |
| Coupling | pattern of the couplings A_bk |
| Layout | order of the stored matrix, by rows or by columns |
|
inlinestaticnodiscardconstexprnoexcept |
Border-border entry (r, c), r and c < border.
| [in] | s | shape (valid) |
| [in] | r | border row |
| [in] | c | border column |
|
inlinestaticnodiscardconstexprnoexcept |
Coupling entry of border row r and unknown i of block k (dense coupling).
| [in] | s | shape (valid) |
| [in] | k | block |
| [in] | r | border row |
| [in] | i | unknown of the block |
|
inlinestaticnodiscardconstexprnoexcept |
Coupling entry of border row coupling_row + i and unknown i of block k (diagonal coupling).
| [in] | s | shape (valid) |
| [in] | k | block |
| [in] | i | unknown of the block |
|
inlinestaticnodiscardconstexprnoexcept |
Entry of row i of block k in border column c.
| [in] | s | shape (valid) |
| [in] | k | block |
| [in] | i | row of the block |
| [in] | c | border column |
|
inlinestaticconstexprnoexcept |
Writes the canonical block compressed index arrays, in square blocks of block entries: BSR by block rows under the row-major layout, BSC by block columns under the column-major one, minor block indices in increasing order. Meaningful for the Bsr storage.
| [in] | s | shape (valid, border a multiple of block) |
| [out] | ptr | border / block + blocks + 1 pointers |
| [out] | idx | size(s) / (block * block) minor block indices |
|
inlinestaticconstexprnoexcept |
Writes the canonical compressed index arrays of the pattern: CSR (row pointers, column indices) under the row-major layout, CSC (column pointers, row indices) under the column-major one, minor indices in increasing order. Meaningful for the Csr storage.
| [in] | s | shape (valid) |
| [out] | ptr | n + 1 pointers |
| [out] | idx | size(s) minor indices |
|
inlinestaticnodiscardconstexprnoexcept |
Entry (i, j) of the diagonal block k.
| [in] | s | shape (valid) |
| [in] | k | block |
| [in] | i | row of the block |
| [in] | j | column of the block |
|
inlinestaticnodiscardconstexprnoexcept |
Whether entry (r, c) of the full matrix belongs to the pattern.
| [in] | s | shape (valid) |
| [in] | r | row of the full matrix |
| [in] | c | column of the full matrix |
|
inlinestaticnodiscardconstexprnoexcept |
Number of stored entries.
| [in] | s | shape (valid) |
|
inlinestaticnodiscardconstexprnoexcept |
Whether a shape suits this storage and coupling: positive sizes, coupled rows inside the border (diagonal coupling) or coupling_row = 0 (dense coupling), a border and a coupling_row multiple of the block (Bsr), a dimension and a number of stored entries below 2^31. The checks cannot overflow, whatever the shape.
| [in] | s | shape |
|
inlinestaticnodiscardconstexprnoexcept |
Number of stored entries, in 64-bit arithmetic (the overflow check of valid()).
| [in] | s | shape of positive sizes and of dimension below 2^31, which bounds the result by 2 n^2 < 2^63 |