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.propagation.analytical.gnss.data;
18
19 import org.hipparchus.util.FastMath;
20
21 /**
22 * Class for Galileo almanac.
23 *
24 * @see "European GNSS (Galileo) Open Service, Signal In Space,
25 * Interface Control Document, Table 75"
26 *
27 * @author Bryan Cazabonne
28 * @since 10.0
29 *
30 */
31 public class GalileoAlmanac extends AbstractAlmanac {
32
33 /** Nominal inclination (Ref: Galileo ICD - Table 75). */
34 private static final double I0 = FastMath.toRadians(56.0);
35
36 /** Nominal semi-major axis in meters (Ref: Galileo ICD - Table 75). */
37 private static final double A0 = 29600000;
38
39 /** Satellite E5a signal health status. */
40 private int healthE5a;
41
42 /** Satellite E5b signal health status. */
43 private int healthE5b;
44
45 /** Satellite E1-B/C signal health status. */
46 private int healthE1;
47
48 /** Almanac Issue Of Data. */
49 private int iod;
50
51 /**
52 * Build a new almanac.
53 */
54 public GalileoAlmanac() {
55 super(GNSSConstants.GALILEO_MU, GNSSConstants.GALILEO_AV, GNSSConstants.GALILEO_WEEK_NB);
56 }
57
58 /**
59 * Sets the difference between the square root of the semi-major axis
60 * and the square root of the nominal semi-major axis.
61 * <p>
62 * In addition, this method set the value of the Semi-Major Axis.
63 * </p>
64 * @param dsqa the value to set
65 */
66 public void setDeltaSqrtA(final double dsqa) {
67 final double sqrtA = dsqa + FastMath.sqrt(A0);
68 super.setSma(sqrtA * sqrtA);
69 }
70
71 /**
72 * Sets the the correction of orbit reference inclination at reference time.
73 * <p>
74 * In addition, this method set the value of the reference inclination.
75 * </p>
76 * @param dinc correction of orbit reference inclination at reference time in radians
77 */
78 public void setDeltaInc(final double dinc) {
79 super.setI0(I0 + dinc);
80 }
81
82 /**
83 * Gets the Issue of Data (IOD).
84 *
85 * @return the Issue Of Data
86 */
87 public int getIOD() {
88 return iod;
89 }
90
91 /**
92 * Sets the Issue of Data (IOD).
93 *
94 * @param iodValue the value to set
95 */
96 public void setIOD(final int iodValue) {
97 this.iod = iodValue;
98 }
99
100 /**
101 * Gets the E1-B/C signal health status.
102 *
103 * @return the E1-B/C signal health status
104 */
105 public int getHealthE1() {
106 return healthE1;
107 }
108
109 /**
110 * Sets the E1-B/C signal health status.
111 *
112 * @param healthE1 health status to set
113 */
114 public void setHealthE1(final int healthE1) {
115 this.healthE1 = healthE1;
116 }
117
118 /**
119 * Gets the E5a signal health status.
120 *
121 * @return the E5a signal health status
122 */
123 public int getHealthE5a() {
124 return healthE5a;
125 }
126
127 /**
128 * Sets the E5a signal health status.
129 *
130 * @param healthE5a health status to set
131 */
132 public void setHealthE5a(final int healthE5a) {
133 this.healthE5a = healthE5a;
134 }
135
136 /**
137 * Gets the E5b signal health status.
138 *
139 * @return the E5b signal health status
140 */
141 public int getHealthE5b() {
142 return healthE5b;
143 }
144
145 /**
146 * Sets the E5b signal health status.
147 *
148 * @param healthE5b health status to set
149 */
150 public void setHealthE5b(final int healthE5b) {
151 this.healthE5b = healthE5b;
152 }
153
154 }