Abstract
In many industrial applications, one is interested in finding an optimal layout of an object, which often leads to PDE-constrained shape optimization problems. Such problems can be approached by shape optimization methods, where a domain is altered by smooth deformation of its boundary, or by means of topology optimization methods, which in addition can alter the connectivity of the initial design. We give an overview over established topology optimization methods and focus on an approach based on the sensitivity of the cost function with respect to a topological perturbation of the domain, called the topological derivative. We illustrate a way to derive this sensitivity and discuss the additional difficulties arising in the case of a nonlinear PDE constraint. We show numerical results for the optimization of an electric motor which are obtained by a combination of two methods: a level set algorithm which is based on the topological derivative, and a shape optimization method together with a special treatment of the evolving material interface which assures accurate approximate solutions to the underlying PDE constraint as well as a smooth final design.
Access provided by CONRICYT-eBooks. Download chapter PDF
Similar content being viewed by others
1 Introduction
This chapter deals with PDE-constrained topology and shape optimization and is motivated by a concrete application from electrical engineering, namely the design optimization of an electric motor. The goal is to identify an admissible subset Ω of the design region Ωd of the motor which yields the best possible performance of the motor. The performance is measured by a functional J which is related to the smoothness of the rotation or to the torque of the motor. In shape optimization, the domain can be modified by a smooth deformation of the boundary, whereas the topology optimization methods can also alter the connectivity of the domain by, e.g., introducing new holes.
In contrast to optimal control problems, here the set of admissible controls is a set of subsets of \(\mathbb R^d\), which does not admit a vector space structure. Nevertheless, we will use the notions of derivatives of the objective functional J with respect to the control variable Ω: On the one hand, the shape derivative represents the sensitivity of a domain-dependent functional with respect to a smooth variation of the boundary of this domain whereas, on the other hand, the topological derivative is the sensitivity of the functional with respect to a topological perturbation of the set Ω, i.e., with respect to the introduction of a hole in its interior. Starting out from an initial design, these sensitivities can be used to successively update the shape and topology of the control Ω in order to reach an optimal design. In our case, the set Ω is a subset of the computational domain D representing the motor, and its boundary ∂Ω represents a material interface, e.g., the interface between a ferromagnetic region and an air region of the motor. Both the shape derivative and the topological derivative of this PDE-constrained optimization problem involve the solution to the state equation u and the solution to the adjoint equation p. In a numerical algorithm, these quantities must be computed approximately in each iteration, which is often done by a finite element method. In order to obtain accurate approximations uh, ph to the state and adjoint variable, one has to take care of the material interface between the different subdomains. This interface evolves over the iterations of the algorithm and is, in general, not aligned with the underlying finite element mesh.
This book chapter is meant to give an overview over various aspects of topology and shape optimization approaches and many details and proofs are omitted. For more details and more mathematical rigor, we refer the interested reader to [20]. The rest of this chapter is organized as follows: The design optimization problem for the electric motor, which serves as a model problem throughout this chapter, is introduced in Section 2. In Section 3, we give an overview over established topology optimization methods and demonstrate the main steps in the derivation of the topological derivative for the optimization problem at hand, which is constrained by a quasilinear PDE constraint. Section 4 deals with shape optimization and we will derive the shape derivative for our problem. In Section 5, we give an overview over possible ways to treat moving interfaces in the context of finite elements, before combining all of these techniques to an efficient design tool in Section 6, where we will also give numerical optimization results.
2 Problem Description
We consider an interior permanent magnet electric motor as depicted in Figure 1 which consists of a fixed outer part (called the stator) and a rotating inner part (the rotor). The stator contains coils where alternating electric current is induced and the rotor holds permanent magnets which are magnetized in the directions indicated in Figure 1. Both parts contain a ferromagnetic subdomain and they are separated by a thin air gap. A rotation of the rotor occurs due to the interaction between the magnetic fields produced by magnets and the electric currents in the coils. As it is common for the simulation of electric motors at constant rotation speed, we consider the setting of two-dimensional magnetostatics. There, the magnetic flux density B is given as \(\mathbf B = \mbox{curl}\left ((0,0,u)^\top \right )\) where u solves the quasilinear boundary value problem
on a circular hold-all domain D where J3 denotes the currents impressed in the coil areas and M⊥ is the perpendicular of the permanent magnetization in the magnets. Here, Ω ⊂ Ωd denotes the unknown subset of the design region that is occupied with ferromagnetic material, and the magnetic reluctivity νΩ is a nonlinear function \(\hat {\nu }\) in the ferromagnetic subdomain and a constant ν0 in the rest of the motor,
Here, Ωf consists of the fixed ferromagnetic domain \(\varOmega _f^{fix}\) outside the design region Ωd and the variable ferromagnetic subset of the design region Ω ⊂ Ωd, i.e., \(\overline {\varOmega _f} = \overline {\varOmega _f^{fix}} \cup \overline {\varOmega }\), see Figure 1. Note that, in general, the nonlinear function \(\hat {\nu }\) is not known in a closed form but is usually approximated from measured values, see [28].
The magnetic reluctivity νΩ, which is the reciprocal of the magnetic permeability μΩ, is much larger in the air subdomains compared to the ferromagnetic subdomains of the motor. Therefore, the distribution of ferromagnetic material inside the design area Ωd (i.e., the shape and topology of the unknown set Ω) influences the magnetic flux density B in Ωd and also in the rest of the motor. The magnetic flux density B inside the air gap between rotor and stator has a big impact on the behavior of the rotation of the motor. The goal of the optimization problem is to identify a subset Ω which minimizes the objective function J that is related to the smoothness of the rotation of the motor. The functional J depends on the magnetic flux density B in the air gap and will be introduced later in Section 6. The PDE-constrained design optimization problem reads
where (3b) is the weak form of boundary value problem (1) with F ∈ H−1(D) given by
Remark 1
In applications of electric motors, the functional J is usually supported only in the air gap between the rotor and the stator. Since the design areas are part of the rotor, we assume that J does not depend on Ω directly, but only via the state variable u, J = J(u) ≠ J(u, Ω). Furthermore, we introduce the reduced functional \(\mathcal J(\varOmega ) = J(u(\varOmega ))\) where u(Ω) is the solution to (3b) for given Ω.
3 Topology Optimization
In this chapter, we employ a topology optimization algorithm which is based on the topological derivative. Beside this approach, there exist a number of other approaches to topology optimization. We give an overview over the most widely used methods in Section 3.1 before coming to the derivation of the topological derivative for the problem at hand in Section 3.2.
3.1 Overview of Topology Optimization Methods
The concept of topology optimization originates from applications in mechanical engineering but has been applied to a large variety of other applications such as fluid dynamics, acoustics, or electromagnetics. This section is meant to give a brief overview over the most common methods of topology optimization. For a more detailed discussion of the single approaches, we refer the reader to the review articles [14, 29, 34] and the references therein.
The starting point of numerical topology optimization is widely considered to be the seminal paper by Bendsøe and Kikuchi [9] introducing the homogenization method for topology optimization, followed by the paper [8], where Bendsøe introduced what is now known as the Solid Isotropic Material with Penalization (SIMP) method, giving rise to the large class of density-based methods.
3.1.1 Homogenization Method
The idea of the homogenization method is to represent a domain as a periodic microstructure (usually consisting of rectangular cells like a regular quadrilateral finite element grid) and then to find the optimal layout for each cell. Each of these cells is considered to consist of material and void regions (often a rectangular hole surrounded by solid material) and the dimensions and orientations of these holes are the design variables with respect to which the optimization is performed. Finally, one ends up with a perforated design which can be interpreted as a microstructure. A black-and-white structure can be obtained by setting those cells which are mostly occupied with material to solid, and the other cells to void. The method uses several degrees of freedom for each of the cells, resulting in a large number of degrees of freedom, which is considered a significant drawback of this method. For more details on the homogenization method, we refer the reader to the monograph [1] and the references therein.
3.1.2 Density Methods
In density-based approaches to topology optimization, a design can be represented by a function ρ which takes the value 1 in areas of material and the value 0 in void areas. We remark that, in applications of mechanical engineering, if ρ is 0, the elasticity tensor vanishes and the global stiffness matrix becomes singular. Therefore, it is common practice in density-based topology optimization of mechanical structures to replace the value of 0 by a small, but positive number ρmin > 0. The idea of density-based topology optimization approaches is to relax this strict 0–1 nature of the problem by allowing the function ρ to attain any value between 0 and 1. The function ρ is called a density variable. In order to enforce a 0–1 structure of the final design, the idea of [8] is to combine this idea with a penalization of intermediate density values, i.e., to replace the density function ρ in the state equation (and only there) by a penalized version of the density, \(\tilde {\rho }(\rho ) = \rho ^p\) for some p > 1. In combination with a constraint on the volume of the arising structure, the algorithm favors the use of “black” and “white” regions, i.e., regions where ρ = 1 and ρ = 0, respectively, because intermediate values “give very little stiffness at an unreasonable cost” [8]. As remarked in [29], a constraint which limits the volume is important for this penalizing effect to appear. The method described in [8] together with the choice \(\tilde {\rho }(\rho ) = \rho ^p\) for some p > 1 became well known as the SIMP method. We remark that the method is sensitive with respect to the value of p and that good results are usually obtained by using p = 3 or by gradually increasing the parameter from p = 1 to higher values in the course of the optimization procedure [29].
While the penalization of intermediate density values yields designs with a 0–1 structure, these problems usually lack existence of a solution, a fact which often results in a mesh dependence of the optimized designs. For a detailed survey on the numerical problems resulting from the ill-posedness of such problems, we refer the reader to [30]. The most widely used approach to regularizing these ill-posed problems is by applying a filter to the density variable ρ. This means that one replaces the actual density at a point by an average over the density values in a neighborhood of a certain radius R, called the filter radius. Other approaches include a filtering of the sensitivities, adding a bound on the perimeter of the arising structure or on the gradient of the density variable ρ, see [29, 30].
A more detailed overview of density-based topology optimization methods can be found in, e.g., [10, 29].
3.1.3 Phase-Field Method
The phase-field method for topology optimization is a density-based method using a linear material interpolation, \(\tilde {\rho }(\rho ) = \rho \). A regularization is achieved by adding a term to the cost functional which approximates the total variation of the density variable. This term is a Cahn-Hilliard type functional, which itself is a weighted sum of two terms. One of these two terms causes a regularizing effect whereas the other term penalizes intermediate density values. We mention that the choices of the weighting factor between these two parts, as well as the weight of the Cahn-Hilliard type functional relative to the objective function, are often crucial for obtaining good results. The phase-field method has been applied to many topology optimization problems, see, e.g., [12, 22].
3.1.4 Level Set Methods
In the level set method [27], a material interface is represented by the zero level set of an evolving function ψ = ψ(x, t) which attains positive values in one subdomain and negative values in the other. The evolution of ψ is given by the solution to the Hamilton-Jacobi equation
where t is a pseudo-time variable and V determines the direction of the evolution. In applications from shape optimization, this vector field is given according to shape sensitivities. For a thorough overview over level set methods, we refer the reader to the review papers [29, 34].
3.1.5 Topological Derivative
The concept of the topological derivative was introduced in [17] as a means to allow for changes of the topology in the course of a classical shape optimization method. The topological derivative of a domain-dependent functional at an interior point of the domain describes its sensitivity with respect to the introduction of a hole around that point. We will deal with the topological derivative in detail in Section 3.2.
3.2 Topological Derivative for Nonlinear Magnetostatics
The topological derivative of a domain-dependent functional \(\mathcal J = \mathcal J(\varOmega )\) was introduced in a mathematically rigorous way in [31]. Given a domain Ω, an interior point x0 ∈ Ω, and a bounded domain ω which contains the origin, let ωε = x0 + εω represent the hole of radius ε around x0 and let \(\varOmega _{\varepsilon } := \varOmega \setminus \overline \omega _{\varepsilon }\) denote the perturbed domain. Then, the topological derivative of \(\mathcal J\) at the point x0 is defined as the quantity G(x0) satisfying a topological asymptotic expansion of the form
where f is a positive function which tends to zero with ε, most often f(ε) = εd with d the space dimension. In many situations such as in the context of electromagnetics, one is not interested in a perturbation of the domain where a hole is excluded from the computational domain, but rather in a local perturbation of a material coefficient. In fact, in the context of magnetostatics, introducing a “hole” in the ferromagnetic subdomain corresponds to the introduction of a different material, namely air. Then, one is interested in an expansion of the form
Here, uε is the solution to the state equation where the material coefficient is perturbed within a radius ε around x0, and u0 is the solution to the unperturbed state equation. Likewise, Jε and J0 denote the objective functional in the perturbed and unperturbed configuration, respectively. We remark that this interpretation is possible in the context of electromagnetics where air is just a different material with a different, positive material coefficient, whereas in mechanical engineering an inclusion of void would lead to a loss of the ellipticity of the perturbed bilinear form.
It can be seen from the expansion (4) that, at points x0 where G(x0) < 0, for ε > 0 small enough, the objective value for the perturbed configuration is smaller than that in the unperturbed configuration, Jε(uε) − J0(u0) < 0. Thus, in order to minimize a given functional J, it is beneficial to change the material in areas where the topological derivative is negative. Using this information for the iterative introduction of holes at the most favorable positions is one possible topology optimization algorithm using the topological derivative. A different algorithm that is based on the topological derivative is the level set algorithm introduced in [5]. As opposed to the classical level set method for shape optimization, the updates are based on the topological derivative rather than on the shape derivative. Therefore, this algorithm can also nucleate new holes in the interior. More details on the algorithm can be found in [4].
3.2.1 Preliminaries
We show the main steps in the derivation of the topological derivative according to (4) in the context of two-dimensional magnetostatics. We consider a simplified version of the PDE constraint (3b) where, in the unperturbed configuration, the entire computational domain is occupied with ferromagnetic material. Let F ∈ H−1(D) denote the sources on the right-hand side of the PDE constraint and let Ωd denote the design subdomain which we assume to be compactly contained in D ∖supp(F), i.e., Ωd ⊂⊂ D ∖supp(F). Let x0 ∈ Ωd denote a fixed interior point around which the material coefficient is perturbed. Given a smooth bounded domain ω containing the origin, which represents the shape of the material perturbation, let ωε = x0 + εω for small ε > 0. Then, the ferromagnetic subdomain in the perturbed configuration is given by \(\varOmega _{\varepsilon } = \varOmega \setminus \overline {\omega }_{\varepsilon }\). For ε > 0 and \(W \in \mathbb R^2\), we define
where \(\nu _{\varOmega _\varepsilon }\) is defined according to (2). For the rest of this chapter, we will use ω = B(0, 1) the unit disk in \(\mathbb R^2\). For more details about a possible extension of the results to ellipse-shaped inclusions, see [20].
Let ε > 0 small enough such that ωε ⊂ Ωd. Using the notation introduced above, the state equation in the unperturbed and in the perturbed setting read
respectively. Note that the right-hand sides coincide since we assumed that x0 ∈ Ωd ⊂⊂ D ∖supp(F). We will be interested in the behavior of the difference between the solution to these two boundary value problems in terms of ε. By subtracting (5) from (6), we get the boundary value problem defining the variation of the direct state \(\tilde u_\varepsilon := u_{\varepsilon } - u_0\),
Furthermore, for simplicity, we assume that the objective functional is the same in the perturbed and in the unperturbed configuration, Jε = J0 = J. Note that this is satisfied for functionals which are supported only outside the design area like in the case of electric motors, cf. Remark 1. For deriving the topological derivative, we make the following assumption on the objective function:
Assumption 1
For ε > 0, there exist\(\tilde G \in H^{-1}(D)\)and\(\delta _J \in \mathbb R\)such that
Note that this assumption is satisfied, e.g., for quadratic functionals which are supported only outside the design region.
Moreover, we introduce the following adjoint equations in the unperturbed and perturbed configurations:
Here, \(\tilde G\) is according to Assumption 1 and DT, DTε denote the Jacobians of the operators T, Tε, respectively. Also here, we introduce the difference between the solutions to the two problems above, called the variation of the adjoint state \(\tilde p_\varepsilon := p_{\varepsilon } - p_{0}\), which is the solution to
For the rest of this section, we will drop the differential dx in the volume integrals as there is no danger of confusion.
3.2.2 Derivation of Topological Derivative
By virtue of Assumption 1, choosing f(ε) = ε2, it remains to show that there exists \(G_0 \in \mathbb R\) such that \(\langle \tilde G, \tilde {u}_{\varepsilon } \rangle = \varepsilon ^2 G_0 + o(\varepsilon ^2)\). Testing the perturbed adjoint equation (9) with \(\eta = \tilde {u}_{\varepsilon }\) and exploiting the symmetry of DTε, we get
where we added the left- and right-hand side of (7) tested with η = pε. For ε > 0, \(V, W \in \mathbb R^2\), we introduce the operator
which characterizes the nonlinearity of the operator Tε. Then, we get
Noting that \(p_{\varepsilon } = p_{0} + \tilde {p}_{\varepsilon }\), and defining
we get from Assumption 1 that
In view of (4), it remains to show that there exist numbers J1, J2 such that
Then, the topological derivative is given by G(x0) = J1 + J2 + δJ.
In what follows, we will first sketch the procedure to obtain the topological derivative in the case of a linear model, i.e., in the case where the nonlinear function \(\hat {\nu }\) introduced in (2) is replaced by a constant ν1 < ν0, before discussing the additional difficulties in the case of nonlinear material behavior in the ferromagnetic subdomain.
3.2.3 Linear Case
It can be seen from the definition of the operator Sε in (11) that, in the linear case, the second term j2(ε) vanishes. Thus, we only have to consider the term
where we used (7) with \(\eta = \tilde {p}_{\varepsilon }\) and introduced \(\nu _\varepsilon (x) = \chi _{D \setminus \omega _\varepsilon }(x)\,\nu _1 +\chi _{\omega _\varepsilon }(x)\, \nu _0 \) with χS denoting the characteristic function of a set S.
Assuming enough regularity for the unperturbed direct and adjoint state, it can be seen that, for the first term in (14), we have
as ε approaches zero.
In order to treat the second term in (14), we define \(\tilde \nu (x) = \chi _{\mathbb R^2 \setminus \omega }(x) \nu _1 + \chi _{\omega }(x) \nu _0\) for \(x \in \mathbb R^2\), and introduce ε-independent approximations to boundary value problems (7) and (10). After a change of scale, we get the transmission problem defining the variation of the direct state at scale 1,
approximating (7), and the problem defining the variation of the adjoint state at scale 1,
as an approximation of (10), where \(\mathcal H\) is a suitable weighted Hilbert space over \(\mathbb R^2\). The solutions H, K are approximations to \(\tilde {u}_{\varepsilon }\) and \(\tilde {p}_{\varepsilon }\), respectively, at scale 1 and it holds
for almost every x ∈ D. An important ingredient for deriving an expansion of the form (12) is to show that these ε-independent approximations of \(\tilde {u}_{\varepsilon }\) and \(\tilde {p}_{\varepsilon }\) have a sufficiently fast decay as |x| approaches infinity. This would imply that the impact of the local variation of the material is small “far away” from the inclusion. In the case of a linear state equation, this sufficiently fast decay can be established by convolution of the right-hand side of problems (16) and (17) with the fundamental solution of the Laplace equation. Exploiting these sufficiently fast decays allows us to show that
which, by means of (16) tested with η = K, together with the term (15), yields (12) with
It can be seen from (17) that K depends linearly on ∇p0(x0) and, therefore, J1 can be represented by means of a matrix \(\mathcal M\). Finally, in the linear case we get
Here, \(\mathcal M = \nu _1 \mathcal P(\omega , \nu _0/\nu _1)\) where the matrix \(\mathcal P(\omega , \nu _0/\nu _1)\) only depends on the shape of the inclusion ω and the contrast ν0∕ν1 and is called a polarization matrix, see, e.g., [2]. Explicit formulas for these matrices are available if ω is a disk or ellipse in two space dimensions, or a ball or ellipsoid in three space dimensions, see also [2, 3]. We mention that in the case where ω is the unit disk in \(\mathbb R^2\), the polarization matrix in the linear setting reads
where I is the identity matrix. A more detailed derivation of the topological derivative in the linear setting can be found in [3].
3.2.4 Nonlinear Case
In the nonlinear case, the procedure to treat the term j1(ε) is similar. However, one big difference is that in the nonlinear setting a sufficiently fast decay of the variation of the direct state H cannot be shown by convolution, but other, more technical tools must be used, see [6, 20]. Furthermore, the term j2(ε) does not vanish here and an estimate of the type (13) has to be established. Under certain assumptions on the nonlinearity of the function \(\hat {\nu }\), this was done in [20]. If those assumptions on the ferromagnetic material are fulfilled, the result is the following:
Theorem 1 ([20])
Let ω = B(0, 1). Assume that the functional J fulfills Assumption 1 and that, for the unperturbed direct and adjoint state, it holds u0, p0 ∈ C1, β(D) for some β > 0. For\(V,W \in \mathbb R^2\), let\(\tilde S_V(x,W) = \chi _{\mathbb R^2 \setminus \omega }(x) \left ( T(V+W) -T(V) - \mathrm {D}T(V)W \right )\). Then, the topological derivative of the PDE-constrained optimization problem (3) according to (4) at point x0 ∈ Ωdreads
with \(\mathcal M = \mathcal M(\omega , \mathrm {D}T(\nabla u_0(x_0)) ) \in \mathbb R^{2\times 2}\) and H and K being the variations of the direct and adjoint state at scale 1, respectively.
Remark 2
In order to make use of this formula in numerical optimization algorithms, the following aspects are treated in [20]:
-
An explicit formula for the matrix \(\mathcal M\) is computed. This matrix is related to the concept of polarization matrices.
-
The term
$$\displaystyle \begin{aligned} J_2 =\int_{\mathbb R^2} \tilde S_{\nabla u_0(x_0)}(x,\nabla H)\cdot (\nabla p_0(x_0) + \nabla K) \end{aligned}$$seems to be computationally extremely costly since H depends on ∇u0(x0) via (16) and, thus, the (nonlinear) transmission problem (16) defining H would have to be solved for every point x0 in order to evaluate the term J2. This problem was overcome by exploiting a rotational invariance property of J2 with respect to a simultaneous rotation of the quantities ∇u0(x0) and ∇p0(x0). This property allows to precompute a range of typical values of J2 in a computationally expensive offline stage and to look up the precomputed values during the optimization procedure.
-
The formula of Theorem 1 represents the sensitivity of the objective function with respect to the introduction of an inclusion of air around a point x0. In order to be able to employ bidirectional optimization algorithms which are capable of both removing and reintroducing material at the most favorable positions such as the algorithm introduced in [5], also the topological derivative for the reverse scenario must be computed. We refer to these two topological derivatives as Gf→air and Gair→f.
4 Shape Optimization
In contrast to topology optimization, in shape optimization the connectivity of a domain is assumed to be fixed. Here, one is interested in finding the shape of a domain or subdomain which is optimal with respect to a given criterion by means of smooth variations of the boundary or of a material interface. In this section, we are concerned with finding the optimal shape of the ferromagnetic part Ω within the design area Ωd of the electric motor introduced in Section 2. An essential tool for gradient-based shape optimization is the notion of the sensitivity of a shape functional \(\mathcal J=\mathcal J(\varOmega )\) with respect to a smooth perturbation of the boundary of the shape Ω, called the shape derivative. A shape functional \(\mathcal J\) is said to be shape differentiable if the limit
exists and the mapping V ↦ \(d \mathcal J(\varOmega ;V)\) is linear and continuous with respect to the topology of \(C_c^\infty (D,\mathbb R^2)\). Here, Ωt = Tt(Ω) denotes the transformed domain under the flow Tt generated by a smooth vector field V .
We mention that there are two ways to define this flow given a smooth vector field V . In the perturbation of identity method, the transformation is given by Tt(X) = X + tV (X) for all \(X \in \mathbb R^d\) and t ≥ 0, whereas in the velocity or speed method, it is given as Tt(X) = x(t, X) with x(t, X) the solution to the initial value problem
which, for small τ > 0, has a unique solution, see [16, 32]. Note that, for simplicity, we assumed the vector field V to be autonomous. We remark that both approaches are equivalent for the derivation of first-order shape derivatives but differ by an acceleration term in the case of second-order shape derivatives [16].
4.1 Representation of Shape Derivative
There are basically two ways how one can represent the shape derivative of a functional depending on a domain Ω: either as a distribution on the boundary ∂Ω which only depends on the normal component of the perturbation, called the Hadamard form, or in a more general volume form, also called the distributed shape derivative. If the shape Ω is regular enough, the Hadamard form can be rewritten as an integral over the boundary,
with an integrable function gΓ. The volume form can be written as
for some function g.
One obvious advantage of the boundary-based form (19) is that a descent direction V = −gΓn is readily available. However, in many situations this choice of V might not be regular enough and has to be regularized. Furthermore, in many numerical procedures for shape optimization, it is not enough to have a descent direction that is only defined on the material interface and it has to be extended to a neighborhood or to the entire computational domain.
On the other hand, in the case where the shape derivative is given in the distributed form (20), the extraction of a descent direction V such that \(d\mathcal J(\varOmega ; V)<0\) can also be achieved easily but requires the solution of an auxiliary boundary value problem of the form
where V, W are elements of a suitable function space and b(⋅, ⋅) is a positive definite bilinear form on the same space. Obviously, a solution V to (21) is a descent direction since \(d\mathcal J(\varOmega ; V) = - b(V,V) <0\). One benefit of the volume form is that it is more general, meaning that for shapes with lower regularity the distributed shape derivative (20) may be well defined whereas the Hadamard form (19) is not. A different aspect favoring the volume-based form (20) is concerned with numerical accuracy of the approximation of the shape derivative when the underlying state and adjoint equations are solved by the finite element method. In [24], the authors show that the finite element approximation to the volume-based form converges quadratically to the “true” shape derivative on the continuous level as the mesh size tends to zero, whereas the boundary-based form converges only linearly.
We mention that, in the case of the Hadamard form of the shape derivative (19), the auxiliary boundary value problem (21) with b(⋅, ⋅) defined on ∂Ω can be used to compute a regularized gradient descent velocity for the case where the choice V = −gΓn is not smooth enough.
A more detailed comparison between these two possible representations can be found in [25].
4.2 Shape Derivative for Nonlinear Magnetostatics
For the reasons mentioned above, we restrict ourselves to the shape derivative in its volume-based representation (20). The rigorous derivation of the shape derivative for the model problem involving the quasilinear PDE of two-dimensional magnetostatics, which was introduced in Section 2, can be found in [21]. There, the shape derivative was computed using the averaged adjoint method introduced in [33].
The shape derivative of the model problem (3) reads
where \(\mathbb {P}'(0)= (\mbox{div} \, V) I-\mathrm {D}V^\top \), \(\mathbb {Q}'(0)= (\mbox{div} \, V) I-\mathrm {D}V^\top -\mathrm {D}V\), \(I \in \mathbb R^{2\times 2}\) is the identity matrix, and \(u,p\in H^1_0(D)\) are the state and adjoint state, respectively.
5 Interface Handling
Both the topological derivative (18) and the shape derivative (22) involve the solution to the state equation (3b) and to the adjoint equation in the current configuration. These two quantities are usually computed approximately by means of the finite element method. In the course of the numerical optimization algorithm, the interface between the ferromagnetic and the air subdomain evolves. In order to get accurate solutions using standard finite element methods, this material interface must be resolved by the underlying mesh. We give an overview over the possible approaches to deal with evolving material interfaces in Section 5.1, before introducing our method in Section 5.2.
5.1 Finite Element Methods for Interface Problems
One way to deal with evolving interfaces in the context of finite elements is to create a new triangulation in each step of the algorithm, which is computationally very costly. Another approach, which is often used in shape optimization, is to start with a mesh that resolves the interface and to advect all nodes of the mesh in the direction of the descent vector field V – provided that V is defined on the whole computational domain. This procedure has the limitation that it does not allow for topological changes and can become problematic when more complex geometries with geometric constraints are involved, as it is the case for our model problem. Here, fixed parts of the electric motor like the circular air gap should not be altered under any circumstances.
The idea of the extended finite element method (XFEM) is to enrich the finite element basis by additional basis functions which are modified versions of the standard basis functions. The solution is seeked in the enriched space \(V_h^\varGamma = V_h \oplus V_h^x\) where Vh is a standard finite element space, and \(V_h^x\) the space of standard finite element functions which are supported at the interface, multiplied with a so-called enrichment function, see, e.g., [7, 19].
The idea of the immersed finite element method [26] is similar to that of the XFEM. However, rather than adding basis functions to the basis, existing basis functions of the finite element space which are supported across the interface are modified in such a way that the interface jump conditions are satisfied.
In the unfitted Nitsche method introduced in [23], a discontinuity or kink of the solution across an interface is enforced in a weak sense. This way of treating the interface conditions is often used in combination with XFEM, called the Nitsche-XFEM. In this method, just like in all other methods mentioned above, a crucial task is to establish stability of the method with respect to the location of the interface relative to the mesh. Generally, if an element of the underlying unfitted background mesh is cut by the interface very close to one of the vertices, the condition of the system becomes very bad. This issue is treated in the CutFEM [13], which is a stabilized version of the Nitsche-XFEM.
An alternative to these fixed mesh approaches is to modify the mesh and always work with a fitted discretization while still guaranteeing a certain quality of the mesh. We mention the deformable simplicial complex (DSC) method [15].
In [18], an interface finite element method on a fixed mesh is introduced where the interface is resolved by locally modifying the finite element basis functions. Optimal order of convergence and also, when choosing a special hierarchical basis, optimal conditioning of the system matrix are shown. We note that this parametric approach can be equivalently interpreted as a fitted finite element method where some of the mesh nodes close to the interface are moved in such a way that the interface is resolved by the mesh. In the next section, we will follow the approach of [18] and translate it to the case of triangular finite elements.
5.2 A Local Mesh Modification Strategy
We adapt the method presented in [18] for quadrilateral meshes to the case of piecewise linear finite elements on a triangular grid. Our method is based on the assumption that the mesh has a one-level hierarchy, i.e., that always four triangles of the mesh \(\mathcal T_h\) can be combined to one triangle of a coarser mesh \(\mathcal T_{2h}\). We will refer to this bigger triangle as a macro triangle and call \(\mathcal T_{2h}\) the macro mesh. Furthermore, we assume that each element of the macro mesh which is cut by the interface is intersected either in two distinct edges or in one vertex and the opposite edge. Note that this assumption can be enforced by choosing a fine enough macro mesh \(\mathcal T_{2h}\).
The idea of the method is the following: If a macro element is not cut by the material interface, it is left unchanged. For those macro elements which are cut by the interface in two distinct edges, two of the three vertices lying on the edges of the macro element are moved along these edges to the intersection points of the interface and the macro edge, see Figure 2. If necessary, the vertex lying on the third edge can be moved along that edge in order to avoid some angle to become too close to 180∘. The vertices of the macro element remain unchanged. Similarly, if the macro element is cut in one vertex and the opposite edge, the vertex lying on the intersected macro edge is moved to meet the intersection point and the other two vertices may be moved such that a maximum angle condition is satisfied. More details on this procedure can be found in [20] where also the optimal order of convergence of the finite element solution to the true solution in the L2(D) and in the H1(D) norm is shown.
6 Numerical Optimization Results
In this section, we combine the results of Sections 3 and 4 and the method introduced in Section 5.2 to one efficient design tool. We describe the procedure in Section 6.1 before applying it to the model problem introduced in Section 2 in Section 6.2.
6.1 Combined Topology and Shape Optimization with Interface Handling
We present a two-stage algorithm where topology optimization is performed in the first stage in order to find the optimal connectivity of the design domain, followed by shape optimization in combination with the interface resolution method of Section 5.2 as a post-processing in order to obtain smoother designs.
In the first stage, topology optimization is performed using the level set algorithm [5]. In order to apply this algorithm, it is important to have the topological derivative for both directions, i.e., the sensitivity of the objective function with respect to the nucleation of a hole of air inside ferromagnetic material, Gf→air, and the sensitivity for the creation of ferromagnetic material in an air region, Gair→f.
The shape optimization is done by means of a gradient descent algorithm. Starting out from an initial design, the interface between the ferromagnetic and the air subdomain of the design area Ωd is moved a certain distance in a descent direction V which was obtained from (21). The step size is chosen in such a way that a decrease of the objective functional is achieved. Note that, for the evaluation of the shape derivative on the right-hand side of (21), the state and adjoint equations have to be solved, which is done by the finite element method. In order to obtain accurate finite element solutions, the mesh modification strategy of Section 5.2 should be applied whenever the interface is updated.
The proposed optimization procedure is summarized in the following algorithm:
Algorithm 1
(Combined topology and shape optimization with interface handling)
-
Stage I: Apply the algorithm [ 5 ] to find an optimal topology.
-
Stage II: Use the final design of Stage I as an initial design and perform gradient-based shape optimization where for each solve of the state and adjoint equations, the local mesh adaptation strategy of Section 5.2 is applied.
A more detailed description of the algorithm can be found in [20].
6.2 Minimizing Total Harmonic Distortion
The goal of the model problem introduced in Section 2 was to achieve a smooth rotation of the rotor. This can be achieved by ensuring a smooth radial component of the magnetic flux density Br = B ⋅ n = ∇u ⋅ τ in the air gap between the rotor and the stator when the electric current is switched off (J3 = 0). Here, n and τ denote the unit normal and tangential vectors on a circular path in the air gap, respectively. For that purpose, we consider Br along this circular curve inside the air gap as a periodic signal and decompose it into its Fourier coefficients,
where Ak, \(B_k \in \mathbb R\), φ ∈ [0, 2π], and ω denotes the number of pole pairs of the motor. In the motor introduced in Section 2, we have eight magnetic poles, thus ω = 4. Due to the geometry of the motor, the coefficients Ak are approximately zero and will be neglected. The total harmonic distortion (THD) measures the contributions of higher harmonics (i.e., k > 1) to the total signal, see [11]. For practical purposes, we only consider the first N = 20 harmonics. Then, the total harmonic distortion of Br reads
where the coefficients Bk are according to (23). The minimization of the THD filters out all higher harmonics. In order to make sure that the first harmonic does not become too small, we minimize the functional
where B1(Br(u)) denotes the coefficient B1 in (23). In our implementation, we computed the Fourier coefficients by a least square approach.
Figure 3 shows the evolution of the design by using Algorithm 1 starting from an initial design. The final design of Stage I obtained after a total of 47 iterations is approximated by an explicit polygonal interface, which serves as an initial guess for the shape optimization. The final design after the shape optimization procedure together with the local mesh modification strategy introduced in Section 5.2 can be seen in the bottom row of Figure 3. Figure 4 shows the curve Br for the initial and the final design of both stages of the optimization procedure, and Figure 5 the final design together with the magnetic field.
7 Conclusion
This book chapter was motivated by a concrete application from electrical engineering, the design optimization of an electric motor. We addressed the problem by a two-stage algorithm. In the first stage, we used a topology optimization approach which is based on the mathematical concept of the topological derivative. Here, the derivation and efficient implementation of the topological derivative for the optimization problem at hand, which is constrained by a nonlinear PDE, turned out to be particularly challenging. The second stage of the global algorithm is a shape optimization algorithm where we additionally took care to accurately resolve the evolving material interfaces by means of a mesh modification strategy. Finally, we showed numerical results obtained by applying the introduced algorithm to find a motor design which exhibits very smooth rotation properties.
References
G. Allaire. Shape optimization by the homogenization method. Applied mathematical sciences. Springer, New York, 2002.
H. Ammari and H. Kang. Polarization and Moment Tensors. Springer-Verlag New York, 2007.
S. Amstutz. Sensitivity analysis with respect to a local perturbation of the material property. Asymptotic analysis, 49(1), 2006.
S. Amstutz. Analysis of a level set method for topology optimization. Optimization Methods and Software - Advances in Shape an Topology Optimization: Theory, Numerics and New Application Areas, 26(4–5):555–573, 2011.
S. Amstutz and H. Andrä. A new algorithm for topology optimization using a level-set method. Journal of Computational Physics, 216(2):573–588, 2006.
S. Amstutz and A. Bonnafé. Topological derivatives for a class of quasilinear elliptic equations. Journal de mathématiques pures et appliquées.
T. Belytschko, R. Gracie, and G. Ventura. A review of extended/generalized finite element methods for material modeling. Model. Simul. Mater. Sci. Eng., 17(4), 2009.
M. P. Bendsøe. Optimal shape design as a material distribution problem. Structural Optimization, 1(4):193–202, 1989.
M. P. Bendsoe and N. Kikuchi. Generating optimal topologies in structural design using a homogenization method. Comput. Methods Appl. Mech. Eng., 71(2):197–224, Nov. 1988.
M. P. Bendsøe and O. Sigmund. Topology Optimization: Theory, Methods and Applications. Springer, Berlin, 2003.
A. Binder. Elektrische Maschinen und Antriebe: Grundlagen, Betriebsverhalten. Springer-Lehrbuch. Springer, 2012.
M. Burger and R. Stainko. Phase-field relaxation of topology optimization with local stress constraints. SIAM J. Control Optim., 45(4):1447–1466, 2006.
E. Burman, S. Claus, P. Hansbo, M. G. Larson, and A. Massing. CutFEM: Discretizing geometry and partial differential equations. International Journal for Numerical Methods in Engineering, 104(7):472–501, 2015.
F. Campelo, J. Ramırez, and H. Igarashi. A survey of topology optimization in electromagnetics: considerations and current trends. 2010.
A. N. Christiansen, M. Nobel-Jørgensen, N. Aage, O. Sigmund, and J. A. Bærentzen. Topology optimization using an explicit interface representation. Structural and Multidisciplinary Optimization, 49(3):387–399, 2014.
M. C. Delfour and J.-P. Zolésio. Shapes and geometries, volume 22 of Advances in Design and Control. Society for Industrial and Applied Mathematics (SIAM), Philadelphia, PA, second edition, 2011. Metrics, analysis, differential calculus, and optimization.
H. A. Eschenauer, V. V. Kobelev, and A. Schumacher. Bubble method for topology and shape optimization of structures. Structural optimization, 8(1):42–51, 1994.
S. Frei and T. Richter. A locally modified parametric finite element method for interface problems. SIAM J. Numer. Anal., 52(5):2315–2334, 2014.
T.-P. Fries and T. Belytschko. The extended/generalized finite element method: An overview of the method and its applications. Int. J. Numer. Meth. Eng., 84(3):253–304, 2010.
P. Gangl. Sensitivity-based topology and shape optimization with application to electrical machines. PhD thesis, Johannes Kepler University Linz, 2016.
P. Gangl, U. Langer, A. Laurain, H. Meftahi, and K. Sturm. Shape optimization of an electric motor subject to nonlinear magnetostatics. SIAM Journal on Scientific Computing, 37(6):B1002–B1025, 2015.
H. Garcke, C. Hecht, M. Hinze, and C. Kahle. Numerical approximation of phase field based shape and topology optimization for fluids. SIAM Journal on Scientific Computing, 37(4):A1846–A1871, 2015.
A. Hansbo and P. Hansbo. An unfitted finite element method, based on Nitsche’s method, for elliptic interface problems. Computer Methods in Applied Mechanics and Engineering, 191(47–48):5537 – 5552, 2002.
R. Hiptmair, A. Paganini, and S. Sargheini. Comparison of approximate shape gradients. BIT, 55(2):459–485, 2015.
A. Laurain and K. Sturm. Distributed shape derivative via averaged adjoint method and applications. ESAIM: M2AN, 50(4):1241–1267, 2016.
Z. Li. The immersed interface method using a finite element formulation. Appl. Num. Math., 27:253–267, 1998.
S. Osher and J. A. Sethian. Fronts propagating with curvature dependent speed: Algorithms based on Hamilton-Jacobi formulations. Journal of Computational Physics, 79(1):12–49, 1988.
C. Pechstein and B. Jüttler. Monotonicity-preserving interproximation of B-H-curves. J. Comp. App. Math., 196:45–57, 2006.
O. Sigmund and K. Maute. Topology optimization approaches: A comparative review. Structural and Multidisciplinary Optimization, 48(6):1031–1055, 2013.
O. Sigmund and J. Petersson. Numerical instabilities in topology optimization: A survey on procedures dealing with checkerboards, mesh-dependencies and local minima. Structural Optimization, 16(1):68–75, 1998.
J. Sokołowski and A. Zochowski. On the topological derivative in shape optimization. SIAM Journal on Control and Optimization, 37(4):1251–1272, 1999.
J. Sokołowski and J.-P. Zolésio. Introduction to shape optimization, volume 16 of Springer Series in Computational Mathematics. Springer-Verlag, Berlin, 1992. Shape sensitivity analysis.
K. Sturm. Minimax Lagrangian approach to the differentiability of nonlinear PDE constrained shape functions without saddle point assumption. SIAM Journal on Control and Optimization, 53(4):2017–2039, 2015.
N. P. van Dijk, K. Maute, M. Langelaar, and F. van Keulen. Level-set methods for structural topology optimization: a review. Structural and Multidisciplinary Optimization, 48(3): 437–472, 2013.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2018 Springer Science+Business Media, LLC, part of Springer Nature
About this chapter
Cite this chapter
Gangl, P. (2018). Sensitivity-Based Topology and Shape Optimization with Application to Electric Motors. In: Antil, H., Kouri, D.P., Lacasse, MD., Ridzal, D. (eds) Frontiers in PDE-Constrained Optimization. The IMA Volumes in Mathematics and its Applications, vol 163. Springer, New York, NY. https://doi.org/10.1007/978-1-4939-8636-1_9
Download citation
DOI: https://doi.org/10.1007/978-1-4939-8636-1_9
Publisher Name: Springer, New York, NY
Print ISBN: 978-1-4939-8635-4
Online ISBN: 978-1-4939-8636-1
eBook Packages: Mathematics and StatisticsMathematics and Statistics (R0)