• Class / Function / Type

      std::
    • Header file

      <>
    • Other / All

    最終更新日時(UTC):
    が更新

    履歴 編集

    concept
    <linalg>

    in-matrix, out-matrix, inout-matrix

    template<class T>
    concept in-matrix =
      is-mdspan<T> && T::rank() == 2;
    
    template<class T>
    concept out-matrix =
      is-mdspan<T> && T::rank() == 2 &&
      is_assignable_v<typename T::reference, typename T::element_type> && T::is_always_unique();
    
    template<class T>
    concept inout-matrix =
      is-mdspan<T> && T::rank() == 2 &&
      is_assignable_v<typename T::reference, typename T::element_type> && T::is_always_unique();
    

    概要

    Tが行列(2次元mdspan)であることを表す、説明専用のコンセプトである。

    • in-matrix : 入力パラメータを表す。アルゴリズム内でmdspan要素が更新されることはない。
    • out-matrix : 出力パラメータを表す。演算結果の書き出しが行われる。
    • inout-matrix : 入出力パラメータを表す。要素の読み取りと演算結果の書き出しが行われる。

    関数仕様で明示されない限り、out-matrixおよびinout-matrixで制約されるmdspan型引数は、同関数の他mdspan引数のエイリアスであってはならない。

    バージョン

    言語

    • C++26

    参照