Sensitivity analysis using Sobol’ indices

Consider the input random vector \vect{X} = \left( X_1,\ldots,X_{n_X} \right) and let \vect{Y} = \left( Y_1,\ldots,Y_{n_Y} \right) be the output of the physical model:

\vect{Y} = \operatorname{g}(\vect{X}).

We consider the output Y_k for any index k \in \{1, \ldots, n_Y\}. Sobol’ indices measure the influence of the input \vect{X} to the output Y_k. The method considers the part of the variance of the output Y_k produced by the different inputs X_i.

In the first part of this document, we introduce the Sobol’ indices of a scalar output Y_k. Hence, the model is simplified to:

Y = \operatorname{g}(\vect{X}).

In the second part of the document, we consider the general case where the output is multivariate. In this case, aggregated Sobol’ indices can be used [gamboa2013].

The Sobol’ decomposition is described more easily when the domain of the input is the unit interval [0,1]^{n_X}. It can be easily extended to any input domain using expectations, variances and variance of conditional expectations.

We assume that the input marginal variables X_1,\ldots,X_{n_X} are independent. This restrictive hypothesis implies that the only copula of the input random vector \bdX for which the Sobol’ indices are easy to interpret is the independent copula. If the input variables are dependent, then the Sobol’ indices can be defined, but some of their properties are lost.

Partition of the input

For any i\in\{1,\ldots, n_X\}, let \bdx_{\overline{\{i\}}} \in [0,1]^{n_X - 1} be the vector made of components of \bdx=(x_1,x_2, \ldots,x_p)\in [0,1]^{n_X } which indices are different from i. Hence, if \bdx\in[0,1]^{n_X}, then:

\bdx_{\overline{\{i\}}} = (x_1,x_2,\ldots,x_{i-1},x_{i+1},\ldots,x_p)^T\in [0,1]^{n_X - 1}.

Consider the function \operatorname{g} defined by the equation:

y = \operatorname{g}(\bdx)

where \bdx=(x_1,\ldots,x_p)^T \in [0,1]^{n_X}. With this notation, we can partition the input of g:

\operatorname{g}(\bdx) = \operatorname{g} \left(x_i,\bdx_{\overline{\{i\}}} \right).

The goal of sensitivity analysis is to measure the sensitivity of the variance of the output Y depending on the variable X_i. This may take into account the dependence of the output to the interactions of X_i and \bdX_{\overline{\{i\}}} through the function g.

More generally, let \bdu \subseteq \{1,2,\ldots,n_X\} be a group of variables. Therefore:

\operatorname{g}(\bdx) = \operatorname{g} \left(\bdx_\bdu,\bdx_{\overline{\bdu}} \right).

The goal of sensitivity analysis is to measure the sensitivity of the variance of the output Y depending on the group of variables \bdX_\bdu. This may take into account the dependence of the output to the interactions of \bdX_\bdu and \bdX_{\bdu} through the function g.

Sobol’ decomposition

In this section, we introduce the Sobol’-Hoeffding decomposition [sobol1993]. If \operatorname{g} can be integrated in [0,1]^{n_X}, then there is a unique decomposition:

y &= h_0 + \sum_{i=1,2,\ldots,n_X} h_{\{i\}}(x_i)
     \quad + \sum_{1\leq i < j \leq n_X} h_{\{i,j\}}(x_i,x_j) \nonumber \\
  & \quad+ \ldots +
         h_{\{1,2,\ldots,n_X\}}(x_1,x_2,\ldots,x_p),

where h_0 is a constant and the functions of the decomposition satisfy the equalities:

\int_0^1 h_{\{i_1,\ldots,i_s\}}(x_{i_1},\ldots,x_{i_s})dx_{i_k} = 0,

for any k=1,2,\ldots,s and any indices 1\leq i_1< i_2< \ldots< i_s\leq n_X and s=1,2,\ldots,n_X.

Extension to any input distribution with independent marginals

In this section, we extend the previous definitions to an input random vector that is not necessarily defined on the input unit cube [0,1]^{n_X}. To do this, we define the functions h_\bdu using conditional expectations.

The functions h_\bdu satisfy the equality:

\int_{[0,1]^{|\overline{\bdu}|}} \operatorname{g}(\bdx) d\bdx_{\overline{\bdu}}
= \sum_{\bdv \subseteq \bdu} h_\bdv(\bdx_\bdv),

for any group of variables \bdu \subseteq \{1,2,\ldots,n_X\} with size lower or equal to n_X, where |\overline{\bdu}| is the cardinal of the subset \overline{\bdu}. The functions h_\bdu can be defined recursively, using groups of variables of lower dimensionality:

h_\bdu(\bdx_\bdu)
= \int_{[0,1]^{|\overline{\bdu}|}} \operatorname{g}(\bdx_\bdu,\bdx_{\overline{\bdu}}) d\bdx_{\overline{\bdu}}
-  \sum_{\bdv \subsetneq \bdu} h_\bdv(\bdx_\bdv)

where \subsetneq denotes a proper subset. Let \boldsymbol{x} \in [0,1]^{n_X} be a point and let \bdu \subseteq \{1, \ldots, n_X\} be a group of variables. Therefore:

\Expect{Y|\bdX_\bdu=\bdx_\bdu}
= \sum_{\bdv \subseteq \bdu} h_\bdv(\bdx_\bdv).

The Möbius inversion formula implies (see [daveiga2022] Theorem 3.3 page 49):

h_\bdu(\bdx_\bdu)
= \sum_{\bdv \subseteq \bdu} (-1)^{|\bdu| - |\bdv|} \Expect{Y|\bdX_\bdv=\bdx_\bdv}.

The previous equation is a consequence of the Möbius inversion formula [rota1964] (also called the exclusion-inclusion principle).

Decomposition of the variance

The variance of the function \operatorname{g} can be decomposed into:

\Var{Y}=\sum_{i=1}^{n_X} V_{i}
+ \sum_{1\leq i < j\leq n_X} V_{\{i,j\}} + \ldots + V_{\{1,2,\ldots,n_X\}}

where the interaction variances are:

V_{i}        &= \Var{h_{\{i\}}(X_i)}, \label{eq-sde-varvi1-2} \\
V_{\{i,j\}}  &= \Var{h_{\{i, j\}}(X_i,X_j)}, \\
V_{\{i,j,\}} &= \Var{h_{i,j,k}(X_i,X_j,k)}, \\
\ldots       & \\
V_{\{1,2,\ldots,n_X\}} &= \Var{h_{\{1,2,\ldots,n_X\}}(X_1,X_2,\ldots,X_p)}.

More generally, the interaction variance of a group of variables is:

V_\bdu = \Var{h_\bdu(\bdx_\bdu)},

for any \bdu \subseteq \{1,2,\ldots,n_X\}. Using the Hoeffding decomposition, we get:

\Var{Y} = \sum_{ \bdu \subseteq \{1, \ldots, n_X\} } V_\bdu.

The Möbius inversion formula implies (see [daveiga2022] corrollary 3.5 page 52):

V_\bdu = \sum_{\bdv \subseteq \bdu} (-1)^{ |\bdu| - |\bdv| } \Var{\Expect{ Y \vert \mat{X}_\bdv} }.

Interaction sensitivity indices of a variable

The first order interaction sensitivity indices are equal to:

S_i           &= \frac{V_{i}}{\Var{Y}} , \\
S_{\{i,j\}}   &= \frac{V_{\{i,j\}}}{\Var{Y}} , \\
S_{\{i,j,k\}} &= \frac{V_{\{i,j,k\}}}{\Var{Y}} , \\
\ldots & \\
S_{\{i_1,i_2,\ldots,i_s\}} &= \frac{V_{\{i_1,i_2,\ldots,i_s\}}}{\Var{Y}}, \\
\ldots & \\
S_{\{1,2,\ldots,p\}} &= \frac{V_{\{1,2,\ldots,p\}}}{\Var{Y}}.

The first order Sobol’ index S_i measures the part of the variance of Y explained by X_i alone. The second order Sobol’ index S_{i,j} measures the part of the variance of Y explained by the interaction of X_i and X_j.

More generally, the first order interaction Sobol’ index of a group of variables \bdu is:

S_\bdu = \frac{V_\bdu}{\Var{Y}} = \frac{\Var{h_\bdu(\bdX_\bdu)}}{\Var{Y}}.

where h_\bdu is the function of the input variables in the group \bdu of the functional Sobol’-Hoeffding ANOVA decomposition of the physical model. This index measures the sensitivity of the variance of the output explained by interactions within the group.

The total interaction sensitivity index of the group \bdu is (see [liu2006]):

S^{T,i}_\bdu = \sum_{\bdv \supseteq \bdu} S_{\bdv}

This index measures the sensitivity of the variance of the output explained by interactions within the group and groups of variables containing it.

First order and total sensitivity indices of a variable

The first order Sobol’ sensitivity index is equal to the corresponding interaction index of the group \{i\}:

S_i &= S_{\{i\}}

for i=1,\ldots, n_X. The first order Sobol’ index S_i measures the sensitivity of the output variance explained by the effect of X_i alone. We can alternatively define the first order Sobol’ sensitivity index using the variance of a conditional expectation. The first order Sobol’ sensitivity index satisfies the equation:

S_i &= \frac{\Var{\Expect{Y|X_i}}}{\Var{Y}}

for i=1,\ldots, n_X.

The total Sobol’ sensitivity index is:

S^T_i &= \frac{V_{i} + \sum_{\substack{j\in\{1,\ldots, n_X\}\\j\neq i}} V_{\{i,j\}} + \ldots
V_{1, 2,\ldots, n_X}}{\Var{Y}}

for i=1,\ldots, n_X. The total Sobol’ sensitivity index can be equivalently defined in terms of the variance of a conditional expectation. The total Sobol’ sensitivity index satisfies the equation:

S^T_i &= 1 - \frac{\Var{\Expect{Y|X_{\overline{\{i\}}}}}}{\Var{Y}}

for