1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package org.orekit.data;
18
19 import org.hipparchus.RealFieldElement;
20
21
22
23
24
25 class GeneralTerm extends SeriesTerm {
26
27
28 private final int cL;
29
30
31 private final int cLPrime;
32
33
34 private final int cF;
35
36
37 private final int cD;
38
39
40 private final int cOmega;
41
42
43 private final int cMe;
44
45
46 private final int cVe;
47
48
49 private final int cE;
50
51
52 private final int cMa;
53
54
55 private final int cJu;
56
57
58 private final int cSa;
59
60
61 private final int cUr;
62
63
64 private final int cNe;
65
66
67 private final int cPa;
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85 GeneralTerm(final int cL, final int cLPrime, final int cF, final int cD, final int cOmega,
86 final int cMe, final int cVe, final int cE, final int cMa, final int cJu,
87 final int cSa, final int cUr, final int cNe, final int cPa) {
88 this.cL = cL;
89 this.cLPrime = cLPrime;
90 this.cF = cF;
91 this.cD = cD;
92 this.cOmega = cOmega;
93 this.cMe = cMe;
94 this.cVe = cVe;
95 this.cE = cE;
96 this.cMa = cMa;
97 this.cJu = cJu;
98 this.cSa = cSa;
99 this.cUr = cUr;
100 this.cNe = cNe;
101 this.cPa = cPa;
102 }
103
104
105 protected double argument(final BodiesElements elements) {
106 return cL * elements.getL() + cLPrime * elements.getLPrime() + cF * elements.getF() +
107 cD * elements.getD() + cOmega * elements.getOmega() +
108 cMe * elements.getLMe() + cVe * elements.getLVe() + cE * elements.getLE() +
109 cMa * elements.getLMa() + cJu * elements.getLJu() +
110 cSa * elements.getLSa() + cUr * elements.getLUr() +
111 cNe * elements.getLNe() + cPa * elements.getPa();
112 }
113
114
115 protected double argumentDerivative(final BodiesElements elements) {
116 return cL * elements.getLDot() + cLPrime * elements.getLPrimeDot() + cF * elements.getFDot() +
117 cD * elements.getDDot() + cOmega * elements.getOmegaDot() +
118 cMe * elements.getLMeDot() + cVe * elements.getLVeDot() + cE * elements.getLEDot() +
119 cMa * elements.getLMaDot() + cJu * elements.getLJuDot() +
120 cSa * elements.getLSaDot() + cUr * elements.getLUrDot() +
121 cNe * elements.getLNeDot() + cPa * elements.getPaDot();
122 }
123
124
125 protected <T extends RealFieldElement<T>> T argument(final FieldBodiesElements<T> elements) {
126 return elements.getL().multiply(cL).
127 add(elements.getLPrime().multiply(cLPrime)).
128 add(elements.getF().multiply(cF)).
129 add(elements.getD().multiply(cD)).
130 add(elements.getOmega().multiply(cOmega)).
131 add(elements.getLMe().multiply(cMe)).
132 add(elements.getLVe().multiply(cVe)).
133 add(elements.getLE().multiply(cE)).
134 add(elements.getLMa().multiply(cMa)).
135 add(elements.getLJu().multiply(cJu)).
136 add(elements.getLSa().multiply(cSa)).
137 add(elements.getLUr().multiply(cUr)).
138 add(elements.getLNe().multiply(cNe)).
139 add(elements.getPa().multiply(cPa));
140 }
141
142
143 protected <T extends RealFieldElement<T>> T argumentDerivative(final FieldBodiesElements<T> elements) {
144 return elements.getLDot().multiply(cL).
145 add(elements.getLPrimeDot().multiply(cLPrime)).
146 add(elements.getFDot().multiply(cF)).
147 add(elements.getDDot().multiply(cD)).
148 add(elements.getOmegaDot().multiply(cOmega)).
149 add(elements.getLMeDot().multiply(cMe)).
150 add(elements.getLVeDot().multiply(cVe)).
151 add(elements.getLEDot().multiply(cE)).
152 add(elements.getLMaDot().multiply(cMa)).
153 add(elements.getLJuDot().multiply(cJu)).
154 add(elements.getLSaDot().multiply(cSa)).
155 add(elements.getLUrDot().multiply(cUr)).
156 add(elements.getLNeDot().multiply(cNe)).
157 add(elements.getPaDot().multiply(cPa));
158 }
159
160 }