# Patent

## Title
Method for determining construction parameters of magnet structures designed to generate magnetic fields in predetermined volumes of space and method for correcting magnetic fields in predetermined volumes of space, particularly in MRI apparatus

## Abstract

A method for determining construction parameters of magnet structures designed to generate magnetic fields in predetermined volumes of space, comprising the steps of: a) defining a predetermined volume of space in which a static magnetic field is to be generated; b) defining the nominal strength and profile of the magnetic field in said predetermined volume of space; c) mathematically describing the nominal magnetic field on the surface of and/or in said predetermined volume of space by using a polynomial expansion of the magnetic field-describing function, which provides a series of coefficients; d) determining the size, geometry and relative position in space of the means for generating said nominal magnetic field, with respect to the volume of space in and on which the desired, i.e. nominal magnetic field, is defined. According to the invention, the predetermined volume of space is delimited by an ideal ellipsoidal closed surface and the magnetic field is expressed by coefficients of a polynomial ellipsoidal harmonic expansion. The method may be also used as a shimming method in volumes of space ideally delimited by ellipsoidal closed surfaces, to be implemented whether or not the predetermined volume of space defined by the magnet structure is also delimited by an ideal closed surface, with an ellipsoidal or other shape.

## Background
This application claims priority under 35 U.S.C. § 119(e) to U.S. Provisional Application Ser. No. 60/788,703, filed Apr. 4, 2006.


A method for determining construction parameters of magnet structures designed to generate magnetic fields in predetermined volumes of space, comprising the steps of:
a) defining a predetermined volume of space in which a static magnetic field is to be generated;
b) defining the nominal strength and profile of the magnetic field in said predetermined volume of space;
c) mathematically describing the nominal magnetic field on the surface of and/or in said predetermined volume of space by using a polynomial expansion of the magnetic field-describing function, which provides a series of coefficients;
d) determining the size, geometry and relative position in space of the means for generating said nominal magnetic field, with respect to the volume of space in and on which the desired, i.e. nominal magnetic field, is defined.
The mathematical means that are currently used to carry out these steps consist of a polynomial expansion of the magnetic field describing function, which is based on volumes of space defined by spherical surfaces.
Here, the polynomial expansion provides a series of coefficients to uniquely describe the magnetic field features, which coefficients are spherical harmonics (see for instance SV98A00015).
Currently available mathematical instruments allow to define magnet structures in relation to static magnetic fields with a predetermined homogeneity, which are distributed in volumes of space delimited by ideal spheres.
Particularly referring to a MRI apparatus, its magnet structure delimits a cavity for receiving a body or a part of a body, which cavity has one, two, three or more open sides. The magnet structure is designed to generate a static magnetic field to permeate the cavity space. Due to magnetic field perturbations caused by such opened sides, the static magnetic field only has the homogeneity required to ensure a sufficient image quality for diagnostic imaging in a partial volume of the overall cavity volume. This partial volume which is defined, as previously mentioned, by an ideal sphere, must have a sufficient size to receive the part of the body under examination. Furthermore, this partial volume of space, also known as Field of View, must not intersect or be tangent to the magnet structure, and must not extend outside it.
Since the morphology of the organs or anatomic regions that are typically examined by MRI is far from being spherical, then wide portions of space within the ideal sphere extend beyond the volume actually occupied by the limb or anatomic region to be examined.
As a result, the magnet structure must be sufficiently large to define and delimit a cavity having at least a sufficient size to contain the partial volume of space or field of view delimited by the ideal sphere, with the sphere never coming in contact with the magnet structure. Therefore, the size and weight of the magnet structure, which are often considerable per se, are greater than is currently required to contain the limb, body part or anatomic region to be examined, also due to a redundant or unnecessary portion of the partial volume within which the magnetic field generated thereby must have sufficient characteristics to allow useful diagnostic imaging.
Also, during the design and construction of the magnet structure, a relatively high inhomogeneity tolerance threshold is set for the magnetic field in said partial volume, which is generally of the order of about one thousand of parts per million and in a subsequent step, known as shimming, this threshold is dramatically decreased to values of a few parts per million, however such shimming step must occur over the whole partial volume delimited by the ideal sphere, even on useless portions thereof, which are not occupied by the limb, the organ, body part or anatomic region under examination. Inhomogeneity tolerance shall be intended herein as magnetic field tolerance within the predetermined volume of space, i.e. a volume in which the anatomic region to be examined is placed, such tolerance being typically of the order of a few units or tens of ppm (parts per million) peak to peak.
Therefore, the invention is based on the problem of providing a method as described hereinbefore, which allows to determine the suitable magnet structure to generate a homogeneous static magnetic field in a volume of space defined by a surface whose shape is more similar to that of a limb, an organ, a body part or an anatomic region under examination, without involving excessive time, cost and material requirements.
The invention achieves the above purposes by providing a method as described above, in which:
the predetermined volume of space is delimited by an ideal closed surface having an ellipsoidal shape;
the magnetic field is expressed by the coefficients of a polynomial expansion, which coefficients are ellipsoidal harmonics.
Thanks to the above, the volume of space in which the homogeneous magnetic field is generated may be better adapted to the shape of the limb, organ, body part or anatomic region under examination. This also allows to reduce the size of the cavity containing said volume of space, which constitutes a partial volume of said cavity, thence the size of the magnet structure.
In fact, a larger portion of the predetermined volume of space, in which the magnetic field has the required homogeneity, is filled by the limb, organ, body part or anatomic region under examination.
Particularly dedicated MRI apparatus, whose use is restricted to the examination of specific limbs or body parts or anatomic regions, such as a hand or a foot, or the lower or upper limbs, may have a smaller size than current apparatus, with equally sized fields of view, thanks to the increase of the filling ratio due to an improved adaptation of the partial volume of space in which the magnetic field has the required characteristics for imaging, to the morphology of the limb, body part or anatomic region under examination.
Once again in this invention, an inhomogeneity tolerance threshold of one to a few thousands of ppm is set in the design of the magnet structure and after construction, the magnet structure is subjected to a correction process, known as shimming, in which the inhomogeneity of the magnetic field within the predetermined volume of space is reduced below a tolerance threshold of the order of a few units to a few tens of ppm (parts per million) peak to peak, by measuring the magnetic field that was actually generated in said predetermined volume of space at several predetermined points in a grid of predetermined measuring points arranged in said predetermined volume of space delimited by the ideal closed surface, which ideally delimits said volume of space and/or along said ideal closed surface, comparing the actual measured magnetic field with the nominal desired field within said predetermined volume of space, determining the value of the magnetic moment of magnetic shims and the position thereof over one or more positioning grids, which positioning grids have a predetermined position and orientation relative to said predetermined volume of space.
These steps may be possibly sequentially repeated several times.
In this invention, the steps of correcting or shimming the static magnetic field in the predetermined volume of space also require the magnetic field in the predetermined volume of space and the magnetic field generated by the effects of magnetic shims to be described by ellipsoidal harmonics.
The use of this invention may be also limited to the correction or shimming step, e.g. combined with an existing magnet structure, in which the volume of space with the magnetic field having the required homogeneity for imaging, was designed with an ideal spherical shape. In this case, the correction or shimming step may be carried out by defining a second volume of space having an ellipsoidal shape, which is wholly inscribed or contained in the first spherical volume of space and by only performing correction and shimming in the second volume of space delimited by the ellipsoidal surface.
In both cases of use of this invention for correcting or shimming the magnetic field, the shim positioning grid may be of any type, i.e. a Cartesian grid, an annular grid, formed by the intersection of concentric circles and radiuses or an ellipsoidal grid, formed by a number of ellipses, one inside the other, intersecting with radiuses or adjacent parallel lines.
The latter arrangement provides the advantage of limiting the correction effort to a smaller volume, which is smaller than the volume defined by the ideal spherical delimiting surface. This facilitates or improves the shimming process.



The theory and implementations at the basis of the above methods of this invention will be now described in further detail, with reference to the accompanying drawings, in which:
FIG. 1 shows a two-dimensional grid of Gaussian abscissas.
FIG. 2 shows the three-dimensional grid (continuous line) of Gaussian abscissas in Cartesian coordinates and reference ellipsoid (a=90, b=80, c=70).
FIG. 3 shows the projection of the 3D Gaussian grid in the xy plane.
FIG. 4 shows a reference ellipsoid with a Brillouin sphere.
FIG. 5 shows the profile of ellipsoidal cosine coefficients with ‘even-even’ symmetry
FIG. 6 shows the profile of ellipsoidal sine coefficients with ‘even-even symmetry’.



BRIEF DESCRIPTION OF THE ELLIPSOIDAL INTEGRAL
Considering the non-one-to-one transformation of coordinates



  
    
      x
      2
    
    =
    
      
        
          λ
          1
          2
        
        ⁢
        
          λ
          2
          2
        
        ⁢
        
          λ
          3
          2
        
      
      
        
          h
          2
        
        ⁢
        
          k
          2
        
      
    
  




  
    
      y
      2
    
    =
    
      
        
          (
          
            
              λ
              1
              2
            
            -
            
              h
              2
            
          
          )
        
        ⁢
        
          (
          
            
              λ
              2
              2
            
            -
            
              h
              2
            
          
          )
        
        ⁢
        
          (
          
            
              h
              2
            
            -
            
              λ
              3
              2
            
          
          )
        
      
      
        
          h
          2
        
        ⁡
        
          (
          
            
              k
              2
            
            -
            
              h
              2
            
          
          )
        
      
    
  




  
    
      z
      2
    
    =
    
      
        
          (
          
            
              λ
              1
              2
            
            -
            
              k
              2
            
          
          )
        
        ⁢
        
          (
          
            
              k
              2
            
            -
            
              λ
              2
              2
            
          
          )
        
        ⁢
        
          (
          
            
              k
              2
            
            -
            
              λ
              3
              2
            
          
          )
        
      
      
        
          k
          2
        
        ⁡
        
          (
          
            
              k
              2
            
            -
            
              h
              2
            
          
          )
        
      
    
  




  
    where
    ⁢
    
      :
    
  




  
    
      h
      2
    
    =
    
      
        a
        2
      
      -
      
        b
        2
      
    
  




  
    
      k
      2
    
    =
    
      
        a
        2
      
      -
      
        c
        2
      
    
  



are the confocal distances of the reference ellipsoid:




  
    
      
        
          
            
              (
              
                x
                a
              
              )
            
            2
          
          +
          
            
              (
              
                y
                b
              
              )
            
            2
          
          +
          
            
              (
              
                z
                c
              
              )
            
            2
          
        
        =
        1
      
    
    
      
        (
        2
        )
      
    
  




Laplace's equation

∇2B=0  (3)

rewritten in these new coordinates (so-called ellipsoidal coordinates) provides a solution obtained by separation of variables, of the following type:




  
    
      
        
          B
          ⁡
          
            (
            
              
                λ
                1
              
              ,
              
                λ
                2
              
              ,
              
                λ
                3
              
            
            )
          
        
        =
        
          
            ∑
            
              n
              =
              0
            
            ∞
          
          ⁢
          
            
              ∑
              
                p
                =
                1
              
              
                
                  2
                  ⁢
                  n
                
                +
                1
              
            
            ⁢
            
              
                α
                np
              
              ⁢
              
                
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        1
                      
                      )
                    
                  
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        1
                        ref
                      
                      )
                    
                  
                
                ·
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      2
                    
                    )
                  
                
              
              ⁢
              
                
                  E
                  n
                  p
                
                ⁡
                
                  (
                  
                    λ
                    3
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        4
        )
      
    
  




with Enp(λ1)Enp(λ2) Enp(λ3) being known as Lamé functions of order n and degree p (the quantity Enp(λ2) Enp(λ3) being usually called ellipsoidal harmonic) and




  
    
      
        
          α
          np
        
        =
        
          
            1
            
              γ
              n
              p
            
          
          ⁢
          
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                  ref
                
                )
              
            
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                
                )
              
            
          
          ⁢
          
            
              ∫
              E
              
                
              
            
            ⁢
            
              
                ∫
                
                  λ
                  1
                
                
                  
                
              
              ⁢
              
                
                  
                    
                      B
                      ⁡
                      
                        (
                        
                          
                            λ
                            1
                          
                          ,
                          
                            λ
                            2
                          
                          ,
                          
                            λ
                            3
                          
                        
                        )
                      
                    
                    
                      
                        
                          (
                          
                            
                              λ
                              1
                              2
                            
                            -
                            
                              λ
                              2
                              2
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              λ
                              1
                              2
                            
                            -
                            
                              λ
                              3
                              2
                            
                          
                          )
                        
                      
                    
                  
                  ·
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        2
                      
                      )
                    
                  
                
                ⁢
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      3
                    
                    )
                  
                
                ⁢
                
                  
                
                ⁢
                
                  d
                  S
                
              
            
          
        
      
    
    
      
        (
        5
        )
      
    
  




The quantities γnp, in (5), are ellipsoidal harmonic normalization coefficients (so that the integral over the ellipsoid of each ellipsoidal harmonic is one),




  
    
      
        
          γ
          n
          p
        
        =
        
          
            ∫
            E
            
              
            
          
          ⁢
          
            
              ∫
              
                λ
                1
              
              
                
              
            
            ⁢
            
              
                
                  
                    (
                    
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            λ
                            2
                          
                          )
                        
                      
                      ⁢
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            λ
                            3
                          
                          )
                        
                      
                    
                    )
                  
                  2
                
                
                  
                    
                      (
                      
                        
                          λ
                          1
                          2
                        
                        -
                        
                          λ
                          3
                          2
                        
                      
                      )
                    
                    ⁢
                    
                      (
                      
                        
                          λ
                          1
                          2
                        
                        -
                        
                          λ
                          2
                          2
                        
                      
                      )
                    
                  
                
              
              ⁢
              
                
              
              ⁢
              
                d
                S
              
            
          
        
      
    
    
      
        (
        6
        )
      
    
  




The integrals in relations (5) and (6) are surface integrals extended over the surface defined by the relation λ1=cost., which corresponds to the reference ellipsoid (2).
The surface element dS of the ellipsoid in the ellipsoidal coordinates is given by the quantity:




  
    
      
        dS
        =
        
          
            
              (
              
                
                  λ
                  2
                  2
                
                -
                
                  λ
                  3
                  2
                
              
              )
            
            ⁢
            
              
                
                  (
                  
                    
                      λ
                      1
                      2
                    
                    -
                    
                      λ
                      2
                      2
                    
                  
                  )
                
                ⁢
                
                  (
                  
                    
                      λ
                      1
                      2
                    
                    -
                    
                      λ
                      3
                      2
                    
                  
                  )
                
              
            
          
          
            
              
                
                  (
                  
                    
                      λ
                      2
                      2
                    
                    -
                    
                      h
                      2
                    
                  
                  )
                
                ⁢
                
                  (
                  
                    
                      k
                      2
                    
                    -
                    
                      λ
                      2
                      2
                    
                  
                  )
                
              
            
            ⁢
            
              
                
                  (
                  
                    
                      h
                      2
                    
                    -
                    
                      λ
                      3
                      2
                    
                  
                  )
                
                ⁢
                
                  (
                  
                    
                      k
                      2
                    
                    -
                    
                      λ
                      3
                      2
                    
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        7
        )
      
    
  




whereby the relation (6) may be rewritten, after introducing the integration limits, as follows:





  
    
      
        
          γ
          n
          p
        
        =
        
          8
          ⁢
          
            
              ∫
              0
              h
            
            ⁢
            
              
            
            ⁢
            
              
                d
                
                  λ
                  3
                
              
              ⁢
              
                
              
              ⁢
              
                
                  ∫
                  h
                  k
                
                ⁢
                
                  
                
                ⁢
                
                  
                    d
                    
                      λ
                      2
                    
                  
                  ⁢
                  
                    
                      
                        (
                        
                          
                            λ
                            2
                            2
                          
                          -
                          
                            λ
                            3
                            2
                          
                        
                        )
                      
                      ⁢
                      
                        
                          (
                          
                            
                              
                                E
                                n
                                p
                              
                              ⁡
                              
                                (
                                
                                  λ
                                  2
                                
                                )
                              
                            
                            ⁢
                            
                              
                                E
                                n
                                p
                              
                              ⁡
                              
                                (
                                
                                  λ
                                  3
                                
                                )
                              
                            
                          
                          )
                        
                        2
                      
                    
                    
                      
                        
                          
                            (
                            
                              
                                λ
                                2
                                2
                              
                              -
                              
                                h
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                k
                                2
                              
                              -
                              
                                λ
                                2
                                2
                              
                            
                            )
                          
                        
                      
                      ⁢
                      
                        
                          
                            (
                            
                              
                                h
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                k
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                        
                      
                    
                  
                
              
            
          
        
      
    
    
      
        (
        8
        )
      
    
  




Similarly, the relation (5) becomes:





  
    
      
        
          α
          np
        
        =
        
          
            8
            
              γ
              n
              p
            
          
          ⁢
          
            
              ∫
              0
              h
            
            ⁢
            
              
            
            ⁢
            
              
                d
                
                  λ
                  3
                
              
              ⁢
              
                
              
              ⁢
              
                
                  ∫
                  h
                  k
                
                ⁢
                
                  
                
                ⁢
                
                  
                    d
                    
                      λ
                      2
                    
                  
                  ⁢
                  
                    
                      
                        (
                        
                          
                            λ
                            2
                            2
                          
                          -
                          
                            λ
                            3
                            2
                          
                        
                        )
                      
                      ⁢
                      
                        B
                        ⁡
                        
                          (
                          
                            
                              λ
                              1
                            
                            ,
                            
                              λ
                              2
                            
                            ,
                            
                              λ
                              3
                            
                          
                          )
                        
                      
                      ⁢
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            λ
                            2
                          
                          )
                        
                      
                      ⁢
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            λ
                            3
                          
                          )
                        
                      
                    
                    
                      
                        
                          
                            (
                            
                              
                                λ
                                2
                                2
                              
                              -
                              
                                h
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                k
                                2
                              
                              -
                              
                                λ
                                2
                                2
                              
                            
                            )
                          
                        
                      
                      ⁢
                      
                        
                          
                            (
                            
                              
                                h
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                k
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                        
                      
                    
                  
                
              
            
          
        
      
    
    
      
        (
        9
        )
      
    
  




Ellipsoidal Integral and Gauss Method

As mentioned above, the ellipsoidal coefficients may be obtained by quantifying the integrals:




  
    
      
        
          
            γ
            n
            p
          
          =
          
            8
            ⁢
            
              
                ∫
                0
                h
              
              ⁢
              
                
              
              ⁢
              
                
                  d
                  
                    λ
                    3
                  
                
                ⁢
                
                  
                
                ⁢
                
                  
                    ∫
                    h
                    k
                  
                  ⁢
                  
                    
                  
                  ⁢
                  
                    
                      d
                      
                        λ
                        2
                      
                    
                    ⁢
                    
                      
                        
                          (
                          
                            
                              λ
                              2
                              2
                            
                            -
                            
                              λ
                              3
                              2
                            
                          
                          )
                        
                        ⁢
                        
                          
                            (
                            
                              
                                
                                  E
                                  n
                                  p
                                
                                ⁡
                                
                                  (
                                  
                                    λ
                                    2
                                  
                                  )
                                
                              
                              ⁢
                              
                                
                                  E
                                  n
                                  p
                                
                                ⁡
                                
                                  (
                                  
                                    λ
                                    3
                                  
                                  )
                                
                              
                            
                            )
                          
                          2
                        
                      
                      
                        
                          
                            
                              (
                              
                                
                                  λ
                                  2
                                  2
                                
                                -
                                
                                  h
                                  2
                                
                              
                              )
                            
                            ⁢
                            
                              (
                              
                                
                                  k
                                  2
                                
                                -
                                
                                  λ
                                  2
                                  2
                                
                              
                              )
                            
                          
                        
                        ⁢
                        
                          
                            
                              (
                              
                                
                                  h
                                  2
                                
                                -
                                
                                  λ
                                  3
                                  2
                                
                              
                              )
                            
                            ⁢
                            
                              (
                              
                                
                                  k
                                  2
                                
                                -
                                
                                  λ
                                  3
                                  2
                                
                              
                              )
                            
                          
                        
                      
                    
                  
                
              
            
          
        
        ⁢
        
          

        
        ⁢
        and
      
    
    
      
        (
        0.1
        )
      
    
  
  
    
      
        
          α
          np
        
        =
        
          
            8
            
              γ
              n
              p
            
          
          ⁢
          
            
              ∫
              0
              h
            
            ⁢
            
              
            
            ⁢
            
              
                d
                
                  λ
                  3
                
              
              ⁢
              
                
              
              ⁢
              
                
                  ∫
                  h
                  k
                
                ⁢
                
                  
                
                ⁢
                
                  
                    d
                    
                      λ
                      2
                    
                  
                  ⁢
                  
                    
                      
                        (
                        
                          
                            λ
                            2
                            2
                          
                          -
                          
                            λ
                            3
                            2
                          
                        
                        )
                      
                      ⁢
                      
                        B
                        ⁡
                        
                          (
                          
                            
                              λ
                              1
                            
                            ,
                            
                              λ
                              2
                            
                            ,
                            
                              λ
                              3
                            
                          
                          )
                        
                      
                      ⁢
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            λ
                            2
                          
                          )
                        
                      
                      ⁢
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            λ
                            3
                          
                          )
                        
                      
                    
                    
                      
                        
                          
                            (
                            
                              
                                λ
                                2
                                2
                              
                              -
                              
                                h
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                k
                                2
                              
                              -
                              
                                λ
                                2
                                2
                              
                            
                            )
                          
                        
                      
                      ⁢
                      
                        
                          
                            (
                            
                              
                                h
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                k
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                        
                      
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.2
        )
      
    
  




where (0.1) are the ellipsoidal harmonic normalization coefficients and (0.2) are the coefficients of expansion of the field B to Lamé functions in ellipsoidal coordinates:




  
    
      
        
          B
          ⁡
          
            (
            
              
                λ
                1
              
              ,
              
                λ
                2
              
              ,
              
                λ
                3
              
            
            )
          
        
        =
        
          
            ∑
            
              n
              =
              0
            
            ∞
          
          ⁢
          
            
              ∑
              
                p
                =
                1
              
              
                
                  2
                  ⁢
                  n
                
                +
                1
              
            
            ⁢
            
              
                α
                np
              
              ⁢
              
                
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        1
                      
                      )
                    
                  
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        1
                        ref
                      
                      )
                    
                  
                
                ·
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      2
                    
                    )
                  
                
              
              ⁢
              
                
                  E
                  n
                  p
                
                ⁡
                
                  (
                  
                    λ
                    3
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        0.3
        )
      
    
  




The integral (0.3) may be rewritten as follows, after application of a mixed Gauss-Legendre and Gauss-Chebyshev method:




  
    
      
        
          γ
          n
          p
        
        =
        
          8
          ⁢
          
            
              ∑
              
                i
                =
                1
              
              N
            
            ⁢
            
              
                ω
                i
                C
              
              ⁢
              
                
                  ω
                  i
                  L
                
                ⁡
                
                  (
                  
                    
                      
                        
                          F
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            L
                          
                          )
                        
                      
                      ⁢
                      
                        
                          G
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            C
                          
                          )
                        
                      
                    
                    -
                    
                      
                        
                          G
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            L
                          
                          )
                        
                      
                      ⁢
                      
                        
                          F
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            C
                          
                          )
                        
                      
                    
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        0.4
        )
      
    
  




where the quantities Fnp (xiL) and Gnp (xiC) are related to the ellipsoidal harmonics of degree n and order p, as determined in Gauss-Chebychev abscissas xiC and Gauss-Legendre abscissas xiL, whereas the quantities ωiC and ωiL represent the respective weights. Similarly, the integral (0.2) is evaluated according to the following relation:




  
    
      
        
          α
          n
          p
        
        =
        
          
            2
            
              γ
              n
              p
            
          
          ⁢
          
            
              ∑
              
                i
                =
                1
              
              
                N
                /
                2
              
            
            ⁢
            
              
                ∑
                
                  j
                  =
                  1
                
                N
              
              ⁢
              
                
                  ω
                  i
                  C
                
                ⁢
                
                  ω
                  i
                  L
                
                ⁢
                
                  B
                  ⁡
                  
                    (
                    
                      
                        x
                        i
                        C
                      
                      ,
                      
                        x
                        i
                        L
                      
                    
                    )
                  
                
                ⁢
                
                  (
                  
                    
                      
                        
                          F
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            L
                          
                          )
                        
                      
                      ⁢
                      
                        
                          G
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            C
                          
                          )
                        
                      
                    
                    -
                    
                      
                        
                          G
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            L
                          
                          )
                        
                      
                      ⁢
                      
                        
                          F
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            C
                          
                          )
                        
                      
                    
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        0.5
        )
      
    
  




where N represents the order of approximation that is used in the calculation. The field B in (0.5) is expressed in ppm and is normalized with respect to the value assumed at the center of the ellipsoid. The next paragraph will describe the complete algorithm to determine the quantities (0.4) and (0.5), involving, as a first step, the construction of ellipsoidal harmonics to the order n=N−1 and degree, which are not tabled functions (unlike spherical harmonics) but are constructed on the basis of the actual dimensions of the ellipsoid (i.e. on the values of the three semiaxes).
Algorithm for Determining Ellipsoidal Coefficients
The algorithm to calculate the ellipsoidal coefficients may be summarized in the following basic macrosteps:

    
    
        a. Construction of Lamé functions from the dimensions of semiaxes up to the order N−1.
        b. Calculation of normalization coefficients γnp according to (0.4).
        c. Calculation of expansion coefficients αnp by using (0.5).
    
    


As inputs, the algorithm receives the three semiaxes, the order of approximation N and the experimental measurement file, which makes it a general algorithm, adapted to be used for any ellipsoid.
The construction of ellipsoidal harmonics follows the matrix algorithm described in “Ellipsoidal harmonic expansions of the gravitational potential: theory and application”, Garmier R., Barriot J. P., Celestial Mechanics and Dynamical Astronomy 79, pp. 235-275 (2001)
that will be summarized hereafter. A Lamé function Enp(λi) of order n and degree p may be rewritten as a product of a function ψnp(λi), which is characteristic of the class of the above function (K, L, M, N) with a normalized polynomial Pnp(λi2).




  
    
      
        
          
            P
            n
            p
          
          ⁡
          
            (
            
              λ
              i
              2
            
            )
          
        
        =
        
          
            ∑
            
              j
              =
              0
            
            m
          
          ⁢
          
            
              
                b
                j
              
              ⁡
              
                (
                
                  1
                  -
                  
                    
                      λ
                      i
                      2
                    
                    
                      h
                      2
                    
                  
                
                )
              
            
            j
          
        
      
    
    
      
        (
        0.6
        )
      
    
  




if i=3 and k instead of h if i=2. The quantities bj are the polynomial coefficients to be calculated and are a function of the semiaxes a, b, c of the characteristic ellipsoid:

bj=bj(a,b,c)

By replacing the equation (0.6) in Laplace equation in ellipsoidal coordinates (known as Lamé equation), the coefficients bj appear to be the components of the eigenvectors of an eigenvalue problem of the following type:

=p  (0.7)

where  is an eigenvector having components (b0,b1, . . . , br)T and  is a tridiagonal matrix characteristic of the Lamé function class. For class K, such matrix will be as follows:




  
    
      
        
                    ⁢
                  
        =
        
          
            (
            
              
                
                  
                                        ⁢
                                      
                
                
                  
                                        ⁢
                                      
                
                
                  0
                
                
                  0
                
                
                  0
                
              
              
                
                                  
                
                                  
                
                                  
                
                  ⋯
                
                
                  0
                
              
              
                
                  0
                
                
                                  
                
                  ⋮
                
                
                  ⋯
                
                
                  ⋮
                
              
              
                
                  ⋮
                
                
                  ⋮
                
                
                  ⋮
                
                
                  ⋯
                
                
                  ⋮
                
              
              
                
                  0
                
                
                  0
                
                
                  ⋮
                
                
                                  
                
                                  
              
            
            )
          
          ⁢
                  
      
    
    
      
        (
        0.8
        )
      
    
  




where the quantities , i, i and are constructed from the semiaxes a, b, c (see “Ellipsoidal harmonic expansions of the gravitational potential: theory and application”, Garmier R., Barriot J. P., Celestial Mechanics and Dynamical Astronomy 79, pp. 235-275 (2001) Annex 3). The Lamé harmonics for the other classes may be constructed in a similar manner.
Once the quantities bjn,p have been determined, (0.4) may be applied to the points of the grid of plane (λ2,λ3). Gauss-Legendre and Gauss-Chebyshev abscissas, as determined in the previous step, naturally define a two-dimensional grid (λ2,λ3) in space, as shown in FIG. 1.
The grid of FIG. 1 is composed of N*N points in overlapping pairs, thence N*N/2 individual points, such overlapping structure being essentially the result of the initial construction of fixed-N Chebyshev abscissas. Since the coordinate transformation defined by equations (1) is not one-to-one, but one-to-eight, the grid of Gaussian abscissas only maps an octant (particularly the positive octant with x>0,y>0,z>0) of the Cartesian space (x,y,z), with λ1=cost.=a (i.e. the reference ellipsoid belonging to the family of confocal ellipsoids) being previously set. From this octant, the whole three-dimensional Cartesian space may be reconstructed, by making use of symmetry properties, which allow to generate a 3D grid of Gaussian abscissas, transformed from ellipsoidal coordinates (where they were defined) to Cartesian coordinates, as shown in FIG. 2.
As shown in FIGS. 2 and 3, the Gaussian abscissas define a number N of ellipses over the surface of the ellipsoid, each formed by 4*N points. The following table indicates the number of points of the 3D grid, as N changes.















Number of points



Order
Number of ellipses
per ellipse
Total points


















N = 8
8
32
256


N = 10
10
40
400


N = 12
12
48
576


N = 20
20
80
1600









On such integral paths, (8) may be rewritten as follows:




  
    
      
        
          α
          n
          p
        
        =
        
          
            2
            
              γ
              n
              p
            
          
          ⁢
          
            
              ∑
              
                i
                =
                1
              
              
                N
                /
                2
              
            
            ⁢
            
              
                ∑
                
                  j
                  =
                  1
                
                N
              
              ⁢
              
                
                  ω
                  i
                  C
                
                ⁢
                
                  ω
                  i
                  L
                
                ⁢
                
                  B
                  ⁡
                  
                    (
                    
                      
                        x
                        i
                        C
                      
                      ,
                      
                        x
                        i
                        L
                      
                    
                    )
                  
                
                ⁢
                
                  (
                  
                    
                      
                        
                          F
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            L
                          
                          )
                        
                      
                      ⁢
                      
                        
                          G
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            C
                          
                          )
                        
                      
                    
                    -
                    
                      
                        
                          G
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            L
                          
                          )
                        
                      
                      ⁢
                      
                        
                          F
                          n
                          p
                        
                        ⁡
                        
                          (
                          
                            x
                            i
                            C
                          
                          )
                        
                      
                    
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        14
        )
      
    
  




where a field B appears in the summation, which is sampled at points that correspond, as mentioned above, to the “mixed” Gaussian abscissas transformed into Cartesian coordinates. The following paragraph will describe a test on equation (14), with n=0 and p=1 (i.e. α01), and with a measurement of the field B over the ellipsoid being simulated.
Back to the algorithm, once the quantities γnp have been determined up to the order N−1, the algorithm computes the coefficient αnp by applying the equation (0.5) with the values of the sampled field to the 3D Cartesian grid obtained from the ellipsoidal coordinate grid.
Algorithm Testing and Validation
This paragraph proposes a number of tests and considerations on the above algorithm, through which the results may be checked for correctness, for a full validation of the algorithm as from the construction of ellipsoidal harmonics.
Test on Matrix Construction of Ellipsoidal Harmonics
Lamé functions up to the order n=3 inclusive, may be analytically computed in a relatively simple manner, as a function of the semiaxes a, b, c or more specifically as a function of the confocal distances h and k (see Annex 1). The analytical expression of such functions is as follows:



  
    
      K
      0
      1
    
    =
    1
  




  
    n
    =
    0
  




  
    
      
        K
        1
        1
      
      ⁡
      
        (
        x
        )
      
    
    =
    x
  




  
    
      
        L
        1
        2
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
        
          
            x
            2
          
          -
          
            k
            2
          
        
        
      
    
  




  
    
      
        M
        1
        3
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
        
          
            h
            2
          
          -
          
            x
            2
          
        
        
      
    
  




  
    n
    =
    1
  




  
    
      
        K
        2
        1
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        x
        2
      
      -
      
        
          1
          3
        
        ⁡
        
          [
          
            
              b
              2
            
            +
            
              c
              2
            
            -
            
              
                
                  
                    (
                    
                      
                        b
                        2
                      
                      +
                      
                        c
                        2
                      
                    
                    )
                  
                  2
                
                -
                
                  3
                  ⁢
                  
                    b
                    2
                  
                  ⁢
                  
                    c
                    2
                  
                
              
            
          
          ]
        
      
    
  




  
    
      
        K
        2
        2
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        x
        2
      
      -
      
        
          1
          3
        
        ⁡
        
          [
          
            
              b
              2
            
            +
            
              c
              2
            
            +
            
              
                
                  
                    (
                    
                      
                        b
                        2
                      
                      +
                      
                        c
                        2
                      
                    
                    )
                  
                  2
                
                -
                
                  3
                  ⁢
                  
                    b
                    2
                  
                  ⁢
                  
                    c
                    2
                  
                
              
            
          
          ]
        
      
    
  




  
    
      
        L
        2
        3
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      x
      ⁢
      
        
          
          
            
              x
              2
            
            -
            
              k
              2
            
          
          
        
      
    
  




  
    
      
        M
        2
        4
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      x
      ⁢
      
        
          
          
            
              h
              2
            
            -
            
              x
              2
            
          
          
        
      
    
  




  
    
      
        N
        2
        5
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
          
          
            
              h
              2
            
            -
            
              x
              2
            
          
          
        
      
      ⁢
      
        
          
          
            
              x
              2
            
            -
            
              k
              2
            
          
          
        
      
    
  




  
    n
    =
    2
  




  
    
      
        K
        3
        1
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        x
        3
      
      -
      
        
          x
          5
        
        ⁡
        
          [
          
            
              2
              ⁢
              
                (
                
                  
                    b
                    2
                  
                  +
                  
                    c
                    2
                  
                
                )
              
            
            -
            
              
                
                  4
                  ⁢
                  
                    
                      (
                      
                        
                          b
                          2
                        
                        +
                        
                          c
                          2
                        
                      
                      )
                    
                    2
                  
                
                -
                
                  15
                  ⁢
                  
                    b
                    2
                  
                  ⁢
                  
                    c
                    2
                  
                
              
            
          
          ]
        
      
    
  




  
    
      
        K
        3
        2
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        x
        3
      
      -
      
        
          x
          5
        
        ⁡
        
          [
          
            
              2
              ⁢
              
                (
                
                  
                    b
                    2
                  
                  +
                  
                    c
                    2
                  
                
                )
              
            
            +
            
              
                
                  4
                  ⁢
                  
                    
                      (
                      
                        
                          b
                          2
                        
                        +
                        
                          c
                          2
                        
                      
                      )
                    
                    2
                  
                
                -
                
                  15
                  ⁢
                  
                    b
                    2
                  
                  ⁢
                  
                    c
                    2
                  
                
              
            
          
          ]
        
      
    
  




  
    
      
        L
        3
        3
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
          
          
            
              x
              2
            
            -
            
              k
              2
            
          
          
        
      
      ⁡
      
        [
        
          
            x
            2
          
          -
          
            
              1
              5
            
            ⁢
            
              (
              
                
                  b
                  2
                
                +
                
                  2
                  ⁢
                  
                    c
                    2
                  
                
                -
                
                  
                    
                      
                        (
                        
                          
                            b
                            2
                          
                          +
                          
                            2
                            ⁢
                            
                              c
                              2
                            
                          
                        
                        )
                      
                      2
                    
                    -
                    
                      5
                      ⁢
                      
                        b
                        2
                      
                      ⁢
                      
                        c
                        2
                      
                    
                  
                
              
              )
            
          
        
        ]
      
    
  




  
    
      
        L
        3
        4
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
          
          
            
              x
              2
            
            -
            
              k
              2
            
          
          
        
      
      ⁡
      
        [
        
          
            x
            2
          
          -
          
            
              1
              5
            
            ⁢
            
              (
              
                
                  b
                  2
                
                +
                
                  2
                  ⁢
                  
                    c
                    2
                  
                
                +
                
                  
                    
                      
                        (
                        
                          
                            b
                            2
                          
                          +
                          
                            2
                            ⁢
                            
                              c
                              2
                            
                          
                        
                        )
                      
                      2
                    
                    -
                    
                      5
                      ⁢
                      
                        b
                        2
                      
                      ⁢
                      
                        c
                        2
                      
                    
                  
                
              
              )
            
          
        
        ]
      
    
  




  
    
      
        M
        3
        5
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
          
          
            
              h
              2
            
            -
            
              x
              2
            
          
          
        
      
      ⁡
      
        [
        
          
            x
            2
          
          -
          
            
              1
              5
            
            ⁢
            
              (
              
                
                  2
                  ⁢
                  
                    b
                    2
                  
                
                +
                
                  c
                  2
                
                -
                
                  
                    
                      
                        (
                        
                          
                            2
                            ⁢
                            
                              b
                              2
                            
                          
                          +
                          
                            c
                            2
                          
                        
                        )
                      
                      2
                    
                    -
                    
                      5
                      ⁢
                      
                        b
                        2
                      
                      ⁢
                      
                        c
                        2
                      
                    
                  
                
              
              )
            
          
        
        ]
      
    
  




  
    
      
        M
        3
        6
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        
          
          
            
              h
              2
            
            -
            
              x
              2
            
          
          
        
      
      ⁡
      
        [
        
          
            x
            2
          
          -
          
            
              1
              5
            
            ⁢
            
              (
              
                
                  2
                  ⁢
                  
                    b
                    2
                  
                
                +
                
                  c
                  2
                
                +
                
                  
                    
                      
                        (
                        
                          
                            2
                            ⁢
                            
                              b
                              2
                            
                          
                          +
                          
                            c
                            2
                          
                        
                        )
                      
                      2
                    
                    -
                    
                      5
                      ⁢
                      
                        b
                        2
                      
                      ⁢
                      
                        c
                        2
                      
                    
                  
                
              
              )
            
          
        
        ]
      
    
  




  
    
      
        N
        3
        7
      
      ⁡
      
        (
        x
        )
      
    
    =
    
      
        x
        ⁢
        
          
            
            
              
                h
                2
              
              -
              
                x
                2
              
            
            
          
        
        ⁢
        
          
            
            
              
                x
                2
              
              -
              
                k
                2
              
            
            
          
        
        ⁢
        
          

        
        ⁢
        n
      
      =
      3
    
  



when n=0 or n=1, the matrix algorithm for Lamé function construction correctly provides the identity vector as an eigenvalue, considering the form of ψnp(λi). This also occurs if n=1, for functions L23(x), M24(x) and N25(x). With n=3 and n=2, a comparison was performed, for functions K21(x) and K22(x), between the values assumed in the 2D grid of points in the ellipsoidal space of each function, constructed either in matrix form or with the above explicit expressions. The values obtained from the two computation methods are identical and shall be interpreted, like the results obtained with n=0, n=1 and n=2, as a first validation of the Lamé function construction method.
Calculation of Normalization Coefficients γnp 
In the next macrostep, the ellipsoidal harmonic normalization coefficients γnp are calculated. As an example, the following table shows the values obtained by applying (0.4) to the points of the 2D ellipsoidal grid up to the order n=3:













gr














ord.
p = 1
p = 2
p = 3
p = 4
p = 5
p = 6
p = 7

















n = 0
12.5663
/
/
/
/
/
/


n = 1
4.1888
1.5708
1.5708
/
/
/
/


n = 2
8.3776
0.1413
0.2158
0.2158
0.5013
/
/


n = 3
1.7531
1.037 · 10−2
2.3598
6.1 · 10−3
5.7 · 10−3
0.8929
405 · 10−2









It should be noted that any γnp may be expressed in terms of 4π (see document [3]), e.g,




  
    
      γ
      1
      1
    
    ⁢
    
      
    
    ⁢
    is
    ⁢
    
      
    
    ⁢
    
      4
      3
    
    ⁢
    π
  
  ,
  
    
      
        γ
        1
        2
      
      ⁢
      
        
      
      ⁢
      and
      ⁢
      
        
      
      ⁢
      
        γ
        1
        3
      
      ⁢
      
        
      
      ⁢
      are
      ⁢
      
        
      
      ⁢
      
        4
        8
      
      ⁢
      π
    
    =
    
      
        π
        2
      
      ⁢
      
        
      
      ⁢
      and
      ⁢
      
        
      
      ⁢
      
        γ
        2
        1
      
      ⁢
      
        
      
      ⁢
      is
      ⁢
      
        
      
      ⁢
      
        
          2
          3
        
        ·
        4
      
      ⁢
      
        
      
      ⁢
      π
    
  
  ,




whereas γ01 is 4π. Finally, since the calculation of γnp is a pure mathematical problem, which is not related to magnetic field sampling, (0.4) may be calculated with a maximum N precision (in this case N=20), in principle different from the calculation of (0.5).

Calculation of Ellipsoidal Harmonics Expansion Coefficients αnp 
This section will describe a number of test-cases performed on the algorithm for determining the coefficients αnp, using different measurement file simulations as inputs. In all cases, the ellipsoid considered has the following dimensions:

a(x semiaxis)=100 mm;

b(y semiaxis)=50 mm;

c(z semiaxis)=130 mm;

FIG. 4 shows the diagram of this ellipsoid as well as the comparison with the corresponding Brillouin sphere having radius R=130 mm on the relevant volumes.
By this geometrical configuration, the volume of space in which field shimming would be performed appears to be reduced to 30% of the corresponding spherical volume.
Constant field over the ellipsoid
Using Matlab, a measurement file was generated, which simulated a uniformly constant field over the surface of the ellipsoid. In this case, all output coefficients provided by the algorithm shall be zero, except α01, which is the value of the field at the center of the ellipsoid. The results obtained for this case will be shown below, according to the corresponding spherical symmetries (see annex 1 to paragraph 6).
α01=10.07750001 Mhz; field at the center=10.07750000 Mhz; difference=1.1*10−8 
Cosine Coefficients for Even-Even Symmetry














p














n
1
2
3
4
5
6
















2
0
0
/
/
/
/


4
0
0
0
/
/
/


6
0
0
0
0
/
/


8
0
0
0
0
0
/


10
0
0
0
0
0
0









Sine Coefficients for Even-Even Symmetry














p
















n
3
4
5
6
7
8
9
10
11



















2
0
/
/
/
/
/
/
/
/


4
/
0
0
/
/
/
/
/
/


6
/
/
0
0
0
/
/
/
/


8
/
/
/
0
0
0
0
/
/


10
/
/
/
/
0
0
0
0
0









Cosine Coefficients for Even-Odd Symmetry














p



















n
4
6
7
8
9
10
11
12
13
14
15
16






















2
0
/
/
/
/
/
/
/
/
/
/
/


4
/
0
0
/
/
/
/
/
/
/
/
/


6
/
/
/
0
0
0
/
/
/
/
/
/


8
/
/
/
/
/
0
0
0
0
/
/
/


10
/
/
/
/
/
/
/
0
0
0
0
0









Sine Coefficients for Even-Odd Symmetry














p





















n
5
8
9
11
12
13
14
15
16
17
18
19
20
21





2
0
/
/
/
/
/
/
/
/
/
/
/
/
/


4
/
0
0
/
/
/
/
/
/
/
/
/
/
/


6
/
/
/
0
0
0
/
/
/
/
/
/
/
/


8
/
/
/
/
/
/
0
0
0
0
/
/
/
/


10 
/
/
/
/
/
/
/
/
/
0
0
0
0
0









Cosine Coefficients for Odd-Odd Symmetry















p














n
1
2
3
4
5
6





1
0
/
/
/
/
/


3
0
0
/
/
/
/


5
0
0
0
/
/
/


7
0
0
0
0
/
/


9
0
0
0
0
0
/


11 
0
0
0
0
0
0









Sine Coefficients for Odd-Odd Symmetry














p


















n
2
3
4
5
6
7
8
9
10
11
12





















1
0
/
/
/
/
/
/
/
/
/
/


3
/
0
0
/
/
/
/
/
/
/
/


5
/
/
0
0
0
/
/
/
/
/
/


7
/
/
/
0
0
0
0
/
/
/
/


9
/
/
/
/
0
0
0
0
0
/
/


11
/
/
/
/
/
0
0
0
0
0
0









Cosine Coefficients For Odd-Even Symmetry














p






















n
3
5
6
7
8
9
10
11
12
13
14
15
16
17
18





1
0
/
/
/
/
/
/
/
/
/
/
/
/
/
/


3
/
0
0
/
/
/
/
/
/
/
/
/
/
/
/


5
/
/
/
0
0
0
/
/
/
/
/
/
/
/
/


7
/
/
/
/
/
0
0
0
0
/
/
/
/
/
/


9
/
/
/
/
/
/
/
0
0
0
0
0
/
/
/


11 
/
/
/
/
/
/
/
/
/
0
0
0
0
0
0









Sine Coefficients For Odd-Even Symmetry














p





















n
7
10
11
13
14
15
16
17
18
19
20
21
22
23





3
0
/
/
/
/
/
/
/
/
/
/
/
/
/


5
/
0
0
/
/
/
/
/
/
/
/
/
/
/


7
/
/
/
0
0
0
/
/
/
/
/
/
/
/


9
/
/
/
/
/
/
0
0
0
0
/
/
/
/


11 
/
/
/
/
/
/
/
/
/
0
0
0
0
0









Therefore, the result appears to be consistent with the theory. Expansion is performed up to the order N=11, considering as a measurement file a file with 12 ‘ellipses’ (planes) over the surface of the ellipsoid. The test-cases always relate to a measurement file of this type, which involves sampling of the magnetic field at 576 different points over the ellipsoid. A few considerations and tests will be now proposed with the aim of reducing the sampling points, thence the duration of each measurement.
The diagrams of FIGS. 5 and 6 show the profiles of a few ellipsoidal coefficients for two spherical symmetries (see previous paragraph), through four distinct field shimming steps, denoted as start shim, intermediate shim 1, intermediate shim 2 and end shim.
The measurement files were obtained, using Matlab, from four field developments in spherical harmonics, on the basis of four actual measurements over a sphere having a radius r=125 mm, in four distinct shimming steps on a magnet (in this specific case, a MRI apparatus called G-Scan, manufactured by Esaote S.p.A.).
Similar profiles are obtained for all the other coefficients (i.e. for the other symmetries), and this result proves that the algorithm can correctly follow the shimming profile as field uniformity (i.e. its ‘convergence’ to the ideal constant field over the ellipsoid) increases, and further confirms proper construction of ellipsoidal harmonics (and thence of the series of functions that represent the field development) even for orders n>3.
Ellipsoidal Expansion from an Actual Measurement over an Ellipsoid
The development of an actual measurement over an ellipsoid having dimensions a=100 mm, b=50 mm; c=130 mm will be now described, in association with a magnet as that used in the MRI apparatus G-Scan, manufactured by Esaote S.p.A., in an intermediate shimming step. This measurement is important both because it is the first expansion in ellipsoidal coefficients that is performed on actual experimental data and because it is taken as a starting point for the test that will be described in the next paragraph about the reconstruction of the magnetic field from the ellipsoidal coefficients. The coefficients are listed by spherical symmetries, like in the previous paragraph, and are compared with those resulting from a measurement over a sphere having a radius r=125 mm in the same shimming conditions.
Cosine Coefficients for Even-Even Symmetry (Ellipsoid)














p














n
1
2
3
4
5
6
















2
917
−70
/
/
/
/


4
410
−185
−0.014
/
/
/


6
166
−19
−0.2
0
/
/


8
68
−2
−0.2
0
0
/


10 
27
0
−0.4
−0.03
0.1
0.4









Cosine Coefficients for Even-Even Symmetry (Sphere)















m














l
0
2
4
6
8
10
















2
1612
6.1
/
/
/
/


4
−216
−0.04
−4.9
/
/
/


6
−367
−7.5
6.3
−0.6
/
/


8
−121
1.9
−3.8
1.7
1.2
/


10
56
1.2
2.1
1.1
0.2
0.8









Sine Coefficients for Even-Even Symmetry (Ellipsoid)














p
















n
3
4
5
6
7
8
9
10
11



















2
−11
/
/
/
/
/
/
/
/


4
/
4.7
−0.2
/
/
/
/
/
/


6
/
/
 6.9
−0.7
0
/
/
/
/


8
/
/
/
 3.1
−0.4
0.03
0  
/
/


10
/
/
/
/
1.2
−0.1
0.1
0
0.02









Sine Coefficients for Even-Even Symmetry (Sphere)














m














l
2
4
6
8
10


















2
2
/
/
/
/



4
1.2
0.03
/
/
/



6
0.7
−1.5
−1.3
/
/



8
−1.5
0.1
−0.8
0.1
/



10
−2.2
−1.8
−1.3
1.8
0.8










Cosine Coefficients for Even-Odd Symmetry (Ellipsoid)














p



















n
4
6
7
8
9
10
11
12
13
14
15
16






















2
−11.3
/
/
/
/
/
/
/
/
/
/
/


4
/
4.9
0
/
/
/
/
/
/
/
/
/


6
/
/
/
3.2
−0.2
0  
/
/
/
/
/
/


8
/
/
/
/
/
1.3
−0.1
0  
0
/
/
/


10
/
/
/
/
/
/
/
0.5
0
0
0
0









Cosine Coefficients for Even-Odd Symmetry (Sphere)














m














l
1
3
5
7
9


















2
42
/
/
/
/



4
−8.8
1.1
/
/
/



6
−5.0
−0.4
−2.3
/
/



8
−3.0
1.5
−0.5
−0.4
/



10
3.7
3.2
−0.1
1.4
−1.1










Sine Coefficients for Even-Odd Symmetry (Ellipsoid)














p





















n
5
8
9
11
12
13
14
15
16
17
18
19
20
21
























2
101
/
/
/
/
/
/
/
/
/
/
/
/
/


4
/
−0.2
127
/
/
/
/
/
/
/
/
/
/
/


6
/
/
/
0.01
−0.6
69
/
/
/
/
/
/
/
/


8
/
/
/
/
/
/
0
0
−0.2
32
/
/
/
/


10
/
/
/
/
/
/
/
/
/
0.04
0.1
14
0
0.07









Sine Coefficients for Even-Odd Symmetry (Sphere)














m














l
1
3
5
7
9


















2
52
/
/
/
/



4
−4.8
−0.06
/
/
/



6
−1.8
−0.5
−0.05
/
/



8
−0.1
0.05
−3.1
−0.3
/



10
1.6
−1.2
−2.9
0.5
−1.1










Cosine Coefficients for Odd-Odd Symmetry (Ellipsoid)














p














n
1
2
3
4
5


















1
−1259
/
/
/
/



3
−321
−2.2
/
/
/



5
3.8
−14
0
/
/



7
4.9
−4.4
0
0
/



9
1.9
−0.3
0
0
0










Cosine Coefficients for Odd-Odd Symmetry (Sphere)














m














l
1
3
5
7
9


















1
50
/
/
/
/



3
−22
2
/
/
/



5
−12
−6.3
−0.4
/
/



7
−2.5
−2.7
0.1
−0.4
/



9
1.7
1.4
−0.6
0.8
−0.1










Sine Coefficients for Odd-Odd Symmetry (Ellipsoid)














p
















n
2
3
4
5
6
7
8
9
10





1
272
/
/
/
/
/
/
/
/


3
/
476
−2
/
/
/
/
/
/


5
/
/
246
−7
0
/
/
/
/


7
/
/
/
105
−3.1
0
0
/
/


9
/
/
/
/
43
−0.7
0
0
0









Sine Coefficients for Odd-Odd Symmetry (Sphere)














m














l
1
3
5
7
9


















1
−360
/
/
/
/



3
19
−77
/
/
/



5
−13
7
6
/
/



7
14
5
0.6
−0.1
/



9
−4.5
−0.2
−4.0
0.7
0.4



1
−360
/
/
/
/



3
19
−77
/
/
/



5
−13
7
6
/
/



7
14
5
0.6
−0.1
/



9
−4.5
−0.2
−4.0
0.7
0.4










Cosine Coefficients for Odd-Even Symmetry (Ellipsoid)














p



















n
3
5
6
7
8
9
10
11
12
13
14
15





1
272
/
/
/
/
/
/
/
/
/
/
/


3
/
−2
189
/
/
/
/
/
/
/
/
/


5
/
/
/
0
−3
100
/
/
/
/
/
/


7
/
/
/
/
/
0
0
−0.6
47
/
/
/


9
/
/
/
/
/
/
/
0
21
0
0
−0.1









Cosine Coefficients for Odd-Even Symmetry (Sphere)














m














l
0
2
4
6
8


















1
−19
/
/
/
/



3
−38
−18
/
/
/



5
−6
−2
1.2
/
/



7
−2.4
−0.3
−2.1
0.7
/



9
3.8
1.1
−3.5
2.6
0.5










Sine Coefficients for Odd-Even Symmetry (Ellipsoid)














p

















n
7
10
11
13
14
15
16
17
18
19





3
2.2
/
/
/
/
/
/
/
/
/


5
/
3.9
0
/
/
/
/
/
/
/


7
/
/
/
2.1
0
0
/
/
/
/


9
/
/
/
/
/
/
0.8
0
0
0









Sine Coefficients for Odd-Even Symmetry (Sphere)















m












I
2
4
6
8














3
−5.8
/
/
/


5
1.3
−0.8
/
/


7
−0.1
−2.1
−0.8
/


9
−2.2
−0.3
−1.3
0.03









Obviously, both the total number of coefficients and the number of coefficients per each symmetry coincide, thanks to the properties of the base transformation of orthonormal functions (i.e. from spherical functions to ellipsoidal functions), as described in annex 1. Basically, although two different surfaces are considered, it is just like using two ‘dialects’ (of two neighboring regions) of one mother tongue (i.e. the same physical phenomenon).
Reconstruction of the Magnetic Field from the Ellipsoidal Harmonic Expansion
Once the quantities αnp have been determined, it is possible to reconstruct the actual magnetic field from which they were obtained over the whole 3D Cartesian grid, by using (0.3), and compare the result obtained with the experimental value. It shall be noted that the αnp considered for field reconstruction are not those expressed in ppm and normalized by the γnp as set out in the previous sub-paragraphs. The average differences, expressed in ppm, for the four measurements simulated and described in the previous paragraphs, relating to simulated measurement and actual measurement, are set out below. For proper interpretation of these somewhat ‘unexpected’ results, these values were compared with those obtained considering field reconstruction, for the case of the sphere, from the same expansions in spherical coefficients that were used above.















measurement/difference
ellipsoid (ppm)
sphere (ppm)




















Start shim
3
2.5



Intermediate shim 1
2
1.8



Intermediate shim 2
1.4
1.5



End shim
0.7
1



Measurement at point 4.3.3
2.1
1.9










As shown in this table, field reconstruction from ellipsoidal coefficients has a degree of accuracy that is consistent with the results obtained in the sphere case and substantially reflects one of the characteristics of the numerical technique (Gauss) that was used to determine the coefficients, regardless of its being applied in the ‘sphere’ or ‘ellipsoid’ case. The following table shows, for each measurement, the standard deviation from the mean calculated from the observed values, contained in measurement files, both for the sphere case and for the actual measurement performed over the ellipsoid, as a data ‘scattering’ parameter:














measurement
Standard deviation



(sphere)
(MHz)









Start shim
  2 · 10−2



Intermediate shim 1
8.3 · 10−3



Intermediate shim 2
1.9 · 10−3



End shim
1.3 · 10−4



Measurement
9.6 · 10−3



(ellipsoid)










The data in this table shows that the Gauss method that was used for numerical determination of either spherical or ellipsoidal harmonic expansion coefficients is particularly sensitive to distribution (‘scattering’) of data around the mean value, although we can state that this dependency is “weak” and in any case the precision and the stability shown by the algorithm allows its use for carrying out a real shimming of the magnetic field. Thus, from a comparison with the sphere case, field reconstruction by using ellipsoidal coefficients may be considered ‘acceptable’ according to the above mentioned parameters.
Sampling Point Reduction Test
The numerical results of the algorithm, as described in the previous paragraphs, refer to a measurement file containing 576 experimental points whereat the magnetic field was sampled. These points are divided into 12 ‘ellipses’ lying on the ellipsoid, each being formed by 48 experimental points. With the final purpose of optimizing the duration of each measurement, an actual measurement was performed with half as many sampling points, i.e. 288 points divided into 12 ‘ellipses’ each having 24 points. The following tables define the ellipsoidal expansion deriving from such measurement, which has to be compared with that obtained in the previous paragraph, relating to the ellipsoidal expansion from an actual measurement over an ellipsoid:
Cosine Coefficients for Even-Even Symmetry














p














n
1
2
3
4
5
6
















2
957
−70
/
/
/
/


4
426
−182
−0.014
/
/
/


6
171
−19
−0.2
0
/
/


8
70
−2
−0.2
0
0
/


10
28
0
−0.4
−0.03
0.1
0.4









Sine Coefficients for Even-Even Symmetry














p
















n
3
4
5
6
7
8
9
10
11



















2
−10
/
/
/
/
/
/
/
/


4
/
5.7
−0.2
/
/
/
/
/
/


6
/
/
7.2
−0.7
0
/
/
/
/


8
/
/
/
3.2
−0.4
0.03
0
/
/


10
/
/
/
/
1.2
−0.1
0.1
0
0.02









Cosine Coefficients for Even-Odd Symmetry














p



















n
4
6
7
8
9
10
11
12
13
14
15
16






















2
−10.1
/
/
/
/
/
/
/
/
/
/
/


4
/
5.3
0
/
/
/
/
/
/
/
/
/


6
/
/
/
3.4
−0.2
0
/
/
/
/
/
/


8
/
/
/
/
/
1.4
−0.1
0
0
/
/
/


10
/
/
/
/
/
/
/
0.5
0
0
0
0









Sine Coefficients for Even-Odd Symmetry














p





















n
5
8
9
11
12
13
14
15
16
17
18
19
20
21
























2
105
/
/
/
/
/
/
/
/
/
/
/
/
/


4
/
−0.2
131
/
/
/
/
/
/
/
/
/
/
/


6
/
/
/
0.01
−0.6
71
/
/
/
/
/
/
/
/


8
/
/
/
/
/
/
0
0
−0.2
33
/
/
/
/


10
/
/
/
/
/
/
/
/
/
0.01
0.1
14
0
0.07









Cosine Coefficients for Odd-Odd Symmetry















p














n
1
2
3
4
5
6
















1
−1216
/
/
/
/
/


3
−311
−2.2
/
/
/
/


5
5.8
−14
0
/
/
/


7
5.2
−4.4
0
0
/
/


9
2
−0.3
0
0.014
0
/









Sine Coefficients for Odd-Odd Symmetry














p


















n
2
3
4
5
6
7
8
9
10
11
12





1
286
/
/
/
/
/
/
/
/
/
/


3
/
494
−2
/
/
/
/
/
/
/
/


5
/
/
255
−7
0
/
/
/
/
/
/


7
/
/
/
108
−3.1
0
0
/
/
/
/


9
/
/
/
/
44
−0.7
0
0
0
/
/









Cosine Coefficients for Odd-Even Symmetry














p






















n
3
5
6
7
8
9
10
11
12
13
14
15
16
17
18





1
286
/
/
/
/
/
/
/
/
/
/
/
/
/
/


3
/
−2
195
/
/
/
/
/
/
/
/
/
/
/
/


5
/
/
/
0
−3
104
/
/
/
/
/
/
/
/
/


7
/
/
/
/
/
0
0
−0.6
49
/
/
/
/
/
/


9
/
/
/
/
/
/
/
0
22
0
0
−0.1
/
/
/









Sine Coefficients for Odd-Even Symmetry














p





















n
7
10
11
13
14
15
16
17
18
19
20
21
22
23





3
2.6
/
/
/
/
/
/
/
/
/
/
/
/
/


5
/
4.2
0
/
/
/
/
/
/
/
/
/
/
/


7
/
/
/
2.2
0
0
/
/
/
/
/
/
/
/


9
/
/
/
/
/
/
0.8
0
0
0
/
/
/
/









The expansion obtained thereby is consistent with that described in the previous paragraph, which was obtained by using twice as many sampling points. This result, which is ‘expected’ on the basis of the theory of ellipsoidal harmonics and their representation in spherical harmonics (see The Theory of Spherical and Ellipsoidal Harmonics, Hobson E. W., Cambridge University Press, 1996), confirms the possibility of performing measurements with half as many sampling points, thence in half as long time. A further confirmation of the validity of this result may be obtained by comparing the maximum error committed in both cases, in field reconstruction as described in the previous paragraph, which is shown in the following table:














measurement/difference
ppm



















Measurement with 576 points
3



Measurement with 288 points
3.2










Eventually, the resulting average difference is consistent with that is obtained with a more intensive magnetic field sampling, which further confirms the possibility of reducing the number of experimental points on which the magnetic field is sampled.
Indeed in the described algorithm it is also possible to consider a 3D grid of points which is formed by 11 “ellipses” positioned on the ellipsoid and defining a total of 266 sampled points which grid shows a degree of precision which is consistent with the case of 288 points.
Algorithm Execution Times
The time to determine the coefficients by the algorithm as described above is in any case, i.e. for any order N of expansion development, below 30 seconds in a computer having an average hardware configuration.
The above description showed the results of a set of tests on the algorithm for expansion of the magnetic field in ellipsoidal harmonics. The resulting numerical properties and data generally confirm the validity and correctness of the algorithm and are always consistent with those obtained in the more familiar case of the sphere. This algorithm may be used as a future ellipsoidal shimming instrument. Besides allowing integration of the software with the general coefficient calculation program, the algorithm described as an application of the inventive method allows to determine new specially designed magnet structures, adapted to contain a homogeneous magnetic field which permeates an ellipsoidal volume of space and is delimited by an ideal delimiting ellipsoid and is shimmed over an ellipsoid.
Annex 1
Solution of Laplace's Equation with Boundary Conditions over an Ellipsoid
1. Definition of Ellipsoidal Coordinates
The ellipsoidal coordinates may be associated to the Cartesian coordinates in various manners. They are defined with respect to the fundamental ellipsoid, whose center is in the origin with semiaxes a, b, c, described in equation:




  
    
      
        
          
            
              x
              2
            
            
              a
              2
            
          
          +
          
            
              y
              2
            
            
              b
              2
            
          
          +
          
            
              z
              2
            
            
              c
              2
            
          
        
        =
        1
      
    
    
      
        (
        0.9
        )
      
    
  




A set of confocal quadrics may be defined from this reference ellipsoid:




  
    
      
        
          
            
              x
              2
            
            
              
                a
                2
              
              +
              
                θ
                2
              
            
          
          +
          
            
              y
              2
            
            
              
                b
                2
              
              +
              
                θ
                2
              
            
          
          +
          
            
              z
              2
            
            
              
                c
                2
              
              +
              
                θ
                2
              
            
          
        
        =
        1
      
    
    
      
        (
        0.10
        )
      
    
  




and by introducing the parameters

λ2=a2+θ2

h2=a2−b2

k2=a2−c2  (0.11)

the equation (0.10) may be rewritten as follows:




  
    
      
        
          
            
              x
              2
            
            
              λ
              2
            
          
          +
          
            
              y
              2
            
            
              
                λ
                2
              
              -
              
                h
                2
              
            
          
          +
          
            
              z
              2
            
            
              
                λ
                2
              
              -
              
                k
                2
              
            
          
        
        =
        1
      
    
    
      
        (
        0.12
        )
      
    
  




the advantage of (0.12) is that the family of confocal quadrics is directly related to the fundamental ellipsoid and is wholly characterized by two parameters h and k.
By setting a point p(x,y,z) the equation (0.12) has three roots λ1,λ2,λ3 which satisfy the chain of inequalities:

λ21>k2>λ22>h2>λ32

the set of values (λ1,λ2,λ3) is orthogonal and is called set of ellipsoidal coordinates.
The cartesian coordinates are related to the ellipsoidal coordinates as defined above by the following transformations:




  
    
      
        
          
            x
            2
          
          =
          
            
              
                λ
                1
                2
              
              ⁢
              
                λ
                2
                2
              
              ⁢
              
                λ
                3
                2
              
            
            
              
                h
                2
              
              ⁢
              
                k
                2
              
            
          
        
        ⁢
        
          

        
        ⁢
        
          
            y
            2
          
          =
          
            
              
                (
                
                  
                    λ
                    1
                    2
                  
                  -
                  
                    h
                    2
                  
                
                )
              
              ⁢
              
                (
                
                  
                    λ
                    2
                    2
                  
                  -
                  
                    h
                    2
                  
                
                )
              
              ⁢
              
                (
                
                  
                    h
                    2
                  
                  -
                  
                    λ
                    3
                    2
                  
                
                )
              
            
            
              
                h
                2
              
              ⁡
              
                (
                
                  
                    k
                    2
                  
                  -
                  
                    h
                    2
                  
                
                )
              
            
          
        
        ⁢
        
          

        
        ⁢
        
          
            z
            2
          
          =
          
            
              
                (
                
                  
                    λ
                    1
                    2
                  
                  -
                  
                    k
                    2
                  
                
                )
              
              ⁢
              
                (
                
                  
                    k
                    2
                  
                  -
                  
                    λ
                    2
                    2
                  
                
                )
              
              ⁢
              
                (
                
                  
                    k
                    2
                  
                  -
                  
                    λ
                    3
                    2
                  
                
                )
              
            
            
              
                k
                2
              
              ⁡
              
                (
                
                  
                    k
                    2
                  
                  -
                  
                    h
                    2
                  
                
                )
              
            
          
        
      
    
    
      
        (
        0.13
        )
      
    
  




Finally, if the following transformation is introduced:



  
    
      cos
      ⁢
      
        
      
      ⁢
      θ
    
    =
    
      
        
          λ
          2
        
        ⁢
        
          λ
          3
        
      
      hk
    
  




  
    
      sin
      ⁢
      
        
      
      ⁢
      θ
      ⁢
      
        
      
      ⁢
      cos
      ⁢
      
        
      
      ⁢
      φ
    
    =
    
      
        
          
            
              λ
              2
              2
            
            -
            
              h
              2
            
          
        
        ⁢
        
          
            
              h
              2
            
            -
            
              λ
              3
              2
            
          
        
      
      
        h
        ⁢
        
          
            
              k
              2
            
            -
            
              h
              2
            
          
        
      
    
  




  
    
      sin
      ⁢
      
        
      
      ⁢
      θ
      ⁢
      
        
      
      ⁢
      sin
      ⁢
      
        
      
      ⁢
      φ
    
    =
    
      
        
          
            
              k
              2
            
            -
            
              λ
              2
              2
            
          
        
        ⁢
        
          
            
              k
              2
            
            -
            
              λ
              3
              2
            
          
        
      
      
        k
        ⁢
        
          
            
              k
              2
            
            -
            
              h
              2
            
          
        
      
    
  



where 0≦θ≦π and 0≦φ<2π, the following will be obtained:

x=λi cos θ

y=√{square root over (λ21−h2)} sin θ cos φ

z=√{square root over (λ21−k2)} sin θsin φ

where the analogy shows that λ1 may be reinterpreted as a sort of “radius” of the ellipsoid. Paragraph 4 will confirm this analogy between spherical and ellipsoidal coordinates.
2. Laplace's Equation in Ellipsoidal Coordinates
In the set of ellipsoidal coordinates as defined in paragraph 1, the Laplace's equation

∇2V=0  (0.14)

may be rewritten as follows




  
    
      
        
          
            ∑
            
              
                
                  
                    i
                    =
                    1
                  
                
              
              
                
                  
                    j
                    <
                    k
                  
                
              
              
                
                  
                    j
                    ≠
                    i
                  
                
              
              
                
                  
                    k
                    ≠
                    i
                  
                
              
            
            3
          
          ⁢
          
            
              (
              
                
                  λ
                  j
                  2
                
                -
                
                  λ
                  k
                  2
                
              
              )
            
            ⁢
            
              
            
            ⁢
            
              
                
                  (
                  
                    
                      λ
                      i
                      2
                    
                    -
                    
                      h
                      2
                    
                  
                  )
                
                ⁢
                
                  (
                  
                    
                      λ
                      i
                      2
                    
                    -
                    
                      k
                      2
                    
                  
                  )
                
              
            
            ⁢
            
              ∂
              
                ∂
                
                  λ
                  i
                
              
            
            ⁢
            
              (
              
                
                  
                    
                      (
                      
                        
                          λ
                          i
                          2
                        
                        -
                        
                          h
                          2
                        
                      
                      )
                    
                    ⁢
                    
                      (
                      
                        
                          λ
                          i
                          2
                        
                        -
                        
                          k
                          2
                        
                      
                      )
                    
                  
                
                ⁢
                
                  
                    ∂
                    V
                  
                  
                    ∂
                    
                      λ
                      i
                    
                  
                
              
              )
            
          
        
        =
        0
      
    
    
      
        (
        0.15
        )
      
    
  




If the equation has to be solved by separations of variables of the following type:




  
    V
    ⁡
    
      (
      
        
          λ
          1
        
        ,
        
          λ
          2
        
        ,
        
          λ
          3
        
      
      )
    
  
  =
  
    
      ∏
      
        i
        =
        1
      
      3
    
    ⁢
    
      
    
    ⁢
    
      
        X
        i
      
      ⁡
      
        (
        
          λ
          i
        
        )
      
    
  




then the equation (0.15) may be separated into three differential equations as follows:




  
    
      
        
          
            
              (
              
                
                  λ
                  i
                  2
                
                -
                
                  h
                  2
                
              
              )
            
            ⁢
            
              (
              
                
                  λ
                  i
                  2
                
                -
                
                  k
                  2
                
              
              )
            
            ⁢
            
              
                
                  d
                  2
                
                ⁢
                
                  X
                  i
                
              
              
                d
                
                  λ
                  i
                  2
                
              
            
          
          +
          
            
              
                λ
                i
              
              ⁡
              
                (
                
                  
                    2
                    ⁢
                    
                      
                    
                    ⁢
                    
                      λ
                      i
                      2
                    
                  
                  -
                  
                    k
                    2
                  
                  -
                  
                    h
                    2
                  
                
                )
              
            
            ⁢
            
              
                d
                
                  X
                  i
                
              
              
                d
                
                  λ
                  i
                
              
            
          
          +
          
            
              (
              
                K
                -
                
                  H
                  ⁢
                  
                    
                  
                  ⁢
                  
                    λ
                    i
                    2
                  
                
              
              )
            
            ⁢
            
              X
              i
            
          
        
        =
        0
      
    
    
      
        (
        0.16
        )
      
    
  




which contain one ellipsoidal coordinate at a time. These equations are known as Lamé equations. The parameters H and K may be selected in such a manner that a solution to the equation (0.16) may have the following general form:

Enp(λ)=ψ(λ)P(λ)  (0.17)

where P is a polynomial in λ2 and ψ is as follows:

ψu,v,w(λ)=λu√{square root over (|λ2−h2|)}v√{square root over (|λ2−k2|)}w  (0.18)

with u, v,w that can be either 0 or 1.
The function defined in the equation (0.17) is known as Lamé function (or ellipsoidal harmonic) of the first kind, where the index n denotes the highest degree of λ and p can vary from 1 to 2n+1. As defined in the equation (0.18), there are four different types of Lamé functions of the first kind, depending on the values of u,v,w, which are denoted by K, L, M and N. More specifically:
1. u=v=w=0→ψ=1 said Knp(λ) with P(λ) of degree n.
2. u=1 v=1 w=0→ψ=√{square root over (|λ2−h2|)} said Lnp(λ) with P(λ) of degree n−1.
3. u=0 v=0 w=1→ψ=√{square root over (|λ2−k2|)} said Mnp(λ) with P(λ) of degree n−1.
4. u=v=w=1→ψ=λ√{square root over (|λ2−k2|)}√{square root over (|λ2−h2|)} said Nnp(λ) with P(λ) of degree n−2.
A Lamé function of the second kind can be also defined, because a solution to the Laplace's equation as follows:

V(λ1, λ2, λ3)=Enp(λ1)Enp(λ2)Enp(λ3)  (0.19)

is not appropriate to describe the potential at large distances, as it diverges for λ1→∞.
Lamé functions of the second kind are defined from Lamé functions of the first kind, as follows:




  
    
      
        
          
            F
            n
            p
          
          ⁡
          
            (
            
              λ
              1
            
            )
          
        
        =
        
          
            (
            
              
                2
                ⁢
                n
              
              +
              1
            
            )
          
          ⁢
          
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                
                )
              
            
            ·
            
              
                ∫
                
                  λ
                  1
                
                ∞
              
              ⁢
              
                
                  d
                  
                    
                  
                  ⁢
                  u
                
                
                  
                    
                      (
                      
                        
                          E
                          n
                          p
                        
                        ⁡
                        
                          (
                          u
                          )
                        
                      
                      )
                    
                    2
                  
                  ⁢
                  
                    
                      
                        (
                        
                          
                            u
                            2
                          
                          -
                          
                            k
                            2
                          
                        
                        )
                      
                      ⁢
                      
                        (
                        
                          
                            u
                            2
                          
                          -
                          
                            h
                            2
                          
                        
                        )
                      
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.20
        )
      
    
  




so that Fnp(λ1)→0 for λ1→∞.
Therefore, generally, once the index n has been set and said σ=n/2, when n is even or σ=n/2 when n is odd, there will be:
σ+1 functions of type K with p=1 . . . σ+1;
n−σ functions of type L with p=σ+2 . . . n+1;
n−σ functions of type N with p=n+2 . . . 2n−σ+1;
σ functions of type N with p=2n−σ+2 . . . 2n+1;
Paragraph 8 will explain in greater detail the form of Lamé functions, and will show explicit calculations for certain orders.
3. Solution of the Laplace'S Equation in Ellipsoidal Harmonics
As a result of what has been defined in paragraphs 1 and 2, the solution of the Laplace's equation may be now written in terms of ellipsoidal harmonic expansion, as follows:




  
    
      
        
          
            V
            ⁡
            
              (
              
                
                  λ
                  1
                
                ,
                
                  λ
                  2
                
                ,
                
                  λ
                  3
                
              
              )
            
          
          =
          
            
              ∑
              
                n
                =
                0
              
              ∞
            
            ⁢
            
              
                ∑
                
                  p
                  =
                  1
                
                
                  
                    2
                    ⁢
                    n
                  
                  +
                  1
                
              
              ⁢
              
                
                  α
                  np
                
                ⁢
                
                  
                    
                      
                        E
                        n
                        p
                      
                      ⁡
                      
                        (
                        
                          λ
                          1
                        
                        )
                      
                    
                    
                      
                        E
                        n
                        p
                      
                      ⁡
                      
                        (
                        
                          λ
                          1
                          ref
                        
                        )
                      
                    
                  
                  ·
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        2
                      
                      )
                    
                  
                
                ⁢
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      3
                    
                    )
                  
                
              
            
          
        
        ⁢
        
          

        
        ⁢
        
          
            for
            ⁢
            
              
            
            ⁢
            
              λ
              1
            
          
          ≤
          
            
              λ
              1
              ref
            
            ⁢
            
              
            
            ⁢
            and
          
        
      
    
    
      
        (
        0.21
        )
      
    
  
  
    
      
        
          V
          ⁡
          
            (
            
              
                λ
                1
              
              ,
              
                λ
                2
              
              ,
              
                λ
                3
              
            
            )
          
        
        =
        
          
            ∑
            
              n
              =
              0
            
            ∞
          
          ⁢
          
            
              ∑
              
                p
                =
                1
              
              
                
                  2
                  ⁢
                  n
                
                +
                1
              
            
            ⁢
            
              
                α
                np
              
              ⁢
              
                
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        1
                      
                      )
                    
                  
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        1
                        ref
                      
                      )
                    
                  
                
                ·
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      2
                    
                    )
                  
                
              
              ⁢
              
                
                  E
                  n
                  p
                
                ⁡
                
                  (
                  
                    λ
                    3
                  
                  )
                
              
            
          
        
      
    
    
      
        (
        0.22
        )
      
    
  




for λ1≧λ1ref, where αnp has been introduced, representing the ellipsoidal harmonic expansion coefficients. Over the ellipsoid λ1=λ1ref, the two previous expressions are identical, hence the potential is a continuous function all over the space.
4. Analogy between Ellipsoidal and Spherical Harmonics
A strong analogy exists between the spherical harmonics and the ellipsoidal harmonics, the former typically having indexes (l, m) and the latter having, as shown above, indexes (n, p). For a given l=n, there are (21+1) spherical harmonics and an identical number of ellipsoidal harmonics. Also, each spherical harmonic may be rewritten in terms of a development of (finite) sets of ellipsoidal harmonics of the following type:

Plm(cos θ)cos(mφ)=ΣαE(λ2)E(λ3)

and the same applies for sine, where a denotes appropriate constants. Finally, as mentioned in paragraphs 1 and 2, λ1 substantially defines the ‘radius’ of the ellipsoid and governs its profile at the origin and infinity, thereby completing the analogy between the two coordinate systems and the two family of harmonics.
5. Passage from Ellipsoidal Harmonics to Spherical Harmonics
By virtue of the strict analogy between ellipsoidal harmonics and spherical harmonics, it may be useful to find a possible transformation which allows to map the coefficients αnp into coefficients of a spherical harmonic expansion over a given ellipsoid-specific sphere, known as Brillouin sphere. Paragraph 7 discusses the properties of the Brillouin sphere, and its use for the above purposes, in greater detail.
The Lamé functions of the first kind prove to satisfy the following relation:




  
    
      
        
          
            ∫
            E
            
              
            
          
          ⁢
          
            
              ∫
              
                λ
                1
              
              
                
              
            
            ⁢
            
              
                
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        2
                      
                      )
                    
                  
                  ⁢
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        3
                      
                      )
                    
                  
                  ⁢
                  
                    
                      E
                      
                        n
                        ′
                      
                      
                        p
                        ′
                      
                    
                    ⁡
                    
                      (
                      
                        λ
                        2
                      
                      )
                    
                  
                  ⁢
                  
                    
                      E
                      
                        n
                        ′
                      
                      
                        p
                        ′
                      
                    
                    ⁡
                    
                      (
                      
                        λ
                        3
                      
                      )
                    
                  
                
                
                  
                    
                      (
                      
                        
                          λ
                          1
                          2
                        
                        -
                        
                          λ
                          3
                          2
                        
                      
                      )
                    
                    ⁢
                    
                      (
                      
                        
                          λ
                          1
                          2
                        
                        -
                        
                          λ
                          2
                          2
                        
                      
                      )
                    
                  
                
              
              ⁢
              
                
              
              ⁢
              
                d
                S
              
            
          
        
        =
        0
      
    
    
      
        (
        0.23
        )
      
    
  




if n≠n′ and p≠p′, otherwise the integral (0.23) is equal to a certain value, that can be denoted by γnp the integration is over the surface (ellipsoid) at λ1=cost. Now, if (0.23) is applied to both sides of (0.21), the coefficients of ellipsoid harmonic expansion may be extrapolated. Therefore the following may be obtained:




  
    
      
        
          α
          np
        
        =
        
          
            1
            
              γ
              n
              p
            
          
          ⁢
          
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                  ref
                
                )
              
            
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                
                )
              
            
          
          ⁢
          
            
              ∫
              E
              
                
              
            
            ⁢
            
              
                ∫
                
                  λ
                  1
                
                
                  
                
              
              ⁢
              
                
                  
                    
                      V
                      ⁡
                      
                        (
                        
                          
                            λ
                            1
                          
                          ,
                          
                            λ
                            2
                          
                          ,
                          
                            λ
                            3
                          
                        
                        )
                      
                    
                    
                      
                        
                          (
                          
                            
                              λ
                              1
                              2
                            
                            -
                            
                              λ
                              2
                              2
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              λ
                              1
                              2
                            
                            -
                            
                              λ
                              3
                              2
                            
                          
                          )
                        
                      
                    
                  
                  ·
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        2
                      
                      )
                    
                  
                
                ⁢
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      3
                    
                    )
                  
                
                ⁢
                
                  
                
                ⁢
                
                  d
                  S
                
              
            
          
        
      
    
    
      
        (
        0.24
        )
      
    
  




Thus, once the potential over the surface is known, it is possible to calculate the coefficients of ellipsoidal harmonic expansion.
Once these coefficients have been determined, it may be convenient is to express (map) them in terms of coefficients of spherical harmonic development of the potential determined over the Brillouin sphere, and corresponding to:




  
    
      
        
          V
          ⁡
          
            (
            
              r
              ,
              θ
              ,
              φ
            
            )
          
        
        =
        
          
            ∑
            
              l
              =
              0
            
            ∞
          
          ⁢
          
            
              ∑
              
                m
                =
                0
              
              l
            
            ⁢
            
              
                r
                l
              
              ⁢
              
                
                  
                    P
                    
                      l
                      ⁢
                      
                        
                      
                      ⁢
                      m
                    
                  
                  ⁡
                  
                    (
                    
                      cos
                      ⁢
                      
                        
                      
                      ⁢
                      θ
                    
                    )
                  
                
                ⁡
                
                  [
                  
                    
                      
                        a
                        
                          l
                          ⁢
                          
                            
                          
                          ⁢
                          m
                        
                      
                      ⁢
                      
                        cos
                        ⁡
                        
                          (
                          
                            m
                            ⁢
                            
                              
                            
                            ⁢
                            φ
                          
                          )
                        
                      
                    
                    +
                    
                      
                        b
                        
                          l
                          ⁢
                          
                            
                          
                          ⁢
                          m
                        
                      
                      ⁢
                      
                        sin
                        ⁡
                        
                          (
                          
                            m
                            ⁢
                            
                              
                            
                            ⁢
                            φ
                          
                          )
                        
                      
                    
                  
                  ]
                
              
            
          
        
      
    
    
      
        (
        0.25
        )
      
    
  




By replacing the second member of (0.24) with (0.25), the coefficients αnp may be expressed as a linear combination of coefficients alm and blm:




  
    
      
        
          α
          np
        
        =
        
          
            ∑
            
              l
              =
              0
            
            ∞
          
          ⁢
          
            
              ∑
              
                m
                =
                0
              
              l
            
            ⁢
            
              (
              
                
                  
                    A
                    np
                    
                      l
                      ⁢
                      
                        
                      
                      ⁢
                      m
                    
                  
                  ⁢
                  
                    a
                    
                      l
                      ⁢
                      
                        
                      
                      ⁢
                      m
                    
                  
                
                +
                
                  
                    B
                    np
                    
                      l
                      ⁢
                      
                        
                      
                      ⁢
                      m
                    
                  
                  ⁢
                  
                    b
                    
                      l
                      ⁢
                      
                        
                      
                      ⁢
                      m
                    
                  
                
              
              )
            
          
        
      
    
    
      
        (
        0.26
        )
      
    
  




where, the following quantities have been introduced:




  
    
      
        
          
            A
            np
            
              l
              ⁢
              
                
              
              ⁢
              m
            
          
          =
          
            
              1
              
                γ
                n
                p
              
            
            ⁢
            
              
                
                  E
                  n
                  p
                
                ⁡
                
                  (
                  
                    λ
                    1
                    ref
                  
                  )
                
              
              
                
                  E
                  n
                  p
                
                ⁡
                
                  (
                  
                    λ
                    1
                  
                  )
                
              
            
            ⁢
            
              
                ∫
                E
                
                  
                
              
              ⁢
              
                
                  ∫
                  
                    λ
                    1
                  
                  
                    
                  
                
                ⁢
                
                  
                    
                      
                        
                          r
                          l
                        
                        ⁢
                        
                          
                            P
                            
                              l
                              ⁢
                              
                                
                              
                              ⁢
                              m
                            
                          
                          ⁡
                          
                            (
                            
                              cos
                              ⁢
                              
                                
                              
                              ⁢
                              θ
                            
                            )
                          
                        
                        ⁢
                        
                          cos
                          ⁡
                          
                            (
                            
                              m
                              ⁢
                              
                                
                              
                              ⁢
                              φ
                            
                            )
                          
                        
                      
                      
                        
                          
                            (
                            
                              
                                λ
                                1
                                2
                              
                              -
                              
                                λ
                                2
                                2
                              
                            
                            )
                          
                          ⁢
                          
                            (
                            
                              
                                λ
                                1
                                2
                              
                              -
                              
                                λ
                                3
                                2
                              
                            
                            )
                          
                        
                      
                    
                    ·
                    
                      
                        E
                        n
                        p
                      
                      ⁡
                      
                        (
                        
                          λ
                          2
                        
                        )
                      
                    
                  
                  ⁢
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        3
                      
                      )
                    
                  
                  ⁢
                  
                    
                  
                  ⁢
                  
                    d
                    S
                  
                
              
            
          
        
        ⁢
        
          

        
        ⁢
        and
      
    
    
      
        (
        0.27
        )
      
    
  
  
    
      
        
          B
          np
          
            l
            ⁢
            
              
            
            ⁢
            m
          
        
        =
        
          
            1
            
              γ
              n
              p
            
          
          ⁢
          
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                  ref
                
                )
              
            
            
              
                E
                n
                p
              
              ⁡
              
                (
                
                  λ
                  1
                
                )
              
            
          
          ⁢
          
            
              ∫
              E
              
                
              
            
            ⁢
            
              
                ∫
                
                  λ
                  1
                
                
                  
                
              
              ⁢
              
                
                  
                    
                      
                        r
                        l
                      
                      ⁢
                      
                        
                          P
                          
                            l
                            ⁢
                            
                              
                            
                            ⁢
                            m
                          
                        
                        ⁡
                        
                          (
                          
                            cos
                            ⁢
                            
                              
                            
                            ⁢
                            θ
                          
                          )
                        
                      
                      ⁢
                      
                        sin
                        ⁡
                        
                          (
                          
                            m
                            ⁢
                            
                              
                            
                            ⁢
                            φ
                          
                          )
                        
                      
                    
                    
                      
                        
                          (
                          
                            
                              λ
                              1
                              2
                            
                            -
                            
                              λ
                              2
                              2
                            
                          
                          )
                        
                        ⁢
                        
                          (
                          
                            
                              λ
                              1
                              2
                            
                            -
                            
                              λ
                              3
                              2
                            
                          
                          )
                        
                      
                    
                  
                  ·
                  
                    
                      E
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        λ
                        2
                      
                      )
                    
                  
                
                ⁢
                
                  
                    E
                    n
                    p
                  
                  ⁡
                  
                    (
                    
                      λ
                      3
                    
                    )
                  
                
                ⁢
                
                  
                
                ⁢
                
                  d
                  S
                
              
            
          
        
      
    
    
      
        (
        0.28
        )
      
    
  




Once the coefficients αnp are known and the coefficients Anplm and Bnplm have been calculated, it is possible to invert (0.26) and determine the coefficients alm and blm, which contain more familiar field uniformity information.
This procedure, which is in principle highly complex, is dramatically simplified thanks to the symmetry properties of the transformation coefficients Anplm and Bnplm, as will be discussed in the next paragraph.
6. Symmetry Properties of the Transformation Coefficients Anplm and Bnplm 
The relation of the coefficients αnp to the coefficients αlm and blm may be considerably simplified by accounting for the symmetry properties of the transformation coefficients Anplm and Bnplm. It appears that, depending on the values of n and p, the relation (0.26) is considerably simplified. More specifically, two large families of relations may be defined: with n being even and n being odd.
When n is even, the following will be obtained:




  
    
      
        
          
            a
            ⁢
            
              )
            
            ⁢
            
              
            
            ⁢
            for
            ⁢
            
              
            
            ⁢
            1
          
          ≤
          p
          ≤
          
            
              n
              +
              2
            
            2
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  A
                  np
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
                ⁢
                
                  a
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.29
        )
      
    
  
  
    
      
        
          
            b
            ⁢
            
              )
            
            ⁢
            
              
            
            ⁢
            for
            ⁢
            
              
            
            ⁢
            
              
                n
                +
                4
              
              2
            
          
          ≤
          p
          ≤
          
            n
            +
            1
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  B
                  np
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
                ⁢
                
                  b
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.30
        )
      
    
  
  
    
      
        
          
            
              c
              ⁢
              
                )
              
              ⁢
              
                
              
              ⁢
              for
              ⁢
              
                
              
              ⁢
              n
            
            +
            2
          
          ≤
          p
          ≤
          
            
              
                3
                ⁢
                n
              
              +
              2
            
            2
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  A
                  np
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
                ⁢
                
                  a
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.31
        )
      
    
  
  
    
      
        
          
            
              d
              )
            
            ⁢
            
              
            
            ⁢
            for
            ⁢
            
              
            
            ⁢
            
              
                
                  3
                  ⁢
                  n
                
                +
                4
              
              2
            
          
          ≤
          p
          ≤
          
            
              2
              ⁢
              n
            
            +
            1
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  B
                  np
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
                ⁢
                
                  b
                  
                    
                      2
                      ⁢
                      l
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
              
            
          
        
        ⁢
        
          

        
        ⁢
        
          
            When
            ⁢
            
              
            
            ⁢
            n
            ⁢
            
              
            
            ⁢
            is
            ⁢
            
              
            
            ⁢
            odd
          
          ,
          
            the
            ⁢
            
              
            
            ⁢
            following
            ⁢
            
              
            
            ⁢
            will
            ⁢
            
              
            
            ⁢
            be
            ⁢
            
              
            
            ⁢
            obtained
            ⁢
            
              :
            
          
        
      
    
    
      
        (
        0.32
        )
      
    
  
  
    
      
        
          
            
              a
              )
            
            ⁢
            
              
            
            ⁢
            for
            ⁢
            
              
            
            ⁢
            1
          
          ≤
          p
          ≤
          
            
              n
              +
              1
            
            2
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  A
                  np
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
                ⁢
                
                  a
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.33
        )
      
    
  
  
    
      
        
          
            
              b
              )
            
            ⁢
            
              
            
            ⁢
            for
            ⁢
            
              
            
            ⁢
            
              
                n
                +
                3
              
              2
            
          
          ≤
          p
          ≤
          
            n
            +
            1
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  B
                  np
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
                ⁢
                
                  b
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      
                        2
                        ⁢
                        m
                      
                      +
                      1
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.34
        )
      
    
  
  
    
      
        
          
            
              
                c
                )
              
              ⁢
              
                
              
              ⁢
              for
              ⁢
              
                
              
              ⁢
              n
            
            +
            2
          
          ≤
          p
          ≤
          
            
              
                3
                ⁢
                n
              
              +
              3
            
            2
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  A
                  np
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
                ⁢
                
                  a
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.35
        )
      
    
  
  
    
      
        
          
            
              d
              )
            
            ⁢
            
              
            
            ⁢
            for
            ⁢
            
              
            
            ⁢
            
              
                
                  3
                  ⁢
                  n
                
                +
                5
              
              2
            
          
          ≤
          p
          ≤
          
            
              2
              ⁢
              n
            
            +
            1
          
        
        ⁢
        
          

        
        ⁢
        
          
            α
            np
          
          =
          
            
              ∑
              l
            
            ⁢
            
              
                ∑
                m
              
              ⁢
              
                
                  B
                  np
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
                ⁢
                
                  b
                  
                    
                      
                        2
                        ⁢
                        l
                      
                      +
                      1
                    
                    ,
                    
                      2
                      ⁢
                      m
                    
                  
                
              
            
          
        
      
    
    
      
        (
        0.36
        )
      
    
  




7. LamÉ Functions and Construction thereof
As mentioned in paragraph 2, once the index n has been set and said σ=n/2, when n is even or σ=(n−1)/2 when n is odd, there will be:
σ+1 functions of type K with p=1 . . . σ+1;
n−σ functions of type L with p=σ+2 . . . n+1;
n−σ functions of type N with p=n+2 . . . 2n−σ+1;
σ functions of type N with p=2n−σ+2 . . . 2n+1;
These functions are n-order polynomials of the following type (for K):

Knp(x)=a0pxn+a1pxn−2+a2pxn−4+  (0.37)

where the coefficients aip are typically functions of h, k and of order n.
Assuming, for example, that n=4 is set, σ=2 will follow, which will therefore generate 3 K functions, two L functions, two M functions and two N functions.
9 Functions will thus be Obtained:

K41,K42, K43, L44, L45, M46, M47, N48, N49

The K functions are explicitly written as follows:




  
    
      
        
          
            
              K
              4
              1
            
            ⁡
            
              (
              x
              )
            
          
          =
          
            
              x
              4
            
            +
            
              
                
                  α
                  ⁡
                  
                    (
                    
                      
                        δ
                        1
                      
                      -
                      16
                    
                    )
                  
                
                14
              
              ⁢
              
                x
                2
              
            
            -
            
              β
              ⁢
              
                
                  (
                  
                    
                      δ
                      1
                    
                    -
                    16
                  
                  )
                
                
                  7
                  ⁢
                  
                    
                  
                  ⁢
                  
                    δ
                    1
                  
                
              
            
          
        
        ⁢
        
          

        
        ⁢
        
          
            
              K
              4
              2
            
            ⁡
            
              (
              x
              )
            
          
          =
          
            
              x
              4
            
            +
            
              
                
                  α
                  ⁡
                  
                    (
                    
                      
                        δ
                        2
                      
                      -
                      16
                    
                    )
                  
                
                14
              
              ⁢
              
                x
                2
              
            
            -
            
              β
              ⁢
              
                
                  (
                  
                    
                      δ
                      2
                    
                    -
                    16
                  
                  )
                
                
                  7
                  ⁢
                  
                    
                  
                  ⁢
                  
                    δ
                    2
                  
                
              
            
          
        
        ⁢
        
          

        
        ⁢
        
          
            
              K
              4
              3
            
            ⁡
            
              (
              x
              )
            
          
          =
          
            
              x
              4
            
            +
            
              
                
                  α
                  ⁡
                  
                    (
                    
                      
                        δ
                        3
                      
                      -
                      16
                    
                    )
                  
                
                14
              
              ⁢
              
                x
                2
              
            
            -
            
              β
              ⁢
              
                
                  (
                  
                    
                      δ
                      3
                    
                    -
                    16
                  
                  )
                
                
                  7
                  ⁢
                  
                    
                  
                  ⁢
                  
                    δ
                    3
                  
                
              
            
          
        
      
    
    
      
        (
        0.38
        )
      
    
  




where α=h2+k2 and β=h2k2 therefore they depend on the geometrical dimensions of the ellipsoid and δi roots of the third degree polynomial:

α2δ3−20α2δ2+(208β+64α2)δ−640β=0  (0.39)

These roots can be proved to be always real.
In a much similar manner, explicit expressions may be determined for the other functions and for any degree n. Therefore, once the order n and the geometrical dimensions of the ellipsoid have been defined, a set of ellipsoidal harmonics suitable for the specific case may be uniquely defined.
8. Conclusions
The considerations of the previous paragraph show that the Laplace's equation may be in principle solved in an analytical-numerical manner, by using as boundary conditions the field value over a non revolving ellipsoid. Furthermore, as shown in paragraphs 5 and 6, the ellipsoidal coefficients may be transformed into the more familiar spherical coefficients for a field expansion over a characteristic sphere (Brillouin sphere). In addition to providing more direct physical information about field homogeneity, this procedure allows to calculate the shimming ‘solutions’ in a standard manner, i.e. considering a sphere, even though the surface being shimmed is actually an ellipsoid.

## Claims

1. A method for determining construction parameters of magnet structures designed to generate magnetic fields in predetermined volumes of space, comprising the steps of:
a) defining a predetermined volume of space in which a magnetic field is to be generated;
b) defining a nominal strength and a profile of a nominal desired magnetic field in said predetermined volume of space;
c) mathematically defining the nominal desired magnetic field on a surface of and/or in said predetermined volume of space by calculating a series of coefficients using a polynomial expansion of a magnetic field-describing function; and
d) determining a size, a geometry and a relative position in space of a magnet structure designed to generate said nominal desired magnetic field, with respect to the predetermined volume of space in and on which the nominal desired magnetic field is defined;
the magnetic field being expressed by the coefficients of the polynomial expansion in ellipsoidal harmonics;
wherein the calculation of the coefficients of the polynomial expansion in ellipsoidal harmonics is performed with the following steps;
measuring three semiaxes of the ideal ellipsoid delimiting the predetermined volume having an order of approximation N;
constructing Lamé functions from dimensions of the semiaxes up to an order of N−1;
calculating normalization coefficients γnp according to the function





  
    
      γ
      n
      p
    
    =
    
      8
      ⁢
      
        
          ∑
          
            i
            =
            1
          
          N
        
        ⁢
        
          
            ω
            i
            C
          
          ⁢
          
            
              ω
              i
              L
            
            ⁡
            
              (
              
                
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
                -
                
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
              
              )
            
          
        
      
    
  
  ,




where Fnp(xiL) and Gnp(xiC) are related to the ellipsoidal harmonics of degree n and order p as determined in Gauss-Chebychev abscissas xiCand Gauss-Legendre abscissas xiL, and where ωiC and ωiL represent respective weights; and
calculating expansion coefficients αnp by using the function





  
    
      α
      n
      p
    
    =
    
      
        2
        
          γ
          n
          p
        
      
      ⁢
      
        
          ∑
          
            i
            =
            1
          
          
            N
            /
            2
          
        
        ⁢
        
          
            ∑
            
              j
              =
              1
            
            N
          
          ⁢
          
            
              ω
              i
              C
            
            ⁢
            
              ω
              i
              L
            
            ⁢
            
              B
              ⁡
              
                (
                
                  
                    x
                    i
                    C
                  
                  ,
                  
                    x
                    i
                    L
                  
                
                )
              
            
            ⁢
            
              (
              
                
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
                -
                
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
              
              )
            
          
        
      
    
  
  ,




where N represents the order of approximation and B represents the magnetic field expressed in ppm and normalized with respect to an assumed value of the magnetic field at the center of the ellipsoid.

2. A method as claimed in claim 1, wherein the magnet structure is designed with an inhomogeneity tolerance threshold of up to thousands of parts per million (ppm) and after the magnet structure is constructed, the magnet structure is subjected to a shimming correction process.

3. A method as claimed in claim 2, wherein the shimming is sequentially repeated several times.

4. A method as claimed in claim 2, wherein in the shimming process an inhomogeneity of the magnetic field within the predetermined volume of space is reduced below a tolerance threshold of up to tens of ppm peak to peak, the shimming process comprising the steps of:
measuring a magnetic field generated in said predetermined volume of space at several predetermined points in a grid of predetermined measuring points arranged in said predetermined volume of space delimited by the ideal closed surface;
comparing the measured magnetic field with the nominal desired magnetic field within said predetermined volume of space; and
determining a value of a magnetic moment of magnetic shims and a position thereof over one or more shim positioning grids having a predetermined position and an orientation relative to said predetermined volume of space.

5. A method as claimed in claim 4, wherein the shimming is sequentially repeated several times.

6. A method as claimed in claim 5, wherein the shim positioning grid is configured as at least one of a cartesian grid, an annular grid formed by intersection of concentric circles and radiuses, and an ellipsoidal grid formed by a number of ellipses, one inside another, intersecting with radiuses or adjacent parallel lines.

7. A method as claimed in claim 4, wherein the shim positioning grid is configured as at least one of a cartesian grid, an annular grid formed by intersection of concentric circles and radiuses, and an ellipsoidal grid formed by a number of ellipses, one inside another, intersecting with radiuses or adjacent parallel lines.

8. A method as claimed in claim 7, wherein the ellipses of the ellipsoidal grid are concentric or confocal.

9. A method as claimed in claim 1, wherein the ideal surface that delimits the predetermined volume of space corresponds to an ellipsoid enveloping a limb, an organ, a body part under examination, a body under examination, or an anatomic region under examination and having a size that provides a highest filling ratio in the volume of space by the limb, the organ, the body under examination, the body part under examination, or the anatomic region under examination.

10. A method as claimed in claim 1, wherein the magnetic field is a static magnetic field of an MRI apparatus, which permeates a predetermined part of the volume that is defined by a cavity designed to receive a limb, an organ, a body part under examination, a body under examination, or an anatomic region under examination.

11. A shimming method for correcting magnetic fields in predetermined volumes of space, comprising the following steps:
defining a predetermined volume of space, which is permeated by the magnetic field, by defining an ideal closed delimiting surface;
measuring a magnetic field generated in said predetermined volume of space at several predetermined points in a grid of predetermined measuring points arranged in said predetermined volume of space delimited by the ideal closed surface and/or along said ideal closed surface;
comparing the measured magnetic field with a nominal desired magnetic field within said predetermined volume of space and/or over the ideal closed delimiting surface; and
determining a value of magnetic moment of magnetic shims and a position thereof over one or more shim positioning grids having a predetermined position and an orientation relative to said predetermined volume of space,
the magnetic field being expressed by a polynomial expansion in ellipsoidal harmonics;
wherein the calculation of the coefficients of the polynomial expansion in ellipsoidal harmonics is performed with the following steps:
measuring three semiaxes of the ideal ellipsoid delimiting the predetermined volume having an order of approximation N;
constructing Lamé functions from dimensions of the semiaxes up to an order of N−1;
calculating normalization coefficients γnp according to the function





  
    
      γ
      n
      p
    
    =
    
      8
      ⁢
      
        
          ∑
          
            i
            =
            1
          
          N
        
        ⁢
        
          
            ω
            i
            C
          
          ⁢
          
            
              ω
              i
              L
            
            ⁡
            
              (
              
                
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
                -
                
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
              
              )
            
          
        
      
    
  
  ,




where Fnp(xiL) and Gnp(xiC) are related to the ellipsoidal harmonics of degree n and order p, as determined in Gauss-Chebychev abscissas xiC and Gauss-Legendre abscissas xiL and where ωiC and ωiL represent respective weights; and
calculating expansion coefficients αiL by using the function





  
    
      α
      n
      p
    
    =
    
      
        2
        
          γ
          n
          p
        
      
      ⁢
      
        
          ∑
          
            i
            =
            1
          
          
            N
            /
            2
          
        
        ⁢
        
          
            ∑
            
              j
              =
              1
            
            N
          
          ⁢
          
            
              ω
              i
              C
            
            ⁢
            
              ω
              i
              L
            
            ⁢
            
              B
              ⁡
              
                (
                
                  
                    x
                    i
                    C
                  
                  ,
                  
                    x
                    i
                    L
                  
                
                )
              
            
            ⁢
            
              (
              
                
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
                -
                
                  
                    
                      G
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        L
                      
                      )
                    
                  
                  ⁢
                  
                    
                      F
                      n
                      p
                    
                    ⁡
                    
                      (
                      
                        x
                        i
                        C
                      
                      )
                    
                  
                
              
              )
            
          
        
      
    
  
  ,




where N represents the order of approximation and B represents the magnetic field expressed in ppm and normalized with respect to an assumed value of the magnetic field at the center of the ellipsoid.

12. A method as claimed in claim 11, wherein the shimming is sequentially repeated several times.

13. A method as claimed in claim 11, wherein the shim positioning grid is configured as at least one of a cartesian grid, an annular grid formed by intersection of concentric circles and radiuses, and an ellipsoidal grid formed by a number of ellipses, one inside another, intersecting with radiuses or adjacent parallel lines.

14. A method as claimed in claim 13, wherein the ellipses of the ellipsoidal grid are concentric or confocal.