Abstract
In this paper, gradient-based optimization methods are combined with finite-element modeling for improving electric devices. Geometric design parameters are considered by piecewise affine parametrizations of the geometry or by the design element approach, both of which avoid remeshing. Furthermore, it is shown how to robustify the optimization procedure, that is, how to deal with uncertainties on the design parameters. The overall procedure is illustrated by an academic example and by the example of a permanent-magnet synchronous machine. The examples show the advantages of deterministic optimization compared to standard and popular stochastic optimization procedures such as particle swarm optimization.
Similar content being viewed by others
Avoid common mistakes on your manuscript.
1 Introduction
In almost all electric design procedures, numerical optimization is employed as one of the last design steps in order to optimize the device’s performance and efficiency, to minimize its weight and size and to save on material and manufacturing costs. Often, the quality of this optimization step indirectly determines the success of the product and, hence, the market position of the company. The reliability, accuracy and computational cost of the numerical optimization procedure becomes in itself a subject of competition. This paper illustrates that shape optimization can be improved substantially when finite-element (FE) analysis procedures are equipped with piecewise affine parametrization or design elements, such that well-performing deterministic optimization methods become applicable.
Impressive technical improvements have been achieved by numerical optimization on the basis of magnetic equivalent circuits or 2D and 3D FE models. All have led to highly optimized designs, for example, for permanent-magnet synchronous machines (PMSMs) in automotive applications. Since three decades, FE-based optimization has been addressed in several text books (see, e.g., [12]) and hundreds of journal articles (see, e.g., [14] and the references therein). Although originally, gradient-based methods were preferred (see, e.g., [48, 56, 58]), already for more than two decades, stochastic algorithms are more popular (see, e.g., [19, 33]). The majority of the proposed procedures opt for stochastic or population-based optimization methods, such as genetic algorithms and particle swarm optimization (see, e.g., [34]), because they allow to use FE solvers as a black box, they can easily consider geometric parameters, their parallelization is straightforward and they are more likely to find the global optimum. Stochastic algorithms have been used for robust optimization, have been applied together with surrogate modeling and have been extended to multi-objective optimization problems [3, 23]. In particular for PMSMs, optimization with stochastic methods became the method of choice [2, 9, 51].
The trend toward stochastic optimization combined with FE analysis continues without restraint, as is illustrated by the number of according contributions at recent conferences. This paper partially counteracts this tendency by turning back to deterministic optimization algorithms. Deterministic optimization methods are known to converge faster than stochastic optimization methods, albeit possibly to a local optimum. Moreover, the analysis of gradient-based methods is more mature, allowing for a rigorous control of mesh discretization errors, for instance. The main drawback of many deterministic methods is, however, the necessity to provide derivatives, which is particularly cumbersome when optimization according to geometric parameters is pursued. This drawback is here addressed explicitly and is alleviated by piecewise affine parametrizations of the geometry or by the design element approach. The overall deterministic optimization routine is shown to outperform the most popular stochastic algorithms by factors. Moreover, the optimization method will be robustified to include uncertainties on the design parameters.
The paper is structured as follows: Sect. 2 recalls the basics of mathematical optimization. It clearly distinguishes between deterministic methods (Sect. 2.3) and particle swarm optimization as a relevant representative of stochastic methods (Sect. 2.4). Furthermore, an extension to robust optimization is discussed in Sect. 2.5. Section 3 deals with FE analysis of magnetodynamic fields. The core parts of the paper are Sect. 3.3.1 about affine parametrization and Sect. 3.3.2 about design elements, both facilitating and improving the calculation of derivatives with respect to geometric parameters. The superior performance of gradient-type deterministic optimization is illustrated for a benchmark example in Sect. 4 and for a PMSM in Sect. 5. Conclusions are formulated in Sect. 6.
2 Constrained optimization
2.1 Constrained optimization problem
The optimization is carried out with respect to I design parameters \(\mathbf{p}=(p_1,p_2,\ldots ,p_I)\) belonging to the admissible set \({\mathcal {P}}_{\mathrm {ad}} =\{\mathbf{p}\in {\mathbb {R}}^I|G_m(\mathbf{p})\le 0,m=1,\ldots ,M\}\), where \(G_m(\mathbf{p})\) denote the constraints. The design parameters can be any continuous variables, for example material constants, excitation parameters and geometric sizes or positions. The constraints limit the admissible range of these parameters, for example to preserve the topology of the geometry or to set physical and operational constraints. Discrete design parameters are not considered in this work, although many methods apply, for example as part of a branch-and-bound technique, to mixed-integer optimization problems as well [21].
The optimization goal is represented by the objective function \(J(\mathbf{p})\) returning a scalar value for every set of design parameters. Relevant quantities are, for example force, torque, current, efficiency, weight, temperature or a combination thereof. When N objective functions \(J_n(\mathbf{p})\), \(n=1,\ldots ,N\) are relevant, a possible approach is to combine them with user-defined weight factors \(\alpha _n\) into a single cost function \(J(\mathbf{p})=\sum _{n=1}^N \alpha _n J_n(\mathbf{p})\). The optimization problem then reads
In this work, the evaluation of \(G_m(\mathbf{p})\) and/or \(J(\mathbf{p})\) involves a FE analysis of the device. Hence, the computational performance of the overall approach is heavily determined by the number of FE-solver calls.
2.2 Optimization methods
The selection of a particular optimization method consists of four essentially independent choices (see also Table 3 in [18]).
-
Problem (1) considers a single optimization goal. For a multi-objective optimization problem, a Pareto front is calculated such that the relative importance of the optimization goals can be fixed later on [7, 12]. This paper does not further consider multi-objective optimization. Nonetheless, the developed techniques are applicable to multi-objective optimization as well.
-
A distinction is made between global optimization and local optimization, where the first strives to a global optimum, whereas the second may run into a local one. This paper is limited to methods for local optimization. In practice, if a global optimum is required, the methods may be repeated for different start values, or could be embedded as part of a global optimization scheme [24].
-
Especially when the evaluation of the objective function is computationally expensive, it is recommended to carry out the optimization method on the basis of a surrogate model (indirect optimization methods). Such a simplified model can be obtained by expert knowledge on the application [59], by design space reduction [17], by a response surface methodology [17] or by space mapping [29] or manifold mapping [15]. Here, a direct optimization procedure is used. All ideas presented here can, however, be used in combination with indirect optimization approaches as well [30].
-
The result from a nominal optimization is a set of optimized design parameters leading to an optimum of the objective function. The optimum may, however, become irrelevant when it is highly sensitive to uncertainties in the design parameters. One speaks about robust optimization when the optimization is carried out taking such uncertainties into account. In this paper, both nominal and robust optimization methods are considered. An approach for robustification is discussed in Sect. 2.5.
-
Two families of basic optimization methods exist: deterministic and stochastic methods. Among the stochastic methods, genetic algorithms [35], differential evolution [38] and particle swarm optimization (PSO) [27] are well known.
This paper motivates the use of a gradient-based deterministic method for nominal and robust optimization and compares it with a standard particle swarm technique.
2.3 Gradient-based deterministic method
This work proposes to solve (1) by standard sequential quadratic programming (SQP) with damped Broyden–Fletcher–Goldfarb–Shanno (BFGS) updates for the Hessian approximation [22, 40]. This method establishes locally a second-order convergence, which means that
for \(C>0\) and k the iteration step, which should be sufficiently large. The method, however, requires knowledge about the sensitivities of the objective function with respect to the design parameters, in particular, \(\nabla _\mathbf{p}J(\mathbf{p})\) or, alternatively, a locally quadratic approximation of the objective function [44]. Many FE solution and post-processing routines do not provide this information, especially when geometric design parameters are involved. Therefore, one is tempted to approximate the sensitivities by finite differences as in, e.g., [48]. This is, however, known to be particularly cumbersome because of the limited accuracy of the finite differences [58]. Even when relying on gradient-free deterministic methods (e.g., [44, 45]), artifacts caused by FE analysis may hamper the convergence of the optimization routines. Eventually, as apparently the only option, deterministic optimization algorithms are abandoned in favor of stochastic approaches. This paper, however, sticks to gradient-based deterministic methods by complementing the FE simulation procedure with sensitivity information. The problems caused by the presence of geometric parameters are alleviated by introducing piecewise affine parametrization (see Sect. 3.3.1) or, alternatively, design elements (see Sect. 3.3.2) to the FE procedure.
2.4 Particle swarm optimization
Particle swarm optimization (PSO) [27] belongs to the broad class of Stochastic algorithms and is particularly popular for optimizing electric machines (see, e.g., [2, 3, 9, 23, 34]). In PSO, a set of Q particles indicated by \(q=1,\ldots ,Q\) moves through the admissible set in the design space in search of an optimum. At each iteration step k, the algorithm evaluates the objective function \(J(\mathbf{p})\) in every particle position \(\mathbf{p}_{k,q}\). The newly obtained values are compared to the previous best values in the individual particle histories and the best value of the entire swarm. The corresponding best sets are denoted by \({\hat{\mathbf{p}}}_q\) and \({\hat{\mathbf{p}}}_\text {swarm}\), respectively. The velocities of the particles are updated according to
where \(\omega _0\), \(\omega _1\) and \(\omega _2\) are swarm characteristic constants and \({\mathbf {N}}_1\) and \({\mathbf {N}}_2\) are two random diagonal matrices with elements in [0, 1] generated independently and uniformly for each particle at every step, representing the free will of the swarm. The components of the velocity update are:
-
1.
Maintain a part of the current velocity;
-
2.
Head toward the particle’s best found point (\({\hat{\mathbf{p}}}_q\));
-
3.
Head toward the swarm’s best found point (\({\hat{\mathbf{p}}}_\text {swarm}\)).
If at some iteration there is a particle that leaves the admissible set, its position is projected on the boundary of the admissible set. Initially, all particles are randomly and uniformly distributed in the admissible set and the initial velocities are set to 0. The particle swarm is a gradient-free method and works for non-smooth functions as well. The iteration ends when a maximum number of iterations is reached, or when the majority of the particles are close enough to the best point \({\hat{\mathbf{p}}}_\text {swarm}\):
with a user-defined tolerance \(\epsilon \), or if there is no further change in the global best point \({\hat{\mathbf{p}}}_\text {swarm}\) over \(N_\text {stall}\) consecutive iterations.
2.5 Robust optimization
In a nominal optimization procedure, one is looking for the minimum value of an objective function. However, during manufacturing, small deviations can occur on the parameters. As a consequence, the optimal solution may become suboptimal in reality. Robust optimization searches for an optimum that is not too much affected by the expected parameter deviations [41, 60].
One possibility is to optimize such that the worst-case scenario within a stochastic set of possibilities around the optimal design parameters is the best possible. The robust counterpart of (1) adopting a worst-case scenario is
Here, the uncertainty set for the deviations \(\varvec{\delta }\) is defined by
where \({\mathbf {D}}\) is a scaling matrix and where \(\delta _i^l=-\delta _i^u\).
The nested optimization problem formulated by (5) is hard to solve. A numerically feasible optimization problem is obtained by approximating the \(\max \) problem, i.e., by applying a first-order Taylor approximation of the objective function and the constraints with respect to \(\mathbf{p}\) [13]:
for \(m = 1,\ldots ,M\). Inserting this approximation into (5), one obtains the linear approximation of the robust optimization problem:
for \(m = 1,\ldots ,M\). A dual norm \(||\cdot ||_*\) is defined by
In this particular case, one can use the property that the dual of \(\Vert {\mathbf {D}}^{-1}\cdot \Vert _\infty \) is given by \(\Vert {\mathbf {D}}\cdot \Vert _1\).
A further problem is introduced by the fact that the norms are not differentiable, which leads to a non-smooth optimization problem. A differentiable problem is obtained by introducing \(M+1\) slack variables \({\xi }_0,\ldots ,{\xi }_M\) and reformulate (9) as
where \(m=1,\ldots ,M\) and \({\mathbb {V}} =[1,\ldots ,1]^\top \in \mathbb R^I\). This optimization problem can now be efficiently solved numerically. Additionally to the quantities introduced in the previous section, now also second-order sensitivities with respect to the design parameters are required. This approach can be generalized to use a quadratic approximation with respect to \(\mathbf{p}\) as worked out in [30].
3 Finite-element model
The behavior of the devices under consideration is determined by magnetic field phenomena and is simulated using a FE model.
3.1 Magnetoquasistatic formulation
The magnetoquasistatic (MQS) subset of Maxwell’s equations is considered. The design parameters \(\mathbf{p}\) influence the material distribution represented by the reluctivity \(\nu (\mathbf{p})\) and the conductivity \(\sigma (\mathbf{p})\), as well as the excitations, represented by the applied current density \(\mathbf {J}_{\mathrm{src}}(\mathbf{p})\) in current carrying conductors and the magnetizing field strength \(\mathbf {H}_\mathrm{m}(\mathbf{p})\) of the present permanent magnets. The MQS formulation in terms of the magnetic vector potential \(\mathbf {A}(\mathbf{p})\) reads
and is complemented with adequate boundary conditions. Equation 12 encompasses the case of linear, nonlinear and remanent magnetic materials expressed by
respectively. \(\mathbf {H}(\mathbf{p})\) and \(\mathbf {B}(\mathbf{p})=\nabla \times \mathbf {A}(\mathbf{p})\) are the magnetic field strength and magnetic flux density. In the nonlinear setting, the formulation is treated by the Newton method, which is equivalent to using a linearized material relation \(\mathbf {H}(\mathbf{p})=\mathbf {H}_\mathrm{m}^{(k)}(\mathbf{p})+\overline{{\overline{\nu }}}^{(k)}(\mathbf{p})\mathbf {B}(\mathbf{p})\) and updating the tensorial differential permeability \(\overline{{\overline{\nu }}}^{(k)}(\mathbf{p})\) and the magnetizing field strength \(\mathbf {H}_{\mathrm{m}}^{(k)}(\mathbf{p})\) between the successive Newton steps k [28].
3.2 Finite-element discretization
The magnetic vector potential is discretized by lowest-order Nédélec edge shape functions \(\mathbf {w}_j(x,y,z)\),
where \(a_j(\mathbf{p})\) are the degrees of freedom and \(N_{\mathrm{dof}}\) is the number of degrees of freedom. In the 3D case, the shape functions are associated with the edges of a tetrahedral mesh. In the 2D Cartesian case, the edge shape functions are aligned with the z-axis and are constructed from the nodal shape functions \(N_j(x,y)\) associated with the nodes of a 2D mesh:
where \(l_z\) is the length of the device in z-direction. In both cases, the discretization procedure leads to the system of equations
where
and where \(V_D\) is the computational domain [36]. In the 2D case, \(V_D=S_D \times [0,l_z]\) where \(S_D\) is the cross section of the device. Equation 18 is further discretized in time by, for example, an implicit Runge–Kutta method, linearized by the Newton–Raphson method and solved by a solution method for large sparse systems of equations [10, 28].
3.3 Geometry parametrization
In the following, designs will be optimized with respect to geometric parameters. At first sight, the changing geometry necessitates the reconstruction of the computational mesh. This would, however, lead to unacceptably high computation times. Moreover, the unavoidable changes in mesh topology would introduce numerical noise which could mask the true sensitivity of the quantities of interest on the geometric parameters. Two different types of parametrizations are presented in the following. Affine parametrization or affine decomposition (see, e.g., [47]) is particularly appealing in the context of model order reduction and well suited for parallelization. However, complex transformations cannot be represented exactly by this approach. One may turn to (empirical) interpolation methods, but they introduce additional approximation errors. This is not the case for the second parametrization, which is based on the well-established concept of design elements [6] in combination with non-uniform rational B-splines (NURBS). Here, the mapping will not be affine and more effort is needed for the update of the FE matrices and vectors. In either case, good results can be obtained for many shape optimization problems by one of the two methods, with moderate implementation effort. It should also be mentioned that nonparametric approaches to shape optimization [11] present a viable alternative and have already been applied for electric machines [16]. There, however, advanced techniques for both derivation and implementation are needed.
The geometry is decomposed in a domain \(V_D^0\) that is unaffected from the geometric parameters and domains \(V_D^\ell (\mathbf{p})\), \(\ell =1,\ldots ,L\) subject to geometry changes according to the geometric parameters \(\mathbf{p}\). The FE matrices \({\mathbf {K}}_\nu (\mathbf{p})\) and \({\mathbf {M}}_\sigma (\mathbf{p})\) and vectors \({\mathbf {j}}_{\mathrm{src}}(\mathbf{p})\) and \({\mathbf {j}}_{\mathrm{m}}(\mathbf{p})\) can be partitioned accordingly:
and similarly for \({\mathbf {M}}_\sigma (\mathbf{p})\), \({\mathbf {j}}_\text {src}(\mathbf{p})\) and \({\mathbf {j}}_\text {m}(\mathbf{p})\). Reference geometries \({\hat{V}}_D^\ell , \ell =1,\ldots ,L\) and \({\hat{V}}_D^0 = V_D^0\) are defined, as well as maps \(f^\ell _\mathbf{p}:{\hat{V}}_D^\ell \rightarrow V_D^\ell (\mathbf{p}), \hat{\mathbf {r}}\mapsto f^\ell _\mathbf{p}(\hat{\mathbf {r}})= \mathbf {r}\), which depend on \(\mathbf{p}\).
3.3.1 Affine parametrization
This section discusses the idea of decomposing (a part of) the mesh such that geometrical changes can be represented by piecewise affine maps [30, 47]. The affine maps will be referred to by \(f^\ell _{\mathbf{p},\text {aff}}\).
As an example, an affine map for the 2D case is developed (Fig. 1). Let \({\mathbf {r}}_j=\left[ x_j \ y_j \right] ^\top \), \(j=1,2,3\) denote the nodes of a deformed triangle in the domain \(V_D^\ell (\mathbf{p})\) and \(\hat{{\mathbf {r}}}_j=\left[ {\hat{x}}_j \ {\hat{y}}_j \right] ^\top \), \(j=1,2,3\) the nodes of the corresponding triangle in the reference domain \({\hat{V}}_D^\ell \). The transformation from the reference triangle to the deformed triangle \(\hat{\mathbf {r}}\mapsto f^\ell _{\mathbf{p},\text {aff}}(\hat{\mathbf {r}}) = \mathbf {r}\) is given by the affine map
with \({\hat{S}}\) the cross-sectional area of the reference triangle. In short, this becomes a linear transformation of the form
In 3D, affine parametrization is organized using a tetrahedral decomposition of the computational domain. The key of affine parametrization is that the Jacobian of the map,
is constant on each subdomain \(V_D^\ell (\mathbf{p})\). In the integrations in (19)–(22), the volume integrations now have to be carried out according to \(\,\text{ d }{{V}}=\vartheta _0^\ell (\mathbf{p})\,\text{ d }{{\hat{V}}}\), where \(\vartheta _0^\ell (\mathbf{p})=|J_{\mathrm{aff}}^\ell (\mathbf{p})|\) denotes the determinant of the Jacobian. Hence,
where \(\hat{{\mathbf {M}}}_\sigma \) and \(\hat{{\mathbf {j}}}_\text {src}\) are assembled for the reference geometry only once. Additionally, the affine maps affect the differential operators in (19) and (22). A bit of calculation is needed to work out the transformed differential operators and the scalar products component-wise. For the 2D Cartesian case, the results are
where the matrix factors \(\hat{{\mathbf {K}}}^{\ell }_{\nu ,xx}\), \(\hat{{\mathbf {K}}}^{\ell }_{\nu ,yy}\), \(\hat{{\mathbf {K}}}^{\ell }_{\nu ,xy}\), \(\hat{{\mathbf {K}}}^{\ell }_{\nu ,yx}\), and the vector factors \(\hat{{\mathbf {j}}}_{\text {m},x}^\ell \) and \(\hat{{\mathbf {j}}}_{\text {m},y}\) are assembled for the reference geometry in advance. Hence, the assembly of new FE matrices and vectors can be avoided during the optimization procedure. The functions \(\vartheta _q^\ell (\mathbf{p})\) are simple scalar functions in terms of the design parameters and are evaluated for each model instantiation.
3.3.2 Design element approach
For many geometry optimization tasks, the domain underlying geometry changes cannot be decomposed in triangles or tetrahedra with straight edges and faces, which excludes the use of affine parametrization. NURBS are a more general way to represent geometries and are widely used in CAD systems. Therefore, it seems natural to use the control points (and weights) of NURBS curves as design parameters [6, 49]. This approach has received considerable attention in recent years as new approaches, incorporating NURBS geometries into FE analysis, have emerged. Isogeometric analysis [25] and the NURBS-enhanced FE method [50] are important examples. Here, NURBS are only used for the geometry parametrization. A triangular (tetrahedral) mesh is generated once and deformed using the concept of design elements [6, 26].
In the following, for simplicity, the two-dimensional case is considered solely. A generic NURBS curve of degree p is given as
where \(\mathbf {P}_{i}\) refers to a control point and the rational spline \(R_i^p\) is defined in terms of B-splines \(N_i^p\) and weights \(w_i\) as
In total, L design elements are considered, each of which is represented by two NURBS curves \(\mathbf {C}_{\mathbf{p},1}^\ell \) and \(\mathbf {C}_{\mathbf{p},2}^\ell \), each depending on the geometric parameters \(\mathbf{p}\). More precisely, a design element is defined by a map \(f_{\mathbf{p},\text {de}}^\ell :{\hat{V}}_D^\ell = [0,1]^2\rightarrow V_D^\ell (\mathbf{p})\) given as
Hence, design elements are obtained by successively connecting points of each NURBS curve by a straight line, as depicted in Fig. 2. The affine parametrization may result in unstructured representations where such a patch structure is missing. For each node \((x_i,y_i)\) in \(V_D^\ell (\mathbf{p})\), its position in the reference domain \([0,1]^2\) is computed in advance by solving
for example with the Newton–Raphson method. Then, the mesh can be easily deformed by applying the parameter-dependent map \(f_{\mathbf{p},\text {de}}^\ell \) to all nodes \(({\hat{x}}_i,{\hat{y}}_i)\).
The transformation of the FE matrices and vectors is more involved compared to the affine parametrization described in Sect. 3.3.1. Each entry of the mass matrix is transformed as
where it is important to emphasize that \(|J_{\mathrm{de}}^\ell (\mathbf{p})|\) is not constant on each design element. A similar expression is obtained for \({\mathbf {j}}_\text {src}(\mathbf{p})\), whereas the conforming transformation of the curl operator yields
In (36) and (37), the dependence of the integration domain on the geometry changes was eliminated. Because the Jacobian \(J_{\mathrm{de}}^{\ell }(\mathbf{p})\) can be expressed as a function of the geometric parameters \(p_i\), the analytical derivative of the system matrix and of the right-hand side with respect to the geometric parameters can be determined.
3.4 Sensitivities
After differentiating the FE system, a new linear system for the derivatives of the degrees of freedom with respect to the geometric parameters is obtained:
where \({\mathbf {s}}_i(\mathbf{p})=\frac{\partial {\mathbf{a}({\mathbf{p}})}}{\partial {p_i}}\) are the sensitivities of the FE solution. To calculate \({\mathbf {s}}_i\), I equations of the form (38) have to be solved. In the case of affine parametrization, derivatives of \({\mathbf {K}}_\nu \) are easily calculated from (23) and (29) using expressions for \(\frac{\partial {\vartheta ^\ell (\mathbf{p})}}{\partial {p_i}}\) which are known analytically as derivatives of the functions \(\vartheta ^{\ell }(\mathbf{p})\). The expressions become more involved when NURBS are involved, yet closed-form formulas also exist in this case.
The optimization algorithm requires the derivatives of the objective function with respect to each of the design parameters. Often, the objective function does not explicitly depend on the design parameters, i.e., \(J(\mathbf{p})={\tilde{J}}(\mathbf a(\mathbf{p}))\). In this case, the derivatives are given as
For a large number of parameters, an adjoint method should be used instead [57].
4 Example 1: Die press mold
As a first example, a die press mold for radially magnetizing a segment of sintered magnetic powder (SMP) is considered [54]. This problem has been proposed as testing electromagnetic analysis methods (TEAM) benchmark problem 25 [53] and has been used in numerous papers for comparing optimization algorithms. The vast majority of these publications apply and compare stochastic optimization methods [32, 52], possibly combined with surrogate models [8], uncertainty quantification [39], multi-objective optimization or a combination of them [31]. Only a few papers (see, e.g., [1, 4]) choose deterministic methods, again possibly combined with surrogate models [20], uncertainty quantification [55] or multi-objective optimization. This paper addresses one of the main drawbacks of deterministic methods, which is the consideration of geometric parameters. For this example, the design element approach is used.
The SMP segment is arranged between a cylindrical inner pole and a more generally shaped outer pole (Fig. 3). The original TEAM-25 problem considers an outer pole with an elliptical inner surface. Here, the inner surface is described by a spline. This is motivated by the fact that splines are currently the basic building block for mechanical processing. The considered design parameters are then chosen to be
Both the circle and the ellipse are exactly represented by NURBS curves. The relation between the geometric parameters and the NURBS control points is given in the Appendix.
The optimization aims at a homogeneous, radially oriented magnetic flux density of \(B_{\mathrm{goal}}=0.35\) T inside the SMP segment. The objective function \(J(\mathbf{p})\) is defined as the mean-squared error between the simulated magnetic field and the goal at 9 sample points equidistantly distributed along the arc with radius \(r_\text {smp}\) between points \(e=(r_\text {smp},0)\) and \(f=(r_\text {smp}\cos \varphi _f,r_\text {smp}\sin \varphi _f)\):
where \(\varphi _k=\varphi _f \frac{k-1}{8}\) and \(\mathbf {e}_k=(\cos \varphi _k,\sin \varphi _k)\). The optimization problem yields:
where the admissible set is defined as:
For the gradient, the derivatives of J with respect to the geometry parameters \(p_i\) are needed. Before applying the chain rule on (40), the derivatives of the degrees of freedom with respect to the geometry parameters \(\partial _{p_i} {\mathbf {a}}\) are calculated as described in Sect. 3.3.2.
The performance of a standard algorithm for particle swarm optimization (PSO), of the sequential quadratic programming (SQP) method implemented in MATLAB\(^{\circledR }\)’s fmincon function [43] and of an own implementation of SQP is compared in Table 1. Both SQP implementations use the analytical gradients, the BFGS formula for updating the Hessian and a sufficient decrease condition in a merit function. For the PSO, a set of 40 particles is considered and the implementation is multi-threaded, while the gradient-based methods are single-thread implementations. The termination criterion for the PSO algorithm is the number of stall iterations, which was set to 5. The PSO actually finds the optimum after 2 iterations. This is because the optimum is at a vertex of the box-shaped domain and all the particles leaving the admissible region are projected onto the boundary. All three methods converge to the same optimum. The deterministic algorithms are substantially faster than PSO, even though PSO exploits parallelization. On the same machine, an evaluation of the objective function \(J(\mathbf{p})\) is performed in 1.65 s, an analytical evaluation of the gradient \(\nabla J(\mathbf{p})\) in 4.69 s and a numerical evaluation of the gradient \(\nabla _{\text {num}} J(\mathbf{p})\) using a forward difference quotient in 7.48 s. All tests were done on a 64 GB RAM Intel\(^{\circledR }\) Xeon\(^{\circledR }\) E5-2630 v4 machine.
5 Example 2: Permanent-magnet synchronous machine (PMSM)
5.1 Design parameters
The second example is a 3-phase 6-pole permanent-magnet (PM) synchronous machine (PMSM) borrowed from [42] (Fig. 4) and already studied as an optimization example in [5]. The stator features two slots per pole and per phase with a conventional distributed double-layer winding. The rotor contains a buried rare-earth magnet. The yoke parts are laminated. The design parameters are
5.2 Objective function
The optimization goal is to minimize the size \(S_{\mathrm{pm}}=p_1p_2\) of PM material while preserving a prescribed electromotive force \(E_0\). The electromotive force (EMF) \(E_0(\mathbf{p})\) is post-processed from a magnetostatic solution of a 2D FE model of the PMSM using the loading method proposed in [46]. For that purpose, the FE solution of the z-component of the magnetic vector potential is sampled at a circle (or in the case of a partial machine model, an arc) in the PMSM’s air gap, yielding \(A_z(r_\mathrm{ag},\varphi )\approx {\hat{A}}_{z,\mathrm{eff}}\sqrt{2}\sin (N_p\varphi -\varphi _{\mathrm{d}})\), where \(N_{p}=3\) is the pole-pair number, \({\hat{A}}_{z,\mathrm{eff}}\) is the rms magnitude of fundamental harmonic component and \(\varphi _{\mathrm{d}}\) is the angle of the PMSM’s direct axis. The EMF is then found from
where \(\omega _{\mathrm{syn}}\) is the synchronous speed and \(N_{\mathrm{w}}\) is the number of windings per phase. The winding factor is
where q is the number of coil sides per phase belt, \(\alpha _\mathrm{el}\) is the electric angle between two slots, \(\tau _{\mathrm{c}}\) is the coil pitch, \(\tau _{\mathrm{p}}\) is the pole pitch and \(\varepsilon \) is the electric skew angle [37, 46].
5.3 Optimization problem
The optimization problem reads
The first four constraints are related to the lower (\(p^{\mathrm {l}}\)) and upper (\(p^{\mathrm {u}}\)) bounds of \(\mathbf{p}\): \(\left( p^{\mathrm {l}}_1,p^{\mathrm {l}}_2,p^{\mathrm {l}}_3\right) = (1,1,5)\) mm and \(\left( p^{\mathrm {u}}_1, p^{\mathrm {u}}_2, p^{\mathrm {u}}_3\right) =(\infty , \infty , 14)\) mm. To ensure the validity of the affine parametrization (intersections are not allowed), the fifth constraint is added. The sixth constraint is a design constraint enforcing that each PM has to keep a sufficient distance to the rotor surface, especially for wide PMs. The last constraint expresses the requirement to fulfill the prescribed EMF. Since the EMF is post-processed from the FE solution, the optimization problem actually has a PDE constraint.
5.4 Results
The results for 5 different optimization methods are collected in Table 2.
-
1.
The first optimization run is carried out with the genetic algorithm implemented in MATLAB\(^{\circledR }\).
-
2.
The second optimization run is carried out with MATLAB\(^{\circledR }\)’s PSO implementation. To circumvent the restriction to box-shaped parameter domains, the admissible set is enforced by a penalty turn. The new objective function reads
$$\begin{aligned} J_\text {pen}(\mathbf{p})&=J(\mathbf{p}) +2J(\mathbf{p}) \big ( f\left( \max (p_2+p_3-15,0)\right) \nonumber \\&\quad +f\left( \max (3p_1-2p_3-50,0)\right) \nonumber \\&\quad +f\left( \max (g(x),0)\right) \big ) \text {,}\end{aligned}$$(45)where \(f(t)=e^{(4t^{0.1})}-1\) was chosen heuristically such that \(J_\text {pen}\) grows exponentially if one of the constraints is violated. The function \(J_\text {pen}\) was called 4740 times, but was organized as to only evaluate the nonlinear constraint if all other constraints were satisfied. The number of particles was set to 30, the maximum number of stall iterations to \(N_\text {stall}=15\) and the function change tolerance to \(10^{-6}\). The PSO characteristic constants are chosen to be \(\omega _0=0.5\) and \(\omega _1=\omega _2=1.49\). The algorithm took 157 iterations before termination.
-
3.
The third optimization is carried out with an own PSO implementation, for the original objective function \(J(\mathbf{p})\) and applying the nonlinear constraints directly. Here, it is assumed that the admissible set is convex such that points inside the convex hull formed by all previous points do not need to be checked. Fifty particles were used. Termination was enforced after maximally \(N_\text {it,max}=100\) steps or when \(N_\text {stall,max}=15\) stall iterations were observed.
-
4.
The fourth run was done with the deterministic method described in Sect. 2.3, relying upon FE simulations equipped with an affine parametrization of the geometry as described in Sect. 3.3.1.
-
5.
The fifth run was done with the deterministic method for robust optimization expressed by (11) in Sect. 2.5, again with affine parametrization of the geometry.
The three stochastic algorithms were run on a 64 GB RAM Intel\(^{\circledR }\) Xeon\(^{\circledR }\) E5-2630 v4 machine. Both deterministic algorithms were run on a 16 GB RAM Intel\(^{\circledR }\) Core\(^{\mathrm{TM}}\) with i7-5820K processors (3.30 GHz).
The results of all optimization procedures are compared with the values of the initial design (Fig. 5). All routines achieve a substantial decrease in the PM size from \(133~\hbox {mm}^2\) up to about \(63~\hbox {mm}^2\). The price for robustness is a slightly larger size of about \(77~\hbox {mm}^2\). The deterministic methods outperform the stochastic ones by two orders of magnitude. This impressively illustrates the major message of this paper stating that deterministic optimization methods accompanied by FE analysis providing gradients with respect to geometric parameters should be favored over stochastic methods, at least for the here considered class of problems.
6 Conclusion
Affine parametrization and design element approaches are capable of parametrizing the geometry of finite-element models such that accurate derivatives with respect to geometric parameters become available. This alleviates one of the major drawbacks of gradient-type deterministic optimization methods. For the example of a die mold press, standard sequential programming combined with the design element approach outperforms particle swarm optimization by more than a factor ten. The second example illustrates the applicability of gradient-type robust optimization combined with an affine parametrization of the geometry for a permanent-magnet synchronous machine. Supported by the substantial improvement in computational efficiency, this paper stands up for a revival of deterministic methods for numerical optimization in electrotechnical design procedures.
References
Alotto P, Nervi M (2001) An efficient hybrid algorithm for the optimization of problems with several local minima. Int J Numer Meth Eng 50:847–868
Bash ML, Pekarek SD (2011) Modeling of salient-pole wound-rotor synchronous machines for population-based design. IEEE Trans Energy Convers 26(2):381–392
Baumgartner U, Magele C, Renhart W (2004) Pareto optimality and particle swarm optimization. IEEE Trans Magn 40(2):1172
Berkani M, Giurgea S, Espanet C, Coulomb JL, Kieffer C (2013) Study on optimal design based on direct coupling between a FEM simulation model and L-BFGS-B algorithm. IEEE Trans Magn 49(5):2149–2152
Bontinck Z, Lass O, Schöps S, De Gersem H, Ulbrich S, Rain O (2018) Robust optimization formulations for the design of an electric machine. IET Sci Meas Technol (accepted). arXiv:1712.01536
Braibant V, Fleury C (1984) Shape optimal design using B-splines. Comput Methods Appl Mech Eng 44(3):247–267. https://doi.org/10.1016/0045-7825(84)90132-4
Brisset S, Vizireanu D, Brochet P (2008) Design and optimization of a nine-phase axial-flux PM synchronous generator with concentrated winding for direct-drive wind turbine. IEEE Trans Ind Appl 44(3):707–715. https://doi.org/10.1109/TIA.2008.921379
Canova A, Gruosso G, Repetto M (2003) Magnetic design optimization and objective function approximation. IEEE Trans Magn 39(5):2154–2162
Cassimere BN, Sudhoff SD (2009) Population-based design of surface-mounted permanent-magnet synchronous machines. IEEE Trans Energy Convers 24(2):338–346
Clemens M (2005) Large systems of equations in a discrete electromagnetism: formulations and numerical algorithms. IEE Proc Sci Meas Technol 152(2):50–72. https://doi.org/10.1049/ip-smt:20050849
Delfour M, Zolésio JP (2011) Shapes and geometries: metrics, analysis, differential calculus, and optimization, 2 edn. In: Advances in design and control. SIAM, Philadelphia. https://doi.org/10.1137/1.9780898719826
Di Barba P (2010) Multiobjective shape design in electricity and magnetism, lecture notes in electrical engineering. Springer, Berlin
Diehl M, Bock HG, Kostina E (2006) An approximation technique for robust nonlinear optimization. Math Program 107(1–2):213–230. https://doi.org/10.1007/s10107-005-0685-1
Duan Y, Ionel DM (2013) A review of recent developments in electrical machine design optimization methods with a permanent-magnet synchronous motor benchmark study. IEEE Trans Ind Appl 49(3):1268–1275. https://doi.org/10.1109/TIA.2013.2252597
Echeverría D, Lahaye D, Encica L, Lomonova EA, Hemker PW, Vandenput AJA (2006) Manifold-mapping optimization applied to linear actuator design. IEEE Trans Magn 42(4):1183–1186. https://doi.org/10.1109/TMAG.2006.870969
Gangl P, Amstutz S, Langer U (2016) Topology optimization of electric motor using topological derivative for nonlinear magnetostatics. IEEE Trans Magn 52(3):1–4. https://doi.org/10.1109/TMAG.2015.2496172
Gillon F, Brochet P (2000) Screening and response surface method applied to the numerical optimization of electromagnetic devices. IEEE Trans Magn 36(4):1163–1167. https://doi.org/10.1109/20.877647
Graeb HE (2007) Analog design centering and sizing. Springer, Dordrecht
Hameyer K, Kasper M (1993) Shape optimization of a fractional horse-power DC-motor by stochastic methods. In: Hernandez S, Brebbia C (eds) Computer aided optimimum design of structures III: optimization of structural systems and applications, pp 15–30
Hemker PW, Echeverría D (2007) A trust-region strategy for manifold-mapping optimization. J Comput Phys 224:464–475
Hemker T, von Stryk O, De Gersem H, Weiland T (2008) Mixed-integer nonlinear design optimization of a superconductive magnet with surrogate functions. IEEE Trans Magn 44(6):1110–1113
Hinze M, Kunkel M, Vierling M (2011) POD model order reduction of drift-diffusion equations in electrical networks. In: Benner P, Hinze M, ter Maten EJW (eds) Model reduction for circuit simulation. Lecture notes in electrical engineering, vol 74. Springer, Netherlands, pp 177–192
Ho SL, Yang S, Ni Guangzheng LEWC, Wong HC (2005) A particle swarm optimization-based method for multiobjective design optimizations. IEEE Trans Magn 41(5):1756–1759. https://doi.org/10.1109/TMAG.2005.846033
Horst R, Pardalos PM, Thoai NV (2000) Introduction to global optimization. In: Nonconvex optimization and its applications, vol 48. Springer
Hughes TJR, Cottrell JA, Bazilevs Y (2005) Isogeometric analysis: CAD, finite elements, NURBS, exact geometry and mesh refinement. Comput Methods Appl Mech Eng 194:4135–4195. https://doi.org/10.1016/j.cma.2004.10.008
Imam MH (1982) Three-dimensional shape optimization. Int J Numer Methods Eng 18(5):661–673. https://doi.org/10.1002/nme.1620180504
Kennedy J, Eberhart R (1995) Particle swarm optimization. IEEE Int Conf Neural Netw 4:1942–1948
Koch S, De Gersem H, Weiland T, Fischer E, Moritz G (2008) Transient 3D finite element simulations of the SIS100 magnet considering anisotropic, nonlinear material models for the ferromagnetic yoke. IEEE Trans Appl Supercond 18(2):1601–1604
Koziel S, Leifsson L (2013) Surrogate-based modeling and optimization: applications in engineering. Springer, Berlin
Lass O, Ulbrich S (2017) Model order reduction techniques with a posteriori error control for nonlinear robust optimization governed by partial differential equations. SIAM J Sci Comput 39(5):S112–S139. https://doi.org/10.1137/16M108269X
Lebensztajn L, Rondini Marretto CA, Caldora Costa M, Coulomb JL (2004) Kriging: a useful tool for electromagnetic device optimization. IEEE Trans Magn 40(2):1196–1199
Lei G, Liu C, Zhu J, Guo Y (2015) Techniques for multilevel design optimization of permanent magnet motors. IEEE Trans Energy Convers 30(4):1574–1584
Lok CL, Vengadaesvaran B, Ramesh S (2017) Implementation of hybrid pattern search-genetic algorithm into optimizing axial-flux permanent magnet coreless generator (AFPMG). Electr Eng 99:751–761. https://doi.org/10.1007/s00202-016-0443-9
Ma C, Qu L (2015) Multiobjective optimization of switched reluctance motors based on design of experiments and particle swarm optimization. IEEE Trans Energy Convers 30(3):1144–1153
Man KF, Tang KS, Kwong S (2012) Genetic algorithms: concepts and designs. Springer, Berlin
Monk P (2003) Finite element methods for Maxwell’s equations. Oxford University Press, Oxford
Müller G, Vogt K, Ponick B (1974) Berechnung elektrischer Maschinen, 6th edn. Wiley-VCH, Weinheim
Neri F, Tirronen V (2010) Recent advances in differential evolution: a survey and experimental analysis. Artif Intell Rev 33(1–2):61–106. https://doi.org/10.1007/s10462-009-9137-2
Nishida N, Takahashi Y, Wakao S (2008) Robust design optimization approach by combination of sensitivity analysis and sigma level estimation. IEEE Trans Magn 44(6):998–1001
Nocedal J, Wright SJ (2006) Numerical optimization. Springer series in operations research and financial engineering, 2nd edn. Springer, New York
Omekanda AM (2006) Robust torque and torque-per-inertia optimization of a switched reluctance motor using the Taguchi methods. IEEE Trans Ind Appl 42(2):473–478
Pahner U, Mertens R, De Gersem H, Belmans RJM, Hameyer K (1998) A parametric finite element environment tuned for numerical optimization. IEEE Trans Magn 34(5):2936–2939. https://doi.org/10.1109/20.717685
Powell MJD (1978) A fast algorithm for nonlinearly constrained optimization calculations, vol 630. Springer, Berlin, pp 144–157
Powell MJD (2002) UOBYQA: unconstrained optimization by quadratic approximation. Math Program B92:555–582. https://doi.org/10.1007/s101070100290
Powell MJD (2009) The BOBYQA algorithm for bound constrained optimization without derivatives. In: Technical report DAMTP 2009/NA06. Cambridge University Press
Rahman MA, Zhou P (1991) Determination of saturated parameters of PM motors using loading magnetic fields. IEEE Trans Magn 27(5):3947–3950. https://doi.org/10.1109/20.104967
Rozza G, Huynh DBP, Patera AT (2008) Reduced basis approximation and a posteriori error estimation for affinely parametrized elliptic coercive partial differential equations. Arch Comput Methods Eng 15(3):229–275. https://doi.org/10.1007/s11831-008-9019-9
Russenschuck S (1990) Mathematical optimization techniques for the design of permanent magnet synchronous machines based on numerical field calculation. IEEE Trans Magn 26(2):638–641
Ryu JS, Yao Y, Koh CS, Yun S, Kim DS (2005) Optimal shape design of 3-D nonlinear electromagnetic devices using parameterized design sensitivity analysis. IEEE Trans Magn 41(5):1792–1795. https://doi.org/10.1109/TMAG.2005.845982
Sevilla R, Fernández-Méndez S, Huerta A (2008) NURBS-enhanced finite element method (nefem). Ph.D. Thesis, Universitat Politècnica de Catalunya (2008)
Sizov GY, Zhang P, Ionel DM, Demerdash NAO, Rosu M (2013) Automated multi-objective design optimization of PM AC machines using computationally efficient FEA and differential evolution. IEEE Trans Ind Appl 49(5):2086–2096
Sonoda S, Takahashi Y, Kawagishi K, Nishida N, Wakao S (2007) Application of stepwise multiple regression to design optimization of electric machine. IEEE Trans Magn 43(4):1609–1612
Takahashi N (1997) Optimization of die press model (TEAM workshop problem 25). Technical report, International Compumag Society. http://www.compumag.org/jsite/images/stories/TEAM/problem25.pdf. Accessed 11 Mar 2018
Takahashi N, Ebihara K, Yoshida K, Nakata T, Ohashi K, Miyata K (1996) Investigation of simulated annealing method and its application to optimal design of die mold for orientation of magnetic powder. IEEE Trans Magn 32(3):1210–1213. https://doi.org/10.1109/20.497461
Takahashi RHC, Ramírez JA, Vasconcelos JA, Saldanha RR (2001) Sensitivity analysis for optimization problems solved by stochastic methods. IEEE Trans Magn 37(5):3566–3569. https://doi.org/10.1109/20.952663
Takorabet N, Laporte B, Vinsard G (1997) On the optimization of linear induction devices. Electr Eng 80:221–226
Trältzsch F (2009) Optimale Steuerung Partieller Differentialgleichungen: Theorie. Springer, Verfahren und Anwendungen
Weeber K, Hoole SRH (1992) Geometric parametrization and constrained optimization techniques in the design of salient pole synchronous machines. IEEE Trans Magn 28(4):1948–1960
Wrobel R, Lukaniszyn M, Jagiela M, Latawiec K (2003) A new approach to reduction of the cogging torque in a brushless motor by skewing optimization of permanent magnets. Electr Eng 85:59–69. https://doi.org/10.1007/s00202-002-0144-4
Yoon SB, Jung IS, Hyun DS, Hong JP, Kim YJ (1999) Robust shape optimization of electromechanical devices. IEEE Trans Magn 35(3):1710–1713. https://doi.org/10.1109/20.767356
Acknowledgements
This work is supported by the German BMBF in the context of the SIMUROM project (grant nr. 05M2013) and the PASIROM project (grant nr. 05M2018), by the ’Excellence Initiative’ of the German Federal and State Governments and by the Centre and Graduate School Computational Engineering at TU Darmstadt.
Author information
Authors and Affiliations
Corresponding author
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Appendix
Appendix
The dependence between the geometry parameters and the NURBS representation of the die press model is as follows. For the ellipse arc, the control points and weights are
where
The corresponding knots are \({\mathcal {K}}=\{0,0,0,1,1,1\}\), and the degree of the basis functions is \(p=2\).
For the circular arc, the control points are
with the constant weights
The degree of the basis functions is \(p=2\). The corresponding knots are \({\mathcal {K}}=\{0,0,0,1,1,1\}\). The deformation of the mesh inside one design element region \(V_{D}^{\ell }\) with \(N_V\) vertices is given by
where \((x_i,y_i)\) are the coordinates of the vertices of the deformed mesh and \(({\hat{x}}_i,{\hat{y}}_i)\) are the coordinates in the reference domain \([0,1]^2\).
Rights and permissions
Open Access This article is distributed under the terms of the Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/), which permits unrestricted use, distribution, and reproduction in any medium, provided 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.
About this article
Cite this article
Ion, I.G., Bontinck, Z., Loukrezis, D. et al. Robust shape optimization of electric devices based on deterministic optimization methods and finite-element analysis with affine parametrization and design elements. Electr Eng 100, 2635–2647 (2018). https://doi.org/10.1007/s00202-018-0716-6
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s00202-018-0716-6