public static void g05ym( n, rcord, [,] quas,  iref, out ifail )
|Visual Basic (Declaration)|
Public Shared Sub g05ym ( _ n As , _ rcord As , _ quas As (,), _ iref As (), _ < > ByRef ifail As _ )
public: static void g05ym( n, rcord, array< ,2>^ quas, array< >^ iref, [ ] % ifail )
static member g05ym : n: * rcord: * quas: [,] * iref:  * ifail: byref -> unit
On entry: the number of quasi-random numbers required.Constraint: and
On entry: the order in which the generated values are returned.Constraint: or .
- Type: array<
,2>[,](,)[,]An array of size [ldquas, ]Note: ldquas must satisfy the constraint:
On exit: contains the n quasi-random numbers of dimension idim.If , holds the th value for the th dimension.If , holds the th value for the th dimension.
- if , ;
- if , .
- Type: array<
>()An array of size On entry: contains information on the current state of the sequence.On exit: contains updated information on the state of the sequence.
On exit: unless the method detects an error (see [Error Indicators and Warnings]).
Low discrepancy (quasi-random) sequences are used in numerical integration, simulation and optimization. Like pseudorandom numbers they are uniformly distributed but they are not statistically independent, rather they are designed to give more even distribution in multidimensional space (uniformity). Therefore they are often more efficient than pseudorandom numbers in multidimensional Monte–Carlo methods.
g05ym generates a set of points with high uniformity in the -dimensional unit cube .
Let be a subset of and define the counting function as the number of points . For each , let be the rectangular -dimensional region
with volume . Then one measure of the uniformity of the points is the discrepancy:
which has the form
The principal aim in the construction of low-discrepancy sequences is to find sequences of points in with a bound of this form where the constant is as small as possible.
Bratley P and Fox B L (1988) Algorithm 659: Implementing Sobol's Quasirandom Sequence Generator ACM Trans. Math. Software 14 (1) 88–100
Errors or warnings detected by the method:
Some error messages may refer to parameters that are dropped from this interface (ldquas) In these cases, an error in another parameter has usually caused an incorrect value to be inferred.
In this example the number of dimensions is set to .