mt2203#

説明#

6024 個のメルセンヌツイスター疑似乱数生成器のセット MT2203 [Matsumoto98][Matsumoto00]。それぞれ、周期長が \(2^{2203} - 1\) に等しいシーケンスを生成します。生成器のパラメーターは、対応するシーケンスの相互独立性を提供します。

API#

構文#

namespace oneapi::mkl::rng { 
  class mt2203 { 
  public: 
    static constexpr std::uint32_t default_seed = 1; 

    mt2203(sycl::queue queue, std::uint32_t seed = default_seed); 
    mt2203(sycl::queue queue, std::uint32_t seed, std::uint32_t engine_idx); 
    mt2203(sycl::queue queue, std::initializer_list<std::uint32_t> seed); 
    mt2203(sycl::queue queue, std::initializer_list<std::uint32_t> seed, std::uint32_t engine_idx); 
    mt2203(const mt2203& other); 
    mt2203(mt2203&& other); 
    mt2203& operator=(const mt2203& other); 
    mt2203& operator=(mt2203&& other); 
    ~mt2203() 
  }; 
}

サポートされるデバイス: CPU と GPU。

インクルード・ファイル#

  • oneapi/mkl/rng.hpp

入力パラメーター#

名前

タイプ

説明

queue

sycl::queue

有効な sycl::queueoneapi::mkl::rng::generate() ルーチンの呼び出しにより、カーネルがこのキューに送信されます。

seed

std::uint32_t std::initializer_list<std::uint32_t>

エンジンの初期条件。

engine_idx

std::uint32_t

セットからのエンジンのインデックス (セットには 6024 個の基本生成器が含まれています)

この詳細については VS ノートを参照してください。