public class MultiOrbitalCovariance extends AbstractOrbitalCovariance<MultiOrbitalCovariance>
This class associates a Covariance instance with multiple orbits, their common date being the date of definition of the orbital covariance. The frame, orbit type (Cartesian, Keplerian, etc) and position angle type (mean, true, eccentric) in which the Covariance is expressed are specified at construction.
The covariance matrix must be at least N by N, where N is the number of orbits multiplied by the number of orbital
parameters (SpacecraftState.ORBIT_DIMENSION
). Nevertheless, it can have a bigger size to take into
account additional parameters. The latter can be of two different nature:
The parameter descriptors of orbital parameters must be associated to an orbital coordinate descriptor, and these descriptors must be mapped to a valid OrbitalCoordinate (one with the expected orbit type and state vector index).
ORBIT_DIMENSION, ORBITAL_COORDINATE_DESCRIPTOR
Constructor and Description |
---|
MultiOrbitalCovariance(Covariance covariance,
Collection<Orbit> orbits,
int[] nbAdditionalParametersIn,
Frame frame,
OrbitType orbitType,
PositionAngle positionAngle)
Creates a new instance that associates a covariance matrix with multiple orbits, the
covariance being defined in the specified frame, orbit type and position angle type.
|
MultiOrbitalCovariance(SymmetricPositiveMatrix covarianceMatrix,
Collection<Orbit> orbits,
int[] nbAdditionalParametersIn,
Frame frame,
OrbitType orbitType,
PositionAngle positionAngle)
Creates a new instance that associates a covariance matrix with multiple orbits, the
covariance being defined in the specified frame, orbit type and position angle type.
|
Modifier and Type | Method and Description |
---|---|
MultiOrbitalCovariance |
copy()
Gets a copy of this orbital covariance.
|
boolean |
equals(Object object) |
AbsoluteDate |
getDate()
Get the date.
|
Orbit |
getOrbit(int index)
Gets a specific orbit from the list of associated orbits.
|
OrbitalCovariance |
getOrbitalCovariance(int index)
Extracts the orbital covariance of the selected orbit.
By default, does not include the additional parameters that are not attached to any orbit.
|
OrbitalCovariance |
getOrbitalCovariance(int index,
boolean includeNonOrbitalAdditionalParameters)
Extracts the orbital covariance of the selected orbit.
|
List<Orbit> |
getOrbits()
Gets the list of associated orbits.
|
Covariance |
getRelativeCovariance(int index1,
int index2)
Computes the relative covariance between two orbits.
|
ArrayRowSymmetricPositiveMatrix |
getRelativeCovarianceMatrix(int index1,
int index2)
Computes the relative covariance matrix between two orbits.
|
int |
hashCode() |
MultiOrbitalCovariance |
shiftedBy(double dt)
Shifts the orbital covariance in time by a given duration.
|
MultiOrbitalCovariance |
transformTo(Frame destFrame,
OrbitType destOrbitType,
PositionAngle destPositionAngle)
Transforms this orbital covariance to the specified frame, orbit type and position angle
type.
|
MultiOrbitalCovariance |
transformTo(int index,
LOFType lofType,
boolean frozenLof)
Transforms this orbital covariance to a local orbital frame centered on a given orbit.
|
MultiOrbitalCovariance |
transformTo(Orbit referenceOrbit,
LOFType lofType,
boolean frozenLof)
Transforms this orbital covariance to a local orbital frame centered on a given orbit.
|
checkCovarianceMatrixDimension, checkCovarianceMatrixDimension, checkOrbit, checkParameterDescriptors, checkParameterDescriptors, convertParameterDescriptors, getCovariance, getCovarianceMatrix, getFrame, getOrbitType, getParameterDescriptors, getPositionAngle, initParameterDescriptors, requireNonEmpty, requireNonNull, toString, toString, toString, toString, transformTo, transformTo, transformTo, transformTo, transformTo
public MultiOrbitalCovariance(SymmetricPositiveMatrix covarianceMatrix, Collection<Orbit> orbits, int[] nbAdditionalParametersIn, Frame frame, OrbitType orbitType, PositionAngle positionAngle)
The covariance matrix must be at least N by N, where N is the number of orbits multiplied by the number of orbital parameters. Each orbit is associated with K consecutive rows/columns, where the first six represent the uncertainty on the orbital parameters and the remaining ones represent the uncertainty on the additional parameters. The parameter descriptors of these first six rows/columns are automatically associated with an orbital coordinate descriptor, mapped to a valid OrbitalCoordinate.
Note that additional parameters that are not related to any orbit can be present at the end of the covariance matrix
covarianceMatrix
- the covariance matrixorbits
- the orbits associated with the covariancenbAdditionalParametersIn
- the number of additional parameters for each orbitframe
- the frame of the covarianceorbitType
- the orbit type of the covariancepositionAngle
- the position angle type of the covarianceIllegalArgumentException
- if any of the provided arguments is null
or if the orbits collection is null
or empty or if all the orbits aren't defined at the same datepublic MultiOrbitalCovariance(Covariance covariance, Collection<Orbit> orbits, int[] nbAdditionalParametersIn, Frame frame, OrbitType orbitType, PositionAngle positionAngle)
The covariance matrix must be at least N by N, where N is the number of orbits multiplied by the number of orbital parameters. Each orbit is associated with K consecutive rows/columns, where the first six represent the uncertainty on the orbital parameters and the remaining ones represent the uncertainty on the additional parameters. The parameter descriptors of these first six rows/columns must be associated to an orbital coordinate descriptor, and these descriptors must be mapped to a valid OrbitalCoordinate (one with the expected orbit type and state vector index).
Note that additional parameters that are not related to any orbit can be present at the end of the covariance matrix
covariance
- the covariance matrixorbits
- the orbits associated with the covariancenbAdditionalParametersIn
- the number of additional parameters for each orbitframe
- the frame of the covarianceorbitType
- the orbit type of the covariancepositionAngle
- the position angle type of the covarianceIllegalArgumentException
- if any of the provided arguments is null
or if the orbits collection is null
or empty or if all the orbits aren't defined at the same datepublic AbsoluteDate getDate()
public List<Orbit> getOrbits()
public Orbit getOrbit(int index)
index
- the index of the orbit to be retrievedIllegalArgumentException
- if the provided index is invalidpublic OrbitalCovariance getOrbitalCovariance(int index)
index
- the index of the selected orbit in the orbits listIllegalArgumentException
- if the provided index is invalidpublic OrbitalCovariance getOrbitalCovariance(int index, boolean includeNonOrbitalAdditionalParameters)
index
- the index of the selected orbit in the orbits listincludeNonOrbitalAdditionalParameters
- include the additional parameters that are not attached to any orbit (if true)IllegalArgumentException
- if the provided index is invalidpublic Covariance getRelativeCovariance(int index1, int index2)
The relative covariance matrix is defined by:
Crel = Ci + Cj -Ci,j -Cj,i
where Ci and Cj are the covariance submatrices related representing the
uncertainty on the orbital parameters of the ith and jth orbits, and
where Ci,j and Cj,i are the submatrices representing the correlations
between the orbital parameters of the two orbits.
As an example, for three satellites the complete covariance matrix would be:
[C1, C1,2, C1,3]
[C2,1, C2, C2,3]
[C3,1, C3,2, C3]
The parameter descriptors associated with the relative covariance matrix are built by intersecting the parameter descriptors describing the same orbital coordinate. This intersection only keeps the identical field descriptors and may result in an empty parameter descriptor if the orbital coordinate descriptors are mapped to different kind of orbital coordinates. Since Covariance instances do not allow empty parameter descriptors, an exception is thrown if that occurs.
index1
- the index of the first selected orbit in the list of associated orbitsindex2
- the index of the second selected orbit in the list of associated orbitspublic ArrayRowSymmetricPositiveMatrix getRelativeCovarianceMatrix(int index1, int index2)
The relative covariance matrix is defined by:
Crel = Ci + Cj -Ci,j -Cj,i
where Ci and Cj are the covariance submatrices related representing the
uncertainty on the orbital parameters of the ith and jth orbits, and
where Ci,j and Cj,i are the submatrices representing the correlations
between the orbital parameters of the two orbits.
As an example, for three satellites the complete covariance matrix would be:
[C1, C1,2, C1,3]
[C2,1, C2, C2,3]
[C3,1, C3,2, C3]
index1
- the index of the first selected orbit in the list of associated orbitsindex2
- the index of the second selected orbit in the list of associated orbitspublic MultiOrbitalCovariance shiftedBy(double dt) throws PatriusException
The shift of the orbital covariance is based on a simple Keplerian model. It is not intended as a replacement for proper covariance propagation, but it should be sufficient for small time shifts or coarse accuracy.
dt
- the time shiftPatriusException
- if the Keplerian transition matrix cannot be computedpublic MultiOrbitalCovariance transformTo(Frame destFrame, OrbitType destOrbitType, PositionAngle destPositionAngle) throws PatriusException
Important:
The use of non-Cartesian coordinates types may be incompatible with some frames (e.g. local
orbital frames).
transformTo
in class AbstractOrbitalCovariance<MultiOrbitalCovariance>
destFrame
- the destination framedestOrbitType
- the destination orbit typedestPositionAngle
- the destination position angle typePatriusException
- if the orbital covariance cannot be transformed to the specified frame, orbit type
and position angle typepublic MultiOrbitalCovariance transformTo(int index, LOFType lofType, boolean frozenLof) throws PatriusException
Important:
The returned covariance is defined in Cartesian coordinates,
in the specified LOFType. Note that the local orbital frame uses the reference
orbit as its PVCoordinatesProvider, which relies on a simple Keplerian model for
the propagation. The LOF built is therefore only valid locally, at the date of the reference
orbit, unless it is frozen at this date (the LOF then becomes an inertial frame which can be
used at other dates).
index
- the index of the selected orbit in the list of associated orbits, which will be used
to build the local orbital framelofType
- the type of the local orbital framefrozenLof
- whether or not the local orbital frame built should be frozen at the date of the
reference orbitPatriusException
- if the orbital covariance cannot be transformed to the specified local orbital framepublic MultiOrbitalCovariance transformTo(Orbit referenceOrbit, LOFType lofType, boolean frozenLof) throws PatriusException
The reference orbit must be defined at the same date as the covariance.
Important:
The returned covariance is defined in Cartesian coordinates,
in the specified LOFType. Note that the local orbital frame uses the reference
orbit as its PVCoordinatesProvider, which relies on a simple Keplerian model for
the propagation. The LOF built is therefore only valid locally, at the date of the reference
orbit, unless it is frozen at this date (the LOF then becomes an inertial frame which can be
used at other dates).
referenceOrbit
- the orbit used to build the local orbital framelofType
- the type of the local orbital framefrozenLof
- whether or not the local orbital frame built should be frozen at the date of the
reference orbitPatriusException
- if the orbital covariance cannot be transformed to the specified local orbital framepublic MultiOrbitalCovariance copy()
This method performs a shallow copy of the associated covariance (shallow copy of the parameter descriptors list, deep copy of the covariance matrix) and a shallow copy of the list of orbits (which are immutable). The frame, orbit type and position angle type are all passed by reference since they are immutable.
Covariance.copy()
public boolean equals(Object object)
equals
in class AbstractOrbitalCovariance<MultiOrbitalCovariance>
public int hashCode()
hashCode
in class AbstractOrbitalCovariance<MultiOrbitalCovariance>
Copyright © 2023 CNES. All rights reserved.