std::philox_engine<UIntType,w,n,r,consts>::set_counter
From cppreference.com
< cpp | numeric | random | philox engine
| void set_counter( const std::array<result_type, n>& c ); |
(C++26以降) | |
乱数エンジンのカウンターを設定します。
- k が
[0,n)の各整数に対して、Xk を cn-1-k mod 2w
に設定します。 - j の値は n - 1 に設定されます。[1]
- ↑ j が n - 1 に設定されるため、次の状態遷移は常に新しい乱値を生成します。
[編集] パラメータ
| c | - | カウンターを設定するために使用するカウンターシーケンス |
[編集] 計算量
O(n)。
[編集] 関連項目
| エンジンを構築します。 (public member function) | |
| エンジンの現在の状態を設定します。 (public member function) |