PCEWithGLSorGGMR

class PCEWithGLSorGGMR(inputSample, outputSample, distribution, VYCollection, multivariateBasis, totalDegree, maximumBasisSize, selectedIndices=None, leastSquaresMethod='GLS')

Build a Polynomial Chaos Expansion (PCE) metamodel using Generalized Least Squares (GLS) or GLS with Generalized Golgi-Morse Regularization (GGMR).

Parameters:
inputSampleSample

Input sample of shape (n_samples, n_input_vars).

outputSampleSample

Output sample of shape (n_samples, 1).

distributionDistribution

Probability distribution of the input variables.

VYCollectionsequence of CovarianceMatrix

Covariance matrices for each output column (length = outputSample.getDimension()).

multivariateBasisOrthogonalBasis

Orthogonal basis for the PCE (e.g., Legendre, Hermite).

totalDegreeint

Maximum total degree of the polynomial basis.

maximumBasisSizeint

Maximum number of basis functions to retain. If the total basis size exceeds this, the least significant coefficients are discarded.

selectedIndicesIndicesCollection, optional

Pre-selected indices of basis functions to use. If None, all indices up to totalDegree are considered. Default is None.

leastSquaresMethod{“GLS”, “GGMR”}, optional

Method to solve the least squares problem. Default is “GLS”.

Attributes:
resultFunctionalChaosResult

The PCE metamodel (available after calling run()).

covMCollectionlist of CovarianceMatrix

Covariance matrices for the PCE coefficients.

Methods

getResult()

Return the functional chaos result.

run()

Build the PCE metamodel and compute its coefficients.

Notes

The method automatically selects the most significant basis functions if maximumBasisSize is smaller than the total basis size. For multi-output problems (outputSample dimension > 1), only the first column is currently supported (see FIXME in code).

__init__(inputSample, outputSample, distribution, VYCollection, multivariateBasis, totalDegree, maximumBasisSize, selectedIndices=None, leastSquaresMethod='GLS')
getResult()

Return the functional chaos result.

Returns:
resultFunctionalChaosResult

The metamodel.

covMCollectionsequence of CovarianceMatrix

Sequence of covariance matrices associated to each coefficient set (one per column of output sample).

run()

Build the PCE metamodel and compute its coefficients.

Steps: 1. Construct the design matrix from the input sample and basis functions. 2. Solve the GLS problem to estimate coefficients. 3. If necessary, truncate the basis to maximumBasisSize and re-fit. 4. Store the result in result and covMCollection.

Raises:
NotImplementedError

If outputSample has dimension > 1 (not yet supported).