GPCorrelation

De GENOPUS
Aller à la navigation Aller à la recherche

How to call it

For using the GPCorrelation class, the developer has only to create such an object as is:

gpCor = new GPCorrelation();

or:

gpCor = new GPCorrelation("widgetId", "MyMatrix");

Display

We will get:

GPCorrelation0.png

By selecting the type of parameters, we may enter data for correlation/covariance matrix for Keplerian/Cartesian/LOF cartesians parameters. The different displays will be:

  • In case of Keplerian parameters:

GPCorrelation1.png

  • In case of cartesian parameters:

GPCorrelation2.png

  • In case of LOF cartesian parameters:

GPCorrelation3.png

So we may have a covariance matrix rather than a correlation one:

GPCorrelation4.png

If the initial correlation (resp. covariance) matrix is not null, a specific pop-up window will appear to ask for the type of conversion. A bit as for the GPOrbit widget, it will be possible to do this conversion between correlation and covariance matrices (but not between the different type of parameters) using a kind of “pivot” notion.

GPCorrelation6.png

GPCorrelation5.png => GPCorrelation7.png

How to use it

There are no exactly corresponding correlation/covariance matrices inside PATRIUS but GENOPUS gives some utility classes and methods to use them.

In the examples below, we can get data inside PATRIUS RealMatrix or Realvector objects.

final GPCorrelationData data = gpCor.getGpCorrelationData();
final RealMatrix corMat = data.getCorrelationMatrix();
final RealMatrix covMat = data.getCovarianceMatrix();
final RealMatrix sqrtRootcovMat = data.getSqrtCovarianceMatrix();
final RealVector sigma = data.getSigma();

How it is stored

Here is an example of the XML format:

  <!--Type of matrix:-->
  <String name="matrixType">CORRELATION</String>
  <!--Type of parameters:-->
  <String name="type">LOF</String>
  <!--LOF types:-->
  <String name="lofType">LVLH</String>
  <!--Absolute velocity:-->
  <Boolean name="velocityType">true</Boolean>
  <Real name="Sigma_x" unit="m">1.0E1</Real>
  <Real name="Rho_x/y">5.0E-1</Real>
  <Real name="Rho_x/z">0.0E0</Real>
  <Real name="Rho_x/vx">0.0E0</Real>
  <Real name="Rho_x/vy">0.0E0</Real>
  <Real name="Rho_x/vz">0.0E0</Real>
  <Real name="Sigma_y" unit="m">2.0E4</Real>
  <Real name="Rho_y/z">0.0E0</Real>
  <Real name="Rho_y/vx">0.0E0</Real>
  <Real name="Rho_y/vy">0.0E0</Real>
  <Real name="Rho_y/vz">0.0E0</Real>
  <Real name="Sigma_z" unit="m">3.0E4</Real>
  <Real name="Rho_z/vx">0.0E0</Real>
  <Real name="Rho_z/vy">0.0E0</Real>
  <Real name="Rho_z/vz">0.0E0</Real>
  <Real name="Sigma_vx" unit="m/s">1.0E2</Real>
  <Real name="Rho_vx/vy">0.0E0</Real>
  <Real name="Rho_vx/vz">0.0E0</Real>
  <Real name="Sigma_vy" unit="m/s">2.0E2</Real>
  <Real name="Rho_vy/vz">0.0E0</Real>
  <Real name="Sigma_vz" unit="m/s">3.0E2</Real>