1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.orekit.models.earth.atmosphere;
18
19
20 import org.hipparchus.geometry.euclidean.threed.Vector3D;
21 import org.junit.Assert;
22 import org.junit.Before;
23 import org.junit.Test;
24 import org.orekit.Utils;
25 import org.orekit.bodies.OneAxisEllipsoid;
26 import org.orekit.frames.Frame;
27 import org.orekit.frames.FramesFactory;
28 import org.orekit.frames.Transform;
29 import org.orekit.time.AbsoluteDate;
30 import org.orekit.utils.IERSConventions;
31
32
33 public class SimpleExponentialAtmosphereTest {
34
35 @Test
36 public void testExpAtmosphere() {
37 Vector3D posInEME2000 = new Vector3D(10000, Vector3D.PLUS_I);
38 AbsoluteDate date = AbsoluteDate.J2000_EPOCH;
39 Frame itrf = FramesFactory.getITRF(IERSConventions.IERS_2010, true);
40 SimpleExponentialAtmosphere atm =
41 new SimpleExponentialAtmosphere(new OneAxisEllipsoid(Utils.ae, 1.0 / 298.257222101, itrf),
42 0.0004, 42000.0, 7500.0);
43 Vector3D vel = atm.getVelocity(date, posInEME2000, FramesFactory.getEME2000());
44
45 Transform toBody = FramesFactory.getEME2000().getTransformTo(itrf, date);
46 Vector3D test = Vector3D.crossProduct(toBody.getRotationRate(), posInEME2000);
47 test = test.subtract(vel);
48 Assert.assertEquals(0, test.getNorm(), 2.9e-5);
49
50 }
51
52 @Before
53 public void setUp() {
54 Utils.setDataRoot("regular-data");
55 }
56
57 }