Abstract:
This invention discloses a pose tracking apparatus operative to track the pose of a moving object based on magnetic flux measurements taken in the vicinity of the moving object. The pose tracking apparatus includes a non-linear Kalman filter-based tracker. The tracker is operated to receive magnetic flux measurements performed in the vicinity of the moving object, and to operate a non-linear Kalman-type filter on said measurements, thereby to generate information regarding the pose of the moving object. In addition, the pose tracking apparatus includes a pose indicator operative to provide an output indication of the information regarding the pose of the moving object.

Description:
FIELD OF THE INVENTION 
     The present invention relates to apparatus for localization and tracking. 
     BACKGROUND OF THE INVENTION 
     The theory of non-linear filtering and its applications are discussed in: 
     H. J. Kushner, “Approximations to Optimal Nonlinear Filters”. IEEE Trans. A.C., Vol. AC-12, No. 5, October 1967; 
     A. Gelb, J. F. Kaspar, Jr., R. A. Nash, Jr., C. E. Price, and A. A. Southerland, Jr., “Applied Optimal Estimation”, M.I.T. Press, Cambridge, Mass., 1974; 
     B. D. O. Anderson, and J. B. Moore, “Optimal Filtering”, Prentice-Hall, Englewood Cliffs, N.J., 1979; 
     A. H. Jazwinski, “Stochastic Processes and Filtering Theory”, Academic Press, New York, 1971; and 
     M. S. Grewal, and A. P. Andrews, “Kalman Filtering”, Prentice-Hall, Upper Saddle River, N.J., 1993. 
     The Biot-Savart law is discussed in: 
     J. D. Jackson, “Classical Electrodynamics”, John Willey &amp; Sons, New York, N.Y., 1975. 
     The application of Extended Kalman Filters (EKF) to tracking in the context of radar is discussed, for example, in U.S. Pat. Nos. 5,075,694, 4,179,696, 3,952,304 and 3,935,572. Other tracking systems are discussed, for example, in U.S. Pat. Nos. 5,095, 467 and 4,855,932. 
     The Kalman Filter is a standard tool for “data fusion” of different sensors. In U.S. Pat. No. 5,416,712 GPS signals and dead reckoning are combined by a Kalman Filter, and where the gyro bias is also calibrated. In U.S. Pat. No. 5,645,077 automatic drift compensation is discussed. 
     The disclosures of all publications mentioned in the specification and of the publications cited therein are hereby incorporated by reference. 
     SUMMARY OF THE INVENTION 
     The present invention seeks to provide a non-linear Kalman Filter tracker. 
     There is thus provided in accordance with a preferred embodiment of the present invention pose tracking apparatus operative to track the pose of a moving object based on magnetic flux measurements taken in the vicinity of the moving object, the pose tracking apparatus including a non-linear Kalman filter-based tracker operative to receive magnetic flux measurements performed in the vicinity of the moving object, to operate a non-linear Kalman-type filter on the measurements, thereby to generate information regarding the pose of the moving object, and a pose indicator operative to provide an output indication of the information regarding the pose of the moving object. 
     Further in accordance with a preferred embodiment of the present invention the non-linear tracker includes an EKF (extended Kalman filter). 
     Additionally in accordance with a preferred embodiment of the present invention, the non-linear filter operates on a state vector whose components include pose coordinates and first time-derivatives of the pose coordinates. 
     Further in accordance with a preferred embodiment of the present invention the pose coordinates include 3 spatial coordinates and 2 orientation coordinates. 
     Further in accordance with a preferred embodiment of the present invention the apparatus also includes a transmitter array, which may include less than six operative transmitters, inducing magnetic flux in the vicinity of the moving object. 
     Still further in accordance with a preferred embodiment of the present invention the non-linear tracker employs a Biot-Savart transformation from the pose of the moving object to the magnetic flux measurements taken in its vicinity. 
     Still further in accordance with a preferred embodiment of the present invention the step of employing the Biot-Savart transformation includes computing a function h of a state vector ξ, as follows:          h        (   ξ   )       =         C   0       R   3            (         3        A   1          A   2         R   2       -     A   3       )                              
     where C 0  is a coefficient, 
     R is the distance between a detector detecting the magnetic flux measurements and a transmitter within the transmitter array; and 
       A   1 =δx sin(θ s )cos(φ s )+δy sin(θ s )sin(φ s )+δz cos(θ s ) 
     
       
           A   2 =δx sin(θ d )cos(φ d )+δy sin(θ d )sin(φ d )+δz cos(θ d ) 
       
     
     
       
         A 3 =sin(θ s )cos(φ s )sin(θ d )cos(φ d )+sin(θ s )sin(φ s )sin(θ d )sin(φ d )+cos(φ s )cos(φ d ) 
       
     
     and wherein the pose of the detector is (x d , y d , z d , θ d , φ d ) and the pose of the transmitter is (x s , y s , z s , θ s , φ s ), and where δx, δy and δz denote the distance between the x, y and z components, respectively, of the detector&#39;s pose and the transmitter&#39;s pose. 
     Additionally in accordance with a preferred embodiment of the present invention the non-linear tracker approximates an elliptic integral, at least when the moving object is close to a transmitter within the transmitter array, by computing first and second terms of a Taylor series representing the elliptic integral. 
     Additionally in accordance with a preferred embodiment of the present invention, the approximated elliptic integral includes a correction to the above mentioned A 1  and A 3 , 
     
       
           A   1   →A   1 (1−δ) 
       
     
     
       
           A   3   →A   3 (1−η) 
       
     
     
       
         
           
             δ 
             = 
             
               
                 5 
                 8 
               
                
               
                 
                   ( 
                   
                     ρ 
                     R 
                   
                   ) 
                 
                 2 
               
                
               
                 ( 
                 
                   
                     7 
                      
                     
                       
                         A 
                         1 
                         2 
                       
                       
                         R 
                         2 
                       
                     
                   
                   - 
                   3 
                 
                 ) 
               
             
           
         
         
           
             η 
             = 
             
               
                 9 
                 8 
               
                
               
                 
                   ( 
                   
                     ρ 
                     R 
                   
                   ) 
                 
                 2 
               
                
               
                 ( 
                 
                   
                     5 
                      
                     
                       
                         A 
                         1 
                         2 
                       
                       
                         R 
                         2 
                       
                     
                   
                   - 
                   1 
                 
                 ) 
               
             
           
         
                 
         
             
         
      
     
     and where ρ is the radius of the transmitter. 
     Still further in accordance with a preferred embodiment of the present invention the orientation component of the pose of the moving object is represented by two angles, continuous over time θ′ and φ′, whose relationship with conventional polar coordinates θ and φ is as follows:        θ   =     {               θ   ′               if                     mod   (     θ   ,     2                 π       )       ≤   π               -     θ   ′                 if                     mod   (     θ   ,     2                 π       )       &gt;   π                
        ϕ     =     {           ϕ   ′               if                   θ     =     θ   ′                   ϕ   ′     +   π               if                   θ     =     -     θ   ′                                            
     Still further in accordance with a preferred embodiment of the present invention, in order to avoid singularity, a dynamic offset is described by the following transformation: 
      θ=cos −1 [cos(θ′)cos(φ′)] 
     
       
         φ=cos −1 [{square root over (cos 2 (θ)+sin 2 (φ′)cos 2 (θ′))}] 
       
     
     where θ and φ include the orientation component of the moving object&#39;s pose after the dynamic offset, and θ′ and φ include the orientation component of the moving object&#39;s pose before the dynamic offset. 
     Still further in accordance with a preferred embodiment of the present invention the non-linear filter employs the following matrices and operations: 
     
       
         ξ k (−)=Φξ k−1 (+) 
       
     
     where k is a time index, ξ k (−) is a state vector predictor, ξ k (+) is a state vector corrector, and Φ is a state transition matrix, 
     
       
           P   k (−)=Φ P   k−1 (+)χ T   +Q   
       
     
     where P(−) is an estimate error covariance matrix predictor, P(+) is an estimate error covariance matrix corrector and Q is a process noise covariance matrix,                     H   k     =       ∂     h        (     ξ   →     )           ∂     ξ   →                           ξ   k          (   -   )                              
     where h is a sensitivity function and ξ is a state vector, 
     
       
           K   k   =P   k (−) H   k   T   [H   k   P   k (−) H   k   T   +R   k ] −1   
       
     
     where R k  is a measurement noise covariance matrix, 
     
       
         ξ k (+)=ξ k (−)+ K   k {ζ k −h[ξ k (−)]} 
       
     
     where ζ denotes the magnetic flux measurements taken in the vicinity of the moving object, and 
     
       
           P   k (+)=[ I−K   k   H   k   ]P   k (−) 
       
     
     Still further in accordance with a preferred embodiment of the present invention the magnetic flux measurements may include less than six magnetic flux measurements in the vicinity of the moving object. 
     Additionally in accordance with a preferred embodiment of the present invention, the non-linear tracker is operative to time-vary a measurement-noise covariance matrix R and a process-noise covariance matrix Q. 
     Further in accordance with a preferred embodiment of the present invention the time-varying R and Q includes:          R   k   dec     =       R     k   -   1     dec          e         T   k     -     T     k   -   1           τ   decay                     R   k     =       R   k   dec     +     R   inf                 Q   k   dec     =       Q     k   -   1     dec          e         T   k     -     T     k   -   1           τ   decay                     Q   k     =       Q   k   dec     +     Q   inf                              
     Still further in accordance with a preferred embodiment of the present invention at least one of the transmitters inducing a magnetic flux sampled by the measurements is self-calibrated. 
     Additionally in accordance with a preferred embodiment of the present invention, the non-linear filter is operative to calibrate the location of each of the self-calibrating transmitters. 
     Further in accordance with a preferred embodiment of the present invention the non-linear filter is operative to calibrate the intensity of each of the self-calibrating transmitters. 
     Still further in accordance with a preferred embodiment of the present invention the non-linear filter is operative to calibrate the radius of each of the self-calibrating transmitters. 
     Additionally in accordance with a preferred embodiment of the present invention, the non-linear filter is operative to calibrate the orientation of each of the self-calibrating transmitters. 
     Further in accordance with a preferred embodiment of the present invention, the tracker uses a state vector whose components comprise characteristics of the self-calibrated transmitters inducing a magnetic flux sampled by the measurements, and wherein at least one of the characteristics is self-calibrated. 
     Still further in accordance with a preferred embodiment of the present invention, the non-linear tracker employs a measurement noise matrix R and a process noise covariance matrix Q at least one of which is generated by an adaptive process. 
     Additionally in accordance with a preferred embodiment of the present invention the adaptive process for Q comprises 
               Q   k   acc     =              α        (           ξ   k   velocity          (   +   )       -       ξ     k   -   1     velocity          (   +   )             T   k     -     T     k   -   1           )            2     +       (     1   -   α     )          Q     k   -   1     acc                                Q   k   =Q   k   acc   +Q   o   acc   
     
       
         ξ k   velocity (+) =estimate of {{dot over (x)}, {dot over (y)}, {dot over (z)}, {dot over (φ)}, {dot over (θ)}} 
       
     
     Further in accordance with a preferred embodiment of the present invention the adaptive process for R comprises 
     
       
           R   k   s,s =β{ζ k   s −h s [ξ k (−)]} 2 +(1−β) R   k−1   s,s   
       
     
     
       
         
           R 
           k 
           =R 
           k 
           s,s 
           +R 
           o 
           s,s 
         
       
     
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS AND APPENDIX 
     The present invention will be understood and appreciated from the following detailed description, taken in conjunction with the drawings and appendix in which: 
     FIGS. 1A-1C, taken together, form a simplified flow chart illustration of a preferred method of operation of a Biot-Savart based EKF-type tracking filter; 
     FIG. 2 is a simplified block diagram of an example of a tracking system, including a Biot-Savart based EKF-type tracking filter operating in accordance with the method of FIGS. 1A-1C; 
     FIG. 3 is a vector diagram illustrating state vector orientations; 
     FIG. 4 is a vector diagram illustrating the Biot-Savart law; 
     FIG. 5 is a simplified diagram of a detector crossing a singularity point; 
     FIGS. 6A and 6B are simplified diagrams of the dynamics of the coordinates for the conventional polar orientation of FIG. 5; and 
     FIGS. 7A and 7B are simplified diagrams of the dynamics of the coordinates for the polar orientation of FIG. 5 in accordance with a preferred embodiment of the present invention. 
    
    
     Appendix A is a copy of copending Israel Patent Application No. 126284. 
     DETAILED DESCRIPTION OF PREFERRED EMBODIMENTS 
     Definition of terms: 
     Pose: five dimensional coordinates of a circular-symmetrical object, including three coordinates describing its location in a three-dimensional space, and two coordinates describing its orientation. 
     Orientation: two-dimensional angular position of an object, describing its orientation relative to a fixed orientation in three-dimensional space. 
     Transmitter: a device operative to emit a magnetic field from which a magnetic flux may be created. 
     Detector: a device operative to transform the magnetic flux that crosses its area into electric voltage. 
     FIGS. 1A-1C, taken together, form a flow chart diagram of a preferred method of operation of a Biot-Savart based EKF-type tracking filter. 
     FIG. 2 is a simplified block diagram of an example of a tracking system, including a Biot-Savart based EKF-type tracking filter, operating in accordance with the method of FIGS. 1A-1C. As shown, the system of FIG. 2 preferably comprises the following functional units: 
     1. a transmission system (transmitter)  40 , including a number of electric coils and the electronic circuits that drive them (i.e. driver); 
     2. a detection system (detector)  50 , including a coil and the electronic circuit that provides preprocessing, e.g., pre-amplification, gain control, and filtering; 
     3. a synchronization system  60 ; 
     4. an envelopes-detector  70 ; and 
     5. a tracking non-linear filter (tracker)  80 . 
     Each of transmitters  40  may comprise a conventional solenoid, driven by an A/C current. 
     Detector  50  may be similar to units termed “One axis magnetic field detector  50 ” and “Signal Conditioning and A/D Conversion  64 ” of FIG. 1D of copending Israel Patent Application No. 126284, the text of which is appended hereto as Appendix A. 
     Synchronization system  60  may be similar to a unit termed “System Synchronization  420 ” of FIG. 6A of copending Israel Patent Application No. 126284, the text of which is appended hereto as Appendix A. 
     Envelopes-detector  70  may be similar to a unit termed “Envelope Detector for determination of amplitudes C 1 , . . . C N  (N≧6)  114 ” of FIG. 3 of copending Israel Patent Application No. 126284, the text of which is appended hereto as Appendix A. 
     Tracking non-linear filter  80  may be similar to a unit termed “Position finding  116 ” of FIG. 3 of copending Israel Patent Application No. 126284, the text of which is appended hereto as Appendix A. 
     A preferred method of operation for a Biot-Savart based EKF-type tracking nonlinear filter 80 is described herein in detail with reference to FIGS. 1A-1C. By way of example, a transmitter-array inducing magnetic fields is described. The superposition of these magnetic fluxes is described as being detected by a magnetic flux detector, and resolved to individual fluxes by an envelope detector. However, it is appreciated that this invention may employ other forms of flux induction and flux measurements. 
     State Space Model of a Dynamic System 
     A conventional Kalman filter (KF) is a sequential tracker that generates an optimal estimate of the state of a linear system based on measures of the noise in the system, a model of the system&#39;s equations of motion and an estimate of its previous state. If the system of interest is not linear then an “EKF” (Extended Kalman Filter), one out of many variations of a KF, is typically used. 
     A conventional KF uses several matrices to compute an optimal estimate to a state vector. These matrices are derived from the system equations of motion, e.g. as follows: 
     An approximation to the system dynamics is made: 
     
       
         ξ( t )= F ξ( t )+ w ( t ) 
       
     
     
       
         ξ( t )= h [ξ( t )]+ v ( t )  (1) 
       
     
     In equation (1) ξ(t) is a state vector, F is the differential equation coefficient matrix, w(t) is a system noise, ζ(t) is the measurements, h(•) is the measurement sensitivity function, and v(t) is the measurement noise. h(•) is a vector function whose dimension is the number of measurements. The measurements ζ may be the same as the “C&#39;s” i.e. the output from the Envelope Detector  114  and the input of the Position Detector  116 , of FIG. 5 of copending Israel Patent Application No. 126284, the text of which is appended hereto as Appendix A. Both measurement-noise and system-noise are assumed invariant white Gaussian distributed processes, and are independent of each other. 
     The discrete time form of equation (1) reads: 
      ξ k =Φξ k−1   +w   k−1   
     
       
         ζ k   =h [ζ k   ]+v   k−1   (2) 
       
     
     ξ k  is the state vector a t time-step k, Φ is the state transition matrix, w k  is the system noise, h(•) is the measurement sensitivity function, ζ k  is the measurements vector, and v k  is the measurement noise, all at time bin k. The noises w k  and v k  are independent invariant Gaussian processes. 
     Any choice of state vector is typically accepted providing it includes enough information to compute the desired pose. One possible choice is: 
     
       
         ξ=[ x,y,z ,φ,θ,{dot over (x)},{dot over (y)},{dot over (z)},{dot over (Φ)},{dot over (θ)}]  (3) 
       
     
     where {x, y, z, φ, θ} are the five coordinates of the detector&#39;s pose as illustrated in FIG. 3, and a dot over a variable denotes the variable&#39;s time-derivative. The effect of higher-order d e rivatives is implicitly included within the system noise. 
     The KF is based on some knowledge of t he statistics of Gaussian noises w k  and v k : 
     
       
           E&lt;v   k   v   i   T )=δ k,i   R   k   
       
     
     
       
           E&lt;w   k   w   i   T &gt;=δ k,i   Q   k   
       
     
     
       
           E&lt;w   k   &gt;=E&lt;v   k &gt;=0  (4) 
       
     
     where δ k,i  denotes the Kronecker delta function. 
     The transition from continuous to discrete time is made using the relation: 
      Φ= e   FT   =e   F(t     k     −t     k−1     )   
     
       
           E&lt;v   k   v   i   T &gt;=δ k,i   R E&lt;v ( t ) v ( s )&gt;=δ( t−s ) {tilde over (R)}   
       
     
     
       
           E&lt;w   k   w   i   T &gt;=δ k,i   Q E&lt;w ( t ) w ( s )&gt;=δ( t−s ) {tilde over (Q)}   (5) 
       
     
     
       
         
           
             R 
             = 
             
               
                 
                   
                     R 
                     ~ 
                   
                   
                     ( 
                     
                       
                         t 
                         k 
                       
                       - 
                       
                         t 
                         
                           k 
                           - 
                           1 
                         
                       
                     
                     ) 
                   
                 
                  
                 
                     
                 
                  
                 Q 
               
               = 
               
                 
                   Q 
                   ~ 
                 
                  
                 
                   ( 
                   
                     
                       t 
                       k 
                     
                     - 
                     
                       t 
                       
                         k 
                         - 
                         1 
                       
                     
                   
                   ) 
                 
               
             
           
         
                 
         
             
         
      
     
     The last two expressions of equation (5) are only approximations. The former neglects non-linear terms of (t k −t k−1 ), and the latter is correct if the sensor integrates the noise over the period between t k−1  and t k . 
     Using an Extended Kalman Filter for Magnetic Tracking 
     The measurement sensitivity function h(•), which relates the induced voltage to the magnetic field, is known as the Biot-Savart law and is difficult to express in a closed form. Thus, an approximation is preferably made, such as:                  h        (   ξ   )       =         C   0              r   →          3            [         3            r   →          2            (         n   →     s     ·     r   →       )          (         n   →     d     ·     r   →       )       -     (         n   →     s     ·       n   →     d       )       ]              
            r   →     =         r   →     s     -       r   →     d                 (   6   )                                
     r s  and r d  are the position vector of the transmitter and the detector, and n s  and n d  are their corresponding plane unit vectors (the plane vector is a vector whose orientation is perpendicular to the plane). These notations are depicted in FIG.  4 . The function h(ξ) is a vector flnction. Each of its members corresponds to the interaction with a single transmitter. For each member of the vector flnction, the values of r s , n s , and C 0  take corresponding values. 
     Operation of the tracker  80  can be defined using any of several extensions to the Kalman filter. A preferred embodiment of the present invention utilizing an EKF is described hereinbelow, and is illustrated in FIGS. 1A-1C. 
     The procedure is an iterative one, providing successive estimates each based on the previous one. An initial computation  200  typically provides five initial arrays: Q 0 , R 0 , P 0 , Φ, and ξ o . The role of each is described below. 
     Given an estimate to the state vector at time step k−1, a prediction  205  is made to the state vector at time k: 
     
       
         ξ k (−)=Φξ k−1 (+)  (7) 
       
     
     The notation (−) and (+) denote an estimation made prior to measurement taking (prediction) and after it (correction) respectively. For the state vector suggested in equation (3), the matrix Φ takes the form:              Φ   =     [         1       0       0       0       0         T   s         0       0       0       0           0       1       0       0       0       0         T   s         0       0       0           0       0       1       0       0       0       0         T   s         0       0           0       0       0       1       0       0       0       0         T   s         0           0       0       0       0       1       0       0       0       0         T   s             0       0       0       0       0       1       0       0       0       0           0       0       0       0       0       0       1       0       0       0           0       0       0       0       0       0       0       1       0       0           0       0       0       0       0       0       0       0       1       0           0       0       0       0       0       0       0       0       0       1         ]             (   8   )                                
     A prediction  210  is made to the estimate error covariance-matrix: 
     
       
           P   k (−)=Φ P   k−1 (+)Φ T   +Q   (9) 
       
     
     The matrix Q in this example takes the form:        Q   =     [         0       0       0       0       0       0       0       0       0       0           0       0       0       0       0       0       0       0       0       0           0       0       0       0       0       0       0       0       0       0           0       0       0       0       0       0       0       0       0       0           0       0       0       0       0       0       0       0       0       0           0       0       0       0       0         Q   x         0       0       0       0           0       0       0       0       0       0         Q   y         0       0       0           0       0       0       0       0       0       0         Q   z         0       0           0       0       0       0       0       0       0       0         Q   φ         0           0       0       0       0       0       0       0       0       0         Q   θ           ]                            
     
       
           Q   x =( T   s ×maximalallowed{umlaut over (x)}) 2   
       
     
     
       
           Q   y =( T   s ×maximalallowedÿ) 2   
       
     
     
       
           Q   z =( T   s ×maximalallowed{umlaut over (z)}) 2   
       
     
     
       
           Q   φ =( T   s ×maximalallowed{umlaut over (φ)}) 2   
       
     
     
       
           Q   θ =( T   s ×maximalallowed{umlaut over (θ)}) 2   (10) 
       
     
     A linear approximation  215  is Diade to the measurement sensitivity finction. For the state vector suggested in equation (3), and as to an example of a 9-transmitter system, this approximation becomes:                                 H   k     =                  ∂     h        (   ξ   )           ∂   ξ                         ξ   k          (   -   )                   =                [           h     x   ,   k     1           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     2           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     3           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     4           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     5           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     6           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     7           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     8           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0             h     x   ,   k     9           h     y   ,   k     1           h     z   ,   k     1           h     φ   ,   k     1           h     θ   ,   k     1         0       0       0       0       0         ]                   (   11   )                                
     where the term h 1   x,k  denotes the dlerivative of magnetic interaction of the detector with transmitter number 1 with respect to x taken at the coordinates estimated at time bin k. Similarly, other terms denote (deriTvatives of other interactions with respect to other coordinates. The right half is zero because the contribution of the speed to the magnetic interaction is neglected ,and therefore, the derivative with respect to speed vanishes. It is appreciate the incorporation of the contribution of the speed into the magnetic interaction, if desired, is straightforward. 
     The following approximation miay be used to compute the Kalman gain matrix  220 : 
     
       
           K   k   =P   k (−)H k   T   [H   k   P   k (−) H   k   T   +R   k ] −1   (12) 
       
     
     For the example of a 9-transmitter system, R may take the form:              R   =     [           R   1         0       0       0       0       0       0       0       0           0         R   2         0       0       0       0       0       0       0           0       0         R   3         0       0       0       0       0       0           0       0       0         R   4         0       0       0       0       0           0       0       0       0         R   5         0       0       0       0           0       0       0       0       0         R   6         0       0       0           0       0       0       0       0       0         R   7         0       0           0       0       0       0       0       0       0         R   8         0           0       0       0       0       0       0       0       0         R   9           ]             (   13   )                                
     where R s  denotes the covariance of the measurement error for transmitter s, and the measurement errors of different transmitters are assumed to be uncorrelated. 
     The gain  220 , in turn, may be used to make a correction  225  to the predicted state vector  205  and a correction  230  to the predicted error covariance matrix  210 . The correction to the stae vector  225  may be a multiplication of the gain by the difference between the measurements and the predicted measurements based on the state vector (the innovations): 
     
       
         ξ k (+)=ξ k (−)+ K   k {ζ k   −h [ζ k (−)]}  (14) 
       
     
     The correction to the error covariance matrix  230  contains the gain  220  and the rement sensitivity function  215 : 
     
       
           P   k (+)=[ I−K   k   H   k ]P k (−)  (15) 
       
     
     Thus, by providing initial approximations  200  to the state vector, the error covariance matrix, P o , and a model in terms of Q, R and h(•) a sequence of optimal estimates based on measurements ζ k  can be produced. 
     The exact values of initial arrays  200  are not critical. The values of the matrices Q and R may be estimated from prior knowledge of the system, i.e., the elements of R are computed from the measurement noise and the value of Q from the expected accelerations in the system. P 0  may take any representative value, e.g., if a speed of five meters per second is expected, then the elements of P 0  relating to speed would take the value of twenty-five meters per second. Similarly, ζ 0  may take the values of a typical state, e.g., if tracking is limited to a one-meter cube, and speed is limited to one meter per second, then ζ 0  may become a vector of ones. 
     The approximation to the Biot-Savart law given in equation (6) may not be convenient for computation. In order to facilitate computation, it may be presented in terms of the pose of the detector  50  {x d , y d , z d , φ d , θ d  } and the pose of the transmitter  40  {x s , z s , z s , φ s , θ s }. The translations and distance are computed: 
     
       
         δ x=x   s   =x   d   
       
     
     
       
         δ y=y   s   −y   d   
       
     
     
       
         δ z=z   s   −z   d   
       
     
     
       
           R={square root over (δx 2   +δy   2   +δz   2 )}   (16) 
       
     
     These values are used to compute three temporary values: 
     
       
           A   1   =δx  sin(θ s )cos(φ s )+δ y  sin(θ s )sin(φ s )+ 460  δ z  cos(θ s ) 
       
     
     
       
           A   2   =δx  sin(θ d )cos(φ d )+δ y  sin(θ d )sin(φ d )+δ z  cos(θ d ) 
       
     
     
       
           A   3 =sin(θ s )cos(φ s )sin(θ d )cos(φ d )+sin(θ s )sin(φ s )sin(θ d )sin(φ d )+cos(φ s )cos(φ d )  (17) 
       
     
     The magnetic interaction is computed:                h        (   ξ   )       =         C   0       R   3            (         3        A   1          A   2         R   2       -     A   3       )               (   18   )                                
     where C 0  is a coefficient that is preferably experimentally determined. Knowing the pose of the detector  50  and the pose of the transmitter  40 , once C 0  is known, the magnetic interaction can be computed. 
     Improved Biot-Savart Approximation 
     Equations (16), (17) and (18) are more convenient to use when the state vector (3) is known, though it is sometimes still a poor approximation. Better tracking is achieved when the model of magnetic interaction is improved, considering more physical effects. For example, a simple approximation assumes that the radius of the transmitter&#39;s coil is much smaller than the distance between the transmitter and the detector. In this preferred embodiment of the present invention, a large transmitter is preferred because it allows easier induction of intense magnetic fields. Thus, when the detector nears the transmitter a correction is made to A 1  and A 3 : 
     
       
           A   1   →A   1 (1−δ) 
       
     
     
       
           A   3   →A   3 (1−η) 
       
     
     
       
         
           
             
               
                 
                   
                     δ 
                     = 
                     
                       
                         5 
                         8 
                       
                        
                       
                         
                           ( 
                           
                             ρ 
                             R 
                           
                           ) 
                         
                         2 
                       
                        
                       
                         ( 
                         
                           
                             7 
                              
                             
                               
                                 A 
                                 1 
                                 2 
                               
                               
                                 R 
                                 2 
                               
                             
                           
                           - 
                           3 
                         
                         ) 
                       
                     
                   
                    
                   
                     
 
                   
                    
                   
                     η 
                     = 
                     
                       
                         9 
                         8 
                       
                        
                       
                         
                           ( 
                           
                             ρ 
                             R 
                           
                           ) 
                         
                         2 
                       
                        
                       
                         ( 
                         
                           
                             5 
                              
                             
                               
                                 A 
                                 1 
                                 2 
                               
                               
                                 R 
                                 2 
                               
                             
                           
                           - 
                           1 
                         
                         ) 
                       
                     
                   
                 
               
               
                 
                   ( 
                   19 
                   ) 
                 
               
             
           
         
                 
         
             
         
      
     
     where ρ is the radius of the transmitter&#39;s coil, and R is defined by equation (16). Equations (18) and (19) are both approximations to the Biot-Savart law. The former approaches the exact solution when both the transmitter and the detector have an infinitely small radius. When the transmitter&#39;s radius increases, an exact solution to the Biot-Savart law may be expressed in terms of elliptic integrals. Equation (19) approximates the exact solution when only the first and second terms of a Taylor series in ρ/R are taken. 
     Using Redundant Measurements to Improve Tracking 
     The number of measurements necessary to provide precise tracking is an important practical issue. It is desirable to produce a system with a minimal number of transmitters to reduce the hardware production cost and to decrease the computational load. The reduction in computational load is because the heaviest computation in the whole process is the computation of the inverse operation in equation (12) of step  220 , and the order of the inverted matrix equals the number of transmitters. 
     The tracking system does not require five measurements to work although there are five unknown variable coordinates. The tracking system makes optimal use not only of the current measurements but also of all past measurements. The smaller the number of the measurements the poorer the tracking. However, since only minimal error estimation is produced, it is possible to get reasonable tracking when the perfect solution is not available. 
     To provide a tracking as precise as possible, increasing the number of measurements is desirable. In practice, a situation may arise when the knowledge about the parameters of one or more transmitters deteriorates, e.g. the pose of a transmitter may change as a result of a mechanical shock, or its intensity may change as a result of electronics imperfection or temperature change. With a multiple-measurements system, the Kalman filter would seek to provide an output that minimizes the errors, and a defective transmitter contributes some error. The larger the number of transmitters the smaller the weight of each in the error minimization, and the more precise the estimate. Thus, increasing the number of transmitters improves the tracking performance. 
     It is a clear advantage of a preferred embodiment of the present invention that any number of transmitters may be easily incorporated into the system. Typically, this increase only requires a software change, preferably implemented at the detector&#39;s DSP  90 . 
     Selecting Vector-state Optimized for Tracking Problem 
     The state vector of equation (3) contains two orientation coordinates, φ and θ. The meaning of each is depicted in FIG. 3. A common choice for these coordinates is polar representation wherein the angle θ denotes the angle between the z-axis and the orientation vector, and the angle φ is the angle between the x-axis and the projection of the orientation vector on the x-y plane. θ ranges from zero to π radians, and φ ranges from zero to 2π radians. 
     This representation, common in the prior art, is a problematic one. FIG. 5 shows an orientation vector gradually approaching the orientation of the z-axis, whose θ coordinate is decreasing with constant (negative) velocity while the φ coordinate is constant. As the orientation vector crosses the θ equals zero point, this coordinate starts increasing again. The speed thus instantly changes its signll resulting in a velocity discontinuity. Furthermore, regarding the φ coordinate, as the orientation vector crosses the θ equals zero point its projection on x-y plane suddenly moves to the opposite quadrant resulting in an instant sign change. Thus, not only the velocity, but the coordinate itself is discontinuous. The conventional (prior art) dynamics of these coordinates are illustrated in FIG.  6 . 
     In the preferred embodiment of the present invention, a different orientation coordinate system is used. This system {φ′, θ′} is best described by its mapping  235  into the conventional polar coordinate system {φ, θ}:              θ   =     {               θ   ′             if                 mod                   (     θ   ,     2      π       )       ≤   π               -     θ   ′               if                 mod                   (     θ   ,     2      π       )       &gt;   π                
        ϕ     =     {           ϕ   ′             if                 θ     =     θ   ′                   ϕ   ′     +   π             if                 θ     =     -     θ   ′                             (   20   )                                
     Using this coordinate system, the removal of the discontinuities associated with the movement described in FIG. 5, may be verified. The orientation vector approaches the θ′=0 point with negative velocity, its θ′ coordinate becomes negative, and the φ′ coordinate, having zero velocity keeps its value. However, when translated into the conventional representation then θ=−θ′, and φ=φ′÷π. 
     The dynamics of this representation are illustrated in FIG.  7 . In this preferred embodiment of the invention, both components of the orientation vector may take any value, negative or positive, and both the coordinates and their velocities are always continuous. 
     Neither the conventional representation, nor the representation of the preferred embodiment of the present invention shown and described hereinabove, removes the ambiguity of the φ coordinate when θ equals zero. This singularity may express itself as a tracking discontinuity if the detector pauses at θ=0, develops a φ value that has no physical consequences, and starts movi ng again. 
     A dynamic offset  240  of the coordinate system solves this problem by rotating the axes of the polar orientation representation when the detector&#39;s orientation approaches the singularity. This transformation is equ ivalent to a rotation of the coordinate system such that the z-axis points at a different direction, e.g. the x and z coordinates may typically be switched. The transformation to the new system in this particular example is: 
      θ=cos −1 [cos(θ′)cos(φ′)] 
     
       
         φ=cos −1 [{square root over (cos 2 (θ)+sin 2 (φ′)cos 2 (θ′))}]  (21) 
       
     
     This transformation may be applied every time the detector&#39;s θ becomes smaller than, e.g., 10 degrees. Of course, keeping track of the size of θ and applying the transformation (18) constitutes a computational burden that may be avoided when transformation (17) is employed, and therefore, is only used when the mathematical ambiguity manifests itself in the implementation. 
     Pose Acquisition Using Time Varying Filter 
     The filter described in equations (7) through (15) assumes a good initial estimate of the state vector is available, and further tracking proceeds through the prediction-correction iteration. If an initial estimate is not available, the filter may diverge. The divergence problem becomes more serious for non-linear applications since the initial state estimate may fall at a local minimum of the error function in phase space. Thus the detector-positioning problem comprises two probably separate problems: acquisition and tracking. 
     The exact pose of the detector  50  is never perfectly known. Thus, one would think that any initial estimate, even a poor one, would serve to initiate the process. However, the consistency of the equations preferably should be preserved lest the filter diverge. 
     The filter performs two interwoven operations: tracking the state vector and solving the Ricatti difference equation, i.e., numerically solving the difference equation for P. The Ricatti equation may be updated using equations (9) and (15), and the solution has only a weak feedback through its dependency on the estimate of the state-vector. Thus, it proceeds at its own pace with little reg,ard to the accuracy of the results. The state vector estimate, on the other hand, makes use of the P matrix, assuming it is correct. If the initial guess is very poor, the Ricatti equation may converge and a small P emerges while the error is still very large. The filter would assume the error is small, and the process very stable, and a large gain may result. Tlie large gain combined with large innovations may cause filter divergence. 
     To allow the filter to start with a poor initial guess, the Ricatti equation convergence is preferably slowed down, either by artificially keeping a large R, or a large Q. Large R results in a long integration time due to its location inside the inverse operation at the gain formula. Large Q keeps the steady-state solution large because Q is always added to the prediction. 
     As the filter proceeds, acquires more measurements, and produces better estimates, the large covariance matrices become an obstacle. Once a precise estimate is available, a small R is preferred, allowing an even tighter estimate and thus fuilly exploiting the measurements. The filter preferably requires a mechanism allowing switching from an acquisition mode, in which convergence is dominant to a tracking mode, in which convergence is ensured, and precision becomes more important. The switch is preferably smooth, as sudden changes in filter parameters may also be catastrophic. 
     These considerations lead to a solution of time-varying parameters  245 . At startup, when the state vector is only inaccurately known, large R and Q along with large initial P are supplied. R and Q, however. comprise a component that is allowed to decay exponentially, leaving only the component that better reflects the real noises of the system. For example, the time dependence of R and Q may take the form:                  R   k   dec     =       R     k   -   1     dec          e         T   k     -     T     k   -   1           τ   decay                  
            R   k     =       R   k   dec     +     R   inf              
            Q   k   dec     =       Q     k   -   1     dec          e         T   k     -     T     k   -   1           τ   decay                  
            Q   k     =       Q   k   dec     +     Q   inf                 (   22   )                                
     P, of course, gradually decays as a result of the Ricatti solution. R and Q may be allowed to decay with a time constant of several hundred milliseconds in order to allow successful and smooth transition front acquisition into tracking when no information about the state vector is initially available. 
     Use of Self-calibration 
     The precision of the tracking based on equations (7)-(15) depends upon precise knowledge of the pose of all the transmitters. The five-coordinate pose of each transmitter is preferably known along with its intensity and radius. The pose is used to compute the dipole magnetic field, the intensity contributes to the proportionality factor C 0 , and the radius is used in order to compute the correction to the dipole term in equation (19). Each of these parameters may be directly measured producing successful calibration. In practice, a precise calibration is tedious and sometimes limited, e.g. measuring the physical dimensions of an electric coil encased within a plastic protection shield is difficult. Moreover, almost every parameter is suibject to some variance due to temperature changes. Thus, it is desirable to provide the system with a gross calibration, and allow it to fine-tune the parameters automatically. 
     In the calibration of the proportionality coefficient C 0 , a direct measure of C 0  is possible. The higher the desired accuracy, the more time consuming is the experiment. Alternatively, a state member C i  for each transmitter may be added, and a new Kalman filter built that optimizes these parameters. The new state vector preferably takes the form: 
     
       
         ξ=[ x,y,z ,φ,θ,{dot over (x)},{dot over (y)},{dot over (z)},{dot over (φ)},{dot over (θ)}, C   1    . . . , C   N ]  (23) 
       
     
     N=number of transmitters 
     When the state vector is augmented, the matrices P 0 , Q and Φ are also preferably augmented:              Q   =     [           Q   coor         0           0         Q   sc           ]             (   24   )                                
     where Q coor  is the matrix defined as Q above, and Q sc  is the self-calibration process-noise covariance-matrix. This matrix may be computed from the maximal allowed rate of change of the coefficients C 0  or may be set to zero if a constant calibration is sought. The state transition matrix would take the form:              Φ   =     [           Φ   coor         0           0         Φ   sc           ]             (   25   )                                
     where Φ coor  is the matrix defined as Φ above, and Φ sc  is the coefficients transition matrix. This latter part typically equals the unity matrix unless a time derivative of the coefficients C 0  is included in the state. 
     The matrices K and H are also preferably augmented. To this end the derivative of h(•) with respect to the new state members is typically required. The derivative may be analytically or numerically computed from equations (16), (17) and (18), depending upon which is more convenient or computittionally faster. The sub-matrix of P 0  depends on the csize of calibration uncertainty. For the example of self-calibrating the coefficients C 0 , the 
     H matrix takes the form: 
     
       
           H   k   =[H   coor   H   sc ] 
       
     
     
       
         
           
             
               
                 
                   
                     H 
                     sc 
                   
                   = 
                   
                     [ 
                     
                       
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             1 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             2 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             3 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             4 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             5 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             6 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             7 
                           
                         
                         
                           0 
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             8 
                           
                         
                         
                           0 
                         
                       
                       
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           0 
                         
                         
                           
                             h 
                             
                               C 
                               , 
                               k 
                             
                             9 
                           
                         
                       
                     
                     ] 
                   
                 
               
               
                 
                   ( 
                   26 
                   ) 
                 
               
             
             
               
                 
                   
                     
                       
                         
                           
                              
                             
                               
                                 h 
                                 
                                   C 
                                   , 
                                   k 
                                 
                                 s 
                               
                               = 
                               
                                  
                                 
                                   
                                     ∂ 
                                     
                                       
                                         h 
                                         s 
                                       
                                        
                                       
                                         ( 
                                         ξ 
                                         ) 
                                       
                                     
                                   
                                   
                                     ∂ 
                                     
                                       C 
                                       0 
                                       s 
                                     
                                   
                                 
                                  
                               
                             
                           
                            
                         
                          
                       
                       
                         
                           ξ 
                           k 
                         
                          
                         
                           ( 
                           - 
                           ) 
                         
                       
                     
                     = 
                     
                       
                         
                           h 
                           s 
                         
                          
                         
                           [ 
                           
                             
                               ξ 
                               k 
                             
                              
                             
                               ( 
                               - 
                               ) 
                             
                           
                           ] 
                         
                       
                       
                         C 
                         0 
                         s 
                       
                     
                   
                   ; 
                   
                       
                   
                    
                   
                     
                       C 
                       0 
                       s 
                     
                     = 
                     
                       coefficient of transmitter  
                       s 
                     
                   
                 
               
               
                 
                     
                 
               
             
           
         
                 
         
             
         
      
     
     Similarly, one may add state members for calibration of other parameters. For example, considering the φ orientation of the sources: 
     
       
         ξ=└ x,y,z ,φ,θ,{dot over (x)},{dot over (y)},{dot over (z)},{dot over (φ)}, {dot over (θ)},{dot over (φ)} 1   s , . . . ,φ N   s ┘  (27) 
       
     
     φ i   s =φ coordinate of transmitter i 
     N=number of transmitters 
     or any combination of calibration parameters. For each combination, the matrices P 0 , Q and Φ, are preferably accordingly built. 
     when self-calibration is used, tbe system&#39;s knowledge of the transmitters&#39; calibration data is preferably updated using the state vector  255 . Preferably, this update takes place after every iteration. However, a slower update rate may be used if only small updates are expected. 
     Using an Adaptive Kalman Filter 
     A deterministic time-decay of filter parameters may be generalized into an adaptive approach. For example, one may cstimate the matrices Q and R from the results of the tracking, leading to an adaptive Q and R. In this example, the matrix Q describes every kinetic component that is not modelcd by the equations of motion, modeling it as a white noise. 
     For example, when the state vector of equation (3) is used, the second time derivative, i.e., acceleration, is presumably included within Q as a process noise. Usually, this matrix is assigned a value based on a worst-case scenario. The highest acceleration expected would be based to estimate Q. This choice is not always optimal as a large Q leads to a large steady state P and a noise-sensitive filter. On the other hand, a small Q may result in overlooking quick pose changes. 
     In the state-vector example of equation (3) an adaptive estimation  250  may take the following form:          Q   k   acc     =              α        (           ξ   k   velocity          (   +   )       -       ξ     k   -   1     velocity          (   +   )             T   k     -     T     k   -   1           )            2     +       (     1   -   α     )          Q     k   -   1     acc                                Q   k   =Q   k   acc   +Q   0   acc   
     
       
         ζ k   velocity (+)=estimate of {{dot over (x)},{dot over (y)},{dot over (z)},{dot over (φ)}, {dot over (θ)}}  (28) 
       
     
     where Q acc  denotes the components of Q that correspond to the highest time derivative appearing in the state vector, i.e., the velocity. The squared term is an estimate of the detector&#39;s acceleration. The constant α is a gain factor−the higher the gain, the shorter the period over which the acceleration-estimate is averaged. The term Q 0   acc  is a constant, time-independent term. 
     Similarly, the matrix R preferably benefits from an adaptive approach  250 . When R is too large the system only slowly responds to a detector&#39;s change of course. When R is too small the filter may diverge. Since this matrix models the effects that are not included in the physical model of the system as a white noise, its adaptation depends on the innovations {ζ k   −h [ζ k (−)]}: 
     
       
           R   k   s,s =β{ζ k   s   −h   s [ζ k (−)]} 2 +(1−β) R   k−1   s,s   
       
     
     
       
           R   k   =R   k   s,s   +R   0   s,s   (29) 
       
     
     where the notations are similar to those of equation (28), and the superscript s denotes the transmitter whose measurement noise covariance is computed. The term R o   acc  is a constant, time-independent term. 
     In the present specification, the superscript “t” or “T” associated with a matrix denotes the matrix&#39;s transpose. 
     The preferred embodiment of the present invention described hereinabove considers only an EKF, i.e., first order approximation to an optimal non-linear filter. Improved filters (e.g. as described in Kushner, 1967), including second order EKF and Gaussian filters (both described in Jazwinski, 1970) and Gaussian sum filters (described in Anderson and Moore, 1979), and other versions of the known approximations can easily be applied in alternative embodiments of the present invention, and their derivation is straightforward. 
     It is appreciated that the software components of the present invention may, if desired, be implemented in ROM (read-oinly memory) form. The software components may, generally, be implemented in hardware, if desired, using conventional techniques. 
     It is appreciated that various features of the invention which, for clarity, are described in the contexts of separate embodime nts may also be provided in combination in a single embodiment. Conversely, various features of the invention which are, for brevity, described in the context of a single embodiment may also be provided separately or in any suitable sub-combination. 
     Persons skilled in the art will appreciate that the present invention is not limited to what has been particularly shown and described herein above. Rather, the scope of the present invention is defined only by the claims that follow.