Jump to content

Van der Corput sequence: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
Added references and notes section
Tag: Reverted
Added short Wolfram language implementation
Tag: Reverted
Line 48: Line 48:
return q;
return q;
}
}
</syntaxhighlight>

==Wolfram language implementation==
The following program gives the decimal van der Corput sequence when <code>base=10</code> and <code>m=2</code>:<ref name="NKS note d"/>
<syntaxhighlight lang="Mathematica">
Table[FromDigits[Reverse[IntegerDigits[n, base, m]], base]/base^m, {n, 1, base^m - 1}]
</syntaxhighlight>
</syntaxhighlight>



Revision as of 15:42, 16 October 2020

Illustration of the filling of the unit interval (horizontal axis) using the first n terms of the decimal Van der Corput sequence, for n from 0 to 999 (vertical axis)

A van der Corput sequence is an example of the simplest one-dimensional low-discrepancy sequence over the unit interval; it was first described in 1935 by the Dutch mathematician J. G. van der Corput.[1] It is constructed by reversing the base-n representation of the sequence of natural numbers (1, 2, 3, …).[1]

The b-ary representation of the positive integer n (≥ 1) is

where b is the base in which the number n is represented, and 0 ≤ dk(n) < b, i.e. the k-th digit in the b-ary expansion of n. The n-th number in the van der Corput sequence is

Examples

For example, to get the decimal van der Corput sequence, we start by dividing the numbers 1 to 9 in tenths (x/10), then we change the denominator to 100 to begin dividing in hundredths (x/100). In terms of numerator, we begin with all two-digit numbers from 10 to 99, but in backwards order of digits. Consequently, we will get the numerators grouped by the end digit. Firstly, all two-digit numerators that end with 1, so the next numerators are 01, 11, 21, 31, 41, 51, 61, 71, 81, 91. Then the numerators ending with 2, so they are 02, 12, 22, 32, 42, 52, 62, 72, 82, 92. An after the numerators ending in 3: 03, 13, 23 and so on...

Thus, the sequence begins

or in decimal representation:

0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 0.01, 0.11, 0.21, 0.31, 0.41, 0.51, 0.61, 0.71, 0.81, 0.91, 0.02, 0.12, 0.22, 0.32, …,

The same can be done for the binary numeral system, and the binary van der Corput sequence is

0.12, 0.012, 0.112, 0.0012, 0.1012, 0.0112, 0.1112, 0.00012, 0.10012, 0.01012, 0.11012, 0.00112, 0.10112, 0.01112, 0.11112, …

or, equivalently,

The elements of the van der Corput sequence (in any base) form a dense set in the unit interval; that is, for any real number in [0, 1], there exists a subsequence of the van der Corput sequence that converges to that number. They are also equidistributed over the unit interval.

C implementation

double corput(int n, int base){
    double q=0, bk=(double)1/base;

    while (n > 0) {
      q += (n % base)*bk;
      n /= base;
      bk /= base;
    }

    return q;
}

Wolfram language implementation

The following program gives the decimal van der Corput sequence when base=10 and m=2:[1]

Table[FromDigits[Reverse[IntegerDigits[n, base, m]], base]/base^m, {n, 1, base^m - 1}]

See also

Notes

References

  • van der Corput, J.G. (1935), "Verteilungsfunktionen (Erste Mitteilung)" (PDF), Proceedings of the Koninklijke Akademie van Wetenschappen te Amsterdam (in German), 38: 813–821, Zbl 0012.34705
  • Kuipers, L.; Niederreiter, H. (2005) [1974], Uniform distribution of sequences, Dover Publications, p. 129,158, ISBN 0-486-45019-8, Zbl 0281.10001