20namespace nda::lapack {
51 template <MemoryVector DL, MemoryVector D, MemoryVector DU, MemoryArray B>
53 int gtsv(DL &&dl, D &&d, DU &&du, B &&b) {
54 static_assert((
get_rank<B> == 1 or
get_rank<B> == 2),
"Error in nda::lapack::gtsv: B must be a matrix/array/view of rank 1 or 2");
55 static_assert(
has_F_layout<B>,
"Error in nda::lapack::gtsv: B must have Fortran layout");
58 auto const n = d.size();
59 EXPECTS(dl.size() == n - 1);
60 EXPECTS(du.size() == n - 1);
61 EXPECTS(b.extent(0) == n);
65 f77::gtsv(n, (
get_rank<B> == 2 ? b.extent(1) : 1), dl.data(), d.data(), du.data(), b.data(),
get_ld(b), info);
Provides definitions and type traits involving the different memory address spaces supported by nda.
Provides concepts for the nda library.
Provides various convenient aliases and helper functions for nda::basic_array and nda::basic_array_vi...
constexpr bool have_same_value_type_v
Constexpr variable that is true if all types in As have the same value type as A0.
constexpr int get_rank
Constexpr variable that specifies the rank of an nda::Array or of a contiguous 1-dimensional range.
int gtsv(DL &&dl, D &&d, DU &&du, B &&b)
Interface to the LAPACK gtsv routine.
static constexpr bool have_host_compatible_addr_space
Constexpr variable that is true if all given types have an address space compatible with Host.
constexpr bool is_blas_lapack_v
Alias for nda::is_double_or_complex_v.
Provides a C++ interface for various LAPACK routines.
int get_ld(A const &a)
Get the leading dimension of an nda::MemoryArray with rank 1 or 2 for BLAS/LAPACK calls.
static constexpr bool has_F_layout
Constexpr variable that is true if the given nda::Array type has nda::F_layout.
Macros used in the nda library.
Provides type traits for the nda library.