# Assessing Voltage Stability in Distribution Networks:
## 2 Modeling of Stochastic Variables Considering Correlation
### Generating Correlated Samples Based on Nataf Transformation  
When stochastic variables are correlated, 3 PEM cannot directly sample. To generate samples with correlations, Nataf transformation is used to process the correlation of variables, which involves three steps. Namely, conversion between non-normally distributed input variables and correlated standard normally distributed input variables, transformation of the correlation coefficient matrix, and conversion between correlated standard normally distributed input variables and independent standard normally distributed input variables.  
Assuming there is an n-dimensional stochastic variable \(X\) = [\(x_{1}\), \(x_{2}\), \(\cdots\), \(x_{n}\)] that follows arbitrary distributions, and the CDF of each stochastic variable \(x_{i}\) is \(F_{i}(x_{i})\), then, according to the principle of equal probability, the stochastic variable \(Y\) = [\(y_{1}\), \(y_{2}\), \(\cdots\), \(y_{n}\)] subject to the standard normal distribution can be obtained from Equation (13).  
\[y_{i}=\Phi^{-1}(F_{i}(x_{i})) \tag{13}\]  
In Equation (13), \(\Phi^{-1}\) represents the inverse of the CDF.  
The correlation coefficient matrix for \(X\) is \(p\) and for \(Y\) is \(p_{0}\). According to the Nataf transformation, the corresponding elements \(p_{ij}\) and \(p_{0 ij}\) (where \(i\
eq j\)) of \(p\) and \(p_{0}\) are not equal [25], and this relationship is shown in Equation (14):  
\[\begin{split}& p_{ij}=\int_{-\infty}^{+\infty}\int_{-\infty}^{+ \infty}\frac{x_{i}-\mu_{i}}{\sigma_{i}}\cdot\frac{x_{j}-\mu_{j}}{\sigma_{j}}f_ {ij}\big{(}x_{i},x_{j}\big{)}dx_{i}dx_{j}\\ &=\int_{-\infty}^{+\infty}\int_{-\infty}^{+\infty}\frac{F_{i}^{- 1}(\Phi(y_{i}))-\mu_{i}}{\sigma_{i}}\cdot\frac{F_{j}^{-1}\big{(}\Phi(y_{j}) \big{)}-\mu_{j}}{\sigma_{j}}\cdot\phi\big{(}y_{i},y_{j},p_{0 ij}\big{)}dy_{i}dy _{j}\end{split} \tag{14}\]  
where \(\mu_{i}\), \(\mu_{j}\), \(\sigma_{i}\), and \(\sigma_{j}\), respectively, denote the means and standard deviations of the stochastic variables \(x_{i}\) and \(x_{j}\); \(\phi\) (\(y_{i},y_{j},p_{0 ij}\)) is the joint PDF of a two-dimensional standard normal distribution with \(p_{0 ij}\).  
Because the correlation coefficient matrix \(p_{0}\) is a symmetric positive definite matrix, the lower triangular matrix \(L\) is acquired through Cholesky decomposition.  
\[p_{0}=LL^{\text{T}} \tag{15}\]  
After obtaining the correlated standard normal stochastic variables \(Y\) and matrix \(L\), we can derive the independent standard normal stochastic variables \(Z\) = [\(z_{1}\), \(z_{2}\), \(\cdots\), \(z_{n}\)] from Equation (16):  
\[Z=L^{-1}Y \tag{16}\]  
The process described above, where correlated stochastic variables \(X\) that follow any distribution are transformed into independent standard normal variables \(Z\), is known as the Nataf transformation. The samples of correlated stochastic variables that adhere to arbitrary distributions are constructed on the basis of the Nataf inverse transformation. The samples are obtained using Equation (17) [36]:  
\[X=F^{-1}(\Phi(LZ)) \tag{17}\]