# Patent

## Title
Determination and application of location and angular orientation of a pill transmitter within a body

## Abstract

A mobile pill transmitter system that moves through or adjacent to one or more organs in an animal's body and that provides signals from which the pill's present location and/or present angular orientation can be determined. The system also provides signals from which the present roll angle of the pill, about a selected axis, can be determined. When the location coordinates and the roll angle of the pill are within selected ranges, an aperture on the pill container releases a selected chemical into or onto the body. Optionally, the pill as it moves also provides a sequence of visually perceptible images; the times for image formation may correspond to times at which the pill transmitter system location or image satisfies one or at least four different criteria.

## Background
ORIGIN OF THE INVENTION
This invention was made by an employee of the U.S. government. The U.S. government has the right to make, use and/or sell the invention described herein without payment of compensation, including but not limited to payment of royalties.


FIELD OF THE INVENTION
This invention relates to determination of location and angular orientation of a signal transmitting mobile device within a human or other animal body.
BACKGROUND OF THE INVENTION
Medical imaging procedures now include, in some circumstances, provision of a sequence of images, in video format, of the interior of an organ through which the imaging mechanism passes. The images provided are often life-like and contain considerable detail. However, as yet no such imaging mechanism has provided, at the same time, location coordinates and/or angular orientation coordinates, associated with this mechanism, indicating where the mechanism is presently located and/or presently oriented, when a particular image is made. This location and/or orientation information would be useful in associating a location and/or orientation with a particular image where a troublesome or pathological organ condition is indicated by the image. This location and/or orientation information would also be useful in determining, on a first pass or on a second pass, a location and/or orientation where a particular medical treatment or pharmaceutical is to be delivered to the organ or a visibly perceptible image is to be made.
What is needed is a method and system for determining location and angular orientation, exact and without iterations or approximations, of a mobile signal transmitting device, moving within a human or other animal body (“user”) at each of a sequence of times. Preferably, the system should consume minimal additional energy and should permit arbitrary separation of consecutive times in the time sequence(s). Preferably, the system should flexible to permit changes in the parameters to be monitored or examined. Preferably, the system should permit accurate determination of one or more times and corresponding locations for delivery of a drug or other chemical substance to the user.
SUMMARY OF THE INVENTION
These needs are met by the invention, which provides and applies an algorithm for exact determination of location coordinates and angular orientation coordinates for a mobile pill transmitter (“PT”) or other similar device that is introduced into and moves within a human or other animal body. A set of as many as eight nonlinear equations is developed and applied, relating propagation of a wireless signal between either of two, three or more or more transmitting antennas located on the PT to four or more non-coplanar receiving antennas located on a signal receiver appliance worn by the user. The equations are solved exactly, without approximations or iterations, and are applied in several environments: (1) association of a visual image, transmitted by the PT at each of a second sequence of times, with a PT location and PT angular orientation at that time; (2) determination of a position within the body at which a drug or chemical substance or other treatment is to be delivered to a selected portion of the body; (3) monitoring, after delivery, of the effect(s) of administration of the treatment; and (4) determination of one or more positions within the body where provision and examination of a finer scale image is warranted.
The invention is applicable wherever a mobile pill transmitter is administered and followed within an organ of a human or other animal body. Provision of location and angular orientation coordinates can be used wherever examination and/or therapeutic treatment and/or post-treatment examination of the user is required.



BRIEF DESCRIPTION OF THE DRAWINGS
FIG. 1 schematically illustrates relationships of a mobile pill transmitter and a signal receiving appliance operated according to embodiments of the invention.
FIGS. 2A/2B are a flow chart of procedures for practicing the invention.



DESCRIPTION OF BEST MODES OF THE INVENTION
With reference to FIG. 1, a mobile pill transmitter {“PT”) 11 is introduced into the body of a human or other animal (“user”), and the PT moves slowly within or adjacent to a body organ, for example, the stomach, small intestine, large intestine or other organ in the GI tract. First and second signal transmitters, 12-i (i=1, 2), are provided at spaced apart locations on the PT 11 with location coordinates (x0±a·Δx0,y0±a·Δy0,z0±a·Δz0), where (x0,y0,z0) are the location coordinates of a specified center of the PT and a (0<a≦1) is a selected real number (e.g., a=0.5 or a=1). Herein, it is assumed that a=1, although any other permitted choice can be used. The pill transmitter 11 is introduced into, and travels through a portion of, the user's body to form and transmit visual images and/or other electronic signals, using a data antenna 13 that may coincide with, or be different from, one of the antennas 12-i (i=1,2).
A signal receiving appliance 14, spaced apart from the P[1], is provided with first, second, third and fourth spaced apart, signal receiving antennas, 15-j (j=1, 2, 3, 4), which are non-coplanar so that the four antenna locations do not lie on a single plane. The first, second, third and fourth antennas have the respective location coordinates (x1,y1,z1), (x2,y2,z2), (x3,y3,z3) and (x4,y4,z4). The appliance 14 has one or more data-receiving antennas 16, which may be different from, or may coincide with, one or more of the four signal receiving antennas 15-j, to receive the data signals from the data antenna(s) 13.
A location signal, transmitted from the transmitter antenna 12-i and received by the receiver antenna 15-j, will require a signal propagation time Δt(i,j) determined by the relation

(xj−x0±Δx0)2+(yj−y0±Δy0)2+(zj−z0±Δz0)2={c′Δt(i,j)}2,  (1-i-j)

where, for example, +Δx0 and −Δx0 correspond to i=1 and i=2, respectively, c′ is a representative velocity of signal propagation within the body, and Δt(i,j) is signal propagation time (measured or estimated) from transmitter no. i to receiver no. j. Squaring Eqs. (1-1-j) and (1-2-j) and forming the difference yields a new sequence of relations:

4(xj−x0)Δx0+4(yj−y0)Δy0+4(zj−z0)Δz0=c′2{Δt(1,j)2−Δt(2,j)2}  (2-j)

Subtracting Eq. (2-1) from Eq. (2-2), Eq. (2-1) from Eq. (2-3) and Eq (2-1) from Eq. (2-4) provides three independent relations, which are expressed in matrix form:





  
    
      
        
          M
          ⁢
          
            
            
              
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
              
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
              
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
            
            
          
        
        =
        
          
            (
            
              
                c
                
                  ,
                  2
                
              
              /
              4
            
            )
          
          ⁢
          
            
            
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
            
            
          
        
      
    
    
      
        (
        3
        )
      
    
  
  
    
      
        
          
          
            
              
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
            
            
              
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
            
            
              
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
            
          
          
        
        =
        
          
            (
            
              
                c
                
                  ,
                  2
                
              
              /
              4
            
            )
          
          ⁢
          
            M
            
              -
              1
            
          
          ⁢
          
            
            
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
            
            
          
        
      
    
    
      
        (
        4
        )
      
    
  
  
    
      
        M
        =
        
          
            
            
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      2
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      2
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      2
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
              
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
              
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      4
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      4
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      4
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
              
            
            
          
          .
        
      
    
    
      
        (
        5
        )
      
    
  




The precision matrix M has a non-zero determinant, because the four locations with coordinates are non-coplanar. Thus, Eq. (3) has a unique solution vector {Δx0 Δy0, Δz0}tr. The square of the separation distance d between the two transmitting antenna locations is

4{Δx02+Δy02+Δz02}=d2,  (6)

where d is a known, controllable physical distance. Equation (6) serves as a consistency relation to evaluate the accuracy of Eq. (4).

One can also add Eq. (1-1-i) to Eq. (1-2-j) and use Eq. (6) to obtain




  
    
      
        
          
            
              (
              
                xj
                -
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            2
          
          +
          
            
              (
              
                yj
                -
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            2
          
          +
          
            
              (
              
                zj
                -
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            2
          
          +
          
            
          
          ⁢
          
            
              d
              2
            
            ⁢
            
              /
            
            ⁢
            4
          
        
        ,
        
          

        
        ⁢
        
          =
          
            
              c
              
                ,
                2
              
            
            ⁢
            
              {
              
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  
                    
                      t
                      ⁡
                      
                        (
                        
                          1
                          ,
                          j
                        
                        )
                      
                    
                    2
                  
                
                +
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  
                    
                      t
                      ⁡
                      
                        (
                        
                          2
                          ,
                          j
                        
                        )
                      
                    
                    2
                  
                
              
              }
            
            ⁢
            
              /
            
            ⁢
            2
            ⁢
            
              (
              
                
                  j
                  =
                  1
                
                ,
                2
                ,
                3
                ,
                4
              
              )
            
          
        
      
    
    
      
        (
        
          7
          ⁢
          
            -
          
          ⁢
          j
        
        )
      
    
  




and observe that

xj−x0=(xj−x1)+(x1−x0)(j=1, 2, 3, 4).  (8-j)

Using Eqs. (8-j), Eqs. (7-j) (j=2, 3, 4) can be re-expressed as





  
    
      
        
          
            
              (
              
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
                -
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            2
          
          +
          
            2
            ⁢
            
              (
              
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
                -
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            ⁢
            
              (
              
                xj
                -
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
              
              )
            
          
          +
          
            
              (
              
                xj
                -
                
                  x
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
              
              )
            
            2
          
          +
          
            
              (
              
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
                -
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            2
          
          +
          
            2
            ⁢
            
              (
              
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
                -
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            ⁢
            
              (
              
                yj
                ⁢
                
                  
                
                -
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
              
              )
            
          
          +
          
            
              (
              
                yj
                -
                
                  y
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
              
              )
            
            2
          
          +
          
            
              (
              
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
                -
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            2
          
          +
          
            2
            ⁢
            
              (
              
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
                -
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            ⁢
            
              (
              
                zj
                -
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
              
              )
            
          
          +
          
            
              (
              
                zj
                -
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  1
                
              
              )
            
            2
          
          +
          
            
              d
              2
            
            ⁢
            
              /
            
            ⁢
            4
          
        
        =
        
          
            c
            
              ,
              2
            
          
          ⁢
          
            {
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  
                    t
                    ⁡
                    
                      (
                      
                        1
                        ,
                        j
                      
                      )
                    
                  
                  2
                
              
              +
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  
                    t
                    ⁡
                    
                      (
                      
                        2
                        ,
                        j
                      
                      )
                    
                  
                  2
                
              
            
            }
          
          ⁢
          
            /
          
          ⁢
          2.
        
      
    
    
      
        (
        
          9
          ⁢
          
            -
          
          ⁢
          j
        
        )
      
    
  




Subtracting Eq. (9-1) from Eq. (9-j), for each of j=2, 3, 4, yields three linear relations in the remaining unknowns (j=2, 3, 4):





  
    
      
        
          
            
              
                (
                
                  
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                  -
                  
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                )
              
              ⁢
              
                (
                
                  xj
                  -
                  
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                
                )
              
            
            +
            
              
                (
                
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                  -
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                )
              
              ⁢
              
                (
                
                  yj
                  -
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                
                )
              
            
            +
            
              
                (
                
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                  -
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                )
              
              ⁢
              
                (
                
                  zj
                  -
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                
                )
              
            
          
          =
          
            
              
                c
                
                  ,
                  2
                
              
              ⁢
              
                {
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    
                      
                        t
                        ⁡
                        
                          (
                          
                            1
                            ,
                            2
                          
                          )
                        
                      
                      2
                    
                  
                  +
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    
                      
                        t
                        ⁡
                        
                          (
                          
                            2
                            ,
                            2
                          
                          )
                        
                      
                      2
                    
                  
                
                }
              
            
            -
            
              Δ
              ⁢
              
                
              
              ⁢
              
                
                  t
                  ⁡
                  
                    (
                    
                      1
                      ,
                      1
                    
                    )
                  
                
                2
              
            
            -
            
              Δ
              ⁢
              
                
              
              ⁢
              
                
                  t
                  ⁡
                  
                    (
                    
                      2
                      ,
                      1
                    
                    )
                  
                
                2
              
            
          
        
        }
      
    
    
      
        (
        
          10
          ⁢
          
            -
          
          ⁢
          j
        
        )
      
    
  
  
    
      
        
          M
          ⁢
          
            
            
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                
              
              
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                
              
              
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                
              
            
            
          
        
        =
        
          
            c
            
              ,
              2
            
          
          ⁢
          
            
            
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
            
            
          
        
      
    
    
      
        (
        11
        )
      
    
  
  
    
      
        
          
          
            
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                  ⁢
                  
                    
                  
                
              
            
            
              
                
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                  -
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
            
            
              
                
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    1
                  
                  -
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
            
          
          
        
        =
        
          
            c
            
              ,
              2
            
          
          ⁢
          
            M
            
              -
              1
            
          
          ⁢
          
            
            
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                2
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                2
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                3
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                3
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
              
                
                  
                    {
                    
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                4
                              
                              )
                            
                          
                          2
                        
                      
                      -
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                1
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                      +
                      
                        Δ
                        ⁢
                        
                          
                        
                        ⁢
                        
                          
                            t
                            ⁡
                            
                              (
                              
                                4
                                ,
                                1
                              
                              )
                            
                          
                          2
                        
                      
                    
                    }
                  
                
              
            
            
          
        
      
    
    
      
        (
        12
        )
      
    
  




The location coordinates (x0,y0,z0) of the center are then obtained by subtracting the known values of the antenna coordinates (x1,y1,z1) in Eqs. (12).

Note that inversion of the precision matrix M is involved in each of the solution component triples {Δx0 Δy0, Δz0}tr and {x0,y0,z0}tr. The quantity S={det(M)}−1 is a measure of the sensitivity of these solutions to small errors in measurement and/or timing, which may arise from signal-to-noise problems, from signal propagation problems, from location measurement errors and/or from timing errors. The sensitivity varies approximately monotonically with S, with S=0 being most desirable, so that, as the four receiver antenna locations approach a common plane (coplanar configuration), the sensitivity approaches an infinite value. For this reason, it is preferable to choose the location coordinates, (x1,y1,z1), (x2,y2,z2), (x3,y3,z3) and (x4,y4,z4), for the four receiver antennas to maximize the value det(M)=1/S, consistent with the constraints imposed on the coordinates.
The solutions of Eqs. (3) and (11) provide a determination of the location coordinates (x0,y0,z0) for the center of the PT device 11 and of the angular orientation (Δx0,Δy0,Δz0) of this device relative to axes of a Cartesian coordinate system, which may include pitch and yaw angles of the device.
Another quantity, roll angle θ of the device about its longitudinal axis AA, illustrated in FIG. 1, may be needed in some applications. To determine θ, it is convenient to provide a third signal transmitting antenna 12-3 on the PT, at a location that is not collinear with the locations of the other two signal transmitting antennas, 12-1 and 12-2.
If, as is likely, the PT is cylindrical and the roll angle θ is to be estimated, it is preferable to locate the two transmitting antennas, 12-1 and 12-2, at antipodal locations on the cylinder, as illustrated in FIG. 1. With this configuration, the line L(1,2) connecting the two transmitting antennas, 12-1 and 12-2, is now oriented at an angle

Φ=tan−1{r0/{Δx02+Δy02+Δz02}1/2},  (13)

relative to the axis AA, Where r0 is the radius of the cylinder. The third transmitting antenna 12-3 is assumed to be located at a known, selected rotational angle θ=θ3 (e.g., 15°≦θ3≦90°) relative to a longitudinal plane Π (defined by roll angle θ=0) that contains the transmitting antennas 12-1 and 12-2.
Where the cylinder or PT 11 has rolled or rotated by an angle θ relative to its reference position (θ=0), the distance Δr(i,j) from the first and second transmitting antennas 12-i (i=1, 2) to the receiving antenna 15-j is related to the elapsed time Δt(i,j) for the signal propagation by




  
    
      
        
          
            Δ
            ⁢
            
              
            
            ⁢
            
              
                r
                ⁡
                
                  (
                  
                    i
                    ,
                    j
                  
                  )
                
              
              2
            
          
          =
          
            
              
                {
                
                  xj
                  -
                  
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                  -
                  
                    r
                    ⁢
                    
                      
                    
                    ⁢
                    
                      0
                      ·
                      
                        cos
                        ⁡
                        
                          (
                          
                            θ
                            -
                            
                              θ
                              ⁢
                              
                                
                              
                              ⁢
                              3
                            
                          
                          )
                        
                      
                    
                  
                
                }
              
              2
            
            +
            
              
                {
                
                  yj
                  -
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                  -
                  
                    r
                    ⁢
                    
                      
                    
                    ⁢
                    
                      0
                      ·
                      
                        sin
                        ⁡
                        
                          (
                          
                            θ
                            -
                            
                              θ
                              ⁢
                              
                                
                              
                              ⁢
                              3
                            
                          
                          )
                        
                      
                    
                  
                
                }
              
              2
            
            +
            
              
                {
                
                  
                    zj
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                    +
                  
                  ⩓
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                )
              
              2
            
          
        
        ,
        
          =
          
            
              c
              
                ,
                2
              
            
            ⁢
            Δ
            ⁢
            
              
            
            ⁢
            
              
                t
                ⁡
                
                  (
                  
                    i
                    ,
                    j
                  
                  )
                
              
              2
            
          
        
        ,
      
    
    
      
        (
        
          13
          ⁢
          
            -
          
          ⁢
          i
          ⁢
          
            -
          
          ⁢
          j
        
        )
      
    
  




and the distance from the third transmitting antenna 12-3 to the receiving antenna 15-j is related to the elapsed time Δt(3,j) for the signal propagation by





  
    
      
        
          
            Δ
            ⁢
            
              
            
            ⁢
            
              r
              ⁡
              
                (
                
                  3
                  ,
                  j
                
                )
              
            
            ⁢
            2
          
          =
          
            
              
                {
                
                  xj
                  -
                  
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                  -
                  
                    r
                    ⁢
                    
                      
                    
                    ⁢
                    
                      0
                      ·
                      
                        cos
                        ⁡
                        
                          (
                          θ
                          )
                        
                      
                    
                  
                
                }
              
              2
            
            +
            
              
                {
                
                  yj
                  -
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                  -
                  
                    r
                    ⁢
                    
                      
                    
                    ⁢
                    
                      0
                      ·
                      
                        sin
                        ⁡
                        
                          (
                          θ
                          )
                        
                      
                    
                  
                
                }
              
              2
            
            +
            
              
                {
                
                  zj
                  -
                  
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                }
              
              2
            
          
        
        ,
        
          =
          
            
              c
              
                ,
                2
              
            
            ⁢
            Δ
            ⁢
            
              
            
            ⁢
            
              
                t
                ⁡
                
                  (
                  
                    3
                    ,
                    j
                  
                  )
                
              
              2
            
          
        
        ,
      
    
    
      
        (
        
          13
          ⁢
          
            -
          
          ⁢
          3
          ⁢
          
            -
          
          ⁢
          j
        
        )
      
    
  




where the terms +Δz0 and −Δz0 in Eq. (13-j) correspond to i=1 and i=2, respectively.

The difference in distance squared Δr2 between Eq. (13-i-j) and (13-3-j) becomes

Δr(i,3,j)2−Δr(3,j)2=±2(zi−z0)Δz0+Δz02−2r0(xi−x0){cos(θ−θ3)−cos θ}−2r0(yi−y0){sin(θ−θ3)−sin θ}=c′2{Δt(i,j)2−Δt(3,j)2}.  (14)

Using multiple angle trigonometric identities, one verifies the relations





  
    
      
        
          
            
              cos
              ⁡
              
                (
                
                  θ
                  -
                  
                    θ
                    ⁢
                    
                      
                    
                    ⁢
                    3
                  
                
                )
              
            
            -
            
              cos
              ⁢
              
                
              
              ⁢
              θ
            
          
          =
          
            
              
                cos
                ⁢
                
                  
                
                ⁢
                θ
                ⁢
                
                  {
                  
                    
                      cos
                      ⁢
                      
                        
                      
                      ⁢
                      θ
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    1
                  
                  }
                
              
              +
              
                sin
                ⁢
                
                  
                
                ⁢
                
                  θ
                  ·
                  sin
                
                ⁢
                
                  
                
                ⁢
                θ
                ⁢
                
                  
                
                ⁢
                3
              
            
            =
            
              
                
                  {
                  
                    2
                    ⁢
                    
                      (
                      
                        1
                        -
                        
                          cos
                          ⁢
                          
                            
                          
                          ⁢
                          θ
                          ⁢
                          
                            
                          
                          ⁢
                          3
                        
                      
                      )
                    
                  
                  }
                
                
                  1
                  /
                  2
                
              
              ⁢
              cos
              ⁢
              
                {
                
                  θ
                  -
                  
                    ψ
                    ⁢
                    
                      
                    
                    ⁢
                    3
                  
                
                )
              
            
          
        
        ,
      
    
    
      
        (
        15
        )
      
    
  
  
    
      
        
          
            
              sin
              ⁡
              
                (
                
                  θ
                  -
                  
                    θ
                    ⁢
                    
                      
                    
                    ⁢
                    3
                  
                
                )
              
            
            -
            
              sin
              ⁢
              
                
              
              ⁢
              θ
            
          
          =
          
            
              
                sin
                ⁢
                
                  
                
                ⁢
                θ
                ⁢
                
                  {
                  
                    
                      cos
                      ⁢
                      
                        
                      
                      ⁢
                      θ
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    1
                  
                  }
                
              
              +
              
                cos
                ⁢
                
                  
                
                ⁢
                
                  θ
                  ·
                  sin
                
                ⁢
                
                  
                
                ⁢
                θ
                ⁢
                
                  
                
                ⁢
                3
              
            
            =
            
              
                
                  {
                  
                    2
                    ⁢
                    
                      (
                      
                        1
                        -
                        
                          cos
                          ⁢
                          
                            
                          
                          ⁢
                          θ
                          ⁢
                          
                            
                          
                          ⁢
                          3
                        
                      
                      )
                    
                  
                  }
                
                
                  1
                  /
                  2
                
              
              ⁢
              sin
              ⁢
              
                {
                
                  θ
                  -
                  
                    ψ
                    ⁢
                    
                      
                    
                    ⁢
                    3
                  
                
                )
              
            
          
        
        ,
      
    
    
      
        (
        16
        )
      
    
  
  
    
      
        
          ψ
          ⁢
          
            
          
          ⁢
          3
        
        =
        
          
            
              tan
              
                -
                1
              
            
            ⁢
            
              {
              
                sin
                ⁢
                
                  
                
                ⁢
                θ
                ⁢
                
                  
                
                ⁢
                
                  3
                  /
                  
                    (
                    
                      
                        cos
                        ⁢
                        
                          
                        
                        ⁢
                        θ
                        ⁢
                        
                          
                        
                        ⁢
                        3
                      
                      -
                      1
                    
                    )
                  
                
              
              }
            
          
          =
          
            
              (
              
                
                  θ
                  ⁢
                  
                    
                  
                  ⁢
                  3
                
                -
                π
              
              )
            
            ⁢
            
              /
            
            ⁢
            2
          
        
      
    
    
      
        (
        17
        )
      
    
  




Equation (14) can be rewritten as





  
    
      
        
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                
                  r
                  ⁡
                  
                    (
                    
                      i
                      ,
                      j
                    
                    )
                  
                
                2
              
            
            -
            
              Δ
              ⁢
              
                
              
              ⁢
              
                
                  r
                  ⁡
                  
                    (
                    
                      3
                      ,
                      j
                    
                    )
                  
                
                2
              
            
          
          =
          
            
              
                
                  ±
                  2
                
                ⁢
                
                  (
                  
                    zi
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                  )
                
                ⁢
                Δ
                ⁢
                
                  
                
                ⁢
                z
              
              +
              
                Δ
                ⁢
                
                  
                
                ⁢
                
                  z
                  2
                
              
              -
              
                2
                ⁢
                r
                ⁢
                
                  
                
                ⁢
                0
                ⁢
                
                  
                    {
                    
                      
                        
                          (
                          
                            xi
                            -
                            
                              x
                              ⁢
                              
                                
                              
                              ⁢
                              0
                            
                          
                          )
                        
                        2
                      
                      +
                      
                        
                          (
                          
                            yi
                            -
                            
                              y
                              ⁢
                              
                                
                              
                              ⁢
                              0
                            
                          
                          )
                        
                        2
                      
                    
                    }
                  
                  
                    1
                    /
                    2
                  
                
                ⁢
                
                  
                    {
                    
                      2
                      ⁢
                      
                        (
                        
                          1
                          -
                          
                            cos
                            ⁢
                            
                              
                            
                            ⁢
                            θ
                            ⁢
                            
                              
                            
                            ⁢
                            3
                          
                        
                        )
                      
                    
                    }
                  
                  
                    1
                    /
                    2
                  
                
                ⁢
                cos
                ⁢
                
                  
                
                ⁢
                
                  {
                  
                    θ
                    -
                    
                      ψ
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    ψ
                  
                  )
                
              
            
            =
            
              
                c
                
                  ,
                  2
                
              
              ⁢
              
                {
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    
                      
                        t
                        ⁡
                        
                          (
                          
                            i
                            ,
                            j
                          
                          )
                        
                      
                      2
                    
                  
                  -
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    
                      
                        t
                        ⁡
                        
                          (
                          
                            3
                            ,
                            j
                          
                          )
                        
                      
                      2
                    
                  
                
                }
              
            
          
        
        ,
      
    
    
      
        (
        18
        )
      
    
  
  
    
      
        ψ
        =
        
          
            tan
            
              -
              1
            
          
          ⁢
          
            
              {
              
                
                  (
                  
                    yi
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                  )
                
                ⁢
                
                  /
                
                ⁢
                
                  (
                  
                    xi
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                  )
                
              
              }
            
            .
          
        
      
    
    
      
        (
        19
        )
      
    
  




All quantities in Eq. (18) are known except the roll angle θ, which will vary as the PT 11 moves along a path in or adjacent to an organ in the body. The quantity θ−ψ3−ψ in Eq. (18) can be estimated to within a multiplicative factor (±1) by measurement of the propagation time difference Δr(i,j)2−Δr(3,j)2 

A dispensing aperture for a chemical (pharmaceutical or other substance), can be initially located at the initial rotational angle θ=0, can be allowed to move rotationally with the roll angle θ, and can be caused to dispense the chemical when the aperture is located adjacent to, and is directed at, a target section of an organ that is to be treated, at a target roll angle value. Given a knowledge of the roll angle θ and of the location (x0,y0,z0) of the center of the PT 11, the chemical dispensation point is easily estimated.
Optionally, the PT 11 also forms and transmits signals representing visually perceptible images at a sequence of times as the pill moves through the body, using the signal receiving antenna 16. In a first option, the antenna 16 is part of a signal transceiver that (1A) determines when location coordinates of the pill lie within selected ranges, such as

(xf1≦x0(t)≦xf2,yf1≦y0(t)≦yf2,zf1≦z0(t)≦zf2),  (20)

and (1B) when the pill location coordinates lie within these ranges, a signal is transmitted at the transceiver that causes the pill transmitter system to form and transmit a visually perceptible image. In a second option, the PT forms and transmits an image at two consecutive image transmission times, t1 and t2, when

{(x0(t2)−x0(t1))2+(y0(t2)−y0(t1))2+(z0(t2)−z0(t1))2}1/2≧Δr(thr),  (21)

where Δr is a selected threshold distance. In a third option, the PT forms and transmits an image at each of a selected sequence of times {tn}n, where

|tn+1−tn|≧Δt(thr),  (22)

and Δt(thr) is a selected separation time. In a fourth option, a numerical measure of image difference ID(t1;t2) is provided between an image formed at each of two times, t1 and t2 (>t1), and the image I(t2) is transmitted when

|ID(t1;t2)|≧ΔI(thr),  (23)

where ΔI(thr) is a selected image difference threshold. Each of these image transmission options is made possible by availability of the location coordinates (x0(t),y0(t),z0(t)), or a related quantity.

FIG. 2 is a flow chart covering procedures for practicing the invention. In step 21, the system receives, at the receiving antennas 15-j (j=1, 2, 3, 4 in FIG. 1), signals transmitted by the transmitting antennas 12-i (i=1, 2) and measures the signal propagation times Δt(i,j) from transmitter no. i to receiver no. j. Each transmitter may transmit a signal having a different frequency, indicium or other signal signature, or the two sets of signals (i=1, 2) may be transmitted in different, non-overlapping times intervals, with temporal separations Δt(sep)=0.001−5 sec, or more if desired. In steps 22 and 23, the system respectively computes or otherwise provides the quantities (c′2/4) {Δt(1,j)2−Δt(2,j)2−Δt(1,1)2+Δt(2,1)2} (j=2, 3, 4) and the entries of the matrix M−1, where M is the precision matrix, set forth in Eq. (5). In step 24, the system computes the angular orientation coordinates (Δx0,Δy0,Δz0) as set forth in Eq. (4), where c′ is a measured or estimated velocity of signal propagation within and adjacent to the body.
In step 25, the PT system computes or otherwise provides the quantities c′2{Δt(1,2)2+Δt(2,2)2−Δt(1,1)2−Δt(2,1)2}. In step 26, the PT system computes the center location coordinates (x0,y0,z0) of the PT relative to a location (x1,y1,z1) of one of the receiving antennas, as set forth in Eq. (12). From these values, one can determine the center location and angular orientation of the PT, relative to a Cartesian or other coordinate system and relative to the location (x1,y1,z1) of one of the receiving antennas. In step 27 (optional), the system computes the square of the transmitting antenna separation distance, 4{Δx02+Δy02+Δz02}, and compares this with the square of the known separation distance d2, to evaluate the accuracy of the determinations in one or more of the steps 21-25.
In step 28 (optional), c′2{Δt(i,j)2−Δt(3,j)2}−{Δz02±2(zi−z0)Δz0}, 2r0{(xi−x0)2+(yi−y0)2}1/2{2(1−cos θ3)}1/2, ψ3 and ψ are computed or otherwise provided for at least one of i=1 or 2. In step 29 (optional), the relation




  
    
      
        
          
            2
            ⁢
            
              
            
            ⁢
            r
            ⁢
            
              
            
            ⁢
            0
            ⁢
            
              
                {
                
                  
                    
                      (
                      
                        xi
                        -
                        
                          x
                          ⁢
                          
                            
                          
                          ⁢
                          0
                        
                      
                      )
                    
                    2
                  
                  +
                  
                    
                      (
                      
                        yi
                        -
                        
                          y
                          ⁢
                          
                            
                          
                          ⁢
                          0
                        
                      
                      )
                    
                    2
                  
                
                }
              
              
                1
                /
                2
              
            
            ⁢
            
              
                {
                
                  2
                  ⁢
                  
                    (
                    
                      1
                      -
                      
                        cos
                        ⁢
                        
                          
                        
                        ⁢
                        θ
                        ⁢
                        
                          
                        
                        ⁢
                        3
                      
                    
                    )
                  
                
                }
              
              
                1
                /
                2
              
            
            ⁢
            cos
            ⁢
            
              {
              
                θ
                -
                
                  ψ
                  ⁢
                  
                    
                  
                  ⁢
                  3
                
                -
                ψ
              
              )
            
          
          }
        
        =
        
          
            
              -
              
                c
                
                  ,
                  2
                
              
            
            ⁢
            
              {
              
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  
                    
                      t
                      ⁡
                      
                        (
                        
                          i
                          ,
                          j
                        
                        )
                      
                    
                    2
                  
                
                -
                
                  Δ
                  ⁢
                  
                    
                  
                  ⁢
                  
                    
                      t
                      ⁡
                      
                        (
                        
                          3
                          ,
                          j
                        
                        )
                      
                    
                    2
                  
                
              
              }
            
          
          +
          
            {
            
              
                Δ
                ⁢
                
                  
                
                ⁢
                z
                ⁢
                
                  
                
                ⁢
                
                  0
                  2
                
              
              ±
              
                2
                ⁢
                
                  (
                  
                    zi
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                  )
                
                ⁢
                Δz
                ⁢
                
                  
                
                ⁢
                0
              
            
            }
          
        
      
    
    
      
        (
        18
        )
      
    
  




from Eq. (18) is used to estimate the quantities cos {θ−ψ3−ψ) and the roll angle θ, where θ3, ψ3 and ψ are quantities discussed in the preceding. In step 30 (optional), the system determines if the center location coordinates (x0,y0,z0) lie within selected ranges (xr1≦x0≦xr2,yr1≦y0≦yr2,zr1≦z0≦zrs) and/or the roll angle θ lies in a selected range (θr1≦θ≦θr2) so that a selected chemical can be released through the aperture into or onto the body. If the answer to the query in step 30 is “yes,” the PT system releases the selected chemical, in step 31 (optional). If the answer to the query in step 30 is “no,”, the system moves to the next step, if any.

In step 32 (optional), the PT system determines if one (or more than one) of the selected criteria set forth in Eqs. (20), (21), (22) and (23) is satisfied. If the answer to the query in step 32 is “yes,” the PT system forms and transmits a visually perceptible image, in step 32 (optional). If the answer to the query in step 32 is “no,” the system takes no further action at that time, in step 34 (optional).
The invention thus provides: (1) location coordinates and/or angular orientation coordinates for the PT, as a function of time; (2) an estimation of roll angle for the PT, as a function of time; (3) an estimation of one or more times a selected chemical is appropriately delivered to an organ; and (4) determination of a sequence of times for formation and transmission of a signal representing an image sensed by the PT.

## Claims

1. A method for determination of at least one location coordinate and at least one angular orientation coordinate of a mobile device that moves within or adjacent to at least one organ in a human or other animal body, the method comprising:
(1) providing first and second spaced apart signal transmitting antennas, having index values i=1 and i=2, respectively, on the device, spaced apart along a selected axis of the device, and transmitting a first sequence and a second sequence of distinguishable signals at the first and second transmitting antennas, respectively, where the first and second transmitting antennas have location coordinates (x0+Δx0,y0+Δy0,z0+Δz0) and (x0−Δx0,y0−Δy0,z0−Δz0), respectively, a central location of the mobile device has location coordinates (x0,y0,z0), and the coordinate values x0, y0, z0, Δx0, Δy0, Δz0 are to be determined, and (x,y,z) are location coordinates in a selected Cartesian coordinate system;
(2) receiving the first and second sequences of transmitted signals at least first, second, third and fourth spaced apart, non-coplanar signal receiving antennas, having index values j=1, 2, 3, 4, respectively, having substantially fixed and known location coordinates (xj,yj,zj), and being located adjacent to the body;
(3) for each transmitted signal in each of the first and second sequences, providing an elapsed time of signal propagation Δt(i,j) between the first transmitting antenna (i=1) or second transmitting antenna (i=2) and the first, second, third or fourth signal receiving antenna (j=1, 2, 3, 4, respectively), where Δt(i,j) is expressed by a relation


c′2Δt(i=1,j)2=(xj−x0+Δx0)2+(yj−y0+Δy0)2+(zj−z0+Δz0)2,



c′2Δt(i=2,j)2=(xj−x0−Δx0)2+(yj−y0−Δy0)2+(zj−z0−Δz0)2,



where c′ is a representative value of propagation of a transmitted electromagnetic signal within the body;
(4) estimating the values Δx0, Δy0, Δz0, x0, y0 and z0 by the relations





  
    
      
        
          
            [
            
              
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
              
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
              
                
                  
                    Δ
                    ⁢
                    
                      
                    
                    ⁢
                    z
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
              
            
            ]
          
          =
          
            
              (
              
                
                  c
                  
                    ,
                    2
                  
                
                /
                4
              
              )
            
            ⁢
            
              
                M
                
                  -
                  1
                
              
              ⁡
              
                [
                
                  
                    
                      
                        {
                        
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    2
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    2
                                  
                                  )
                                
                              
                              2
                            
                          
                          +
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    2
                                    ,
                                    2
                                  
                                  )
                                
                              
                              2
                            
                          
                        
                        }
                      
                    
                  
                  
                    
                      
                        {
                        
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    3
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    3
                                  
                                  )
                                
                              
                              2
                            
                          
                          +
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    3
                                    ,
                                    3
                                  
                                  )
                                
                              
                              2
                            
                          
                        
                        }
                      
                    
                  
                  
                    
                      
                        {
                        
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    4
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    4
                                  
                                  )
                                
                              
                              2
                            
                          
                          +
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    4
                                    ,
                                    4
                                  
                                  )
                                
                              
                              2
                            
                          
                        
                        }
                      
                    
                  
                
                ]
              
            
          
        
        ,
      
    
  
  
    
      
        
          
            [
            
              
                
                  
                    
                      
                        x
                        ⁢
                        
                          
                        
                        ⁢
                        1
                      
                      -
                      
                        x
                        ⁢
                        
                          
                        
                        ⁢
                        0
                      
                    
                    ⁢
                    
                      
                    
                  
                
              
              
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                
              
              
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      0
                    
                  
                
              
            
            ]
          
          =
          
            
              (
              
                
                  c
                  
                    ,
                    2
                  
                
                /
                4
              
              )
            
            ⁢
            
              
                M
                
                  -
                  1
                
              
              ⁡
              
                [
                
                  
                    
                      
                        {
                        
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    2
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    2
                                    ,
                                    2
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          +
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    2
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                        
                        }
                      
                    
                  
                  
                    
                      
                        {
                        
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    3
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    3
                                    ,
                                    3
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          +
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    3
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                        
                        }
                      
                    
                  
                  
                    
                      
                        {
                        
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    4
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    4
                                    ,
                                    4
                                  
                                  )
                                
                              
                              2
                            
                          
                          -
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    1
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                          +
                          
                            Δ
                            ⁢
                            
                              
                            
                            ⁢
                            
                              
                                t
                                ⁡
                                
                                  (
                                  
                                    4
                                    ,
                                    1
                                  
                                  )
                                
                              
                              2
                            
                          
                        
                        }
                      
                    
                  
                
                ]
              
            
          
        
        ,
      
    
  
  
    
      
        
          M
          =
          
            [
            
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      2
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      2
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      2
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
              
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      3
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
              
              
                
                  
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      4
                    
                    -
                    
                      x
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      4
                    
                    -
                    
                      y
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
                
                  
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      4
                    
                    -
                    
                      z
                      ⁢
                      
                        
                      
                      ⁢
                      1
                    
                  
                
              
            
            ]
          
        
        ;
      
    
  



(5) interpreting the quantities (x1−x0, y1−y0, z1−z0) as location coordinates of the mobile device central location relative to location coordinates (x1,y1,z1) of the first receiving antenna; and
(6) when D={(Δx0)2+(Δy0)2+(Δz0)2}1/2, is non-zero, interpreting the quantities (Δx0/D, Δy0/D, Δz0/D), where as direction cosines with respect to x-, y- and z-Cartesian coordinate axes, corresponding to angular orientation of a line segment along the selected axis.

2. The method of claim 1, further comprising evaluating accuracy of said angular orientation components by comparing a sum of squares of said angular orientation components, 4{Δx02+Δy02+Δz02}, with a square d2 of a known distance between two selected locations on said mobile device.

3. The method of claim 1, further comprising estimating a roll angle θ of said mobile device about a selected axis by a process comprising:
selecting a location on said mobile device corresponding to a roll angle value, θ=θ3, about a selected axis for said mobile device;
providing a third signal transmitting antenna, numbered i=3, on said mobile device at a location selected with reference to the roll angle value θ=θ3;
providing a square Δt(3,j)2 of elapsed time of signal propagation between the third signal transmitting antenna and at least one of said signal receiving antenna, numbered j,
providing a first selected angle value ψ=(θ3−π)/2 and a second selected angle value ψ;
providing a value Δz0 for said angular orientation component and values, xi−x0, yi−y0 and zi−z0, relating said location coordinate (x0,y0,z0) to corresponding location coordinate (xi,yi,zi) (I=1 or 2) of said signal receiving antenna; and
estimating a roll angle θ of said mobile device at least one time from a relation





  
    
      2
      ⁢
      
        
      
      ⁢
      r
      ⁢
      
        
      
      ⁢
      0
      ⁢
      
        
          {
          
            
              
                (
                
                  xi
                  -
                  
                    x
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                )
              
              2
            
            +
            
              
                (
                
                  yi
                  -
                  
                    y
                    ⁢
                    
                      
                    
                    ⁢
                    0
                  
                
                )
              
              2
            
          
          }
        
        
          1
          /
          2
        
      
      ⁢
      
        
          {
          
            2
            ⁢
            
              (
              
                1
                -
                
                  cos
                  ⁢
                  
                    
                  
                  ⁢
                  θ
                  ⁢
                  
                    
                  
                  ⁢
                  3
                
              
              )
            
          
          }
        
        
          1
          /
          2
        
      
      ⁢
      cos
      ⁢
      
        {
        
          
            θ
            ⁢
            
              
            
            ⁢
            3
          
          -
          
            ψ
            ⁢
            
              
            
            ⁢
            3
          
          -
          ψ
        
        )
      
    
    =
    
      
        
          -
          
            c
            
              ,
              2
            
          
        
        ⁢
        
          {
          
            
              Δ
              ⁢
              
                
              
              ⁢
              
                
                  t
                  ⁡
                  
                    (
                    
                      i
                      ,
                      j
                    
                    )
                  
                
                2
              
            
            -
            
              Δ
              ⁢
              
                
              
              ⁢
              
                
                  t
                  ⁡
                  
                    (
                    
                      3
                      ,
                      j
                    
                    )
                  
                
                2
              
            
          
          }
        
      
      +
      
        {
        
          
            Δ
            ⁢
            
              
            
            ⁢
            z
            ⁢
            
              
            
            ⁢
            
              0
              2
            
          
          ±
          
            2
            ⁢
            
              (
              
                zi
                -
                
                  z
                  ⁢
                  
                    
                  
                  ⁢
                  0
                
              
              )
            
            ⁢
            Δz
            ⁢
            
              
            
            ⁢
            0
          
        
        }
      
    
  
  ,




where rθ is a radius of said mobile device, measured in a direction substantially perpendicular to the selected axis for said mobile device.

4. The method of claim 3, further comprising choosing said angle ψ to be ψ=tan−1 {(yi−y0)/(xi−x0)}.

5. The method of claim 3, further comprising:
providing said mobile device with a controllable aperture and with a source of a selected chemical associated with the aperture;
estimating a time when (1) said location coordinates (x0,y0,z0) for said mobile device lie in selected ranges (xr1≦x0≦xr2,yr1≦y0≦yr2,zr1≦z0≦zr2) and (2) said roll angle θ lies within a selected range, θr1≦θ≦r2; and
when the conditions (1) and (2) are satisfied, causing said mobile device to release the selected chemical through the aperture.

6. The method of claim 1, further comprising:
causing said mobile device to form and transmit signals representing visually perceptible images at a sequence of two or more image formation times, when a selected criterion is satisfied.

7. The method of claim 6, further comprising choosing said selected criterion to comprise: each image formation time corresponds to a time, t=tf, at which said location coordinates (X0(tf),y0(tf),z0(tf)) lie within one or more selected ranges (xf1≦x0≦xf2,yf1≦y0≦≦yf2,zf1≦z0≦zf2).

8. The method of claim 6, further comprising choosing said criterion to comprise: two consecutive image formation times, t=tf1 and t=tf2, correspond to locations (x0(tf),y0(tf),z0(tf)) of said mobile device that satisfy


{(x0(tf2)−x0(tf1)2+(y0(tf2)−y0(tf1)2+(z0(tf2)−z0(tf2)2}1/2≧Δr(thr),


where Δr(thr) is a selected threshold distance.

9. The method of claim 6, further comprising choosing said criterion to comprise: two consecutive image formation time, t=tf1 and t=tf2 satisfy


|tf2−tf1|≧Δt(thr),


where Δt(thr) is a selected threshold separation time.

10. The method of claim 6, further comprising choosing said criterion to comprise:
providing a numerical measure ID(t1; t2) of differences in an image formed by said mobile device at times t=t1 and t=t2 (>t1); and
the measure ID at two consecutive image formation times, t=tf1 and t=tf2 satisfies


ID(tf1;tf2)≧ID(thr),



where ΔID(thr) is a selected image difference threshold value.

11. The method of claim 1, further comprising choosing at least one of said sets of coordinate values, (x1,y1,z1), (x2,y2,z2), (x3,y3,z3) and (x4,y4,z4), to produce a magnitude of an inverse of a determinant, 1/|det(M)|, of said matrix M having a small positive value.