<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="fr">
	<id>https://patrius.cnes.fr/index.php?action=history&amp;feed=atom&amp;title=User_Manual_4.10_Dispersions</id>
	<title>User Manual 4.10 Dispersions - Historique des versions</title>
	<link rel="self" type="application/atom+xml" href="https://patrius.cnes.fr/index.php?action=history&amp;feed=atom&amp;title=User_Manual_4.10_Dispersions"/>
	<link rel="alternate" type="text/html" href="https://patrius.cnes.fr/index.php?title=User_Manual_4.10_Dispersions&amp;action=history"/>
	<updated>2026-04-06T16:01:02Z</updated>
	<subtitle>Historique des versions pour cette page sur le wiki</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>https://patrius.cnes.fr/index.php?title=User_Manual_4.10_Dispersions&amp;diff=3221&amp;oldid=prev</id>
		<title>Admin : Page créée avec « __NOTOC__ == Introduction == === Scope === This section describes how dispersions are defined and used in the PATRIUS library. Dispersions are not to be mixed up with rand... »</title>
		<link rel="alternate" type="text/html" href="https://patrius.cnes.fr/index.php?title=User_Manual_4.10_Dispersions&amp;diff=3221&amp;oldid=prev"/>
		<updated>2022-11-10T08:53:47Z</updated>

		<summary type="html">&lt;p&gt;Page créée avec « __NOTOC__ == Introduction == === Scope === This section describes how dispersions are defined and used in the PATRIUS library. Dispersions are not to be mixed up with rand... »&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Nouvelle page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;__NOTOC__&lt;br /&gt;
== Introduction ==&lt;br /&gt;
=== Scope ===&lt;br /&gt;
This section describes how dispersions are defined and used in the PATRIUS library.&lt;br /&gt;
Dispersions are not to be mixed up with random generation (not detailed in this page). Dispersions always rely on a random generator.&lt;br /&gt;
&lt;br /&gt;
=== Javadoc ===&lt;br /&gt;
The dispersions objects are available in the package &amp;lt;code&amp;gt;fr.cnes.sirius.patrius.math.random&amp;lt;/code&amp;gt;. This package also handles random generation.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Library&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Javadoc&lt;br /&gt;
|-&lt;br /&gt;
|Patrius &lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/package-summary.html Package fr.cnes.sirius.patrius.math.random]&lt;br /&gt;
|-&lt;br /&gt;
|Patrius &lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/package-summary.html Package fr.cnes.sirius.patrius.math.random]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Links ===&lt;br /&gt;
None as of now.&lt;br /&gt;
&lt;br /&gt;
=== Useful Documents ===&lt;br /&gt;
None as of now.&lt;br /&gt;
&lt;br /&gt;
=== Package Overview ===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Features Description ==&lt;br /&gt;
=== Random number generation ===&lt;br /&gt;
Distributed random number generation is based on using implementations of interface &amp;lt;code&amp;gt;fr.cnes.sirius.patrius.math.random.NormalizedRandomGenerator&amp;lt;/code&amp;gt;.&lt;br /&gt;
Each implementation of this interface provides a specific dispersion scheme. For instance, the following code will generate random numbers with Gaussian distribution of mean 0 and unit standard deviation:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;java&amp;quot;&amp;gt;&lt;br /&gt;
final RandomGenerator g = new JDKRandomGenerator();&lt;br /&gt;
final NormalizedRandomGenerator generator = new GaussianRandomGenerator(g);&lt;br /&gt;
final double value = generator.nextNormalizedDouble();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As shown in the above example, building a dispersion object requires a random generator implementing &amp;lt;code&amp;gt;fr.cnes.sirius.patrius.math.random.RandomGenerator&amp;lt;/code&amp;gt; interface.&lt;br /&gt;
&lt;br /&gt;
=== Random vector generation ===&lt;br /&gt;
Correlated random vector generation is based on using implementations of interface &amp;lt;code&amp;gt;fr.cnes.sirius.patrius.math.random.RandomVectorGenerator&amp;lt;/code&amp;gt;.&lt;br /&gt;
Each implementation of this interface provides a specific dispersion scheme. For instance, the following code will generate uniformly correlated random vectors according to provided covariance matrix:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;java&amp;quot;&amp;gt;&lt;br /&gt;
final RandomGenerator g = new JDKRandomGenerator();&lt;br /&gt;
final RandomVectorGenerator generator = new UniformlyCorrelatedRandomVectorGenerator(mean, covariance, 0, g);&lt;br /&gt;
final double[] value = generator.nextVector();&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As shown in the above example, building a dispersion object requires a random generator implementing &amp;lt;code&amp;gt;fr.cnes.sirius.patrius.math.random.RandomGenerator&amp;lt;/code&amp;gt; interface.&lt;br /&gt;
&lt;br /&gt;
=== Correlated random vector generator ===&lt;br /&gt;
The user provides a covariance matrix and a random generator.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;When using Gaussian correlated random vector generator&amp;#039;&amp;#039;&amp;#039;:&lt;br /&gt;
* The covariance matrix root is extracted using a Cholesky decomposition. The number of columns of the root matrix corresponds to the rank of the provided covariance matrix.&lt;br /&gt;
* An uncorrelated vector of size the rank of the covariance matrix is generated using the provided random generator&lt;br /&gt;
* The final correlated vector is obtained by multiplying the covariance root matrix by this generated vector.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;When using uniformly correlated random vector generator&amp;#039;&amp;#039;&amp;#039;, the process is more complex:&lt;br /&gt;
* The covariance matrix is converted into a correlation matrix. Standard deviation vector is extracted from the process. Obtained correlation matrix must be positive semi-definite (all eigenvalues must be non negative).&lt;br /&gt;
* Spearman correction is applied to the correlation matrix. If corrected correlation matrix is not positive semi-definite, correction is not applied.&lt;br /&gt;
[[File:spearmanCorrection.png|center]]&lt;br /&gt;
* The correlation matrix root is extracted using a Cholesky decomposition. The number of columns of the root matrix corresponds to the rank of the correlation matrix.&lt;br /&gt;
* A uncorrelated vector of size the rank of the covariance matrix is generated using the provided random generator&lt;br /&gt;
* The product of correlation matrix root L and uncorrelated vector T is then transformed to get a uniform law:&lt;br /&gt;
[[File:uniformCorrection.png|center]]&lt;br /&gt;
* The final correlated vector is obtained by linearly multiplying z by the standard deviation vector.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
{{specialInclusion prefix=$theme section=&amp;quot;GettingStarted&amp;quot;/}}&lt;br /&gt;
&lt;br /&gt;
== Contents ==&lt;br /&gt;
=== Interfaces ===&lt;br /&gt;
The library defines the following interfaces related to dispersions:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Interface&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Summary&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Javadoc&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;NormalizedRandomGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Interface for normalized random generators&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/NormalizedRandomGenerator.html ...]&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;RandomVectorGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Interface for random vector generators&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/RandomVectorGenerator.html ...]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Note: interface for random number generators is &amp;lt;code&amp;gt;fr.cnes.sirius.patrius.math.random.RandomGenerator&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Classes ===&lt;br /&gt;
The library defines the following classes related to dispersions:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Class&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Summary&lt;br /&gt;
! scope=&amp;quot;col&amp;quot;| Javadoc&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;GaussianRandomGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Generator following Gaussian distribution&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/GaussianRandomGenerator.html ...]&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;UniformRandomGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Generator following uniform distribution&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/UniformRandomGenerator.html ...]&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;UncorrelatedRandomVectorGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Generator for Gaussian uncorrelated vectors&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/UncorrelatedRandomVectorGenerator.html ...]&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;CorrelatedRandomVectorGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Generator for Gaussian correlated vectors&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/CorrelatedRandomVectorGenerator.html ...]&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;UniformlyCorrelatedRandomVectorGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Generator for uniformly correlated vectors&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/UniformlyCorrelatedRandomVectorGenerator.html ...]&lt;br /&gt;
|-&lt;br /&gt;
|&amp;#039;&amp;#039;&amp;#039;UnitSphereRandomVectorGenerator&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
|Generator for vectors isotropically located on a sphere&lt;br /&gt;
|[{{JavaDoc4.10}}/fr/cnes/sirius/patrius/math/random/UnitSphereRandomVectorGenerator.html ...]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
[[Category:User_Manual_4.10_Mathematics]]&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>