ECE 6390 · Interactive learning lab
One acceleration. Two local components.
Keep the physical vector fixed, rotate the satellite’s local axes, and see why the code uses cosine and sine.
Independent geometry demonstration. Use the angle controls or return to the orbit to import a moment.
Back to Orbit & CodeInteractive orbital geometry
One acceleration. Two local components.
The solar acceleration has one direction in the fixed plane. The satellite’s radial and tangential axes point in different directions as it moves. Change either angle to see how the projections change.
Earth → satellite, measured from fixed +x.
φ = FORCE_PHASE + OMEGA_SUN × time.
Interactive controls are initializing. The starting example is shown below.
Fixed orbital plane
Both θ and φ are measured from the same fixed +x direction.
The dashed orange ray is a parallel copy of the acceleration direction, drawn at Earth only to show φ. It is not another acceleration.
Satellite’s local frame
Rotate the view by −θ. Now outward radial is to the right.
Same acceleration, different coordinates. δ = relative = φ − θ. The dashed guides meet at the solar-vector tip; the components are its two projections.
The arrow lengths use asolar = 1. Multiply each fraction by self.acceleration to obtain its acceleration component. The degrees here are for display; Python’s trigonometric functions use radians.
Relative angle 45 degrees. Radial fraction 0.7071. Tangential fraction 0.7071.
Why subtract θ?
φ tells you where the acceleration points relative to fixed +x. θ tells you where outward radial points relative to that same +x. Their difference is the angle between the radial axis and the acceleration.
The radial projection is the adjacent component, so it uses cosine. The tangential projection is the perpendicular component, so it uses sine. The signs tell you which way along each axis the acceleration points.
Try this: leave φ alone and move θ. The orange arrow keeps its fixed-plane direction, but its radial and tangential components change.
Your code, in the same notation
phi = FORCE_PHASE + OMEGA_SUN * time
relative = phi - theta
a_r = self.acceleration * math.cos(relative)
a_theta = self.acceleration * math.sin(relative)
- FORCE_PHASE
- The modeled acceleration direction at time = 0.
- OMEGA_SUN × time
- The change in that modeled direction since time = 0.
- theta
- The satellite’s position angle, not its physical orientation.