fbpx
Wikipedia

Quaternion estimator algorithm

The quaternion estimator algorithm (QUEST) is an algorithm designed to solve Wahba's problem, that consists of finding a rotation matrix between two coordinate systems from two sets of observations sampled in each system respectively. The key idea behind the algorithm is to find an expression of the loss function for the Wahba's problem as a quadratic form, using the Cayley–Hamilton theorem and the Newton–Raphson method to efficiently solve the eigenvalue problem and construct a numerically stable representation of the solution.

The algorithm was introduced by Malcolm D. Shuster in 1981, while working at Computer Sciences Corporation.[1] While being in principle less robust than other methods such as Davenport's q method or singular value decomposition, the algorithm is significantly faster and reliable in practical applications,[2][3] and it is used for attitude determination problem in fields such as robotics and avionics.[4][5][6]

Formulation of the problem edit

Wahba's problem consists of finding a rotation matrix   that minimises the loss function

 

where   are the vector observations in the reference frame,   are the vector observations in the body frame,   is a rotation matrix between the two frames, and   are a set of weights such that  . It is possible to rewrite this as a maximisation problem of a gain function  

 

defined in such a way that the loss   attains a minimum when   is maximised. The gain   can in turn be rewritten as

 

where   is known as the attitude profile matrix.

In order to reduce the number of variables, the problem can be reformulated by parametrising the rotation as a unit quaternion   with vector part   and scalar part  , representing the rotation of angle   around an axis whose direction is described by the vector  , subject to the unity constraint  . It is now possible to express   in terms of the quaternion parametrisation as

 

where   is the skew-symmetric matrix

 .

Substituting   with the quaternion representation and simplifying the resulting expression, the gain function can be written as a quadratic form in  

 

where the   matrix

 

is defined from the quantities

 

This quadratic form can be optimised under the unity constraint by adding a Lagrange multiplier  , obtaining an unconstrained gain function

 

that attains a maximum when

 .

This implies that the optimal rotation is parametrised by the quaternion   that is the eigenvector associated to the largest eigenvalue   of  .[1][2]

Solution of the characteristic equation edit

The optimal quaternion can be determined by solving the characteristic equation of   and constructing the eigenvector for the largest eigenvalue. From the definition of  , it is possible to rewrite

 

as a system of two equations

 

where   is the Rodrigues vector. Substituting   in the second equation with the first, it is possible to derive an expression of the characteristic equation

 .

Since  , it follows that   and therefore   for an optimal solution (when the loss   is small). This permits to construct the optimal quaternion   by replacing   in the Rodrigues vector  

 .

The   vector is however singular for  . An alternative expression of the solution that does not involve the Rodrigues vector can be constructed using the Cayley–Hamilton theorem. The characteristic equation of a   matrix   is

 

where

 

The Cayley–Hamilton theorem states that any square matrix over a commutative ring satisfies its own characteristic equation, therefore

 

allowing to write

 

where

 

and for   this provides a new construction of the optimal vector

 

that gives the conjugate quaternion representation of the optimal rotation as

 

where

 .

The value of   can be determined as a numerical solution of the characteristic equation. Replacing   inside the previously obtained characteristic equation

 .

gives

 

where

 

whose root can be efficiently approximated with the Newton–Raphson method, taking 1 as initial guess of the solution in order to converge to the highest eigenvalue (using the fact, shown above, that   when the quaternion is close to the optimal solution).[1][2]

See also edit

References edit

  1. ^ a b c Shuster and Oh (1981)
  2. ^ a b c Markley and Mortari (2000)
  3. ^ Crassidis (2007)
  4. ^ Psiaki (2000)
  5. ^ Wu et al. (2017)
  6. ^ Xiaoping et al. (2008)

Sources edit

  • Crassidis, John L; Markley, F Landis; Cheng, Yang (2007). "Survey of nonlinear attitude estimation methods". Journal of Guidance, Control, and Dynamics. 30 (1): 12–28. Bibcode:2007JGCD...30...12C. doi:10.2514/1.22452.
  • Markley, F Landis; Mortari, Daniele (2000). "Quaternion attitude estimation using vector observations". The Journal of the Astronautical Sciences. 48 (2). Springer: 359–380. Bibcode:2000JAnSc..48..359M. doi:10.1007/BF03546284.
  • Psiaki, Mark L (2000). "Attitude-determination filtering via extended quaternion estimation". Journal of Guidance, Control, and Dynamics. 23 (2): 206–214. Bibcode:2000JGCD...23..206P. doi:10.2514/2.4540.
  • Shuster, M.D.; Oh, S.D. (1981). "Three-axis attitude determination from vector observations". Journal of Guidance and Control. 4 (1): 70–77. Bibcode:1981JGCD....4...70S. doi:10.2514/3.19717.
  • Wu, Jin; Zhou, Zebo; Gao, Bin; Li, Rui; Cheng, Yuhua; Fourati, Hassen (2017). "Fast linear quaternion attitude estimator using vector observations" (PDF). IEEE Transactions on Automation Science and Engineering. 15 (1). IEEE: 307–319. doi:10.1109/TASE.2017.2699221. S2CID 3455346.
  • Yun, Xiaoping; Bachmann, Eric R; McGhee, Robert B (2008). "A simplified quaternion-based algorithm for orientation estimation from earth gravity and magnetic field measurements". IEEE Transactions on Instrumentation and Measurement. 57 (3). IEEE: 638–650. doi:10.1109/TIM.2007.911646. S2CID 15571138.

External links edit

  • "QUEST — AHRS documentation".
  • University of Colorado Boulder. "QUEST". Kinematics: Describing the Motions of Spacecraft. Coursera.

quaternion, estimator, algorithm, quaternion, estimator, algorithm, quest, algorithm, designed, solve, wahba, problem, that, consists, finding, rotation, matrix, between, coordinate, systems, from, sets, observations, sampled, each, system, respectively, idea,. The quaternion estimator algorithm QUEST is an algorithm designed to solve Wahba s problem that consists of finding a rotation matrix between two coordinate systems from two sets of observations sampled in each system respectively The key idea behind the algorithm is to find an expression of the loss function for the Wahba s problem as a quadratic form using the Cayley Hamilton theorem and the Newton Raphson method to efficiently solve the eigenvalue problem and construct a numerically stable representation of the solution The algorithm was introduced by Malcolm D Shuster in 1981 while working at Computer Sciences Corporation 1 While being in principle less robust than other methods such as Davenport s q method or singular value decomposition the algorithm is significantly faster and reliable in practical applications 2 3 and it is used for attitude determination problem in fields such as robotics and avionics 4 5 6 Contents 1 Formulation of the problem 2 Solution of the characteristic equation 3 See also 4 References 5 Sources 6 External linksFormulation of the problem editWahba s problem consists of finding a rotation matrix A displaystyle mathbf A nbsp that minimises the loss function l A 12 i 1nai wi Avi 2 displaystyle l left mathbf A right frac 1 2 sum i 1 n a i left mathbf w i mathbf A mathbf v i right 2 nbsp where wi displaystyle mathbf w i nbsp are the vector observations in the reference frame vi displaystyle mathbf v i nbsp are the vector observations in the body frame A displaystyle mathbf A nbsp is a rotation matrix between the two frames and ai displaystyle a i nbsp are a set of weights such that iai 1 displaystyle textstyle sum i a i 1 nbsp It is possible to rewrite this as a maximisation problem of a gain function g displaystyle g nbsp g A 1 l A iaiwi Avi displaystyle g left mathbf A right 1 l left mathbf A right sum i a i mathbf w i top mathbf A mathbf v i nbsp defined in such a way that the loss l displaystyle l nbsp attains a minimum when g displaystyle g nbsp is maximised The gain g displaystyle g nbsp can in turn be rewritten as g A tr AB displaystyle g left mathbf A right operatorname tr left mathbf A mathbf B top right nbsp where B iaiwivi displaystyle mathbf B textstyle sum i a i mathbf w i mathbf v i top nbsp is known as the attitude profile matrix In order to reduce the number of variables the problem can be reformulated by parametrising the rotation as a unit quaternion q v1 v2 v3 q displaystyle mathbf q left v 1 v 2 v 3 q right nbsp with vector part v v1 v2 v3 displaystyle mathbf v left v 1 v 2 v 3 right nbsp and scalar part q displaystyle q nbsp representing the rotation of angle 8 2cos 1 q displaystyle theta 2 cos 1 q nbsp around an axis whose direction is described by the vector 1sin 82v displaystyle textstyle frac 1 sin frac theta 2 mathbf v nbsp subject to the unity constraint q q 1 displaystyle mathbf q top mathbf q 1 nbsp It is now possible to express A displaystyle mathbf A nbsp in terms of the quaternion parametrisation as A q2 v v I 2vv 2qV displaystyle mathbf A left q 2 mathbf v cdot mathbf v right mathbf I 2 mathbf v mathbf v top 2q mathbf V times nbsp where V displaystyle mathbf V times nbsp is the skew symmetric matrix V 0v3 v2 v30v1v2 v10 displaystyle mathbf V times begin pmatrix 0 amp v 3 amp v 2 v 3 amp 0 amp v 1 v 2 amp v 1 amp 0 end pmatrix nbsp Substituting A displaystyle mathbf A nbsp with the quaternion representation and simplifying the resulting expression the gain function can be written as a quadratic form in q displaystyle mathbf q nbsp g q q Kq displaystyle g mathbf q mathbf q top mathbf K mathbf q nbsp where the 4 4 displaystyle 4 times 4 nbsp matrix K S sIzz s displaystyle mathbf K begin pmatrix mathbf S sigma mathbf I amp mathbf z mathbf z top amp sigma end pmatrix nbsp is defined from the quantities S B B z iai wi vi s tr B displaystyle begin aligned mathbf S amp mathbf B mathbf B top mathbf z amp sum i a i left mathbf w i times mathbf v i right sigma amp operatorname tr mathbf B end aligned nbsp This quadratic form can be optimised under the unity constraint by adding a Lagrange multiplier lq q displaystyle lambda mathbf q top mathbf q nbsp obtaining an unconstrained gain function g q q Kq lq q displaystyle hat g left mathbf q right mathbf q top mathbf K mathbf q lambda mathbf q top mathbf q nbsp that attains a maximum when Kq lq displaystyle mathbf K mathbf q lambda mathbf q nbsp This implies that the optimal rotation is parametrised by the quaternion q displaystyle mathbf q nbsp that is the eigenvector associated to the largest eigenvalue lmax displaystyle lambda text max nbsp of K displaystyle mathbf K nbsp 1 2 Solution of the characteristic equation editThe optimal quaternion can be determined by solving the characteristic equation of K displaystyle mathbf K nbsp and constructing the eigenvector for the largest eigenvalue From the definition of K displaystyle mathbf K nbsp it is possible to rewrite Kq lq displaystyle mathbf K mathbf q lambda mathbf q nbsp as a system of two equations y l s I S 1zl s zy displaystyle begin aligned mathbf y amp left lambda sigma mathbf I mathbf S right 1 mathbf z lambda amp sigma mathbf z mathbf y end aligned nbsp where y 1qv displaystyle mathbf y textstyle frac 1 q mathbf v nbsp is the Rodrigues vector Substituting y displaystyle mathbf y nbsp in the second equation with the first it is possible to derive an expression of the characteristic equation l s z l s I S 1z displaystyle lambda sigma mathbf z top left lambda sigma mathbf I mathbf S right 1 mathbf z nbsp Since lmax maxg A displaystyle lambda text max max g left mathbf A right nbsp it follows that lmax 1 minl A displaystyle lambda text max 1 min l left mathbf A right nbsp and therefore lmax 1 displaystyle lambda text max approx 1 nbsp for an optimal solution when the loss l displaystyle l nbsp is small This permits to construct the optimal quaternion q displaystyle mathbf q nbsp by replacing lmax displaystyle lambda text max nbsp in the Rodrigues vector y displaystyle mathbf y nbsp q 11 ylmax 2 y 1 displaystyle mathbf q frac 1 sqrt 1 left mathbf y lambda text max right 2 mathbf y 1 top nbsp The y displaystyle mathbf y nbsp vector is however singular for 8 p displaystyle theta pi nbsp An alternative expression of the solution that does not involve the Rodrigues vector can be constructed using the Cayley Hamilton theorem The characteristic equation of a 3 3 displaystyle 3 times 3 nbsp matrix S displaystyle mathbf S nbsp is det S 3I 33 2s32 k3 D 0 displaystyle det left mathbf S xi mathbf I right xi 3 2 sigma xi 2 k xi Delta 0 nbsp where s 12tr Sk tr adj S D detS displaystyle begin aligned sigma amp frac 1 2 operatorname tr mathbf S k amp operatorname tr left operatorname adj mathbf S right Delta amp det mathbf S end aligned nbsp The Cayley Hamilton theorem states that any square matrix over a commutative ring satisfies its own characteristic equation therefore S3 2sS2 kS D 0 displaystyle mathbf S 3 2 sigma mathbf S 2 k mathbf S Delta 0 nbsp allowing to write w s I S 1 aI bS S2g displaystyle left omega sigma mathbf I mathbf S right 1 frac alpha mathbf I beta mathbf S mathbf S 2 gamma nbsp where a w2 s2 kb w sg w s a D displaystyle begin aligned alpha amp omega 2 sigma 2 k beta amp omega sigma gamma amp omega sigma alpha Delta end aligned nbsp and for w lmax displaystyle omega lambda text max nbsp this provides a new construction of the optimal vector y l s I S 1z aI bS S2gz displaystyle begin aligned mathbf y amp left lambda sigma mathbf I mathbf S right 1 mathbf z amp frac alpha mathbf I beta mathbf S mathbf S 2 gamma mathbf z end aligned nbsp that gives the conjugate quaternion representation of the optimal rotation as q 1g2 x 2 x g displaystyle mathbf q frac 1 sqrt gamma 2 left mathbf x right 2 mathbf x gamma top nbsp where x aI bS S2 z displaystyle mathbf x left alpha mathbf I beta mathbf S mathbf S 2 right mathbf z nbsp The value of lmax displaystyle lambda text max nbsp can be determined as a numerical solution of the characteristic equation Replacing w s I S 1 displaystyle left omega sigma mathbf I mathbf S right 1 nbsp inside the previously obtained characteristic equation l s z l s I S 1z displaystyle lambda sigma mathbf z top left lambda sigma mathbf I mathbf S right 1 mathbf z nbsp gives l4 a b l2 cl ab cs d 0 displaystyle lambda 4 a b lambda 2 c lambda ab c sigma d 0 nbsp where a s2 kb s2 z zc D z Szd z S2z displaystyle begin aligned a amp sigma 2 k b amp sigma 2 mathbf z top mathbf z c amp Delta mathbf z top mathbf S mathbf z d amp mathbf z top mathbf S 2 mathbf z end aligned nbsp whose root can be efficiently approximated with the Newton Raphson method taking 1 as initial guess of the solution in order to converge to the highest eigenvalue using the fact shown above that lmax 1 displaystyle lambda text max approx 1 nbsp when the quaternion is close to the optimal solution 1 2 See also editTriad method Wahba s problemReferences edit a b c Shuster and Oh 1981 a b c Markley and Mortari 2000 Crassidis 2007 Psiaki 2000 Wu et al 2017 Xiaoping et al 2008 Sources editCrassidis John L Markley F Landis Cheng Yang 2007 Survey of nonlinear attitude estimation methods Journal of Guidance Control and Dynamics 30 1 12 28 Bibcode 2007JGCD 30 12C doi 10 2514 1 22452 Markley F Landis Mortari Daniele 2000 Quaternion attitude estimation using vector observations The Journal of the Astronautical Sciences 48 2 Springer 359 380 Bibcode 2000JAnSc 48 359M doi 10 1007 BF03546284 Psiaki Mark L 2000 Attitude determination filtering via extended quaternion estimation Journal of Guidance Control and Dynamics 23 2 206 214 Bibcode 2000JGCD 23 206P doi 10 2514 2 4540 Shuster M D Oh S D 1981 Three axis attitude determination from vector observations Journal of Guidance and Control 4 1 70 77 Bibcode 1981JGCD 4 70S doi 10 2514 3 19717 Wu Jin Zhou Zebo Gao Bin Li Rui Cheng Yuhua Fourati Hassen 2017 Fast linear quaternion attitude estimator using vector observations PDF IEEE Transactions on Automation Science and Engineering 15 1 IEEE 307 319 doi 10 1109 TASE 2017 2699221 S2CID 3455346 Yun Xiaoping Bachmann Eric R McGhee Robert B 2008 A simplified quaternion based algorithm for orientation estimation from earth gravity and magnetic field measurements IEEE Transactions on Instrumentation and Measurement 57 3 IEEE 638 650 doi 10 1109 TIM 2007 911646 S2CID 15571138 External links edit QUEST AHRS documentation University of Colorado Boulder QUEST Kinematics Describing the Motions of Spacecraft Coursera Retrieved from https en wikipedia org w index php title Quaternion estimator algorithm amp oldid 1169879608, wikipedia, wiki, book, books, library,

article

, read, download, free, free download, mp3, video, mp4, 3gp, jpg, jpeg, gif, png, picture, music, song, movie, book, game, games.