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.files.rinex.navigation;
18
19 import org.orekit.gnss.SatelliteSystem;
20
21 /** Container for data contained in a ionosphere BDGIM message.
22 * @author Luc Maisonobe
23 * @since 12.0
24 */
25 public class IonosphereBDGIMMessage extends IonosphereBaseMessage {
26
27 /** α (TECu). */
28 private final double[] alpha;
29
30 /** Simple constructor.
31 * @param system satellite system
32 * @param prn satellite number
33 * @param navigationMessageType navigation message type
34 */
35 public IonosphereBDGIMMessage(final SatelliteSystem system, final int prn, final String navigationMessageType) {
36 super(system, prn, navigationMessageType);
37 alpha = new double[9];
38 }
39
40 /** Get the α coefficients.
41 * <p>
42 * Beware Orekit uses SI units here.
43 * In order to retrieve the more traditional TECu, use
44 * {@code Unit.TOTAL_ELECTRON_CONTENT_UNIT.fromSI(msg.getAlpha()[i])}
45 * </p>
46 * @return α coefficients (m⁻²)
47 * @see org.orekit.utils.units.Unit#TOTAL_ELECTRON_CONTENT_UNIT
48 */
49 public double[] getAlpha() {
50 return alpha.clone();
51 }
52
53 /** Set one α coefficient.
54 * <p>
55 * Beware Orekit uses SI units here.
56 * In order to use the more traditional TECu, use
57 * {@code msg.setAlpha(i, Unit.TOTAL_ELECTRON_CONTENT_UNIT.toSI(ai))}
58 * </p>
59 * @param i index of the coefficient
60 * @param alphaI α coefficient to set (m⁻²)
61 * @see org.orekit.utils.units.Unit#TOTAL_ELECTRON_CONTENT_UNIT
62 */
63 public void setAlphaI(final int i, final double alphaI) {
64 alpha[i] = alphaI;
65 }
66
67 }