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