SSJ  3.3.1
Stochastic Simulation in Java
Public Member Functions | List of all members
Palpha Class Reference

Extends the class Discrepancy and implements the methods required to compute the \(P_{\alpha}\) figure of merit for a lattice point set \(\Psi_s\) which is the intersection of a lattice \(L\) and the unit hypercube \([0, 1)^s\) in \(s\) dimensions. More...

Inheritance diagram for Palpha:
[legend]
Collaboration diagram for Palpha:
[legend]

Public Member Functions

 Palpha (double[][] points, int n, int s, double[] beta, int alpha)
 Constructor with \(n\) points in \(s\) dimensions and with alpha \(= \alpha\). More...
 
 Palpha (double[][] points, int n, int s, int alpha)
 Constructor with all \(\beta_j = 1\) (see eq. More...
 
 Palpha (int n, int s, double[] beta, int alpha)
 Constructor with \(n\) points in \(s\) dimensions and with alpha \(= \alpha\). More...
 
 Palpha (int alpha)
 Constructor with parameter alpha \(= \alpha\). More...
 
 Palpha (Rank1Lattice set, double[] beta, int alpha)
 Constructor with the lattice set with weights beta[j] \(=\beta_j\) and parameter alpha \(= \alpha\). More...
 
double compute (double[][] points, int n, int s)
 Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points. More...
 
double compute (double[][] points, int n, int s, double[] beta)
 Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points, with weights \(\beta_j=\) beta[j].
 
double compute (double[][] points, int n, int s, int alpha)
 Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points, with all weights \(\beta_j=1\) and \(\alpha=\) alpha. More...
 
double compute (double[][] points, int n, int s, double[] beta, int alpha)
 Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points, with weights \(\beta_j=\) beta[j] and with \(\alpha=\) alpha. More...
 
String toString ()
 
void setBeta (double[] beta)
 Sets the values of \(\beta_j = \mathtt{beta[j]}, j = 0, …, s\), where \(s\) is the dimension of the points.
 
- Public Member Functions inherited from Discrepancy
 Discrepancy (double[][] points, int n, int s)
 Constructor with the \(n\) points points[i] in \(s\) dimensions. More...
 
 Discrepancy (double[][] points, int n, int s, double[] gamma)
 Constructor with the \(n\) points points[i] in \(s\) dimensions and the \(s\) weight factors gamma[ \(j\)], \(j = 0, 1, …, (s-1)\). More...
 
 Discrepancy (int n, int s, double[] gamma)
 The number of points is \(n\), the dimension \(s\), and the \(s\) weight factors are gamma[ \(j\)], \(j = 0, 1, …, (s-1)\). More...
 
 Discrepancy (PointSet set)
 Constructor with the point set set. More...
 
 Discrepancy ()
 Empty constructor. More...
 
double compute ()
 Computes the discrepancy of all the points in maximal dimension (dimension of the points).
 
double compute (int s)
 Computes the discrepancy of all the points in dimension \(s\).
 
double compute (double[][] points, int n, int s, double[] gamma)
 Computes the discrepancy of the first n points of points in dimension s with weights gamma.
 
abstract double compute (double[][] points, int n, int s)
 Computes the discrepancy of the first n points of points in dimension s with weights \(=1\).
 
double compute (double[][] points)
 Computes the discrepancy of all the points of points in maximum dimension. More...
 
double compute (double[] T, int n)
 Computes the discrepancy of the first n points of T in 1 dimension. More...
 
double compute (double[] T)
 Computes the discrepancy of all the points of T in 1 dimension. More...
 
double compute (double[] T, int n, double gamma)
 Computes the discrepancy of the first n points of T in 1 dimension with weight gamma.
 
double compute (PointSet set, double[] gamma)
 Computes the discrepancy of all the points in set in the same dimension as the point set and with weights gamma.
 
double compute (PointSet set)
 Computes the discrepancy of all the points in set in the same dimension as the point set. More...
 
int getNumPoints ()
 Returns the number of points \(n\).
 
int getDimension ()
 Returns the dimension of the points \(s\).
 
void setPoints (double[][] points, int n, int s)
 Sets the points to points and the dimension to \(s\). More...
 
void setPoints (double[][] points)
 Sets the points to points. More...
 
void setGamma (double[] gam, int s)
 Sets the weight factors to gam for each dimension up to \(s\).
 
double [] getGamma ()
 Returns the weight factors gamma for each dimension up to \(s\).
 
String toString ()
 Returns the parameters of this class.
 
String formatPoints ()
 Returns all the points of this class.
 
String getName ()
 Returns the name of the Discrepancy.
 

Additional Inherited Members

- Static Public Member Functions inherited from Discrepancy
static double [][] toArray (PointSet set)
 Returns all the \(n\) points ( \(s\)-dimensional) of umontreal.ssj.hups.PointSet set as an array points[ \(n\)][ \(s\)].
 
static DoubleArrayList sort (double[] T, int n)
 Sorts the first \(n\) points of \(T\). More...
 
- Protected Member Functions inherited from Discrepancy
void appendGamma (StringBuffer sb, double[] gamma, int s)
 
- Static Protected Member Functions inherited from Discrepancy
static void setONES (int s)
 
- Protected Attributes inherited from Discrepancy
double [] gamma
 
double [][] Points
 
int dim
 
int numPoints
 
- Static Protected Attributes inherited from Discrepancy
static double [] ONES = { 1 }
 
- Static Package Attributes inherited from Discrepancy
static final double UNSIX = 1.0/6.0
 
static final double QUARAN = 1.0/42.0
 
static final double UNTRENTE = 1.0 / 30.0
 
static final double DTIERS = 2.0 / 3.0
 
static final double STIERS = 7.0 / 3.0
 
static final double QTIERS = 14.0 / 3.0
 

Detailed Description

Extends the class Discrepancy and implements the methods required to compute the \(P_{\alpha}\) figure of merit for a lattice point set \(\Psi_s\) which is the intersection of a lattice \(L\) and the unit hypercube \([0, 1)^s\) in \(s\) dimensions.

\(\Psi_s\) contains \(n\) points. For an arbitrary integer \(\alpha> 1\), it is defined as [220], [82], [80]

\[ P_{\alpha}(s) = \sum_{\mathbf{0\neq h}\in L_s^*} \|\mathbf{h}\|^{-\alpha}, \]

where \(L_s^*\) is the lattice dual to \(L_s\), and the norm is defined as \(\|\mathbf{h}\| = \prod^s_{j=1} \max\{1, |h_j|\}\). When \(\alpha\) is even, \(P_{\alpha}\) can be evaluated explicitly as

\[ \qquad P_{\alpha}(s) = -1 + \frac{1}{n}\sum_{i=1}^n \prod_{j=1}^s \left[1 - \frac{(-1)^{\alpha/2}(2\pi)^{\alpha}}{\alpha!} B_{\alpha}(u_{ij})\right], \tag{palpha.1} \]

where \(u_{ij}\) is the \(j\)-th coordinate of point \(i\), and \(B_{\alpha}(x)\) is the Bernoulli polynomial of degree \(\alpha\) (see umontreal.ssj.util.Num.bernoulliPoly in class util/Num).

One may generalize the \(P_{\alpha}\) by introducing a weight for each dimension to give the weighted \(P_{\alpha}\) defined by [82]

\[ P_{\alpha}(s) = \sum_{\mathbf{0\neq h}\in L_s^*}\beta_I^2 \|\mathbf{h}\|^{-\alpha}, \]

where the weights are such that \(\beta_I =\beta_0\prod_{j=1}^s\beta_j^{\alpha}\), and for even \(\alpha\)

\[ \qquad P_{\alpha}(s) = \beta_0 \left\{-1 + \frac{1}{n}\sum_{i=1}^n \prod_{j=1}^s \left[1 - \frac{(-1)^{\alpha/2}(2\pi\beta_j)^{\alpha}}{\alpha!} B_{\alpha}(u_{ij})\right] \right\}. \tag{palpha.2} \]

One recovers the original criterion ( palpha.1 ) for \(P_{\alpha}\) by choosing all \(\beta_j = 1\).

Constructor & Destructor Documentation

◆ Palpha() [1/5]

Palpha ( double  points[][],
int  n,
int  s,
double []  beta,
int  alpha 
)

Constructor with \(n\) points in \(s\) dimensions and with alpha \(= \alpha\).

points[i][j] is the \(j\)-th coordinate of point \(i\). Both i and j start at 0. The weights beta[j], \(j=0, 1,…, s\) are as in eq. ( palpha.2 ). The points and dimensions in ( palpha.2 ) are \(u_{ij} = \) points[i-1][j-1], but \(\beta_j = \) beta[j]. Restriction: alpha \( \in\{2, 4, 6, 8\}\).

◆ Palpha() [2/5]

Palpha ( double  points[][],
int  n,
int  s,
int  alpha 
)

Constructor with all \(\beta_j = 1\) (see eq.

( palpha.1 )).

◆ Palpha() [3/5]

Palpha ( int  n,
int  s,
double []  beta,
int  alpha 
)

Constructor with \(n\) points in \(s\) dimensions and with alpha \(= \alpha\).

The \(n\) points will be chosen later. The weights beta[j], \(j=0, 1,…, s\) are as in eq. ( palpha.2 ), with \(\beta_j = \) beta[j]. Restriction: alpha \( \in\{2, 4, 6, 8\}\).

◆ Palpha() [4/5]

Palpha ( int  alpha)

Constructor with parameter alpha \(= \alpha\).

The points and parameters must be defined before calling methods of this class. Restriction: alpha \( \in\{2, 4, 6, 8\}\).

◆ Palpha() [5/5]

Palpha ( Rank1Lattice  set,
double []  beta,
int  alpha 
)

Constructor with the lattice set with weights beta[j] \(=\beta_j\) and parameter alpha \(= \alpha\).

All the points are copied in an internal array. Restriction: alpha \( \in\{2, 4, 6, 8\}\).

Member Function Documentation

◆ compute() [1/3]

double compute ( double  points[][],
int  n,
int  s 
)

Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points.

All weights \(\beta_j = 1\).

◆ compute() [2/3]

double compute ( double  points[][],
int  n,
int  s,
int  alpha 
)

Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points, with all weights \(\beta_j=1\) and \(\alpha=\) alpha.

Restriction: alpha \( \in\{2, 4, 6, 8\}\).

◆ compute() [3/3]

double compute ( double  points[][],
int  n,
int  s,
double []  beta,
int  alpha 
)

Computes the discrepancy ( shift1lat ) for the \(s\)-dimensional points of lattice points, containing \(n\) points, with weights \(\beta_j=\) beta[j] and with \(\alpha=\) alpha.

Restriction: alpha \( \in\{2, 4, 6, 8\}\).


The documentation for this class was generated from the following file: