1   /* Copyright 2011-2012 Space Applications Services
2    * Licensed to CS Communication & Systèmes (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.models.earth.troposphere;
18  
19  import org.hipparchus.util.Binary64Field;
20  import org.hipparchus.util.FastMath;
21  import org.junit.jupiter.api.Test;
22  import org.orekit.bodies.GeodeticPoint;
23  import org.orekit.models.earth.weather.HeightDependentPressureTemperatureHumidityConverter;
24  import org.orekit.models.earth.weather.PressureTemperatureHumidityProvider;
25  import org.orekit.models.earth.weather.water.CIPM2007;
26  import org.orekit.time.AbsoluteDate;
27  import org.orekit.utils.TrackingCoordinates;
28  
29  public class MariniMurrayTest extends AbstractPathDelayTest<MariniMurray> {
30  
31      protected MariniMurray buildTroposphericModel(final PressureTemperatureHumidityProvider provider) {
32          // ruby laser with wavelength 694.3 nm
33          return new MariniMurray(694.3, TroposphericModelUtils.NANO_M, provider);
34      }
35  
36      @Override
37      @Test
38      public void testFixedHeight() {
39          doTestFixedHeight(TroposphericModelUtils.STANDARD_ATMOSPHERE_PROVIDER);
40      }
41  
42      @Override
43      @Test
44      public void testFieldFixedHeight() {
45          doTestFieldFixedHeight(Binary64Field.getInstance(),
46                                 TroposphericModelUtils.STANDARD_ATMOSPHERE_PROVIDER);
47      }
48  
49      @Override
50      @Test
51      public void testFixedElevation() {
52          doTestFixedElevation(new HeightDependentPressureTemperatureHumidityConverter(new CIPM2007()).
53                               getProvider(TroposphericModelUtils.STANDARD_ATMOSPHERE));
54      }
55  
56      @Override
57      @Test
58      public void testFieldFixedElevation() {
59          doTestFieldFixedElevation(Binary64Field.getInstance(),
60                                    new HeightDependentPressureTemperatureHumidityConverter(new CIPM2007()).
61                                    getProvider(TroposphericModelUtils.STANDARD_ATMOSPHERE));
62      }
63  
64      @Test
65      @Override
66      public void testDelay() {
67          doTestDelay(AbsoluteDate.J2000_EPOCH,
68                      new GeodeticPoint(FastMath.toRadians(45), FastMath.toRadians(45), 100), new TrackingCoordinates(0.0, FastMath.toRadians(10), 0.0),
69                      TroposphericModelUtils.STANDARD_ATMOSPHERE_PROVIDER,
70                      2.3883, 0.001656, 13.2516, 0.009522, 13.2611);
71      }
72  
73      @Test
74      @Override
75      public void testFieldDelay() {
76          doTestDelay(Binary64Field.getInstance(),
77                      AbsoluteDate.J2000_EPOCH,
78                      new GeodeticPoint(FastMath.toRadians(45), FastMath.toRadians(45), 100), new TrackingCoordinates(0.0, FastMath.toRadians(10), 0.0),
79                      TroposphericModelUtils.STANDARD_ATMOSPHERE_PROVIDER,
80                      2.3883, 0.001656, 13.2516, 0.009522, 13.2611);
81      }
82  
83  }