NavICL1NVNavigationMessage.java

  1. /* Copyright 2022-2025 Luc Maisonobe
  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.propagation.analytical.gnss.data;

  18. import org.hipparchus.CalculusFieldElement;
  19. import org.hipparchus.Field;
  20. import org.orekit.gnss.SatelliteSystem;
  21. import org.orekit.time.TimeScales;

  22. /**
  23.  * Container for data contained in a NavIC navigation message.
  24.  * @author Luc Maisonobe
  25.  * @since 13.0
  26.  */
  27. public class NavICL1NVNavigationMessage
  28.     extends CivilianNavigationMessage<NavICL1NVNavigationMessage> {

  29.     /** Reference signal flag. */
  30.     private int referenceSignalFlag;

  31.     /** Estimated group delay differential TGD for S-L5 correction. */
  32.     private double tgdSL5;

  33.     /** Inter Signal Delay for S L1P. */
  34.     private double iscSL1P;

  35.     /** Inter Signal Delay for L1D L1P. */
  36.     private double iscL1DL1P;

  37.     /** Inter Signal Delay for L1P S. */
  38.     private double iscL1PS;

  39.     /** Inter Signal Delay for L1DS. */
  40.     private double iscL1DS;

  41.     /** Constructor.
  42.      * @param timeScales known time scales
  43.      * @param system     satellite system to consider for interpreting week number
  44.      *                   (may be different from real system, for example in Rinex nav, weeks
  45.      *                   are always according to GPS)
  46.      */
  47.     public NavICL1NVNavigationMessage(final TimeScales timeScales, final SatelliteSystem system) {
  48.         super(true, GNSSConstants.NAVIC_MU, GNSSConstants.NAVIC_AV, GNSSConstants.NAVIC_WEEK_NB,
  49.               timeScales, system);
  50.     }

  51.     /** Constructor from field instance.
  52.      * @param <T> type of the field elements
  53.      * @param original regular field instance
  54.      */
  55.     public <T extends CalculusFieldElement<T>> NavICL1NVNavigationMessage(final FieldNavicL1NVNavigationMessage<T> original) {
  56.         super(original);
  57.         setReferenceSignalFlag(original.getReferenceSignalFlag());
  58.         setTGDSL5(original.getTGDSL5().getReal());
  59.         setIscSL1P(original.getIscSL1P().getReal());
  60.         setIscL1DL1P(original.getIscL1DL1P().getReal());
  61.         setIscL1PS(original.getIscL1PS().getReal());
  62.         setIscL1DS(original.getIscL1DS().getReal());
  63.     }

  64.     /** {@inheritDoc} */
  65.     @SuppressWarnings("unchecked")
  66.     @Override
  67.     public <T extends CalculusFieldElement<T>, F extends FieldGnssOrbitalElements<T, NavICL1NVNavigationMessage>>
  68.         F toField(final Field<T> field) {
  69.         return (F) new FieldNavicL1NVNavigationMessage<>(field, this);
  70.     }

  71.     /** Set reference signal flag.
  72.      * @param referenceSignalFlag reference signal flag
  73.      */
  74.     public void setReferenceSignalFlag(final int referenceSignalFlag) {
  75.         this.referenceSignalFlag = referenceSignalFlag;
  76.     }

  77.     /** Get reference signal flag.
  78.      * @return reference signal flag
  79.      */
  80.     public int getReferenceSignalFlag() {
  81.         return referenceSignalFlag;
  82.     }

  83.     /**
  84.      * Set the estimated group delay differential TGD for S-L5 correction.
  85.      * @param groupDelayDifferential the estimated group delay differential TGD for S-L3 correction (s)
  86.      */
  87.     public void setTGDSL5(final double groupDelayDifferential) {
  88.         this.tgdSL5 = groupDelayDifferential;
  89.     }

  90.     /**
  91.      * Set the estimated group delay differential TGD for S-L5 correction.
  92.      * @return estimated group delay differential TGD for S-L3 correction (s)
  93.      */
  94.     public double getTGDSL5() {
  95.         return tgdSL5;
  96.     }

  97.     /**
  98.      * Getter for inter Signal Delay for S L1P.
  99.      * @return inter signal delay
  100.      */
  101.     public double getIscSL1P() {
  102.         return iscSL1P;
  103.     }

  104.     /**
  105.      * Setter for inter Signal Delay for S L1P.
  106.      * @param delay delay to set
  107.      */
  108.     public void setIscSL1P(final double delay) {
  109.         this.iscSL1P = delay;
  110.     }

  111.     /**
  112.      * Getter for inter Signal Delay for L1D L1P.
  113.      * @return inter signal delay
  114.      */
  115.     public double getIscL1DL1P() {
  116.         return iscL1DL1P;
  117.     }

  118.     /**
  119.      * Setter for inter Signal Delay for L1D L1P.
  120.      * @param delay delay to set
  121.      */
  122.     public void setIscL1DL1P(final double delay) {
  123.         this.iscL1DL1P = delay;
  124.     }

  125.     /**
  126.      * Getter for inter Signal Delay for L1P S.
  127.      * @return inter signal delay
  128.      */
  129.     public double getIscL1PS() {
  130.         return iscL1PS;
  131.     }

  132.     /**
  133.      * Setter for inter Signal Delay for L1P S.
  134.      * @param delay delay to set
  135.      */
  136.     public void setIscL1PS(final double delay) {
  137.         this.iscL1PS = delay;
  138.     }

  139.     /**
  140.      * Getter for inter Signal Delay for L1D S.
  141.      * @return inter signal delay
  142.      */
  143.     public double getIscL1DS() {
  144.         return iscL1DS;
  145.     }

  146.     /**
  147.      * Setter for inter Signal Delay for L1D S.
  148.      * @param delay delay to set
  149.      */
  150.     public void setIscL1DS(final double delay) {
  151.         this.iscL1DS = delay;
  152.     }

  153. }