Abstract
Introduction: Transcranial magnetic stimulation (TMS) is a major noninvasive neurostimulation method in which a coil placed near the head employs electromagnetic induction to produce electric fields and currents within the brain. To predict the actual site of stimulation, numerical simulation of the electric fields within the head using high-resolution subject-specific head models is required. A TMS modeling software toolkit has been developed based on the boundary element fast multipole method (BEM-FMM), which has several advantages over conventional finite element method (FEM) solvers.
Objective: To extend the applicability of the BEM-FMM TMS simulation toolkit to head models whose meshing scheme produces a single mesh for every unique tissue instead of producing a single mesh for every unique tissue/tissue boundary.
Method: The MIDA model of the IT’IS Foundation, Switzerland, comprises 115 high-resolution tissue models in the form that the BEM-FMM toolkit is modified to accept. The updated BEM-FMM toolkit is tested using this head model.
Results: The BEM-FMM toolkit has been successfully modified to accept head models consisting of one unique mesh per unique tissue while still supporting its initial model format of one unique mesh per boundary between two specific tissues. Performance impacts occur in the preprocessing phase only, meaning that the charge computation method performs equally well regardless of model format.
You have full access to this open access chapter, Download chapter PDF
Similar content being viewed by others
Keyword
- Boundary Element Fast Multipole Method
- Non-nested meshes
- Meshes with coincident faces
- Brain stimulation
- Transcranial Magnetic Stimulation
- Numerical Modeling
- MATLAB modeling
- Biological applications
1 Introduction
Transcranial magnetic stimulation (TMS) is a noninvasive neurostimulation method wherein a coil placed near the subject’s head induces electric currents within the brain [7, 10, 13]. However, intermediate tissues between the coil and the cortex strongly affect the induced electric field (and thus the induced current). Numerical simulation of the interaction between the primary electric field and tissues of the head is necessary to predict the behavior of the total induced electric field and find the ultimate activation site(s). Further, wide intersubject variations cause the actual fields to deviate strongly from expected fields calculated using a generic head model. To minimize deviation between the simulated and actual fields, the simulated fields must be calculated using an accurate, high-resolution, subject-specific head model.
The TMS toolkit (complete computational code and supporting documentation) available for academic use at the Dropbox repository [2] is one such TMS simulator, which utilizes the boundary element fast multipole method (BEM-FMM) described in [4, 9]. The toolkit is written for MATLAB R2019a and has dependencies on the Image Processing Toolbox, Partial Differential Equations Toolbox/Antenna Toolbox, and Statistics and Machine Learning Toolbox. Its core FMM method is that of [3], included with permission in the redistributable software package.
This toolkit enables users to simulate TMS behavior using predefined or custom coil CAD models and subject-specific head models. These head models consist of a set of nested 3D triangular meshes, where each mesh marks the boundary between two tissues with different electrical properties (e.g., one mesh follows the skin/skull boundary, and another mesh follows the gray matter (GM)/white matter (WM) boundary) [5]. Because the BEM-FMM algorithm operates directly in terms of induced charges on these interfaces [8], it is robust against several common mesh defects that would hinder conventional volumetric finite element method (FEM) simulations, including intersecting meshes. The BEM-FMM algorithm further supports computation of the net electric field at locations arbitrarily close to tissue interfaces, where FEM routines cannot provide field resolution that exceeds the resolution of the underlying volumetric mesh.
Despite the BEM-FMM algorithm’s robustness against common mesh defects, the current implementation of the software toolkit is applicable only to one specific meshing scheme: one in which each mesh represents a boundary between exactly two tissues. This is the standard output format of the SimNIBS v2.1 pipeline [11, 12, 14,15,16,17] in particular, and it produces meshes that are layered one inside the other. For example, the boundary between the skull and cerebrospinal fluid (CSF) completely surrounds and encloses the boundary between the CSF and gray matter (GM), which in turn completely surrounds and encloses the boundary between gray matter and white matter (WM). The goal of this exercise was to add support for a second meshing scheme, in which each mesh represents the entire outer boundary of a single tissue. One model that employs this meshing scheme is the MIDA model, produced by the IT’IS Foundation [6]
The MIDA head model comprises 115 CAD tissue models with more than 11 M triangular facets total. The model was produced from scans of a healthy 29-year-old female volunteer. Data was compiled from several medical imaging methods, including MRI, MRA, and DTI. These diverse imaging methods ensured that high-contrast images of most tissues existed in at least one of the image sets and image resolution approached 500 μm. Special care was taken to obtain high-contrast images of nerve tissue and vasculature. The entire data set was segmented independently by three experts using both manual and automated segmentation techniques, and their individual segmentations were combined to produce a highly accurate final segmentation. A triangulation algorithm was then applied to the resulting voxel model to extract triangular mesh surfaces for every tissue [6].
Several selections of model tissues are shown in Figs. 1, 2, 3, 4, 5, 6, 7, 8, 9 and 10. The mesh processing software used is open-source MeshLab v2016.12 [1]. Some characteristics of the model relevant to the task of enabling its use in the BEM-FMM toolkit are as follows:
-
(a)
Adjacent meshes typically have coincident triangular facets at their interfaces. Observe, for example, the GM, CSF, and vasculature in Figs. 4, 5 and 6.
-
(b)
Some meshes comprise multiple manifold surfaces. The CSF in particular includes a very large number of closed surfaces scattered throughout the cranial volume (see Figs. 5 and 10).
2 Methods
2.1 Mesh Preprocessing
Because the MIDA model’s tissue meshes are not nested in general (i.e., a given MIDA tissue mesh explicitly segments every boundary between that mesh and any other tissue), adjacent tissue meshes each contain their own copies of the facets that form the border between them. When two adjacent tissue meshes are loaded simultaneously, their shared border comprises two sets of coincident facets, one set contributed by each tissue mesh. These coincident facets necessarily share coincident centroids, which in turn create singularities that invalidate simulation results. Figure 11 depicts this case for three hypothetical meshes, Object 1, Object 2, and Object 3. Though Object 1 and Object 2 both segment their shared boundary, Object 3 does not explicitly segment its boundary with Objects 1 and 2 for simplicity. Every mesh is assigned a default exterior conductivity derived from manual inspection of the surrounding tissues.
The function knnsearch of MATLAB’s Statistics and Machine Learning Toolbox is first used to pair facets that have coincident centroids. One facet of each pair is designated as the facet to be kept, and the other is designated as the facet to be deleted. The outer conductivity of the facet to be kept is set equal to the inner conductivity of the facet to be deleted, and associated contrast information is updated for the facet to be kept. After this process has been completed for all coincident facet pairs, all information related to the facets to be deleted (e.g., centroid, area, connectivity) is removed, and any now-unreferenced vertices are cleared from the list of vertices (and face connectivity information is updated as appropriate).
3 Results
The final test setup modeled a TMS configuration intended to target the motor hand area of the precentral gyrus (the hand knob area, [18]) of the MIDA model. The coil model used was a generic figure-eight coil with circular cross-sectional wire, as shown in Fig. 12. The coil was approximated by 16,000 elementary current segments driven by time-varying current \( \frac{dI}{dt}=9.4e7\ Amperes/\mathit{\sec} \).
Preprocessing of the MIDA model for simulation using the BEM-FMM algorithm took approximately 525Â s in total. Of those 525Â s, 138Â s were required to resolve coincident facets. Of the original 11Â M facets, approximately 5.4Â M were removed, and approximately 5.6Â M remain. Table 1 lists the times associated with each preprocessing step.
The coil model was positioned above the head model according to four simple geometric rules:
-
1.
The coil’s centerline passes through a selected point on the hand knob area.
-
2.
The coil’s centerline is perpendicular to the skin surface.
-
3.
The distance from the coil to the skin surface along the coil’s centerline is 10 mm.
-
4.
The dominant field direction (the y-axis of the coil coordinate system) is approximately perpendicular to the gyral crown and associated sulcal walls of the precentral gyrus pattern at the target point.
Figure 13 shows the BEM-FMM convergence curve for this test setup after 100 GMRES iterations, and Fig. 14 shows the convergence curve for the first 15 iterations. The relative residual falls well below the threshold 10−3 within 15 iterations, indicating that 15 iterations produce results within an acceptable error margin. The test was run on a 32-core Intel® Xeon® E5-2683 v4 CPU operating at 2.1 GHz with 256 GB RAM. On this machine, the total computational time required with 5.6 M facets for 15 GMRES iterations was 373 s.
Figure 15 shows simulation results for the electric field at the gray matter/CSF interface (a, c) and the white matter/gray matter interface (b, d). Figure 15 (a, b) shows a heat map of the magnitude of the electric field at the respective surfaces, scaled in V/m. Figure 15 (c, d) shows a focality estimate of the total electric field. In these figures, small blue balls are drawn at every facet for which the total field magnitude is within the range 80% to 100% of the maximum field magnitude observed for that particular surface. We see that the naĂ¯ve geometric coil positioning rules barely stimulate the desired region at all and instead produce local maxima at distant sulci rather than the targeted motor hand area. This further reinforces the necessity of subject-specific head modeling for TMS applications.
Figures 16, 18 and 20 depict cross sections of the tissue meshes coregistered with T1 MRI data for the MIDA subject. The planes of these cross sections pass through the point on the white matter surface where the maximum E-field magnitude occurs. Pink spheres are drawn at the center of every WM facet that experiences a field with magnitude within 80–100% of the maximum E-field magnitude on this surface. Figures 17 and 19 show contour plots of the electric field magnitude in the immediate vicinity (i.e., ±10 mm) of the maximum field locations of Figs. 16 and 18, respectively.
4 Conclusion
The BEM-FMM TMS modeling toolkit has been made compatible with a previously unsupported head mesh scheme, in which each mesh corresponds to one tissue’s entire outer surface. The modifications were tested using the MIDA head model, which employs the newly supported mesh scheme. Simulation was executed successfully with the MIDA model, achieving convergence within 15 GMRES iterations. The performance penalty associated with the new mesh format occurs solely in the preprocessing stage, and there is little to no effect on field calculation performance. The toolkit is now applicable to a wider range of head models and is more robust against models whose meshes have coincident facets in general.
References
Cignoni P, Callieri M, Corsini M, Dellepiane M, Ganovelli F, Ranzuglia G. (2008). MeshLab: an open-source mesh processing tool. Sixth Eurographics Italian Chapter Conference (pp. 129–136).
Dropbox Repository (2019, November). TMS Modeling Package v1.1 Fall 2019. Online: https://www.dropbox.com/sh/0s0tl30a74wevr3/AAAEGu70k9Fx72hEkfdx3qfAa?dl=0.
Gimbutas Z, Greengard L, Magland J, Rachh M, Rokhlin V. (2019). fmm3D documentation. Release 0.1.0. Online: https://github.com/flatironinstitute/FMM3D.
Htet, A. T., Saturnino, G. B., Burnham, E. H., Noetscher, G., Nummenmaa, A., & Makarov, S. N. (2019a). Comparative performance of the finite element method and the boundary element fast multipole method for problems mimicking transcranial magnetic stimulation (TMS). Journal of Neural Engineering, 16, 1–13. https://doi.org/10.1088/1741-2552/aafbb9.
Htet, A. T., Burnham, E. H., Noetscher, G. M., Pham, D. N., Nummenmaa, A., & Makarov, S. N. (2019b). Collection of CAD human head models for electromagnetic simulations and their applications. Biomedical Physics & Engineering Express, 6(5), 1–13. https://doi.org/10.1088/2057-1976/ab4c76.
Iacono, M. I., Neufeld, E., Akinnagbe, E., Bower, K., Wolf, J., Vogiatzis Oikonomidis, I., et al. (2015). MIDA: A multimodal imaging-based detailed anatomical model of the human head and neck. PLoS One, 10(4), e0124126. https://doi.org/10.1371/journal.pone.0124126.
Kobayashi, M., & Pascual-Leone, A. (2003). Transcranial magnetic stimulation in neurology. Lancet Neurology, 2(3), 145–156. PMID: 12849236.
Makarov, S. N., Noetscher, G. M., & Nazarian, A. (2015). Low-frequency electromagnetic modeling for electrical and biological systems using MATLAB (pp. 648). New York: Wiley. ISBN-10: 1119052564.
Makarov, S. N., Noetscher, G. M., Raij, T., & Nummenmaa, A. (2018). A quasi-static boundary element approach with fast multipole acceleration for high-resolution bioelectromagnetic models. IEEE Transactions on Biomedical Engineering, 65(12), 2675–2683. https://doi.org/10.1109/TBME.2018.2813261.
McMullen D. (2017, November 11). NIMH non-invasive brain stimulation E-Field modeling workshop. Online: https://www.nimh.nih.gov/news/events/2017/brainstim/nimh-non-invasive-brain-stimulation-e-field-modeling-workshop.shtml.
Nielsen, J. D., Madsen, K. H., Puonti, O., Siebner, H. R., Bauer, C., Madsen, C. G., Saturnino, G. B., & Thielscher, A. (2018). Automatic skull segmentation from MR images for realistic volume conductor models of the head: Assessment of the state-of-the-art. NeuroImage, 174, 587–598. https://doi.org/10.1016/j.neuroimage.2018.03.001.
Opitz, A., Paulus, W., Will, S., Antunes, A., & Thielscher, A. (2015). Determinants of the electric field during transcranial direct current stimulation. NeuroImage, 109, 140–150. https://doi.org/10.1016/j.neuroimage.2015.01.033.
Rossi, S., Hallett, M., Rossini, P. M., Pascual-Leone, A., & Safety of TMS Consensus Group. (2009 Dec). Safety, ethical considerations, and application guidelines for the use of transcranial magnetic stimulation in clinical practice and research. Clinical Neurophysiology, 120(12), 2008–2039. https://doi.org/10.1016/j.clinph.2009.08.016.
Thielscher, A., Antunes, A., & Saturnino, G. B. (2015). Field modeling for transcranial magnetic stimulation: A useful tool to understand the physiological effects of TMS? Conference Proceedings: Annual International Conference of the IEEE Engineering in Medicine and Biology Society, 222–225. https://doi.org/10.1109/EMBC.2015.7318340.
Saturnino, G. B., Puonti, O., Nielsen, J. D., Antonenko, D., Madsen, K. H., & Thielscher, A. (2019a). SimNIBS 2.1: A comprehensive pipeline for individualized electric field modelling for transcranial brain stimulation. In S. Makarov, G. Noetscher, & M. Horner (Eds.), Brain and human body modeling. New York: Springer. ISBN 9783030212926.
Saturnino, G. B., Madsen, K. H., & Thielscher, A. (2019b). Efficient electric field simulations for transcranial brain stimulation. bioRxiv, 541409. https://doi.org/10.1101/541409.
Saturnino, G. B., Madsen, K. H., & Thielscher, A. (2019c Nov 6). Electric field simulations for transcranial brain stimulation using FEM: An efficient implementation and error analysis. Journal of Neural Engineering, 16(6), 066032. https://doi.org/10.1088/1741-2552/ab41ba.
Yousry, T. A., Schmid, U. D., Alkadhi, H., Schmidt, D., Peraud, A., Buettner, A., et al. (1997). Localization of the motor hand area to a knob on the precentral gyrus.A new landmark. Brain, 120, 141e57. https://doi.org/10.1093/brain/120.1.141.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Open Access This chapter is licensed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license and indicate if changes were made.
The images or other third party material in this chapter are included in the chapter's Creative Commons license, unless indicated otherwise in a credit line to the material. If material is not included in the chapter's Creative Commons license and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder.
Copyright information
© 2021 The Author(s)
About this chapter
Cite this chapter
Wartman, W.A. (2021). Preprocessing General Head Models for BEM-FMM Modeling Pertinent to Brain Stimulation. In: Makarov, S.N., Noetscher, G.M., Nummenmaa, A. (eds) Brain and Human Body Modeling 2020. Springer, Cham. https://doi.org/10.1007/978-3-030-45623-8_20
Download citation
DOI: https://doi.org/10.1007/978-3-030-45623-8_20
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-45622-1
Online ISBN: 978-3-030-45623-8
eBook Packages: Biomedical and Life SciencesBiomedical and Life Sciences (R0)