Namespaces
Variants

Standard library header <linalg> (C++26)

From cppreference.net
Standard library headers

이 헤더는 numeric 라이브러리의 일부입니다.

목차

클래스

네임스페이스에 정의됨 std::linalg
std::mdspan 하나의 삼각형에 있는 항목만 압축된 연속 형식으로 저장하는 정사각 행렬을 나타내는 레이아웃 매핑 정책
(클래스 템플릿)
std::mdspan 접근자 정책으로, 고정된 스케일링 인자와 중첩된 std::mdspan 접근자의 참조를 곱한 값을 참조로 표현함
(클래스 템플릿)
std::mdspan 접근자 정책으로, 참조가 중첩된 std::mdspan 접근자의 참조에 대한 복소 공액을 나타냄
(클래스 템플릿)
std::mdspan 모든 고유 레이아웃 매핑 정책의 가장 오른쪽 두 인덱스, 범위, 스트라이드를 교환하는 레이아웃 매핑 정책
(클래스 템플릿)

태그

네임스페이스에 정의됨 std::linalg
std::mdspan 내 요소들의 순서와 linalg::layout_blas_packed 레이아웃을 설명합니다
(태그)
행렬의 상삼각 부분 또는 하삼각 부분에 알고리즘 및 기타 사용자가 접근해야 하는지 지정합니다
(태그)
알고리즘이 행렬의 대각선 원소에 접근해야 하는지 여부를 지정
(태그)

함수

정의된 네임스페이스 std::linalg
제자리 변환
(C++26)
주어진 std::mdspan 의 해당 요소와 스케일링 인자의 요소별 곱으로 계산된 새로운 읽기 전용 std::mdspan 을 반환합니다
(함수 템플릿)
(C++26)
주어진 std::mdspan 의 해당 요소들의 켤레 복소수를 요소로 갖는 새로운 읽기 전용 std::mdspan 을 반환합니다
(함수 템플릿)
(C++26)
주어진 std::mdspan 의 전치 행렬을 나타내는 새로운 std::mdspan 을 반환합니다
(함수 템플릿)
객체의 켤레 전치 뷰를 반환합니다
(함수 템플릿)
BLAS 1 함수
평면 회전 생성
(함수 템플릿)
벡터에 평면 회전을 적용
(함수 템플릿)
행렬 또는 벡터의 모든 대응하는 요소들을 교환
(함수 템플릿)
(C++26)
행렬이나 벡터를 스칼라 곱셈의 요소별 연산 결과로 덮어씁니다
(함수 템플릿)
(C++26)
한 행렬 또는 벡터의 요소들을 다른 행렬 또는 벡터로 복사합니다
(함수 템플릿)
(C++26)
벡터나 행렬을 요소별로 더함
(함수 템플릿)
(C++26)
두 벡터의 비켤레 내적을 반환합니다
(함수 템플릿)
(C++26)
두 벡터의 켤레 내적을 반환합니다
(함수 템플릿)
벡터 요소들의 제곱합에 스케일을 적용한 값을 반환합니다
(함수 템플릿)
벡터의 유클리드 노름을 반환
(함수 템플릿)
벡터 요소들의 절댓값 합을 반환합니다
(함수 템플릿)
벡터 요소의 최대 절댓값 인덱스를 반환
(함수 템플릿)
행렬의 프로베니우스 놈을 반환합니다
(함수 템플릿)
행렬의 1-노름을 반환합니다
(함수 템플릿)
행렬의 무한대 노름을 반환합니다
(함수 템플릿)
BLAS 2 함수
행렬-벡터 곱을 계산함
(함수 템플릿)
대칭 행렬-벡터 곱을 계산함
(함수 템플릿)
에르미트 행렬-벡터 곱을 계산함
(함수 템플릿)
삼각 행렬-벡터 곱을 계산함
(함수 템플릿)
삼각 선형 시스템을 해결합니다
(함수 템플릿)
행렬의 비대칭 비켤레 복소수 rank-1 업데이트를 수행합니다
(함수 템플릿)
행렬의 비대칭 켤레 rank-1 업데이트를 수행합니다
(함수 템플릿)
대칭 행렬의 랭크-1 업데이트를 수행합니다
(함수 템플릿)
에르미트 행렬의 랭크-1 갱신을 수행합니다
(함수 템플릿)
에르미트 행렬의 랭크-2 업데이트를 수행합니다
(함수 템플릿)
에르미트 행렬의 랭크-2 업데이트를 수행합니다
(함수 템플릿)
BLAS 3 함수
행렬-행렬 곱을 계산함
(함수 템플릿)
대칭 행렬-행렬 곱을 계산함
(함수 템플릿)
Hermitian 행렬-행렬 곱을 계산합니다
(함수 템플릿)
삼각 행렬-행렬 곱을 계산합니다
(함수 템플릿)
대칭 행렬의 rank-k 업데이트를 수행합니다
(함수 템플릿)
에르미트 행렬의 랭크-k 업데이트를 수행합니다
(함수 템플릿)
대칭 행렬의 rank-2k 업데이트를 수행합니다
(함수 템플릿)
에르미트 행렬의 rank-2k 업데이트를 수행합니다
(함수 템플릿)
다중 삼각 선형 시스템을 해결
(함수 템플릿)

시놉시스

namespace std::linalg {
// 저장 순서 태그
struct column_major_t;
inline constexpr column_major_t column_major;
struct row_major_t;
inline constexpr row_major_t row_major;
// 삼각형 태그
struct upper_triangle_t;
inline constexpr upper_triangle_t upper_triangle;
struct lower_triangle_t;
inline constexpr lower_triangle_t lower_triangle;
// 대각선 태그
struct implicit_unit_diagonal_t;
inline constexpr implicit_unit_diagonal_t implicit_unit_diagonal;
struct explicit_diagonal_t;
inline constexpr explicit_diagonal_t explicit_diagonal;
// class template layout_blas_packed
template<class Triangle, class StorageOrder>
class layout_blas_packed;
// exposition-only concepts and traits
template<class T>
struct __is_mdspan; // 설명 전용
template<class T>
concept __in_vector = /* 설명 참조 */; // 설명 전용
template<class T>
concept __out_vector = /* 설명 참조 */; // 설명 전용
template<class T>
concept __inout_vector = /* 설명 참조 */; // 설명 전용
template<class T>
concept __in_matrix = /* 설명 참조 */; // 설명 전용
template<class T>
concept __out_matrix = /* 설명 참조 */; // 설명 전용
template<class T>
concept __inout_matrix = /* 설명 참조 */; // 설명 전용
template<class T>
concept __possibly_packed_inout_matrix = /* 설명 참조 */; // 설명 전용
template<class T>
concept __in_object = /* 설명 참조 */; // 설명 전용
template<class T>
concept __out_object = /* 설명 참조 */; // 설명 전용
template<class T>
concept __inout_object = /* 설명 참조 */; // 설명 전용
// 스케일된 인플레이스 변환
template<class ScalingFactor, class Accessor>
class scaled_accessor;
template<class ScalingFactor,
         class ElementType, class Extents, class Layout, class Accessor>
constexpr auto scaled(ScalingFactor scaling_factor,
                      mdspan<ElementType, Extents, Layout, Accessor> x);
// 제자리에서 수행되는 켤레 변환
template<class Accessor>
class conjugated_accessor;
template<class ElementType, class Extents, class Layout, class Accessor>
constexpr auto conjugated(mdspan<ElementType, Extents, Layout, Accessor> a);
// 전치 제자리 변환
template<class Layout>
class layout_transpose;
template<class ElementType, class Extents, class Layout, class Accessor>
constexpr auto transposed(mdspan<ElementType, Extents, Layout, Accessor> a);
// 켤레 전치 제자리 변환
template<class ElementType, class Extents, class Layout, class Accessor>
constexpr auto conjugate_transposed(mdspan<ElementType, Extents, Layout, Accessor> a);
// 알고리즘
// Givens 회전 계산
template<class Real>
struct setup_givens_rotation_result {
  Real c;
  Real s;
  Real r;
};
template<class Real>
struct setup_givens_rotation_result<complex<Real>> {
  Real c;
  complex<Real> s;
  complex<Real> r;
};
template<class Real>
setup_givens_rotation_result<Real> setup_givens_rotation(Real a, Real b) noexcept;
template<class Real>
setup_givens_rotation_result<complex<Real>>
setup_givens_rotation(complex<Real> a, complex<Real> b) noexcept;
// 계산된 기븐스 회전 적용
template<__inout_vector InOutVec1, __inout_vector InOutVec2, class Real>
void apply_givens_rotation(InOutVec1 x, InOutVec2 y, Real c, Real s);
template<class ExecutionPolicy,
         __inout_vector InOutVec1, __inout_vector InOutVec2, class Real>
void apply_givens_rotation(ExecutionPolicy&& exec,
                           InOutVec1 x, InOutVec2 y, Real c, Real s);
template<__inout_vector InOutVec1, __inout_vector InOutVec2, class Real>
void apply_givens_rotation(InOutVec1 x, InOutVec2 y, Real c, complex<Real> s);
template<class ExecutionPolicy,
         __inout_vector InOutVec1, __inout_vector InOutVec2, class Real>
void apply_givens_rotation(ExecutionPolicy&& exec,
                           InOutVec1 x, InOutVec2 y, Real c, complex<Real> s);
// 요소 교환
template<__inout_object InOutObj1, __inout_object InOutObj2>
void swap_elements(InOutObj1 x, InOutObj2 y);
template<class ExecutionPolicy, __inout_object InOutObj1, __inout_object InOutObj2>
void swap_elements(ExecutionPolicy&& exec, InOutObj1 x, InOutObj2 y);
// 요소에 스칼라 곱하기
template<class Scalar, __inout_object InOutObj>
void scale(Scalar alpha, InOutObj x);
template<class ExecutionPolicy, class Scalar, __inout_object InOutObj>
void scale(ExecutionPolicy&& exec, Scalar alpha, InOutObj x);
// 요소 복사
template<__in_object InObj, __out_object OutObj>
void copy(InObj x, OutObj y);
template<class ExecutionPolicy, __in_object InObj, __out_object OutObj>
void copy(ExecutionPolicy&& exec, InObj x, OutObj y);
// 요소별 덧셈
template<__in_object InObj1, __in_object InObj2, __out_object OutObj>
void add(InObj1 x, InObj2 y, OutObj z);
template<class ExecutionPolicy,
         __in_object InObj1, __in_object InObj2, __out_object OutObj>
void add(ExecutionPolicy&& exec, InObj1 x, InObj2 y, OutObj z);
// 두 벡터의 비켤레 내적
template<__in_vector InVec1, __in_vector InVec2, class Scalar>
Scalar dot(InVec1 v1, InVec2 v2, Scalar init);
template<class ExecutionPolicy,
         __in_vector InVec1, __in_vector InVec2, class Scalar>
Scalar dot(ExecutionPolicy&& exec, InVec1 v1, InVec2 v2, Scalar init);
template<__in_vector InVec1, __in_vector InVec2>
auto dot(InVec1 v1, InVec2 v2) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_vector InVec1, __in_vector InVec2>
auto dot(ExecutionPolicy&& exec, InVec1 v1, InVec2 v2) -> /* 설명 참조 */;
// 두 벡터의 켤레 내적
template<__in_vector InVec1, __in_vector InVec2, class Scalar>
Scalar dotc(InVec1 v1, InVec2 v2, Scalar init);
template<class ExecutionPolicy,
         __in_vector InVec1, __in_vector InVec2, class Scalar>
Scalar dotc(ExecutionPolicy&& exec, InVec1 v1, InVec2 v2, Scalar init);
template<__in_vector InVec1, __in_vector InVec2>
auto dotc(InVec1 v1, InVec2 v2) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_vector InVec1, __in_vector InVec2>
auto dotc(ExecutionPolicy&& exec, InVec1 v1, InVec2 v2) -> /* 설명 참조 */;
// 벡터 요소들의 제곱합 스케일링
template<class Scalar>
struct sum_of_squares_result {
  Scalar scaling_factor;
  Scalar scaled_sum_of_squares;
};
template<__in_vector InVec, class Scalar>
sum_of_squares_result<Scalar>
vector_sum_of_squares(InVec v, sum_of_squares_result<Scalar> init);
template<class ExecutionPolicy, __in_vector InVec, class Scalar>
sum_of_squares_result<Scalar>
vector_sum_of_squares(ExecutionPolicy&& exec, InVec v,
                      sum_of_squares_result<Scalar> init);
// 벡터의 유클리드 노름
template<__in_vector InVec, class Scalar>
Scalar vector_two_norm(InVec v, Scalar init);
template<class ExecutionPolicy, __in_vector InVec, class Scalar>
Scalar vector_two_norm(ExecutionPolicy&& exec, InVec v, Scalar init);
template<__in_vector InVec>
auto vector_two_norm(InVec v) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_vector InVec>
auto vector_two_norm(ExecutionPolicy&& exec, InVec v) -> /* 설명 참조 */;
// 벡터 요소들의 절댓값 합
template<__in_vector InVec, class Scalar>
Scalar vector_abs_sum(InVec v, Scalar init);
template<class ExecutionPolicy, __in_vector InVec, class Scalar>
Scalar vector_abs_sum(ExecutionPolicy&& exec, InVec v, Scalar init);
template<__in_vector InVec>
auto vector_abs_sum(InVec v) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_vector InVec>
auto vector_abs_sum(ExecutionPolicy&& exec, InVec v) -> /* 설명 참조 */;
// 벡터 요소의 최대 절대값 인덱스
template<__in_vector InVec>
typename InVec::extents_type vector_idx_abs_max(InVec v);
template<class ExecutionPolicy, __in_vector InVec>
typename InVec::extents_type vector_idx_abs_max(ExecutionPolicy&& exec, InVec v);
// 행렬의 프로베니우스 놈
template<__in_matrix InMat, class Scalar>
Scalar matrix_frob_norm(InMat A, Scalar init);
template<class ExecutionPolicy, __in_matrix InMat, class Scalar>
Scalar matrix_frob_norm(ExecutionPolicy&& exec,
                        InMat A, Scalar init);
template<__in_matrix InMat>
auto matrix_frob_norm(InMat A) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_matrix InMat>
auto matrix_frob_norm(ExecutionPolicy&& exec, InMat A) -> /* 설명 참조 */;
// 행렬의 1-노름
template<__in_matrix InMat, class Scalar>
Scalar matrix_one_norm(InMat A, Scalar init);
template<class ExecutionPolicy, __in_matrix InMat, class Scalar>
Scalar matrix_one_norm(ExecutionPolicy&& exec,
                       InMat A, Scalar init);
template<__in_matrix InMat>
auto matrix_one_norm(InMat A) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_matrix InMat>
auto matrix_one_norm(ExecutionPolicy&& exec, InMat A) -> /* 설명 참조 */;
// 행렬의 무한대 노름
template<__in_matrix InMat, class Scalar>
Scalar matrix_inf_norm(InMat A, Scalar init);
template<class ExecutionPolicy, __in_matrix InMat, class Scalar>
Scalar matrix_inf_norm(ExecutionPolicy&& exec,
                       InMat A, Scalar init);
template<__in_matrix InMat>
auto matrix_inf_norm(InMat A) -> /* 설명 참조 */;
template<class ExecutionPolicy, __in_matrix InMat>
auto matrix_inf_norm(ExecutionPolicy&& exec, InMat A) -> /* 설명 참조 */;
// 일반적인 행렬-벡터 곱
template<__in_matrix InMat, __in_vector InVec, __out_vector OutVec>
void matrix_vector_product(InMat A, InVec x, OutVec y);
template<class ExecutionPolicy,
         __in_matrix InMat, __in_vector InVec, __out_vector OutVec>
void matrix_vector_product(ExecutionPolicy&& exec,
                           InMat A, InVec x, OutVec y);
template<__in_matrix InMat, __in_vector InVec1,
         __in_vector InVec2, __out_vector OutVec>
void matrix_vector_product(InMat A, InVec1 x, InVec2 y, OutVec z);
template<class ExecutionPolicy,
         __in_matrix InMat, __in_vector InVec1,
         __in_vector InVec2, __out_vector OutVec>
void matrix_vector_product(ExecutionPolicy&& exec,
                           InMat A, InVec1 x, InVec2 y, OutVec z);
// 대칭 행렬-벡터 곱
template<__in_matrix InMat, class Triangle,
         __in_vector InVec, __out_vector OutVec>
void symmetric_matrix_vector_product(InMat A, Triangle t,
                                     InVec x, OutVec y);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle,
         __in_vector InVec, __out_vector OutVec>
void symmetric_matrix_vector_product(ExecutionPolicy&& exec,
                                     InMat A, Triangle t,
                                     InVec x, OutVec y);
template<__in_matrix InMat, class Triangle,
         __in_vector InVec1, __in_vector InVec2,
         __out_vector OutVec>
void symmetric_matrix_vector_product(InMat A, Triangle t,
                                     InVec1 x, InVec2 y, OutVec z);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle,
         __in_vector InVec1, __in_vector InVec2,
         __out_vector OutVec>
void symmetric_matrix_vector_product(ExecutionPolicy&& exec,
                                     InMat A, Triangle t,
                                     InVec1 x, InVec2 y, OutVec z);
// 에르미트 행렬-벡터 곱
template<__in_matrix InMat, class Triangle,
         __in_vector InVec, __out_vector OutVec>
void hermitian_matrix_vector_product(InMat A, Triangle t,
                                     InVec x, OutVec y);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle,
         __in_vector InVec, __out_vector OutVec>
void hermitian_matrix_vector_product(ExecutionPolicy&& exec,
                                     InMat A, Triangle t,
                                     InVec x, OutVec y);
template<__in_matrix InMat, class Triangle,
         __in_vector InVec1, __in_vector InVec2,
         __out_vector OutVec>
void hermitian_matrix_vector_product(InMat A, Triangle t,
                                     InVec1 x, InVec2 y, OutVec z);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle,
         __in_vector InVec1, __in_vector InVec2,
         __out_vector OutVec>
void hermitian_matrix_vector_product(ExecutionPolicy&& exec,
                                     InMat A, Triangle t,
                                     InVec1 x, InVec2 y, OutVec z);
// 삼각 행렬-벡터 곱
// 삼각 행렬-벡터 곱 덮어쓰기
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec, __out_vector OutVec>
void triangular_matrix_vector_product(InMat A, Triangle t, DiagonalStorage d,
                                      InVec x, OutVec y);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec, __out_vector OutVec>
void triangular_matrix_vector_product(ExecutionPolicy&& exec,
                                      InMat A, Triangle t, DiagonalStorage d,
                                      InVec x, OutVec y);
// In-place 삼각 행렬-벡터 곱
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __inout_vector InOutVec>
void triangular_matrix_vector_product(InMat A, Triangle t, DiagonalStorage d,
                                      InOutVec y);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __inout_vector InOutVec>
void triangular_matrix_vector_product(ExecutionPolicy&& exec,
                                      InMat A, Triangle t, DiagonalStorage d,
                                      InOutVec y);
// 삼각 행렬-벡터 곱 업데이트
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec1, __in_vector InVec2,
         __out_vector OutVec>
void triangular_matrix_vector_product(InMat A, Triangle t, DiagonalStorage d,
                                      InVec1 x, InVec2 y, OutVec z);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec1, __in_vector InVec2,
         __out_vector OutVec>
void triangular_matrix_vector_product(ExecutionPolicy&& exec,
                                      InMat A, Triangle t, DiagonalStorage d,
                                      InVec1 x, InVec2 y, OutVec z);
// 삼각 선형 시스템 풀이, 제자리에서 수행하지 않음
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec, __out_vector OutVec, class BinaryDivideOp>
void triangular_matrix_vector_solve(InMat A, Triangle t, DiagonalStorage d,
                                    InVec b, OutVec x, BinaryDivideOp divide);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec, __out_vector OutVec, class BinaryDivideOp>
void triangular_matrix_vector_solve(ExecutionPolicy&& exec,
                                    InMat A, Triangle t, DiagonalStorage d,
                                    InVec b, OutVec x, BinaryDivideOp divide);
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec, __out_vector OutVec>
void triangular_matrix_vector_solve(InMat A, Triangle t, DiagonalStorage d,
                                    InVec b, OutVec x);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __in_vector InVec, __out_vector OutVec>
void triangular_matrix_vector_solve(ExecutionPolicy&& exec,
                                    InMat A, Triangle t, DiagonalStorage d,
                                    InVec b, OutVec x);
// 삼각 선형 시스템을 제자리에서 해결
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __inout_vector InOutVec, class BinaryDivideOp>
void triangular_matrix_vector_solve(InMat A, Triangle t, DiagonalStorage d,
                                    InOutVec b, BinaryDivideOp divide);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __inout_vector InOutVec, class BinaryDivideOp>
void triangular_matrix_vector_solve(ExecutionPolicy&& exec,
                                    InMat A, Triangle t, DiagonalStorage d,
                                    InOutVec b, BinaryDivideOp divide);
template<__in_matrix InMat, class Triangle, class DiagonalStorage,
         __inout_vector InOutVec>
void triangular_matrix_vector_solve(InMat A, Triangle t, DiagonalStorage d,
                                    InOutVec b);
template<class ExecutionPolicy,
         __in_matrix InMat, class Triangle, class DiagonalStorage,
         __inout_vector InOutVec>
void triangular_matrix_vector_solve(ExecutionPolicy&& exec,
                                    InMat A, Triangle t, DiagonalStorage d,
                                    InOutVec b);
// 비켤레 순위-1 행렬 업데이트
template<__in_vector InVec1, __in_vector InVec2, __inout_matrix InOutMat>
void matrix_rank_1_update(InVec1 x, InVec2 y, InOutMat A);
template<class ExecutionPolicy,
         __in_vector InVec1, __in_vector InVec2, __inout_matrix InOutMat>
void matrix_rank_1_update(ExecutionPolicy&& exec,
                          InVec1 x, InVec2 y, InOutMat A);
// 켤레 순위-1 행렬 갱신
template<__in_vector InVec1, __in_vector InVec2, __inout_matrix InOutMat>
void matrix_rank_1_update_c(InVec1 x, InVec2 y, InOutMat A);
template<class ExecutionPolicy, 
         __in_vector InVec1, __in_vector InVec2, __inout_matrix InOutMat>
void matrix_rank_1_update_c(ExecutionPolicy&& exec,
                            InVec1 x, InVec2 y, InOutMat A);
// 대칭 rank-1 행렬 업데이트
template<__in_vector InVec, __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void symmetric_matrix_rank_1_update(InVec x, InOutMat A, Triangle t);
template<class ExecutionPolicy,
         __in_vector InVec, __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void symmetric_matrix_rank_1_update(ExecutionPolicy&& exec,
                                    InVec x, InOutMat A, Triangle t);
template<class Scalar, __in_vector InVec,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_1_update(Scalar alpha, InVec x, InOutMat A,
                                    Triangle t);
template<class ExecutionPolicy,
         class Scalar, __in_vector InVec,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_1_update(ExecutionPolicy&& exec,
                                    Scalar alpha, InVec x, InOutMat A,
                                    Triangle t);
// Hermitian rank-1 matrix update
template<__in_vector InVec, __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void hermitian_matrix_rank_1_update(InVec x, InOutMat A, Triangle t);
template<class ExecutionPolicy,
         __in_vector InVec, __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void hermitian_matrix_rank_1_update(ExecutionPolicy&& exec,
                                    InVec x, InOutMat A, Triangle t);
template<class Scalar, __in_vector InVec,
         __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void hermitian_matrix_rank_1_update(Scalar alpha, InVec x, InOutMat A,
                                    Triangle t);
template<class ExecutionPolicy,
         class Scalar, __in_vector InVec,
         __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void hermitian_matrix_rank_1_update(ExecutionPolicy&& exec,
                                    Scalar alpha, InVec x, InOutMat A,
                                    Triangle t);
// 대칭 rank-2 행렬 업데이트
template<__in_vector InVec1, __in_vector InVec2,
         __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void symmetric_matrix_rank_2_update(InVec1 x, InVec2 y, InOutMat A,
                                    Triangle t);
template<class ExecutionPolicy,
         __in_vector InVec1, __in_vector InVec2,
         __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void symmetric_matrix_rank_2_update(ExecutionPolicy&& exec,
                                    InVec1 x, InVec2 y, InOutMat A,
                                    Triangle t);
// Hermitian rank-2 행렬 업데이트
template<__in_vector InVec1, __in_vector InVec2,
         __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void hermitian_matrix_rank_2_update(InVec1 x, InVec2 y, InOutMat A,
                                    Triangle t);
template<class ExecutionPolicy,
         __in_vector InVec1, __in_vector InVec2,
         __possibly_packed_inout_matrix InOutMat,
         class Triangle>
void hermitian_matrix_rank_2_update(ExecutionPolicy&& exec,
                                    InVec1 x, InVec2 y, InOutMat A,
                                    Triangle t);
// 일반 행렬-행렬 곱
template<__in_matrix InMat1, __in_matrix InMat2, __out_matrix OutMat>
void matrix_product(InMat1 A, InMat2 B, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2, __out_matrix OutMat>
void matrix_product(ExecutionPolicy&& exec, InMat1 A, InMat2 B, OutMat C);
template<__in_matrix InMat1, __in_matrix InMat2, __in_matrix InMat3,
         __out_matrix OutMat>
void matrix_product(InMat1 A, InMat2 B, InMat3 E, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2, __in_matrix InMat3,
         __out_matrix OutMat>
void matrix_product(ExecutionPolicy&& exec,
                    InMat1 A, InMat2 B, InMat3 E, OutMat C);
// 대칭 행렬-행렬 곱
// 대칭 행렬-행렬 왼쪽 곱 덮어쓰기
template<__in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __out_matrix OutMat>
void symmetric_matrix_product(InMat1 A, Triangle t,
                              InMat2 B, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __out_matrix OutMat>
void symmetric_matrix_product(ExecutionPolicy&& exec,
                              InMat1 A, Triangle t,
                              InMat2 B, OutMat C);
// 대칭 행렬-행렬 우측 곱 덮어쓰기
template<__in_matrix InMat1, __in_matrix InMat2,
         class Triangle, __out_matrix OutMat>
void symmetric_matrix_product(InMat1 B, InMat2 A, Triangle t,
                              OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2,
         class Triangle, __out_matrix OutMat>
void symmetric_matrix_product(ExecutionPolicy&& exec,
                              InMat1 B, InMat2 A, Triangle t,
                              OutMat C);
// 대칭 행렬-행렬 왼쪽 곱 업데이트
template<__in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __in_matrix InMat3,
         __out_matrix OutMat>
void symmetric_matrix_product(InMat1 A, Triangle t,
                              InMat2 B, InMat3 E,
                              OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __in_matrix InMat3,
         __out_matrix OutMat>
void symmetric_matrix_product(ExecutionPolicy&& exec,
                              InMat1 A, Triangle t,
                              InMat2 B, InMat3 E,
                              OutMat C);
// 대칭 행렬-행렬 우측 곱 업데이트
template<__in_matrix InMat1, __in_matrix InMat2, class Triangle,
         __in_matrix InMat3, __out_matrix OutMat>
void symmetric_matrix_product(InMat1 B, InMat2 A, Triangle t,
                              InMat3 E, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2, class Triangle,
         __in_matrix InMat3, __out_matrix OutMat>
void symmetric_matrix_product(ExecutionPolicy&& exec,
                              InMat1 B, InMat2 A, Triangle t,
                              InMat3 E, OutMat C);
// 에르미트 행렬-행렬 곱
// 에르미트 행렬-행렬 좌측 곱 덮어쓰기
template<__in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __out_matrix OutMat>
void hermitian_matrix_product(InMat1 A, Triangle t,
                              InMat2 B, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __out_matrix OutMat>
void hermitian_matrix_product(ExecutionPolicy&& exec,
                              InMat1 A, Triangle t,
                              InMat2 B, OutMat C);
// 에르미트 행렬-행렬 우측 곱 덮어쓰기
template<__in_matrix InMat1, __in_matrix InMat2,
         class Triangle, __out_matrix OutMat>
void hermitian_matrix_product(InMat1 B, InMat2 A, Triangle t,
                              OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2,
         class Triangle, __out_matrix OutMat>
void hermitian_matrix_product(ExecutionPolicy&& exec,
                              InMat1 B, InMat2 A, Triangle t,
                              OutMat C);
// 에르미트 행렬-행렬 왼쪽 곱 업데이트
template<__in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __in_matrix InMat3, __out_matrix OutMat>
void hermitian_matrix_product(InMat1 A, Triangle t,
                              InMat2 B, InMat3 E, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle,
         __in_matrix InMat2, __in_matrix InMat3, __out_matrix OutMat>
void hermitian_matrix_product(ExecutionPolicy&& exec,
                              InMat1 A, Triangle t,
                              InMat2 B, InMat3 E, OutMat C);
// 에르미트 행렬-행렬 우측 곱 업데이트
template<__in_matrix InMat1, __in_matrix InMat2, class Triangle,
         __in_matrix InMat3, __out_matrix OutMat>
void hermitian_matrix_product(InMat1 B, InMat2 A, Triangle t,
                              InMat3 E, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2, class Triangle,
         __in_matrix InMat3, __out_matrix OutMat>
void hermitian_matrix_product(ExecutionPolicy&& exec,
                              InMat1 B, InMat2 A, Triangle t,
                              InMat3 E, OutMat C);
// 삼각 행렬-행렬 곱
// 삼각 행렬-행렬 왼쪽 곱 덮어쓰기
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat>
void triangular_matrix_product(InMat1 A, Triangle t, DiagonalStorage d,
                               InMat2 B, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat>
void triangular_matrix_product(ExecutionPolicy&& exec,
                               InMat1 A, Triangle t, DiagonalStorage d,
                               InMat2 B, OutMat C);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_left_product(InMat1 A, Triangle t, DiagonalStorage d,
                                    InOutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_left_product(ExecutionPolicy&& exec,
                                    InMat1 A, Triangle t, DiagonalStorage d,
                                    InOutMat C);
// 삼각 행렬-행렬 우측 곱 덮어쓰기
template<__in_matrix InMat1, __in_matrix InMat2,
         class Triangle, class DiagonalStorage,
         __out_matrix OutMat>
void triangular_matrix_product(InMat1 B, InMat2 A,
                               Triangle t, DiagonalStorage d,
                               OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2,
         class Triangle, class DiagonalStorage,
         __out_matrix OutMat>
void triangular_matrix_product(ExecutionPolicy&& exec,
                               InMat1 B, InMat2 A,
                               Triangle t, DiagonalStorage d,
                               OutMat C);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_right_product(InMat1 A, Triangle t, DiagonalStorage d,
                                     InOutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_right_product(ExecutionPolicy&& exec,
                                     InMat1 A, Triangle t, DiagonalStorage d,
                                     InOutMat C);
// 삼각 행렬-행렬 왼쪽 곱 업데이트
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __in_matrix InMat3,
         __out_matrix OutMat>
void triangular_matrix_product(InMat1 A, Triangle t, DiagonalStorage d,
                               InMat2 B, InMat3 E, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __in_matrix InMat3,
         __out_matrix OutMat>
void triangular_matrix_product(ExecutionPolicy&& exec,
                               InMat1 A, Triangle t, DiagonalStorage d,
                               InMat2 B, InMat3 E, OutMat C);
// 삼각 행렬-행렬 우측 곱 업데이트
template<__in_matrix InMat1, __in_matrix InMat2,
         class Triangle, class DiagonalStorage,
         __in_matrix InMat3, __out_matrix OutMat>
void triangular_matrix_product(InMat1 B, InMat2 A,
                               Triangle t, DiagonalStorage d,
                               InMat3 E, OutMat C);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2,
         class Triangle, class DiagonalStorage,
         __in_matrix InMat3, __out_matrix OutMat>
void triangular_matrix_product(ExecutionPolicy&& exec,
                               InMat1 B, InMat2 A,
                               Triangle t, DiagonalStorage d,
                               InMat3 E, OutMat C);
// rank-k 대칭 행렬 업데이트
template<class Scalar, __in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_k_update(Scalar alpha, InMat1 A, InOutMat C,
                                    Triangle t);
template<class Scalar,
         class ExecutionPolicy,
         ___in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_k_update(ExecutionPolicy&& exec,
                                    Scalar alpha, InMat1 A, InOutMat C,
                                    Triangle t);
template<__in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_k_update(InMat1 A, InOutMat C, Triangle t);
template<class ExecutionPolicy,
         __in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_k_update(ExecutionPolicy&& exec,
                                    InMat1 A, InOutMat C, Triangle t);
// rank-k Hermitian matrix 업데이트
template<class Scalar, __in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void hermitian_matrix_rank_k_update(Scalar alpha, InMat1 A, InOutMat C,
                                    Triangle t);
template<class ExecutionPolicy,
         class Scalar, __in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle
void hermitian_matrix_rank_k_update(ExecutionPolicy&& exec,
                                    Scalar alpha, InMat1 A, InOutMat C,
                                    Triangle t);
template<__in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void hermitian_matrix_rank_k_update(InMat1 A, InOutMat C, Triangle t);
template<class ExecutionPolicy,
         __in_matrix InMat1,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void hermitian_matrix_rank_k_update(ExecutionPolicy&& exec,
                                    InMat1 A, InOutMat C, Triangle t);
// rank-2k 대칭 행렬 업데이트
template<__in_matrix InMat1, __in_matrix InMat2,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_2k_update(InMat1 A, InMat2 B, InOutMat C,
                                     Triangle t);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void symmetric_matrix_rank_2k_update(ExecutionPolicy&& exec,
                                     InMat1 A, InMat2 B, InOutMat C,
                                     Triangle t);
// 랭크-2k 에르미트 행렬 업데이트
template<__in_matrix InMat1, __in_matrix InMat2,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void hermitian_matrix_rank_2k_update(InMat1 A, InMat2 B, InOutMat C,
                                     Triangle t);
template<class ExecutionPolicy,
         __in_matrix InMat1, __in_matrix InMat2,
         __possibly_packed_inout_matrix InOutMat, class Triangle>
void hermitian_matrix_rank_2k_update(ExecutionPolicy&& exec,
                                     InMat1 A, InMat2 B, InOutMat C,
                                     Triangle t);
// 다중 삼각 선형 시스템 해결
// 왼쪽에 삼각 행렬 사용
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat, class BinaryDivideOp>
void triangular_matrix_matrix_left_solve(InMat1 A,
                                         Triangle t, DiagonalStorage d,
                                         InMat2 B, OutMat X,
                                         BinaryDivideOp divide);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat, class BinaryDivideOp>
void triangular_matrix_matrix_left_solve(ExecutionPolicy&& exec,
                                         InMat1 A,
                                         Triangle t, DiagonalStorage d,
                                         InMat2 B, OutMat X,
                                         BinaryDivideOp divide);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat, class BinaryDivideOp>
void triangular_matrix_matrix_left_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                         InOutMat B, BinaryDivideOp divide);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat, class BinaryDivideOp>
void triangular_matrix_matrix_left_solve(ExecutionPolicy&& exec,
                                         InMat1 A, Triangle t, DiagonalStorage d,
                                         InOutMat B, BinaryDivideOp divide);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat>
void triangular_matrix_matrix_left_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                         InMat2 B, OutMat X);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat>
void triangular_matrix_matrix_left_solve(ExecutionPolicy&& exec,
                                         InMat1 A, Triangle t, DiagonalStorage d,
                                         InMat2 B, OutMat X);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_matrix_left_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                         InOutMat B);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_matrix_left_solve(ExecutionPolicy&& exec,
                                         InMat1 A, Triangle t, DiagonalStorage d,
                                         InOutMat B);
// 다중 삼각 선형 시스템 해결
// 삼각 행렬이 오른쪽에 있는 경우
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat, class BinaryDivideOp>
void triangular_matrix_matrix_right_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                          InMat2 B, OutMat X, BinaryDivideOp divide);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat, class BinaryDivideOp>
void triangular_matrix_matrix_right_solve(ExecutionPolicy&& exec,
                                          InMat1 A, Triangle t, DiagonalStorage d,
                                          InMat2 B, OutMat X, BinaryDivideOp divide);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat, class BinaryDivideOp>
void triangular_matrix_matrix_right_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                          InOutMat B, BinaryDivideOp divide);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat, class BinaryDivideOp>
void triangular_matrix_matrix_right_solve(ExecutionPolicy&& exec,
                                          InMat1 A, Triangle t, DiagonalStorage d,
                                          InOutMat B, BinaryDivideOp divide));
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat>
void triangular_matrix_matrix_right_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                          InMat2 B, OutMat X);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __in_matrix InMat2, __out_matrix OutMat>
void triangular_matrix_matrix_right_solve(ExecutionPolicy&& exec,
                                          InMat1 A, Triangle t, DiagonalStorage d,
                                          InMat2 B, OutMat X);
template<__in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_matrix_right_solve(InMat1 A, Triangle t, DiagonalStorage d,
                                          InOutMat B);
template<class ExecutionPolicy,
         __in_matrix InMat1, class Triangle, class DiagonalStorage,
         __inout_matrix InOutMat>
void triangular_matrix_matrix_right_solve(ExecutionPolicy&& exec,
                                          InMat1 A, Triangle t, DiagonalStorage d,
                                          InOutMat B);
}

태그

namespace std::linalg {
  struct column_major_t {
    explicit column_major_t() = default;
  };
  inline constexpr column_major_t column_major = { };
  struct row_major_t {
    explicit row_major_t() = default;
  };
  inline constexpr row_major_t row_major = { };
  struct upper_triangle_t {
    explicit upper_triangle_t() = default;
  };
  inline constexpr upper_triangle_t upper_triangle = { };
  struct lower_triangle_t {
    explicit lower_triangle_t() = default;
  };
  inline constexpr lower_triangle_t lower_triangle = { };
  struct implicit_unit_diagonal_t {
    explicit implicit_unit_diagonal_t() = default;
  };
  inline constexpr implicit_unit_diagonal_t implicit_unit_diagonal = { };
  struct explicit_diagonal_t {
    explicit explicit_diagonal_t() = default;
  };
  inline constexpr explicit_diagonal_t explicit_diagonal = { };
}

클래스 템플릿 std::linalg::layout_blas_packed

namespace std::linalg {
  template<class Triangle, class StorageOrder>
  class layout_blas_packed {
   public:
    using triangle_type = Triangle;
    using storage_order_type = StorageOrder;
    template<class Extents>
    struct mapping {
     public:
      using extents_type = Extents;
      using index_type = typename extents_type::index_type;
      using size_type = typename extents_type::size_type;
      using rank_type = typename extents_type::rank_type;
      using layout_type = layout_blas_packed<Triangle, StorageOrder>;
     private:
      Extents __the_extents{}; // 설명용으로만 사용
     public:
      constexpr mapping() noexcept = default;
      constexpr mapping(const mapping&) noexcept = default;
      constexpr mapping(const extents_type& e) noexcept;
      template<class OtherExtents>
      constexpr explicit(!is_convertible_v<OtherExtents, extents_type>)
      mapping(const mapping<OtherExtents>& other) noexcept;
      constexpr mapping& operator=(const mapping&) noexcept = default;
      constexpr extents_type extents() const noexcept { return __the_extents; }
      constexpr size_type required_span_size() const noexcept;
      template<class Index0, class Index1>
      constexpr index_type operator() (Index0 ind0, Index1 ind1) const noexcept;
      static constexpr bool is_always_unique() {
        return (extents_type::static_extent(0) != dynamic_extent &&
                extents_type::static_extent(0) < 2) ||
               (extents_type::static_extent(1) != dynamic_extent &&
                extents_type::static_extent(1) < 2);
      }
      static constexpr bool is_always_exhaustive() { return true; }
      static constexpr bool is_always_strided() {
        return is_always_unique();
      }
      constexpr bool is_unique() const noexcept {
        return __the_extents.extent(0) < 2;
      }
      constexpr bool is_exhaustive() const noexcept { return true; }
      constexpr bool is_strided() const noexcept {
        return __the_extents.extent(0) < 2;
      }
      constexpr index_type stride(rank_type) const noexcept;
      template<class OtherExtents>
      friend constexpr bool
      operator==(const mapping&, const mapping<OtherExtents>&) noexcept;
    };
  };
}

클래스 템플릿 std::linalg::scaled_accessor

namespace std::linalg {
  template<class ScalingFactor, class NestedAccessor>
  class scaled_accessor {
   public:
    using element_type = 
      add_const_t<decltype(declval<ScalingFactor>() * 
                           declval<NestedAccessor::element_type>())>;
    using reference = remove_const_t<element_type>;
    using data_handle_type = NestedAccessor::data_handle_type;
    using offset_policy = scaled_accessor<ScalingFactor, NestedAccessor::offset_policy>;
    constexpr scaled_accessor() = default;
    template<class OtherNestedAccessor>
      explicit(!is_convertible_v<OtherNestedAccessor, NestedAccessor>)
    constexpr scaled_accessor(const scaled_accessor<ScalingFactor, OtherNestedAccessor>&);
    constexpr scaled_accessor(const ScalingFactor& s, const Accessor& a);
    constexpr reference access(data_handle_type p, size_t i) const noexcept;
    constexpr 
      offset_policy::data_handle_type offset(data_handle_type p, size_t i) const noexcept;
    constexpr const ScalingFactor& scaling_factor() const noexcept 
      { return __scaling_factor; } 
    constexpr const NestedAccessor& nested_accessor() const noexcept
      { return __nested_accessor; }
   private:
    ScalingFactor __scaling_factor; // 설명용으로만 사용
    NestedAccessor __nested_accessor; // 설명용으로만 사용
  };
}

클래스 템플릿 std::linalg::conjugated_accessor

namespace std::linalg {
  template<class NestedAccessor>
  class conjugated_accessor {
   private:
    NestedAccessor __nested_accessor; // 설명 전용
   public:
    using element_type =
      add_const_t<decltype(/*필요 시 켤레 연산*/(declval<NestedAccessor::element_type>()))>;
    using reference = remove_const_t<element_type>;
    using data_handle_type = typename NestedAccessor::data_handle_type;
    using offset_policy = conjugated_accessor<NestedAccessor::offset_policy>;
    constexpr conjugated_accessor() = default;
    template<class OtherNestedAccessor>
      explicit(!is_convertible_v<OtherNestedAccessor, NestedAccessor>)
      constexpr conjugated_accessor(const conjugated_accessor<OtherNestedAccessor>& other);
    constexpr reference access(data_handle_type p, size_t i) const;
    constexpr typename offset_policy::data_handle_type
      offset(data_handle_type p, size_t i) const;
    constexpr const NestedAccessor& nested_accessor() const noexcept
      { return __nested_accessor; }
  };
}

클래스 템플릿 std::linalg::layout_transpose

namespace std::linalg {
  template<class InputExtents>
  using __transpose_extents_t = /* 설명 참조 */; // 설명 전용
  template<class Layout>
  class layout_transpose {
   public:
    using nested_layout_type = Layout;
    template<class Extents>
    struct mapping {
     private:
      using __nested_mapping_type =
        typename Layout::template mapping<
          __transpose_extents_t<Extents>>;    // 설명 전용
      __nested_mapping_type __nested_mapping; // 설명 전용
        extents_type __extents;               // 설명 전용
     public:
      using extents_type = Extents;
      using index_type = typename extents_type::index_type;
      using size_type = typename extents_type::size_type;
      using rank_type = typename extents_type::rank_type;
      using layout_type = layout_transpose;
      constexpr explicit mapping(const __nested_mapping_type& map);
      constexpr const extents_type& extents() const noexcept { return __extents; }
      constexpr index_type required_span_size() const
        { return __nested_mapping.required_span_size(); }
      template<class Index0, class Index1>
        constexpr index_type operator()(Index0 ind0, Index1 ind1) const
        { return __nested_mapping(ind1, ind0); }
      constexpr const __nested_mapping_type& nested_mapping() const noexcept
        { return __nested_mapping; }
      static constexpr bool is_always_unique() noexcept
        { return __nested_mapping_type::is_always_unique(); }
      static constexpr bool is_always_exhaustive() noexcept
        { return __nested_mapping_type::is_always_exhaustive(); }
      static constexpr bool is_always_strided() noexcept
        { return __nested_mapping_type::is_always_strided(); }
      constexpr bool is_unique() const 
        { return __nested_mapping.is_unique(); }
      constexpr bool is_exhaustive() const 
        { return __nested_mapping.is_exhaustive(); }
      constexpr bool is_strided() const 
        { return __nested_mapping.is_strided(); }
      constexpr index_type stride(size_t r) const;
      template<class OtherExtents>
      friend constexpr bool
        operator==(const mapping& x, const mapping<OtherExtents>& y);
    };
  };
}

헬퍼 개념 및 특성

namespace std::linalg {
  template<class T>
  struct __is_mdspan : false_type {}; // 설명 전용
  template<class ElementType, class Extents, class Layout, class Accessor>
  struct __is_mdspan<mdspan<ElementType, Extents, Layout, Accessor>>
  : true_type {}; // 설명 전용
  template<class T>
  concept __in_vector = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 1;
  template<class T>
  concept __out_vector = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 1 &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
    T::is_always_unique();
  template<class T>
  concept __inout_vector = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 1 &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
    T::is_always_unique();
  template<class T>
  concept __in_matrix = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 2;
  template<class T>
  concept __out_matrix = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 2 &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
   T::is_always_unique();
  template<class T>
  concept __inout_matrix = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 2 &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
    T::is_always_unique();
  template<class T>
  concept __possibly_packed_inout_matrix = // 설명 전용
    __is_mdspan<T>::value &&
    T::rank() == 2 &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
    (T::is_always_unique() || is_same_v<typename T::layout_type, layout_blas_packed>);
  template<class T>
  concept __in_object = // 설명 전용
    __is_mdspan<T>::value &&
    (T::rank() == 1 || T::rank() == 2);
  template<class T>
  concept __out_object = // 설명 전용
    __is_mdspan<T>::value &&
    (T::rank() == 1 || T::rank() == 2) &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
    T::is_always_unique();
  template<class T>
  concept __inout_object = // 설명 전용
    __is_mdspan<T>::value &&
    (T::rank() == 1 || T::rank() == 2) &&
    is_assignable_v<typename T::레퍼런스, typename T::element_type> &&
    T::is_always_unique();
}