AP07_4-5.vp 1 Introduction A novel obesity treatment method [1–3] requires a system for measuring stomach volume intended to control on-de- mand switching of a special gastric pacemaker. The crucial purpose of this is to reduce the power consumption of the originally tried, continuously operating implant. For various technological, physiological and medical reasons, many com- mon methods of distance or extension measurement cannot be applied. The main limitations of this task are power con- sumption and the conductive, chemically aggressive working medium on the stomach wall. Mechanical stresses should also be considered. The use of strain gauges is almost impossible, because large planar structures would need to be safely sewed to a certain area of the stomach wall. This is rejected by surgeons as physiologically impossible. Furthermore relative elongations of the stomach can be also large as 100 %, de- pending on location [4]. Ultrasound had been tested before our attempts, because some standard medical probes were available, but the changing speed of sound with the changing composition of the stomach content or of other things in the environment called for a technique that was less dependent on the actual parameters of the medium, and less power de- manding [4]. As a promising solution, the induction principle was adopted [5]. Low power can be achieved by intermittent operation, and at low frequencies (of the order of several kHz) even the conductive medium is proved not to bias the mea- surement by means of eddy currents. The presence of ferro- magnetic materials can cause problems, but such materials are not normally eaten, and when placed outside the body they should not influence the measurement significantly. At least they should not influence switching the stimulation on and off. Magnetic measurements are unfortunately directionally dependent, so only the use of multi-axial probes and trans- mitters can ensure precise position evaluation. This is a similar question as in the case of magnetic tracking [6], but what we need here is just information about the distance between the transmitter(s) and receiver(s). The direction is useless for this application, though for certain configurations it has to be determined anyway. Though the data for tracking in certain configurations should be enough from the mathe- matical point of view, there are regions of low resolution in which the error is high (Fig. 5). The magnetic dipole by which we can represent the induc- tion coil is described by its magnitude M, its position in the Cartesian coordinate system x, y, z and then by its orientation given by the angles � – the azimuth and � - the elevation (Fig. 1). All these parameters should be calculated from the field measurements in order to determine the distance of the di- pole (transmitter) from the receivers. This obviously needs multiple sensors, if we do not have any information about the orientation of the dipole with regard to the sensors. We usually know the size of the moment, but five parameters still remain. 76 © Czech Technical University Publishing House http://ctn.cvut.cz/ap/ Acta Polytechnica Vol. 47 No. 4–5/2007 Inductive Contactless Distance Measurement Intended for a Gastric Electrical Implant J. Tomek For a gastric electrical stimulation project we are developing a system for on-demand switching according to the volume or elongation of the stomach wall. The system is to be implanted into the human abdomen, which limits the utilization of many possible solutions and types of sensors. Magnetic induction has been agreed as the most suitable principle, despite its direction dependency and the need of multi-axial and multiple probes for precision measurements. Possible configurations are discussed as well as the complexity of the necessary electronics and the implantation itself. For detecting food consumption, perfect precision is fortunately not necessary, but a certain compromise will still be necessary for the final system. A simple two-coil system – a transmitter and receiver and a system with a three-axial coil – have already been realized. The first system has already been successfully tested in-vivo on dogs by our US colleagues. However, if the implantation is badly performed, and the coils are completely out of axis, the system cannot sense relative changes in volume properly. The three-axial sensor presented here eliminates these problems. More complex arrangements emerging from magnetic tracking are discussed, because laboratory studies of stomach movements may require them. Keywords: contactless distance measurements, magnetic induction, magnetic tracking, on-demand gastric electrical stimulation, obesity, implantable devices. Fig. 1: Description of a magnetic dipole (its orientation is given by angles � – the azimuth and � – the elevation) The magnetic induction created by the dipole is described by the Biot-Savart law – Eq. (1). This can be written in the form of Eq. (2) when we want the Cartesian coordinate interpretation. B r r( ) � � � � � � � � � 0 5 34 3 M r r M r , (1) B M zx r zy r z r r � � � � � � � � � 0 5 5 2 5 34 3 3 3 1 ; ; . (2) Or we can describe it by the components of the vector of magnetic induction B in the spherical coordinate system – Eqs. (3) and (4). Br � 2 107 3 M r cos �, (3) Bs � 1 107 3 M r sin �. (4) The fact that the magnetic induction decreases with the third power of distance limits these measurements usually to relatively small ranges, because of the need for a wide dynamic range of the sensing electronics. However, this decreases the errors in distance estimation caused by mis- alignment errors. We need at least five independent measurements of the vector of magnetic induction B to calculate the five unknowns, and usually more to decrease the measurement errors. These measurements are usually made using three-axial sensors, thus at least two of them at known locations are needed. Practical experience shows that a much higher number of receivers are needed. Usually even multi-axial transmitters are used to multiply the acquired data when successively driving the individual transmitting coils whose mutual orien- tation is known. 2 Methods The basic of distance measurement solutions using the mutual induction principle is to have just two single axial probes, one transmitter and one receiver. The distance can be determined only if their orientation is fixed. For maximum signals the coils must be aligned coaxially. If they can move, and if there are misalignments either in angle or in the posi- tion of both the transmitter and the receiver, significant errors bias the measurements (see Figs. 8 and 9). A more sophisticated method is to use the three-axial sensor measuring field of a simple coil. By the simple operation of calculating of the magnitude (Mag) of the total vector out of the measured magnetic induction components in the X, Y and Z axes – symbolized by x, y and z, see Eq. (5) – we get a good estimate of the distance (Fig. 4). Up to 45° angular devi- ation of the transmitter coil (when the sensor is in the first Gaussian position) the measured signal does not decrease below 79 % (Fig. 8) and the distance determination error is not greater than 10 % [8]. Angular misalignments of the re- ceiver should ideally cause no difference in the total vector measurement. Therefore, if the precision of the measure- ments is not so crucial, this is a very good solution for the distance measurement. The electronics stays almost the same © Czech Technical University Publishing House http://ctn.cvut.cz/ap/ 77 Acta Polytechnica Vol. 47 No. 4–5/2007 Fig. 2: Magnetic induction of a dipole at a given point described by vector r Fig. 3: Schematic picture of the components of the magnetic in- duction vector for a magnetic dipole [2] Fig. 4: Graph showing regions of the same magnitudes of the to- tal vector of a dipole, i.e., isolines of the same magnitude of the total vector of the induction. The same magnitude as in the 1st Gaussian position is at half distance in the 2nd Gaussian position, in accordance with Eqs. 3. and 4 as in the basic case; there only need to be three channels or a multiplexer if the signals are strong enough and the applica- tion enables it. Mag x y z� � �2 2 2 . (5) For our application three separate channels are necessary, because the signals are extremely low and need to be detected by a synchronous detector and greatly amplified. Switching between the channels would result in significant errors. This application can still be made relatively small and dependable. To achieve far more precise distance measurements, even the transmitter should be multi-axial. This is good when we need at most two compact structures that should be stitched to the stomach wall between which we measure the distance. Unfortunately we cannot use multiple sensors or transmitters for more precise distance determination, as is done in mag- netic tracking [6] because their mutual positions cannot be ensured. However we can use them to measure more dis- tances over some area, which would improve the volume estimate. Mathematically, the two-axial transmitter should be satis- factory. For each coil driven successively or at two frequencies we measure a vector of magnetic induction and we can calcu- late the mutual position of the structures. In practice there are certain regions of low resolution (Fig. 5), but as we do not need to measure with extreme accuracy, this arrangement should be excellent for an evaluation of the elongation of the stomach and for precise sensing of its motility. The applica- tion range (mainly in research) of such an implantable system would be broad especially if the probes were small. An evaluation of the distance would require the use of some processor and appropriate firmware, or relatively com- plex hardware that would realize the methods described in [6]. These are non-iterative analytical methods; however, it will be difficult to make the necessary electronics implantable. There is one more suitable solution, which is the use of even a six-axial transmitter [7]. This method uses the princi- ple of calculating the magnitude of the total vector measured by a three-axial sensor and calculating the average of the six successive measurements. The estimated error is far below 2 % in distance determination [7], which is excellent, and the processing should be relatively simple. 3 The experiments The coils that were used had the parameters described in table 1. To increase the inductance, a ferromagnetic core (see Fig. 6) was inserted into each sensing coil. In order to measure the elongation of the stomach wall during food consumption or to detect gastric wall movement, just the simple two coil system was built at first. This was done to simplify the system and was agreed as suitable for early test- ing on the stomachs of laboratory dogs. The processing electronics was made as external with a USB interface. It was calibrated with coils placed coaxially to each other, and therefore when the coils were implanted not perfectly axially, only relative distance changes could be sensed. We unfortunately could not study the typical range of misalignments of the coils sewed to the stomach wall, so it is difficult to say whether calibration in-vivo with given amounts of water or food would ensure reliable long-term function, but anyway some successful measurements have been conducted, see [6]. However, bad implantation could result in the need for a second operation in order to re-adjust the coils to be- come as close as possible to the coaxial orientation. The errors that can occur when the transmitter or receiver is misaligned are shown in figures 8 and 9. Parallel orientations of the coils are also depicted, and these are even worse. The three-axial sensor was tested just with the laboratory equipment, because we still do not have the electronics for in-vivo testing. The coils are arranged as shown in Fig. 7. Therefore it is not an ideal sensor with concentric coils, but such a probe would be difficult to manufacture and would not have such high inductances because ferromagnetic cores could not be used. Deflections from orthogonality were measured in Helmholtz coils and are below 15°, which is 78 © Czech Technical University Publishing House http://ctn.cvut.cz/ap/ Acta Polytechnica Vol. 47 No. 4–5/2007 Fig. 5: Low resolution regions of a two-axial transmitter [6] Probe Simple Three-axial Turns (� 34 mm) 2000 1000 length 8.5 mm 5 mm diameter 2 mm 2 mm L with H11/without 13mH/1mH 3mH/0.6mH core � 1 mm 1 mm Table 1: Parameters of the coils Fig. 6: Examples of bare coils made of self-bonding copper wire and a ferromagnetic core 8 mm in length. From the right 2000 turn coil, 1000 turn coil and 500 turn coil. acceptable. There are also certain differences in the coil inductances given by slightly different areas etc. These imper- fections result in slightly different measurement errors than there would be in the case of an ideal three-axial sensor (see curves in Fig. 8) 4 Conclusion Possible configurations of transmitter(s) and receiver(s) applicable for contactless magnetic measurement of distance were discussed with reference to an application in an im- plantable gastric elongation measurement system intended for on-demand stimulation of the stomach wall. The stimula- tion is for use in obesity treatment. In order to decrease power consumption, and for other reasons like tissue adaptation to continuous stimulation, this control is required. For initial testing, we developed the simplest system with just two coils, which could even be satisfactory for detecting food consump- tion. This system had been proved by in-vivo measurements. However in the event of really bad alignment after implanta- tion it may fail to operate. Thus a three-axial probe was built to eliminate such eventualities. It should make implantation easy, as there should be good signal that is not dependent on the mutual orientation of the implanted probes. It should provide good enough precision even for gastric motility sens- ing and other possible medical research purposes. In case that there is a need for higher precision measurement of distance by the induction method, configurations with multi- -axial transmitters have been proposed. Acknowledgments The research described in this paper was supervised by Prof. P. Ripka, FEE CTU in Prague and Prof. J. Chen, VRF, VA Medical Center, Oklahoma City, USA. It has been supported by an international grant of the Ministry of Education, Youth and Sports of the Czech Republic – Programs of International Cooperation (Kontakt) No. 1P05ME756. References [1] McCallum, R. W., Sarosiel, Lin, Z., Monocure, M., USA Study Group: Preliminary Results of Gastric Electrical Stimulation on Weight Loss and Gastric Emptying in Morbidly Obese Patients – Randomized Double Blinded Trial. Neurogastroenterology and Motility. 2002;14:422. [2] Ouyang, H., Yin, J., Chen, J.: Therapeutic Potential of Gastric Electrical Stimulation for Obesity and its Possible Mechanisms: a Preliminary Canine Study. Dig Dis Sci Vol. 48 (2003), No. 4, p. 698–705. [3] Ouiang, H., Yin, J. Y., Chen, J. D. Z.: Inhibitory Effects of Chronic Gastric Electrical Stimulation on Food Intake and Weight and Their Possible Mechanisms. Dig Dis Sci Vol. 48 (2003), p. 698–705. [4] Tomek, J., Mlejnek, P., Janasek, V., Ripka, P, Chen, J. Z., Zhu, H.: Gastric Distention Sensing for Implantable Gastric Pacemaker, submitted to IEEE Trans. on Biomedi- cal Physics (2007). [5] Tomek, J., Mlejnek, P., Janasek, V., Ripka, P, Kaspar, P., Chen, J. Z.: Gastric Motility and Volume Sensing by Im- planted Magnetic Sensors. Sensor Letters. Vol . 5 (2007), No. 1 – Special issue on EMSA 2006, ISSN 1546-198X, p. 267–268. [6] Paperno, E., Keisar, P.: Three-Dimensional Tracking of Biaxial sensors, In IEEE Transactions on Magnetics, Vol. 40 (2004), No. 3, p.1530–1536. [7] Majer, A.: Distanční měření s využitím totálního vektoru magnetické indukce prostorově zkřížených cívek. In Dě- jiny staveb, (2005), p. 196–198. [8] Tomek, J., Mlejnek, P., Janasek, V., Ripka, P, Kaspar, P., Chen, J. Z.: The Precision of Gastric Motility and Volume Sensing by Implanted Magnetic Sensors, In: Eurosensors XX Proc. Göteborg, Sweden, Vol. 2 – T3C-O3, September 2006, ISBN 978-91-631-9280-7, p. 253–254. Ing. Jiří Tomek e-mail: tomekj1@fel.cvut.cz Department of Measurement Czech Technical University in Prague Technická 2 166 27 Praha, Czech Republic © Czech Technical University Publishing House http://ctn.cvut.cz/ap/ 79 Acta Polytechnica Vol. 47 No. 4–5/2007 Fig. 7: Arrangement of the coils in the three-axial sensor. Un- der the coating it forms an oval shape of acceptable dimensions Fig. 8: Angular misalignments of the transmitter, signal mea- sured for rotation from the 1st Gaussian position to the 2nd Gaussian position [8] Fig. 9: Rotation of the receiver coil. The three-axial coil is almost rotation independent – not included