The assembling of the global matrix and the right hand side vector is done similarly to the two-dimensional method. The entire region is processed element wise. In each tetrahedron the element matrix is calculated. The local matrix entries are added to the global entries or are multiplied by the known coefficient (obtained from the Dirichlet boundary condition) and added to the right hand side vector element depending on the global index , by which it is distinguished between Dirichlet or unknown node coefficients. The superscript indicates that the indexes are local element indexes, which are converted to global indexes (without superscript ) by the connectivity array. In the three-dimensional case the connectivity array has four row entries for the four element nodes.
For the assembling of the element matrix it is assumed that the permittivity is a scalar and element wise constant. This assumption is not an essential restriction. It allows to change from one element to the next. Thus inhomogeneous materials (with respect to ) can be easily simulated. The regions, in which changes substantially, must be discretized in appropriately small elements. Using the expressions for the gradient of the barycentric coordinates (4.71) to (4.74) the element matrix for the Laplace term is given by
(4.80) | ||
(4.81) | ||
(4.82) | ||
(4.83) | ||
(4.84) | ||
(4.85) | ||
(4.86) | ||
(4.87) | ||
(4.88) | ||
(4.89) |
If inhomogeneous Neumann boundary conditions are used, the corresponding element matrix is depicted in Section C.2.1, which is also used for the quasi magnetostatic case. Thus the magnetic scalar potential and the permeability are used instead and . Additionally it is assumed that the permeability is a scalar and element wise constant ( ).