| 1 | /* boost random/taus88.hpp header file |
| 2 | * |
| 3 | * Copyright Jens Maurer 2000-2001 |
| 4 | * Copyright Steven Watanabe 2011 |
| 5 | * Distributed under the Boost Software License, Version 1.0. (See |
| 6 | * accompanying file LICENSE_1_0.txt or copy at |
| 7 | * http://www.boost.org/LICENSE_1_0.txt) |
| 8 | * |
| 9 | * See http://www.boost.org/libs/random for documentation. |
| 10 | * |
| 11 | * $Id$ |
| 12 | * |
| 13 | */ |
| 14 | |
| 15 | #ifndef BOOST_RANDOM_TAUS88_HPP |
| 16 | #define BOOST_RANDOM_TAUS88_HPP |
| 17 | |
| 18 | #include <boost/random/linear_feedback_shift.hpp> |
| 19 | #include <boost/random/xor_combine.hpp> |
| 20 | |
| 21 | namespace boost { |
| 22 | namespace random { |
| 23 | |
| 24 | /** |
| 25 | * The specialization taus88 was suggested in |
| 26 | * |
| 27 | * @blockquote |
| 28 | * "Maximally Equidistributed Combined Tausworthe Generators", |
| 29 | * Pierre L'Ecuyer, Mathematics of Computation, Volume 65, |
| 30 | * Number 213, January 1996, Pages 203-213 |
| 31 | * @endblockquote |
| 32 | */ |
| 33 | typedef xor_combine_engine< |
| 34 | xor_combine_engine< |
| 35 | linear_feedback_shift_engine<uint32_t, 32, 31, 13, 12>, 0, |
| 36 | linear_feedback_shift_engine<uint32_t, 32, 29, 2, 4>, 0>, 0, |
| 37 | linear_feedback_shift_engine<uint32_t, 32, 28, 3, 17>, 0> taus88; |
| 38 | |
| 39 | } // namespace random |
| 40 | |
| 41 | using random::taus88; |
| 42 | |
| 43 | } // namespace boost |
| 44 | |
| 45 | #endif // BOOST_RANDOM_TAUS88_HPP |
| 46 | |