Quintic polynomial position + quintic-timed SLERP pointing. Planned in the CoM-relative frame pce=pe−pc\bm p_{ce} = \bm p_e - \bm p_cpce=pe−pc.
Boundary conditions: (p0,v0,a0)→(pf,0,0)(p_0, v_0, a_0) \to (p_f, 0, 0)(p0,v0,a0)→(pf,0,0) over [0,T][0, T][0,T].
p(t)=c0+c1t+c2t2+c3t3+c4t4+c5t5p(t) = c_0 + c_1 t + c_2 t^2 + c_3 t^3 + c_4 t^4 + c_5 t^5 p(t)=c0+c1t+c2t2+c3t3+c4t4+c5t5
c0=p0,c1=v0,c2=a02c_0 = p_0, \quad c_1 = v_0, \quad c_2 = \tfrac{a_0}{2} c0=p0,c1=v0,c2=2a0
c3=20(pf−p0)−12v0T−3a0T22T3c_3 = \frac{20(p_f - p_0) - 12 v_0 T - 3 a_0 T^2}{2T^3} c3=2T320(pf−p0)−12v0T−3a0T2
c4=30(p0−pf)+16v0T+3a0T22T4c_4 = \frac{30(p_0 - p_f) + 16 v_0 T + 3 a_0 T^2}{2T^4} c4=2T430(p0−pf)+16v0T+3a0T2
c5=12(pf−p0)−6v0T−a0T22T5c_5 = \frac{12(p_f - p_0) - 6 v_0 T - a_0 T^2}{2T^5} c5=2T512(pf−p0)−6v0T−a0T2
Position, velocity, and acceleration at time ttt:
p˙(t)=c1+2c2t+3c3t2+4c4t3+5c5t4\dot p(t) = c_1 + 2c_2 t + 3c_3 t^2 + 4c_4 t^3 + 5c_5 t^4 p˙(t)=c1+2c2t+3c3t2+4c4t3+5c5t4
p¨(t)=2c2+6c3t+12c4t2+20c5t3\ddot p(t) = 2c_2 + 6c_3 t + 12c_4 t^2 + 20c_5 t^3 p¨(t)=2c2+6c3t+12c4t2+20c5t3
Output triple: (p(t),p˙(t),p¨(t))\bigl(p(t), \dot p(t), \ddot p(t)\bigr)(p(t),p˙(t),p¨(t)) per axis — three axes stacked as (6×3)(6\times 3)(6×3).
τ=t/T∈[0,1]\tau = t/T \in [0,1]τ=t/T∈[0,1]. Smooth step with s,s˙,s¨=0s,\dot s, \ddot s = 0s,s˙,s¨=0 at both ends:
s(τ)=10τ3−15τ4+6τ5s(\tau) = 10\tau^3 - 15\tau^4 + 6\tau^5 s(τ)=10τ3−15τ4+6τ5
s˙(τ)=1T(30τ2−60τ3+30τ4)\dot s(\tau) = \frac{1}{T}\bigl(30\tau^2 - 60\tau^3 + 30\tau^4\bigr) s˙(τ)=T1(30τ2−60τ3+30τ4)
s¨(τ)=1T2(60τ−180τ2+120τ3)\ddot s(\tau) = \frac{1}{T^2}\bigl(60\tau - 180\tau^2 + 120\tau^3\bigr) s¨(τ)=T21(60τ−180τ2+120τ3)
Used as the SLERP fraction sss for the pointing channel.
Unit-vector SLERP between z0\bm z_0z0 and zf\bm z_fzf at parameter s=s(τ)s = s(\tau)s=s(τ):
θ=arccos (z0⊤zf)\theta = \arccos\!\bigl(\bm z_0^\top \bm z_f\bigr) θ=arccos(z0⊤zf)
z(s)=sin ((1−s)θ)z0+sin(sθ)zfsinθ\bm z(s) = \frac{\sin\!\bigl((1-s)\theta\bigr) \bm z_0 + \sin(s \theta) \bm z_f}{\sin\theta} z(s)=sinθsin((1−s)θ)z0+sin(sθ)zf
s(τ)s(\tau)s(τ) is the quintic time-scaling above — pointing is quintic-timed, not linearly-timed.
Rest-to-rest lower bound, whichever constraint binds:
T=max (1.875∥Δp∥vmax,5.7735∥Δp∥amax,θwmax,Tmin)T = \max\!\left(\frac{1.875\|\Delta\bm p\|}{v_{\max}}, \sqrt{\frac{5.7735\|\Delta\bm p\|}{a_{\max}}}, \frac{\theta}{w_{\max}}, T_{\min}\right) T=maxvmax1.875∥Δp∥,amax5.7735∥Δp∥,wmaxθ,Tmin
Non-zero (v0,a0)(v_0, a_0)(v0,a0) can cause realized peaks to exceed caps. Up to 8 refinement passes scale T∗=max (v^vmax,a^amax,1.01)T \mathrel{*}= \max\!\left(\tfrac{\hat v}{v_{\max}}, \sqrt{\tfrac{\hat a}{a_{\max}}}, 1.01\right)T∗=max(vmaxv^,amaxa^,1.01) until peaks satisfy caps within 0.1%0.1\%0.1%.
Re-plan fires when ∥ptarget−plast∥>ε\|\bm p_{\text{target}} - \bm p_{\text{last}}\| > \varepsilon∥ptarget−plast∥>ε (default 0.020.020.02 m).
New segment inherits the live state as initial conditions:
(p0,v0,a0,z0)←(p(t−),p˙(t−),p¨(t−),z(t−))\bigl(p_0, v_0, a_0, \bm z_0\bigr) \leftarrow \bigl(p(t^-), \dot p(t^-), \ddot p(t^-), \bm z(t^-)\bigr) (p0,v0,a0,z0)←(p(t−),p˙(t−),p¨(t−),z(t−))
This carries continuity through the re-plan: position, velocity, and acceleration are C² across the jump.
Per call step(pcedes,zdes,Δt)\text{step}(\bm p_{ce}^{\text{des}}, \bm z^{\text{des}}, \Delta t)step(pcedes,zdes,Δt):
t←min(t+Δt,T)t \leftarrow \min(t + \Delta t, T) t←min(t+Δt,T)
pcecmd=p (t;c),p˙cecmd=p˙ (t;c)\bm p_{ce}^{\text{cmd}} = p\!\left(t; \bm c\right), \quad \dot{\bm p}_{ce}^{\text{cmd}} = \dot p\!\left(t; \bm c\right) pcecmd=p(t;c),p˙cecmd=p˙(t;c)
zcmd=slerp (z0,zf,s(t/T))\bm z^{\text{cmd}} = \text{slerp}\!\left(\bm z_0, \bm z_f, s(t/T)\right) zcmd=slerp(z0,zf,s(t/T))
Output: (pcecmd,p˙cecmd,zcmd)\bigl(\bm p_{ce}^{\text{cmd}}, \dot{\bm p}_{ce}^{\text{cmd}}, \bm z^{\text{cmd}}\bigr)(pcecmd,p˙cecmd,zcmd) — C² position + velocity + unit pointing.