sobol
sobol,
a MATLAB code which
computes elements of the Sobol
quasirandom sequence,
by Bennett Fox.
A quasirandom or low discrepancy sequence, such as the Faure,
Halton, Hammersley, Niederreiter or Sobol sequences, is
"less random" than a pseudorandom number sequence, but
more useful for such tasks as approximation of integrals in
higher dimensions, and in global optimization.
This is because low discrepancy sequences tend to sample
space "more uniformly" than random numbers. Algorithms
that use such sequences may have superior convergence.
SOBOL is an adapation of the INSOBL and GOSOBL routines
in ACM TOMS Algorithm 647 and ACM TOMS Algorithm 659. The original
code can only compute the "next" element of the sequence. The
revised code allows the user to specify the index of the desired element.
A remark by Joe and Kuo shows how to extend the algorithm from
the original maximum spatial dimension of 40 up to a maximum
spatial dimension of 1111. The FORTRAN90 and C++ versions of the code
has been updated in this way, but updating the MATLAB code
has not been simple, since MATLAB doesn't support 64 bit
integers.
The original, true, correct versions of ACM TOMS Algorithm 647
and ACM TOMS Algorithm 659
are available in the TOMS subdirectory of
the NETLIB web site.
Licensing:
The computer code and data files described and made available on this web page
are distributed under
the MIT license
Languages:
sobol is available in
a C++ version and
a FORTRAN90 version and
a MATLAB version and
a Python version
Related Data and Programs:
cvt,
a MATLAB code which
computes points in
a centroidal voronoi tessellation.
faure,
a MATLAB code which
computes faure
sequences.
halton,
a MATLAB code which
computes halton
sequences.
hammersley,
a MATLAB code which
computes elements of a hammersley quasi monte carlo (qmc) sequence,
using a simple interface.
latin_center,
a MATLAB code which
computes
latin square data choosing the center value.
latin_edge,
a MATLAB code which
computes
latin square data choosing the edge value.
latin_random,
a MATLAB code which
computes
latin square data choosing a random value in the square.
lattice_rule,
a MATLAB code which
approximates multidimensional integrals using lattice rules.
niederreiter2,
a MATLAB code which
computes niederreiter sequences with base 2.
sobol_test
uniform,
a MATLAB code which
computes uniform random values.
van_der_corput,
a MATLAB code which
computes van der corput sequences.
Author:
Original FORTRAN77 version by Bennett Fox;
MATLAB version by John Burkardt.
Reference:

IA Antonov, VM Saleev,
An Economic Method of Computing LP TauSequences,
USSR Computational Mathematics and Mathematical Physics,
Volume 19, 1980, pages 252256.

Paul Bratley, Bennett Fox,
Algorithm 659:
Implementing Sobol's Quasirandom Sequence Generator,
ACM Transactions on Mathematical Software,
Volume 14, Number 1, March 1988, pages 88100.

Paul Bratley, Bennett Fox, Harald Niederreiter,
Implementation and Tests of Low Discrepancy Sequences,
ACM Transactions on Modeling and Computer Simulation,
Volume 2, Number 3, July 1992, pages 195213.

Paul Bratley, Bennett Fox, Linus Schrage,
A Guide to Simulation,
Second Edition,
Springer, 1987,
ISBN: 0387964673,
LC: QA76.9.C65.B73.

Bennett Fox,
Algorithm 647:
Implementation and Relative Efficiency of Quasirandom
Sequence Generators,
ACM Transactions on Mathematical Software,
Volume 12, Number 4, December 1986, pages 362376.

Stephen Joe, Frances Kuo,
Remark on Algorithm 659:
Implementing Sobol's Quasirandom Sequence Generator,
ACM Transactions on Mathematical Software,
Volume 29, Number 1, March 2003, pages 4957.

Harald Niederreiter,
Random Number Generation and quasiMonte Carlo Methods,
SIAM, 1992,
ISBN13: 9780898712957,
LC: QA298.N54.

William Press, Brian Flannery, Saul Teukolsky, William Vetterling,
Numerical Recipes in FORTRAN: The Art of Scientific Computing,
Second Edition,
Cambridge University Press, 1992,
ISBN: 052143064X,
LC: QA297.N866.

Ilya Sobol,
Uniformly Distributed Sequences with an Additional Uniform
Property,
USSR Computational Mathematics and Mathematical Physics,
Volume 16, 1977, pages 236242.

Ilya Sobol, YL Levitan,
The Production of Points Uniformly Distributed in a Multidimensional
Cube (in Russian),
Preprint IPM Akademii Nauk SSSR,
Number 40, Moscow 1976.
Source Code:

i4_bit_hi1.m,
returns the position of the high 1 bit base 2 in an integer.

i4_bit_lo0.m,
returns the position of the low 0 bit base 2 in an integer.

i4_sobol.m, generates a new quasirandom
Sobol vector with each call;

i4_sobol_generate.m,
generates a dataset of Sobol vectors.

i4_uniform_ab.m,
returns a random integer in a given range [A,B].

i4_xor.m,
returns the exclusive or (XOR) of two integers.

i8_xor.m,
returns the exclusive or (XOR) of two integers.

prime_ge.m,
finds the smallest prime greater or equal to a given integer.

r8mat_write.m,
writes an R8MAT file.

tau_sobol.m
defines favorable starting seeds for Sobol sequences.
Last revised on 25 December 2020.