1   /* Copyright 2002-2024 CS GROUP
2    * Licensed to CS GROUP (CS) under one or more
3    * contributor license agreements.  See the NOTICE file distributed with
4    * this work for additional information regarding copyright ownership.
5    * CS licenses this file to You under the Apache License, Version 2.0
6    * (the "License"); you may not use this file except in compliance with
7    * the License.  You may obtain a copy of the License at
8    *
9    *   http://www.apache.org/licenses/LICENSE-2.0
10   *
11   * Unless required by applicable law or agreed to in writing, software
12   * distributed under the License is distributed on an "AS IS" BASIS,
13   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   * See the License for the specific language governing permissions and
15   * limitations under the License.
16   */
17  package org.orekit.files.ccsds.ndm.cdm;
18  
19  import org.hipparchus.linear.MatrixUtils;
20  import org.hipparchus.linear.RealMatrix;
21  import org.orekit.errors.OrekitException;
22  import org.orekit.errors.OrekitMessages;
23  import org.orekit.files.ccsds.section.CommentsContainer;
24  
25  /**
26   * Container for XYZ covariance matrix data. This class as a RealMatrix as
27   * attribute which can be acces with getXYZCovariaxMatrix method. Beware that
28   * there are thus 2 ways to modify the XYZ covariance : setC... ( setCxx,
29   * setCyx ...) which should be prioritized and getXYZCovariaxMatrix.setEntry(row, col, value).
30   * <p> The XYZ Covariance Matrix is only provided if {@link CdmMetadataKey#ALT_COV_TYPE} is {@link AltCovarianceType#XYZ}, otherwise
31   * its terms will return NaN. </p>
32   * <p> When available, the matrix is given in the 9×9 Lower Triangular Form. All parameters of the 6×6 position/velocity submatrix
33   * are mandatory. The remaining elements will return NaN if not provided.</p>
34   */
35  public class XYZCovariance extends CommentsContainer {
36  
37      /** XYZ covariance matrix. */
38      private RealMatrix covarianceMatrix;
39  
40      /** Flag indicating whether the alternate covariance type set in the CDM Object metadata section is XYZ. */
41      private boolean covXYZset;
42  
43      /** Simple constructor. To update matrix value there are 2 ways to modify the XYZ
44       * covariance : setC... ( setCxx, setCyx ...) which should be prioritized and
45       * getXYZCovariaxMatrix.setEntry(row, col, value).
46       * <p> The XYZ Covariance Matrix is only provided if {@link CdmMetadataKey#ALT_COV_TYPE} is {@link AltCovarianceType#XYZ}, otherwise
47       * its terms will return NaN. </p>
48       * <p> When available, the matrix is given in the 9×9 Lower Triangular Form. All parameters of the 6×6 position/velocity submatrix
49       * are mandatory. The remaining elements will return NaN if not provided.</p>
50       * @param covXYZset Flag indicating whether the alternate covariance type set in the CDM Object metadata section is XYZ.
51       */
52      public XYZCovariance(final boolean covXYZset) {
53          this.covXYZset = covXYZset;
54          covarianceMatrix = MatrixUtils.createRealMatrix(9, 9);
55          for (int i = 0; i < covarianceMatrix.getRowDimension(); ++i) {
56              for (int j = 0; j <= i; ++j) {
57                  covarianceMatrix.setEntry(i, j, Double.NaN);
58              }
59          }
60  
61      }
62  
63      /** {@inheritDoc} */
64      @Override
65      public void validate(final double version) {
66          super.validate(version);
67  
68          // Conditional on ALT_COV_TYPE = XYZ
69          if (!isCovXYZset()) {
70              throw new OrekitException(OrekitMessages.CCSDS_DATE_INVALID_PREAMBLE_FIELD, CdmMetadataKey.ALT_COV_TYPE);
71          }
72  
73          // We only check values that are mandatory in a cdm file
74          checkNotNaN(getCxx(),              XYZCovarianceKey.CX_X.name());
75          checkNotNaN(getCyx(),              XYZCovarianceKey.CY_X.name());
76          checkNotNaN(getCyy(),              XYZCovarianceKey.CY_Y.name());
77          checkNotNaN(getCzx(),              XYZCovarianceKey.CZ_X.name());
78          checkNotNaN(getCzy(),              XYZCovarianceKey.CZ_Y.name());
79          checkNotNaN(getCzz(),              XYZCovarianceKey.CZ_Z.name());
80          checkNotNaN(getCxdotx(),           XYZCovarianceKey.CXDOT_X.name());
81          checkNotNaN(getCxdoty(),           XYZCovarianceKey.CXDOT_Y.name());
82          checkNotNaN(getCxdotz(),           XYZCovarianceKey.CXDOT_Z.name());
83          checkNotNaN(getCxdotxdot(),        XYZCovarianceKey.CXDOT_XDOT.name());
84          checkNotNaN(getCydotx(),           XYZCovarianceKey.CYDOT_X.name());
85          checkNotNaN(getCydoty(),           XYZCovarianceKey.CYDOT_Y.name());
86          checkNotNaN(getCydotz(),           XYZCovarianceKey.CYDOT_Z.name());
87          checkNotNaN(getCydotxdot(),        XYZCovarianceKey.CYDOT_XDOT.name());
88          checkNotNaN(getCydotydot(),        XYZCovarianceKey.CYDOT_YDOT.name());
89          checkNotNaN(getCzdotx(),           XYZCovarianceKey.CZDOT_X.name());
90          checkNotNaN(getCzdoty(),           XYZCovarianceKey.CZDOT_Y.name());
91          checkNotNaN(getCzdotz(),           XYZCovarianceKey.CZDOT_Z.name());
92          checkNotNaN(getCzdotxdot(),        XYZCovarianceKey.CZDOT_XDOT.name());
93          checkNotNaN(getCzdotydot(),        XYZCovarianceKey.CZDOT_YDOT.name());
94          checkNotNaN(getCzdotzdot(),        XYZCovarianceKey.CZDOT_ZDOT.name());
95      }
96  
97      /** Set an entry in the XYZ covariance matrix.
98       * <p>
99       * Both m(j, k) and m(k, j) are set.
100      * </p>
101      * @param j row index (must be between 0 and 5 (inclusive)
102      * @param k column index (must be between 0 and 5 (inclusive)
103      * @param entry value of the matrix entry
104      */
105     public void setCovarianceMatrixEntry(final int j, final int k, final double entry) {
106         covarianceMatrix.setEntry(j, k, entry);
107         covarianceMatrix.setEntry(k, j, entry);
108     }
109 
110     /**
111      * Get the XYZ covariance matrix.
112      * <p> The XYZ Covariance Matrix is only provided if {@link CdmMetadataKey#ALT_COV_TYPE} is {@link AltCovarianceType#XYZ}, otherwise
113      * its terms will return NaN. </p>
114      * <p> When available, the matrix is given in the 9×9 Lower Triangular Form. All parameters of the 6×6 position/velocity submatrix
115      * are mandatory. The remaining elements will return NaN if not provided.</p>
116      * @return the XYZ covariance matrix
117      */
118     public RealMatrix getXYZCovarianceMatrix() {
119         return covarianceMatrix;
120     }
121 
122     /**
123      * Get the object [1,1] in covariance matrix (with index starting at 1).
124      * @return the object [1,1] in covariance matrix (in m²)
125      */
126     public double getCxx() {
127         return covarianceMatrix.getEntry(0, 0);
128     }
129 
130     /**
131      * Set the object [1,1] in covariance matrix (with index starting at 1).
132      * @param CXX = object [1,1] in covariance matrix (in m²)
133      */
134     public void setCxx(final double CXX) {
135         refuseFurtherComments();
136 
137         // Conditional on ALT_COV_TYPE = XYZ
138         if (!isCovXYZset()) {
139             throw new OrekitException(OrekitMessages.CCSDS_DATE_INVALID_PREAMBLE_FIELD, CdmMetadataKey.ALT_COV_TYPE);
140         }
141 
142         setCovarianceMatrixEntry(0, 0, CXX);
143     }
144 
145     /**
146      * Get the object [2,1] in covariance matrix (with index starting at 1).
147      * @return the object [2,1] in covariance matrix (in m²)
148      */
149     public double getCyx() {
150         return covarianceMatrix.getEntry(1, 0);
151     }
152 
153     /**
154      * Set the object [2,1] in covariance matrix (with index starting at 1).
155      * @param CYX = object [2,1] in covariance matrix (in m²)
156      */
157     public void setCyx(final double CYX) {
158         refuseFurtherComments();
159         setCovarianceMatrixEntry(1, 0, CYX);
160     }
161 
162     /**
163      * Get the object [2,2] in covariance matrix (with index starting at 1).
164      * @return the object [2,2] in covariance matrix (in m²)
165      */
166     public double getCyy() {
167         return covarianceMatrix.getEntry(1, 1);
168     }
169 
170     /**
171      * Set the object [2,2] in covariance matrix (with index starting at 1).
172      * @param CYY = object [2,2] in covariance matrix (in m²)
173      */
174     public void setCyy(final double CYY) {
175         refuseFurtherComments();
176         setCovarianceMatrixEntry(1, 1, CYY);
177     }
178 
179     /**
180      * Get the object [3,1] in covariance matrix (with index starting at 1).
181      * @return the object [3,1] in covariance matrix (in m²)
182      */
183     public double getCzx() {
184         return covarianceMatrix.getEntry(2, 0);
185     }
186 
187     /**
188      * Set the object [3,1] in covariance matrix (with index starting at 1).
189      * @param CZX = object [3,1] in covariance matrix (in m²)
190      */
191     public void setCzx(final double CZX) {
192         refuseFurtherComments();
193         setCovarianceMatrixEntry(2, 0, CZX);
194     }
195 
196     /**
197      * Get the object [3,2] in covariance matrix (with index starting at 1).
198      * @return the object [3,2] in covariance matrix (in m²)
199      */
200     public double getCzy() {
201         return covarianceMatrix.getEntry(2, 1);
202     }
203 
204     /**
205      * Set the object [3,2] in covariance matrix (with index starting at 1).
206      * @param CZY = object [3,2] in covariance matrix (in m²)
207      */
208     public void setCzy(final double CZY) {
209         refuseFurtherComments();
210         setCovarianceMatrixEntry(2, 1, CZY);
211     }
212 
213     /**
214      * Get the object [3,3] in covariance matrix (with index starting at 1).
215      * @return the object [3,3] in covariance matrix (in m²)
216      */
217     public double getCzz() {
218         return covarianceMatrix.getEntry(2, 2);
219     }
220 
221     /**
222      * Set the object [3,3] in covariance matrix (with index starting at 1).
223      * @param CZZ = object [3,3] in covariance matrix (in m²)
224      */
225     public void setCzz(final double CZZ) {
226         refuseFurtherComments();
227         setCovarianceMatrixEntry(2, 2, CZZ);
228     }
229 
230     /**
231      * Get the object [4,1] in covariance matrix (with index starting at 1).
232      * @return the object [4,1] in covariance matrix (in m²/s)
233      */
234     public double getCxdotx() {
235         return covarianceMatrix.getEntry(3, 0);
236     }
237 
238     /**
239      * Set the object [4,1] in covariance matrix (with index starting at 1).
240      * @param CXdotX = object [4,1] in covariance matrix (in m²/s)
241      */
242     public void setCxdotx(final double CXdotX) {
243         refuseFurtherComments();
244         setCovarianceMatrixEntry(3, 0, CXdotX);
245     }
246 
247     /**
248      * Get the object [4,2] in covariance matrix (with index starting at 1).
249      * @return the object [4,2] in covariance matrix (in m²/s)
250      */
251     public double getCxdoty() {
252         return covarianceMatrix.getEntry(3, 1);
253     }
254 
255     /**
256      * Set the object [4, 2] in covariance matrix (with index starting at 1).
257      * @param CXdotY = object [4, 2] in covariance matrix (in m²/s)
258      */
259     public void setCxdoty(final double CXdotY) {
260         refuseFurtherComments();
261         setCovarianceMatrixEntry(3, 1, CXdotY);
262     }
263 
264     /**
265      * Get the object [4, 3] in covariance matrix (with index starting at 1) .
266      * @return the object [4, 3] in covariance matrix (in m²/s)
267      */
268     public double getCxdotz() {
269         return covarianceMatrix.getEntry(3, 2);
270     }
271 
272     /**
273      * Set the object [4, 3] in covariance matrix (with index starting at 1).
274      * @param CXdotZ = object [4,3] in covariance matrix (in m²/s)
275      */
276     public void setCxdotz(final double CXdotZ) {
277         refuseFurtherComments();
278         setCovarianceMatrixEntry(3, 2, CXdotZ);
279     }
280 
281     /**
282      * Get the object [4, 4] in covariance matrix (with index starting at 1).
283      * @return the object [4, 4] in covariance matrix (in m²/s²)
284      */
285     public double getCxdotxdot() {
286         return covarianceMatrix.getEntry(3, 3);
287     }
288 
289     /**
290      * Set the object [4, 4] in covariance matrix (with index starting at 1).
291      * @param CXdotXdot = object [4, 4] in covariance matrix (in m²/s²)
292      */
293     public void setCxdotxdot(final double CXdotXdot) {
294         refuseFurtherComments();
295         setCovarianceMatrixEntry(3, 3, CXdotXdot);
296     }
297 
298     /**
299      * Get the object [5, 1] in covariance matrix (with index starting at 1).
300      * @return the object [5, 1] in covariance matrix (in m²/s)
301      */
302     public double getCydotx() {
303         return covarianceMatrix.getEntry(4, 0);
304     }
305 
306     /**
307      * Set the object [5,1] in covariance matrix (with index starting at 1).
308      * @param CYdotX = object [5,1] in covariance matrix (in m²/s)
309      */
310     public void setCydotx(final double CYdotX) {
311         refuseFurtherComments();
312         setCovarianceMatrixEntry(4, 0, CYdotX);
313     }
314 
315     /**
316      * Get the object [5,2] in covariance matrix (with index starting at 1).
317      * @return the object [5,2] in covariance matrix (in m²/s)
318      */
319     public double getCydoty() {
320         return covarianceMatrix.getEntry(4, 1);
321     }
322 
323     /**
324      * Set the object [5,2] in covariance matrix (with index starting at 1).
325      * @param CYdotY = object [5,2] in covariance matrix (in m²/s)
326      */
327     public void setCydoty(final double CYdotY) {
328         refuseFurtherComments();
329         setCovarianceMatrixEntry(4, 1, CYdotY);
330     }
331 
332     /**
333      * Get the object [5,3] in covariance matrix (with index starting at 1).
334      * @return the object [5,3] in covariance matrix (in m²/s)
335      */
336     public double getCydotz() {
337         return covarianceMatrix.getEntry(4, 2);
338     }
339 
340     /**
341      * Set the object [5,3] in covariance matrix (with index starting at 1).
342      * @param CYdotZ = object [5,3] in covariance matrix (in m²/s)
343      */
344     public void setCydotz(final double CYdotZ) {
345         refuseFurtherComments();
346         setCovarianceMatrixEntry(4, 2, CYdotZ);
347     }
348 
349     /**
350      * Get the object [5,4] in covariance matrix (with index starting at 1).
351      * @return the object [5,4] in covariance matrix (in m²/s²)
352      */
353     public double getCydotxdot() {
354         return covarianceMatrix.getEntry(4, 3);
355     }
356 
357     /**
358      * Set the object [5,4] in covariance matrix (with index starting at 1).
359      * @param CYdotXdot = object [5,4] in covariance matrix (in m²/s²)
360      */
361     public void setCydotxdot(final double CYdotXdot) {
362         refuseFurtherComments();
363         setCovarianceMatrixEntry(4, 3, CYdotXdot);
364     }
365 
366     /**
367      * Get the object [5,5] in covariance matrix (with index starting at 1).
368      * @return the object [5,5] in covariance matrix (in m²/s²)
369      */
370     public double getCydotydot() {
371         return covarianceMatrix.getEntry(4, 4);
372     }
373 
374     /**
375      * Set the object [5,5] in covariance matrix (with index starting at 1).
376      * @param CYdotYdot = object [5,5] in covariance matrix (in m²/s²)
377      */
378     public void setCydotydot(final double CYdotYdot) {
379         refuseFurtherComments();
380         setCovarianceMatrixEntry(4, 4, CYdotYdot);
381     }
382 
383     /**
384      * Get the object [6,1] in covariance matrix (with index starting at 1).
385      * @return the object [6,1] in covariance matrix (in m²/s)
386      */
387     public double getCzdotx() {
388         return covarianceMatrix.getEntry(5, 0);
389     }
390 
391     /**
392      * Set the object [6,1] in covariance matrix (with index starting at 1).
393      * @param CZdotX = object [6,1] in covariance matrix (in m²/s)
394      */
395     public void setCzdotx(final double CZdotX) {
396         refuseFurtherComments();
397         setCovarianceMatrixEntry(5, 0, CZdotX);
398     }
399 
400     /**
401      * Get the object [6,2] in covariance matrix (with index starting at 1).
402      * @return the object [6,2] in covariance matrix (in m²/s)
403      */
404     public double getCzdoty() {
405         return covarianceMatrix.getEntry(5, 1);
406     }
407 
408     /**
409      * Set the object [6,2] in covariance matrix (with index starting at 1).
410      * @param CZdotY = object [6,2] in covariance matrix (in m²/s)
411      */
412     public void setCzdoty(final double CZdotY) {
413         refuseFurtherComments();
414         setCovarianceMatrixEntry(5, 1, CZdotY);
415     }
416 
417     /**
418      * Get the object [6,3] in covariance matrix (with index starting at 1).
419      * @return the object [6,3] in covariance matrix (in m²/s)
420      */
421     public double getCzdotz() {
422         return covarianceMatrix.getEntry(5, 2);
423     }
424 
425     /**
426      * Set the object [6,3] in covariance matrix (with index starting at 1).
427      * @param CZdotZ = object [6,3] in covariance matrix (in m²/s)
428      */
429     public void setCzdotz(final double CZdotZ) {
430         refuseFurtherComments();
431         setCovarianceMatrixEntry(5, 2, CZdotZ);
432     }
433 
434     /**
435      * Get the object [6,4] in covariance matrix (with index starting at 1).
436      * @return the object [6,4] in covariance matrix (in m²/s²)
437      */
438     public double getCzdotxdot() {
439         return covarianceMatrix.getEntry(5, 3);
440     }
441 
442     /**
443      * Set the object [6,4] in covariance matrix (with index starting at 1).
444      * @param CZdotXdot = object [6,4] in covariance matrix (in m²/s²)
445      */
446     public void setCzdotxdot(final double CZdotXdot) {
447         refuseFurtherComments();
448         setCovarianceMatrixEntry(5, 3, CZdotXdot);
449     }
450 
451     /**
452      * Get the object [6,5] in covariance matrix (with index starting at 1).
453      * @return the object [6,5] in covariance matrix (in m²/s²)
454      */
455     public double getCzdotydot() {
456         return covarianceMatrix.getEntry(5, 4);
457     }
458 
459     /**
460      * Set the object [6,5] in covariance matrix (with index starting at 1).
461      * @param CZdotYdot = object [6,5] in covariance matrix (in m²/s²)
462      */
463     public void setCzdotydot(final double CZdotYdot) {
464         refuseFurtherComments();
465         setCovarianceMatrixEntry(5, 4, CZdotYdot);
466     }
467 
468     /**
469      * Get the object [6,6] in covariance matrix (with index starting at 1).
470      * @return the object [6,6] in covariance matrix (in m²/s²)
471      */
472     public double getCzdotzdot() {
473         return covarianceMatrix.getEntry(5, 5);
474     }
475 
476     /**
477      * Set the object [6,6] in covariance matrix (with index starting at 1).
478      * @param CZdotZdot = object [6,6] in covariance matrix (in m²/s²)
479      */
480     public void setCzdotzdot(final double CZdotZdot) {
481         refuseFurtherComments();
482         setCovarianceMatrixEntry(5, 5, CZdotZdot);
483     }
484 
485     /**
486      * Get the object [7,1] in covariance matrix (with index starting at 1).
487      * @return the object [7,1] in covariance matrix (in m³/kg)
488      */
489     public double getCdrgx() {
490         return covarianceMatrix.getEntry(6, 0);
491     }
492 
493     /**
494      * Set the object [7,1] in covariance matrix (with index starting at 1).
495      * @param CDRGX = object [7,1] in covariance matrix (in m³/kg)
496      */
497     public void setCdrgx(final double CDRGX) {
498         refuseFurtherComments();
499         setCovarianceMatrixEntry(6, 0, CDRGX);
500     }
501 
502     /**
503      * Get the object [7,2] in covariance matrix.
504      * @return the object [7,2] in covariance matrix (in m³/kg)
505      */
506     public double getCdrgy() {
507         return covarianceMatrix.getEntry(6, 1);
508     }
509 
510     /**
511      * Set the object [7,2] in covariance matrix (with index starting at 1).
512      * @param CDRGY = object [7,2] in covariance matrix (in m³/kg)
513      */
514     public void setCdrgy(final double CDRGY) {
515         refuseFurtherComments();
516         setCovarianceMatrixEntry(6, 1, CDRGY);
517     }
518 
519     /**
520      * Get the object [7,3] in covariance matrix (with index starting at 1).
521      * @return the object [7,3] in covariance matrix (in m³/kg)
522      */
523     public double getCdrgz() {
524         return covarianceMatrix.getEntry(6, 2);
525     }
526 
527     /**
528      * Set the object [7,3] in covariance matrix (with index starting at 1).
529      * @param CDRGZ = object [7,3] in covariance matrix (in m³/kg)
530      */
531     public void setCdrgz(final double CDRGZ) {
532         refuseFurtherComments();
533         setCovarianceMatrixEntry(6, 2, CDRGZ);
534     }
535 
536     /**
537      * Get the object [7,4] in covariance matrix (with index starting at 1).
538      * @return the object [7,4] in covariance matrix (in m³/(kg.s))
539      */
540     public double getCdrgxdot() {
541         return covarianceMatrix.getEntry(6, 3);
542     }
543 
544     /**
545      * Set the object [7,4] in covariance matrix (with index starting at 1).
546      * @param CDRGXdot = object [7,4] in covariance matrix (in m³/(kg.s))
547      */
548     public void setCdrgxdot(final double CDRGXdot) {
549         refuseFurtherComments();
550         setCovarianceMatrixEntry(6, 3, CDRGXdot);
551     }
552 
553     /**
554      * Get the object [7,5] in covariance matrix (with index starting at 1).
555      * @return the object [7,5] in covariance matrix (in m³/(kg.s))
556      */
557     public double getCdrgydot() {
558         return covarianceMatrix.getEntry(6, 4);
559     }
560 
561     /**
562      * Set the object [7,5] in covariance matrix (with index starting at 1).
563      * @param CDRGYdot = object [7,5] in covariance matrix (in m³/(kg.s))
564      */
565     public void setCdrgydot(final double CDRGYdot) {
566         refuseFurtherComments();
567         setCovarianceMatrixEntry(6, 4, CDRGYdot);
568     }
569 
570     /**
571      * Get the object [7,6] in covariance matrix (with index starting at 1).
572      * @return the object [7,6] in covariance matrix (in m³/(kg.s))
573      */
574     public double getCdrgzdot() {
575         return covarianceMatrix.getEntry(6, 5);
576     }
577 
578     /**
579      * Set the object [7,6] in covariance matrix (with index starting at 1).
580      * @param CDRGZdot = object [7,6] in covariance matrix (in m³/(kg.s))
581      */
582     public void setCdrgzdot(final double CDRGZdot) {
583         refuseFurtherComments();
584         setCovarianceMatrixEntry(6, 5, CDRGZdot);
585     }
586 
587     /**
588      * Get the object [7,7] in covariance matrix (with index starting at 1).
589      * @return the object [7,7] in covariance matrix (in m⁴/kg²)
590      */
591     public double getCdrgdrg() {
592         return covarianceMatrix.getEntry(6, 6);
593     }
594 
595     /**
596      * Set the object [7,7] in covariance matrix (with index starting at 1).
597      * @param CDRGDRG = object [7,7] in covariance matrix (in m⁴/kg²)
598      */
599     public void setCdrgdrg(final double CDRGDRG) {
600         refuseFurtherComments();
601         setCovarianceMatrixEntry(6, 6, CDRGDRG);
602     }
603 
604     /**
605      * Get the object [8,1] in covariance matrix (with index starting at 1).
606      * @return the object [8,1] in covariance matrix (in m³/kg)
607      */
608     public double getCsrpx() {
609         return covarianceMatrix.getEntry(7, 0);
610     }
611 
612     /**
613      * Set the object [8,1] in covariance matrix (with index starting at 1).
614      * @param CSRPX = object [8,1] in covariance matrix (in m³/kg)
615      */
616     public void setCsrpx(final double CSRPX) {
617         refuseFurtherComments();
618         setCovarianceMatrixEntry(7, 0, CSRPX);
619     }
620 
621     /**
622      * Get the object [8,2] in covariance matrix (with index starting at 1).
623      * @return the object [8,2] in covariance matrix (in m³/kg)
624      */
625     public double getCsrpy() {
626         return covarianceMatrix.getEntry(7, 1);
627     }
628 
629     /**
630      * Set the object [8,2] in covariance matrix (with index starting at 1).
631      * @param CSRPY = object [8,2] in covariance matrix (in m³/kg)
632      */
633     public void setCsrpy(final double CSRPY) {
634         refuseFurtherComments();
635         setCovarianceMatrixEntry(7, 1, CSRPY);
636     }
637 
638     /**
639      * Get the object [8,3] in covariance matrix (with index starting at 1).
640      * @return the object [8,3] in covariance matrix (in m³/kg)
641      */
642     public double getCsrpz() {
643         return covarianceMatrix.getEntry(7, 2);
644     }
645 
646     /**
647      * Set the object [8,3] in covariance matrix (with index starting at 1).
648      * @param CSRPZ = object [8,3] in covariance matrix (in m³/kg)
649      */
650     public void setCsrpz(final double CSRPZ) {
651         refuseFurtherComments();
652         setCovarianceMatrixEntry(7, 2, CSRPZ);
653     }
654 
655     /**
656      * Get the object [8,4] in covariance matrix (with index starting at 1).
657      * @return the object [8,4] in covariance matrix (in m³/(kg.s))
658      */
659     public double getCsrpxdot() {
660         return covarianceMatrix.getEntry(7, 3);
661     }
662 
663     /**
664      * Set the object [8,4] in covariance matrix (with index starting at 1).
665      * @param CSRPXdot = object [8,4] in covariance matrix (in m³/(kg.s))
666      */
667     public void setCsrpxdot(final double CSRPXdot) {
668         refuseFurtherComments();
669         setCovarianceMatrixEntry(7, 3, CSRPXdot);
670     }
671 
672     /**
673      * Get the object [8,5] in covariance matrix (with index starting at 1).
674      * @return the object [8,5] in covariance matrix (in m³/(kg.s))
675      */
676     public double getCsrpydot() {
677         return covarianceMatrix.getEntry(7, 4);
678     }
679 
680     /**
681      * Set the object [8,5] in covariance matrix (with index starting at 1).
682      * @param CSRPYdot = object [8,5] in covariance matrix (in m³/(kg.s))
683      */
684     public void setCsrpydot(final double CSRPYdot) {
685         refuseFurtherComments();
686         setCovarianceMatrixEntry(7, 4, CSRPYdot);
687     }
688 
689     /**
690      * Get the object [8,6] in covariance matrix (with index starting at 1).
691      * @return the object [8,6] in covariance matrix (in m³/(kg.s))
692      */
693     public double getCsrpzdot() {
694         return covarianceMatrix.getEntry(7, 5);
695     }
696 
697     /**
698      * Set the object [8,6] in covariance matrix (with index starting at 1).
699      * @param CSRPZdot = object [8,6] in covariance matrix (in m³/(kg.s))
700      */
701     public void setCsrpzdot(final double CSRPZdot) {
702         refuseFurtherComments();
703         setCovarianceMatrixEntry(7, 5, CSRPZdot);
704     }
705 
706     /**
707      * Get the object [8,7] in covariance matrix (with index starting at 1).
708      * @return the object [8,7] in covariance matrix (in m⁴/kg²)
709      */
710     public double getCsrpdrg() {
711         return covarianceMatrix.getEntry(7, 6);
712     }
713 
714     /**
715      * Set the object [8,7] in covariance matrix (with index starting at 1).
716      * @param CSRPDRG = object [8,7] in covariance matrix (in m⁴/kg²)
717      */
718     public void setCsrpdrg(final double CSRPDRG) {
719         refuseFurtherComments();
720         setCovarianceMatrixEntry(7, 6, CSRPDRG);
721     }
722 
723     /**
724      * Get the object [8,8] in covariance matrix (with index starting at 1).
725      * @return the object [8,8] in covariance matrix (in m⁴/kg²)
726      */
727     public double getCsrpsrp() {
728         return covarianceMatrix.getEntry(7, 7);
729     }
730 
731     /**
732      * Set the object [8,8] in covariance matrix (with index starting at 1).
733      * @param CSRPSRP = object [8,8] in covariance matrix (in m⁴/kg²)
734      */
735     public void setCsrpsrp(final double CSRPSRP) {
736         refuseFurtherComments();
737         setCovarianceMatrixEntry(7, 7, CSRPSRP);
738     }
739 
740     /**
741      * Get the object [9,1] in covariance matrix (with index starting at 1).
742      * @return the object [9,1] in covariance matrix (in m²/s²)
743      */
744     public double getCthrx() {
745         return covarianceMatrix.getEntry(8, 0);
746     }
747 
748     /**
749      * Set the object [9,1] in covariance matrix (with index starting at 1).
750      * @param CTHRX = object [9,1] in covariance matrix (in m²/s²)
751      */
752     public void setCthrx(final double CTHRX) {
753         refuseFurtherComments();
754         setCovarianceMatrixEntry(8, 0, CTHRX);
755     }
756 
757     /**
758      * Get the object [9,2] in covariance matrix (with index starting at 1).
759      * @return the object [9,2] in covariance matrix (in m²/s²)
760      */
761     public double getCthry() {
762         return covarianceMatrix.getEntry(8, 1);
763     }
764 
765     /**
766      * Set the object [9,2] in covariance matrix (with index starting at 1).
767      * @param CTHRY = object [9,2] in covariance matrix (in m²/s²)
768      */
769     public void setCthry(final double CTHRY) {
770         refuseFurtherComments();
771         setCovarianceMatrixEntry(8, 1, CTHRY);
772     }
773 
774     /**
775      * Get the object [9,3] in covariance matrix (with index starting at 1).
776      * @return the object [9,3] in covariance matrix (in m²/s²)
777      */
778     public double getCthrz() {
779         return covarianceMatrix.getEntry(8, 2);
780     }
781 
782     /**
783      * Set the object [9,3] in covariance matrix (with index starting at 1).
784      * @param CTHRZ = object [9,3] in covariance matrix (in m²/s²)
785      */
786     public void setCthrz(final double CTHRZ) {
787         refuseFurtherComments();
788         setCovarianceMatrixEntry(8, 2, CTHRZ);
789     }
790 
791     /**
792      * Get the object [9,4] in covariance matrix (with index starting at 1).
793      * @return the object [9,4] in covariance matrix (in m²/s³)
794      */
795     public double getCthrxdot() {
796         return covarianceMatrix.getEntry(8, 3);
797     }
798 
799     /**
800      * Set the object [9,4] in covariance matrix (with index starting at 1).
801      * @param CTHRXdot = object [9,4] in covariance matrix (in m²/s³)
802      */
803     public void setCthrxdot(final double CTHRXdot) {
804         refuseFurtherComments();
805         setCovarianceMatrixEntry(8, 3, CTHRXdot);
806     }
807 
808     /**
809      * Get the object [9,5] in covariance matrix (with index starting at 1).
810      * @return the object [9,5] in covariance matrix (in m²/s³)
811      */
812     public double getCthrydot() {
813         return covarianceMatrix.getEntry(8, 4);
814     }
815 
816     /**
817      * Set the object [9,5] in covariance matrix (with index starting at 1).
818      * @param CTHRYdot = object [9,5] in covariance matrix (in m²/s³)
819      */
820     public void setCthrydot(final double CTHRYdot) {
821         refuseFurtherComments();
822         setCovarianceMatrixEntry(8, 4, CTHRYdot);
823     }
824 
825     /**
826      * Get the object [9,6] in covariance matrix (with index starting at 1).
827      * @return the object [9,6] in covariance matrix (in m²/s³)
828      */
829     public double getCthrzdot() {
830         return covarianceMatrix.getEntry(8, 5);
831     }
832 
833     /**
834      * Set the object [9,6] in covariance matrix (with index starting at 1).
835      * @param CTHRZdot = object [9,6] in covariance matrix (in m²/s³)
836      */
837     public void setCthrzdot(final double CTHRZdot) {
838         refuseFurtherComments();
839         setCovarianceMatrixEntry(8, 5, CTHRZdot);
840     }
841 
842     /**
843      * Get the object [9,7] in covariance matrix (with index starting at 1).
844      * @return the object [9,7] in covariance matrix (in m³/(kg.s²))
845      */
846     public double getCthrdrg() {
847         return covarianceMatrix.getEntry(8, 6);
848     }
849 
850     /**
851      * Set the object [9,7] in covariance matrix (with index starting at 1).
852      * @param CTHRDRG = object [9,7] in covariance matrix (in m³/(kg.s²))
853      */
854     public void setCthrdrg(final double CTHRDRG) {
855         refuseFurtherComments();
856         setCovarianceMatrixEntry(8, 6, CTHRDRG);
857     }
858 
859     /**
860      * Get the object [9,8] in covariance matrix (with index starting at 1).
861      * @return the object [9,8] in covariance matrix (in m³/(kg.s²))
862      */
863     public double getCthrsrp() {
864         return covarianceMatrix.getEntry(8, 7);
865     }
866 
867     /**
868      * Set the object [9,8] in covariance matrix (with index starting at 1).
869      * @param CTHRSRP = object [9,8] in covariance matrix (in m³/(kg.s²))
870      */
871     public void setCthrsrp(final double CTHRSRP) {
872         refuseFurtherComments();
873         setCovarianceMatrixEntry(8, 7, CTHRSRP);
874     }
875 
876     /**
877      * Get the object [9,9] in covariance matrix (with index starting at 1).
878      * @return the object [9,9] in covariance matrix (in m²/s⁴)
879      */
880     public double getCthrthr() {
881         return covarianceMatrix.getEntry(8, 8);
882     }
883 
884     /**
885      * Set the object [9,9] in covariance matrix (with index starting at 1).
886      * @param CTHRTHR = object [9,9] in covariance matrix (in m²/s⁴)
887      */
888     public void setCthrthr(final double CTHRTHR) {
889         refuseFurtherComments();
890         setCovarianceMatrixEntry(8, 8, CTHRTHR);
891     }
892 
893     /** Get the flag indicating whether the alternate covariance type set in the CDM Object metadata section is XYZ.
894      * @return the covXYZset
895      */
896     public boolean isCovXYZset() {
897         return covXYZset;
898     }
899 }