3.5.9 · Physics › Guidance, Navigation & Control (GNC)
Ek rotating rigid body (satellite, drone, aircraft) ka ek attitude hota hai — space mein uski orientation. Hum ise ek unit quaternion q se track karte hain. Jab body ω angular velocity se spin karti hai, quaternion time ke saath evolve hota hai. Yeh note jawab deta hai: q kitni fast change hoti hai, aur WHY rate exactly half angular velocity hai, ek matrix Ξ ( q ) mein wrapped?
Deep idea yeh hai: ek quaternion unit 3-sphere S 3 par rehta hai. Uski velocity hamesha us sphere ke tangent rehni chahiye (taaki ∥ q ∥ 1 rahe). 2 1 factor aur matrix Ξ ( q ) bilkul yehi guarantee karte hain.
Definition Unit quaternion
Ek quaternion ek 4-number object hai
q = [ q 0 q v ] = q 0 q 1 q 2 q 3 , q 0 = cos 2 θ , q v = n ^ sin 2 θ
jo unit axis n ^ ke baare mein angle == θ == ka rotation represent karta hai. Yeh ek unit quaternion hai: ∥ q ∥ 2 = q 0 2 + q 1 2 + q 2 2 + q 3 2 === 1 == .
Quaternion multiplication (Hamilton product): p = ( p 0 , p v ) , q = ( q 0 , q v ) ke liye,
p ⊗ q = [ p 0 q 0 − p v ⋅ q v p 0 q v + q 0 p v + p v × q v ]
Cross product term ka WHY : quaternion multiplication non-commutative hai, bilkul waisi hi jaise rotations compose karna. p v × q v term usi non-commutativity ko encode karta hai.
Intuition Woh ek idea jis par sab kuch tika hai
Abhi ho raha rotation q ( t ) hai. Δ t time par ek tiny extra rotation jo apply hoti hai use ek aur quaternion δ q likhaa ja sakta hai. Do rotations multiplication se compose hote hain. Isliye
q ( t + Δ t ) = q ( t ) ⊗ δ q .
Sab kuch yeh poochh ke milta hai: ek tiny spin ke liye δ q kya hai?
Body-frame axis ω ^ = ω /∥ ω ∥ ke baare mein small angle Δ θ = ∥ ω ∥ Δ t ka rotation hai:
δ q = [ cos 2 Δ θ ω ^ sin 2 Δ θ ]
Yeh step kyun? Yeh sirf quaternion ki definition hai jo infinitesimal rotation par apply ki gayi hai jo Δ t ke dauran hoti hai.
Small Δ t ke liye: cos 2 Δ θ ≈ 1 aur sin 2 Δ θ ≈ 2 Δ θ = 2 ∥ ω ∥Δ t . Toh
δ q ≈ [ 1 2 1 ω Δ t ] = 1 0 0 0 + 2 Δ t [ 0 ω ] .
2 1 yahan kyun aata hai: sin 2 θ mein half-angle quaternion definition mein baked in hai. Yahi famous 2 1 ki origin hai.
q ( t + Δ t ) − q ( t ) = q ⊗ δ q − q = q ⊗ ( δ q − q identity ) = q ⊗ 2 Δ t [ 0 ω ]
jahan q identity = ( 1 , 0 ) hai. Δ t se divide karo aur Δ t → 0 hone do:
q ˙ = 2 1 q ⊗ [ 0 ω ]
Yeh step kyun? Humne "ek tiny rotation compose karna" ko ek genuine time-derivative mein badla. Pure quaternion ( 0 , ω ) ko angular-velocity quaternion kehte hain.
Quaternion multiplication linear hai, isliye q ⊗ ( 0 , ω ) ko ek 4 × 3 matrix times ω likha ja sakta hai. Hamilton product se q ⊗ ( 0 , ω ) workout karne par:
q ⊗ [ 0 ω ] = [ − q v ⋅ ω q 0 ω + q v × ω ] = Ξ ( q ) ω
ke saath
Yeh step kyun? GNC filters (EKF, etc.) ko ek linear relation q ˙ = A ω chahiye. Hamilton product ko Ξ ( q ) ke roop mein package karna hume bilkul yahi deta hai — matrix code ke liye clean.
∥ q ∥ 2 ki rate of change zero honi chahiye — warna q unit sphere se drift kar jaata hai aur valid rotation represent nahi karta.
d t d ∥ q ∥ 2 = 2 q ⊤ q ˙ = 2 q ⊤ ( 2 1 Ξ ( q ) ω ) = ( q ⊤ Ξ ( q ) ) ω .
Key algebraic fact: q ⊤ Ξ ( q ) = 0 ⊤ (ek zero 1 × 3 row). Block form use karke row-by-row check karo:
q ⊤ Ξ ( q ) = q 0 ( − q v ⊤ ) + q v ⊤ ( q 0 I + [ q v × ] ) = − q 0 q v ⊤ + q 0 q v ⊤ + q v ⊤ [ q v × ] = 0 ⊤
kyunki q v ⊤ [ q v × ] = − ( q v × q v ) ⊤ = 0 . Isliye d t d ∥ q ∥ 2 = 0 . ✔
Intuition Geometric meaning
q ˙ hamesha q ke orthogonal hota hai. Sphere par tangent velocity → tum sphere ke saath slide karte ho, kabhi us se door nahi. Yahi reason hai ki equation guaranteed self-consistent hai.
Agar ω body frame mein express kiya gaya hai (usual case, gyros body rates measure karte hain): right multiplication use karo q ˙ = 2 1 q ⊗ ( 0 , ω ) → upar wala Ξ ( q ) .
Agar ω inertial frame mein hai: left multiplication use karo q ˙ = 2 1 ( 0 , ω ) ⊗ q , jo ek alag matrix deta hai (often Ω ( ω ) kehte hain).
Worked example Example 1 — Body
z ke baare mein pure spin
Body rate ω = ( 0 , 0 , ω z ) , identity se shuru q ( 0 ) = ( 1 , 0 , 0 , 0 ) .
q ˙ = 2 1 q ⊗ ( 0 , 0 , 0 , ω z ) .
Kyun: hum expect karte hain ki q trace kare q 0 = cos 2 ω z t , q 3 = sin 2 ω z t — ek rotation about z jo angle mein linearly badhti hai.
Plug in karo: q ˙ 0 = − 2 1 ω z q 3 , q ˙ 3 = 2 1 ω z q 0 . Yeh 2 ω z frequency wala harmonic oscillator hai ⇒ solution q 0 = cos 2 ω z t , q 3 = sin 2 ω z t . ✔ Expected half-angle se match karta hai.
Worked example Example 2 — Numerical single step
Maano q = ( 1 , 0 , 0 , 0 ) , ω = ( 0.1 , 0 , 0 ) rad/s. q ˙ compute karo.
q ˙ = 2 1 Ξ ( q ) ω , Ξ ( q ) = 0 1 0 0 0 0 1 0 0 0 0 1 , q ˙ = 2 1 0 0.1 0 0 = 0 0.05 0 0 .
Yeh step kyun? q 1 pehle badhta hai — yeh x -axis component on ho raha hai, ek roll about x ke consistent hai. Note karo q ˙ 0 = 0 identity par (norm-preserving: q ⊤ q ˙ = 0 ). ✔
Worked example Example 3 — Forecast-then-verify
Forecast: agar ω double ho jaaye, toh fixed q par q ˙ kaise change hoga? Kyunki q ˙ ω mein linear hai, use double hona chahiye.
Verify: 2 1 Ξ ( q ) ( 2 ω ) = 2 ⋅ 2 1 Ξ ( q ) ω = 2 q ˙ . ✔ Linearity confirmed. (Yahi reason hai ki Ξ ek matrix hai, nonlinear map nahi.)
Common mistake "Factor 1 hona chahiye, ½ nahi."
Kyun sahi lagta hai: 3D vector kinematics R ˙ = [ ω × ] R mein koi ½ nahi hai. Toh log expect karte hain ki quaternions match karen.
Fix: quaternions half-angle store karte hain (sin 2 θ ). Half-angle ko differentiate karne par chain rule se 2 1 aata hai. ½ double-cover q aur − q ki kimat hai jo same rotation represent karte hain.
Common mistake "Order matter nahi karta — main
( 0 , ω ) ⊗ q body rates ke saath likhta hun."
Kyun sahi lagta hai: multiplication order cosmetic lagti hai.
Fix: quaternion product non-commutative hai. Body-frame ω ko post-multiply karna zaruri hai (q ⊗ ). Yeh ulta karne par silently wrong attitude integrate hoti hai — ek classic flight-software bug.
Common mistake "Mujhe integration ke dauran renormalize nahi karna."
Kyun sahi lagta hai: math prove karta hai ki ∥ q ∥ = 1 preserved hai.
Fix: yeh sirf continuous time mein exact hai. Discrete numerical steps (Euler/RK) norm leak karte hain. Real GNC code har step mein q ← q /∥ q ∥ renormalize karta hai.
Recall Feynman: ek 12-saal-ke bacche ko explain karo
Imagine karo tum ek office chair par spin kar rahe ho. Tumhara munh kis taraf hai yeh describe karne ke liye, tum ek special 4-number "compass" use karte ho jise quaternion kehte hain. Ab, agar main tumhe batata hun tum kitni fast spin kar rahe ho , tum jaanna chahoge ki tumhare compass numbers kitni fast change ho rahe hain. Turns out compass numbers spin speed ki half se change hote hain — kyunki compass secretly half-turns measure karta hai (ek quirky quirk jo math ko khoobsurat banata hai). Ek chhota bookkeeping table bhi hai (Ξ matrix) jo tumhari current facing ko tumhari spin se mix karta hai sahi change dene ke liye. Aur poori cheez aise built hai ki tumhara compass hamesha ek valid "unit" compass rehta hai — kabhi toot nahi sakta.
"Half the spin, times XI, right-multiply the fin(body)."
Half → 2 1 (half-angle).
XI → Ξ ( q ) ω ko map karta hai.
right-multiply body → body rates ke liye q ⊗ ( 0 , ω ) .
q ˙ = 2 1 Ξ ( q ) ω mein ½ kyun aata hai?Kyunki quaternions half-angle encode karte hain (sin 2 θ , cos 2 θ ); half-angle differentiate karne par chain rule se ½ milta hai.
Continuous-time quaternion kinematic equation (body rates) likho. q ˙ = 2 1 q ⊗ ( 0 , ω ) = 2 1 Ξ ( q ) ω .
Kinematics mein ∥ q ∥ 1 rehna kya guarantee karta hai? q ⊤ Ξ ( q ) = 0 ⊤ , isliye d t d ∥ q ∥ 2 = q ⊤ q ˙ ⋅ 2 = 0 ; q ˙ ⊥ q .
Ξ ( q ) ki structure?4 × 3 : top row − q v ⊤ ; neeche 3 × 3 block q 0 I + [ q v × ] .
Body-frame ω : pre- ya post-multiply? Post-multiply, q ⊗ ( 0 , ω ) . Inertial-frame ω pre-multiply karta hai.
Equivalent Ω ( ω ) form kya hai? q ˙ = 2 1 Ω ( ω ) q , ω ki jagah q factor out karke; Ω ( ω ) 4 × 4 skew hai.
Agar norm provably preserved hai toh code mein renormalize kyun karo? Preservation sirf continuous time mein exact hai; discrete integrators norm leak karte hain, isliye har step mein renormalize karo.
Pure spin ω z identity se, q 3 ( t ) kya hoga? q 3 ( t ) = sin 2 ω z t (half-angle), q 0 = cos 2 ω z t ke saath.
q at t plus dt = q times delta-q
small angle = norm omega times dt
approx identity plus half omega dt
difference quotient to derivative
Rotation theta about axis n-hat
Rotations compose by multiplication
Hamilton product with cross term