Abstract
This note communicates a simple modification of the optimality criteria (OC) design update—as found in well-known Matlab implementations of the classical topology design problem—to an update based on a quadratic program (QP) with a single linear constraint. This QP update is a special case of the dual of Falk, which in general accommodates multiple constraints, as discussed in the Appendix. It is demonstrated that the topology design problem of self-weight may be treated with judicious selection of the adaptive curvature term in the QP, without resorting to more sophisticated algorithms or material interpolation schemes. Theory is recited and an accordingly modified version of the canonical Matlab implementation is provided as supplementary material.
Avoid common mistakes on your manuscript.
1 Introduction
The simple and effective 99- and 88-line Matlab implementation of the classical minimum compliance topology design problem (Bendsøe and Sigmund 2003; Andreassen et al. 2011) is well known in the topology optimization community. At the heart of the implementation is the optimality criteria (OC) design update (Bendsøe and Sigmund 2003). Given a design variable array \({\varvec{x}}^{k}\) with n elements, in some iteration k (also the zeroth iterate), the design is updated according to
with bounds applied to each value in the new design iterate \(\varvec{x}^{k+1}\), such that
for \(i = 1,2,\ldots ,n\). The design variable bounds in each design iterate, \({\check{\varvec{x}}}^k\) and \({\hat{\varvec{x}}}^k\), are determined by a prescribed move limit and the global design variable bounds at 0 and 1. The \(\eta\) is a ‘tuning parameter’ (or ‘numerical damping’ coefficient), typically set at 0.5. The \({\textrm{d}}^k_{\varvec{x}} f_0\) and \({\textrm{d}}^k_{\varvec{x}} f_1\) are the sensitivitiesFootnote 1 of the objective and constraint function, evaluated at design iterate k. When applied to the classical minimum compliance topology design problem, \(f_0\) is the compliance objective and \(f_1\) is the resource constraint. The \(\lambda\) is the Lagrange multiplier (dual variable) associated with the constraint, computed with a bisectioning algorithm.
With fixed (constant) external loads, the minimum compliance objective function is monotonic: the first-order derivatives are negative \({{\textrm{d}}_{x_i}^k f_0} \le 0 \, \forall i\) at any design \(\varvec{x}^k\). The resource constraint has strictly positive sensitivities \({{\textrm{d}}_{x_i}^k f_0} > 0 \, \forall i\), and the Lagrange multiplier is positive \(\lambda > 0\) due to activity of the inequality constraint in negative null form. Therefore, the square-root implicated by \(\eta = 0.5\) in the OC update (1) is guaranteed to yield real numbers. Bendsøe and Sigmund (2003) address the issue which arises when a positive number under the square-root cannot be guaranteed. For example, in eigenvalue maximization problems, it is suggested that the OC update is modified to
The same is done in Bendsøe and Sigmund’s (2003) treatment of (linear) compliant mechanism design, with \(\eta\) ‘sometimes chosen a bit lower’ to promote stable convergence. A smaller value for \(\eta\) corresponds to reciprocal intervening variables with a larger (negative) exponent, increasing the effective curvature of the resulting objective function approximation (Groenwold and Etman 2008b). Generalized and adaptive intervening (or intermediate) variables form the basis of the very successful CONLIN (Fleury 1989) and MMA (Svanberg 1987) algorithms.
Arguably, the simplest topology optimization problem with a non-monotonic objective function is the classical minimum compliance design problem posed with design-dependent self-weight loads (i.e. body forces). See Bruyneel and Duysinx (2005). In classical minimum compliance design with fixed external loading, increasing the material at a point in a structure can only decrease the total elastic energy—proportional to compliance. However, if the load on the structure is the self-weight, then a non-trivial trade-off occurs: increasing the amount of material at a point in the structure increases its stiffness, but it also increases the load, and, depending on the configuration, it may increase the total elastic energy. Considering only self-weight loads, without a constraint on the minimum amount of material to be distributed, the global optimum is, strictly speaking, the trivial all-void design associated with no loading whatsoever.
Bruyneel and Duysinx (2005) summarize the difficulties in the self-weight problem, as follows: (i) non-monotonicity of the compliance objective function, (ii) the ‘unconstrained character of the optimum’, and (iii) the ‘parasitic effect for low densities’.Footnote 2 To address (iii), Bruyneel and Duysinx (2005) introduce a modification to the SIMP material law, making it linear at small design variable values. To address (ii), a constraint on the minimum amount of material to be distributed is introduced. And to address (i), the ‘structural [response function] approximations’ in the MMA are modified.
With the work of Bruyneel and Duysinx (2005) serving as backdrop, and prompted by contemporary works on the subject (Kumar 2022; Garaigordobil et al. 2022), we wish to show that the self-weight problem can also be solved with a design update based on a quadratic program (QP) with an adaptive curvature approximation, without modifying the material interpolation scheme. That is to say, we retain a straight-forward optimization problem formulation:
wherein \(\varvec{u}\) is the displacement degrees-of-freedom dependent implicitly on the design variables \(\varvec{x}\), \(\varvec{u}[\varvec{x}]\), via solution of the linear, finite element discretized equilibrium equations \(\varvec{K}[\varvec{x}] \varvec{u}= \varvec{g}[\varvec{x}]\) in each design iterate. The design variables are subjected to density filtering \(\varvec{\rho } = \varvec{H}\varvec{x}\) and SIMP is applied (Bendsøe and Sigmund 2003) in the construction of the global stiffness matrix \(\varvec{K}\). The self-weight (body-force) per element \(\varvec{g}_e\) is taken to scale linearly with the corresponding (filtered) density variable \(\rho _e\), and the resource constraint is modified to enforce distribution of a minimum amount of material in terms of a volume fraction \(v\). See the Appendix for the treatment of the more general problem with the addition of a fixed external load and a second resource constraint on the maximum amount of material to be distributed—a variant also studied by Bruyneel and Duysinx (2005). The reader is invited to consult the cited literature and the Matlab implementation provided in the supplementary material for more detail.
In the following section theory is recited, after which the implementation and numerical demonstrations are presented.
2 An adaptive QP
Groenwold et al. (2007) generalize the notion of intervening variable functions with the introduction of incomplete Taylor series expansions for function approximation. Arguably, the simplest response function approximation is quadratic with a single (scalar) curvature term \(c^k\), written as
In general, the quadratic (or curvature) terms may be constructed in all manner of ways, including the approximation (5) to the response function linearized in terms of intervening variables (Groenwold et al. 2010). The so-called spherical quadratic approximation (Groenwold et al. 2007, 2010) is obtained with
a result of requiring the function approximation to render the same zero-order information \({f}_0^{k-1}\) at the previous design iterate \(\varvec{x}^{k-1}\). Strict convexity of the objective function approximation is enforced by
with \(\epsilon\) a small positive number—e.g. 1E\(-9\). Limiting ourselves to a single linear constraint, herein, we can write an OC-like update of the form
which results from requiring the Lagrangian of the QP associated with the iterate to be stationary with respect to \(\varvec{x}\). In this case, the Lagrange multiplier (dual variable) \(\lambda\) can be determined with the same bisectioning algorithm employed in the OC update, and the bounds (2) are applied as before. This is a special case of the dual due to Falk (1967), as discussed in more detail in the Appendix.
Due to the simplicity of the QP, and because the problem is simply constrained, so-called global convergence (enforced convergence) of the GCMMA (Svanberg 2002) is readily applied by requiring a descent step in each design iterate \({f}_0^{k+1} < {f}_0^{k}\). If a descent step is not taken, the previous iterate is restored and the curvature approximation of the objective function is increased by some factor, e.g. \(c^k \leftarrow 2 c^k\). We return to this topic later. See Groenwold and Etman for a detailed description of enforced convergence by conditional acceptance of iterates (Groenwold and Etman 2010a).
3 Implementation and demonstration
We take as basis the 88-line Matlab implementation of the classical minimum compliance problem with fixed external loads and the OC solution procedure (Andreassen et al. 2011). Please see the modified code topqpsw.m provided in the Supplementary Material. The fixed external loading is removed, design-dependent (distributed) loads in the y direction are introduced (lines 52–56), the objective sensitivities are modified (line 64), density filtering is used exclusively, and the resource constraint and its sensitivities are modified to limit the minimum amount of material to be distributed (lines 65–66). Please see the Appendix for the treatment of the problem with additional external loading and a second resource constraint on the maximum amount of material to be distributed. Variables and logic are introduced to calculate the adaptive curvature term (6) (line 85) and optionally enforce convergence (lines 77–91) with the input flag ec. Other modifications include scaling of the objective function (lines 68–71), provision of additional output information—e.g. the ‘black-and-white’ fraction (B &W) of the design—and the convergence criteria (line 49).
The OC update is replaced by the QP update (8) (lines 93–102):
A smaller move limit than typical is set (0.1 vs 0.2) in the presence of this less well-behaved, non-monotonic objective function.
The first example concerns the well-known MMB beam design domain and kinematic boundary conditions (symmetry and roller support). It may be executed with topqpsw(180,60,0.1,3.,3.,0). The result—the filtered design variable field \(\varvec{\rho }\) at termination—is given in Fig. 1. The number of iterations k, the objective function value \({f}_0\), the volume fraction V, and the black-and-white fraction \(B \& W\) are given in the caption of the figure. The constraint on the minimum amount of material (volume) to be distributed is not active. Executed with a larger filter radius (e.g. 4), increasing the minimum feature size of the design, increases the volume fraction at solution further (e.g. 0.19). It is understood that a particular amount of material is required to construct a topology which connects the roller supports in some stiffness optimized manner with respect to its own weight.
The second example is a self-weight arch. The roller is changed to a pin support, with line 20 replaced by
The example may then be executed with topqpsw(120,120,0.1,3,3,0). This case confirms the difficulties in the self-weight problem: iterates oscillate with low-density material and termination occurs at a design with a low black-and-white fraction (0.87). This is remedied by running the case with enforced convergence; topqpsw(120,120,0.1,3,3,1). The result is given in Fig. 2. In this case, the constraint on the minimum amount of volume is active. If executed with a lower volume fraction (e.g. 0.05), it is recommended to modify the starting point (line 45) to, e.g. x = repmat(0.5,nely,nelx); in order that, too much material is not zeroed in the initial iterates, causing the run to have a bad starting position.
The same is achieved in 3D using a simple C/C++ implementation (provided on request). Figures 3 and 4 illustrate the result of a 3D version of the self-weight arch problem considered above, with volume fractions of 0.05 and 0.07, respectively. The density field is interpolated to the nodes and clipped at 0.25. The domain is 100\(\times\)100\(\times\)50 elements. In both cases, the volume constraint is active at the solution.
4 Concluding remarks
It is fairly remarkable that the self-weight problem, typically addressed with modification of material interpolation schemes and sophisticated algorithms, can be solved with only a simple QP design update with an adaptive curvature approximation. The QP update presented is a special case of the dual of Falk (1967), with which multiple constraints may be treated—see the Appendix. Curvature information (if present) of constraint functions may also be taken into account (Groenwold 2012).
Notes
First-order derivatives evaluated at \(\varvec{x}^k\), written in an abbreviated (Euler-like) notation; \({\textrm{d}}^k_{x_i} f_0 = \frac{{\textrm{d}}f_0}{{\textrm{d}}x_i} \Big \vert _{\varvec{x}=\varvec{x}^k}\).
The penalized stiffness tends to zero faster than the self-weight load, as the associated design variable goes to zero. But of course, a minimum stiffness is typically present to prevent singularity of the global stiffness matrix.
The interested reader will see that the implementation with two back-to-back QP updates, topqp2vsw.m yields the same results.
References
Andreassen E, Clausen A, Schevenels M, Lazarov BS, Sigmund O (2011) Efficient topology optimization in MATLAB using 88 lines of code. Struct Multidisc Optim 43(1):1–16
Bendsøe MP, Sigmund O (2003) Topology optimization: theory, methods, and applications. Springer, Berlin
Bruyneel M, Duysinx P (2005) Note on topology optimization of continuum structures including self-weight. Struct Multidisc Optim 29(4):245–256
Cronje M, Ras MN, Munro DP, Groenwold AA (2019) Brief note on equality constraints in pure dual SAO settings. Struct Multidisc Optim 59(5):1853–1861
Falk JE (1967) Lagrange multipliers and nonlinear programming. J Math Anal Appl 19(1):141–159
Fleury C (1989) CONLIN: an efficient dual optimizer based on convex approximation concepts. Struct Optim 1(2):81–89
Garaigordobil A, Ansola R, Canales J, Borinaga R (2022) Addressing topology optimization with overhang constraints for structures subjected to self-weight loads. Struct Multidisc Optim 65(358):1–15
Groenwold AA (2012) Positive definite separable quadratic programs for non-convex problems. Struct Multidisc Optim 46(6):795–802
Groenwold AA, Etman L (2008a) Sequential approximate optimization using dual subproblems based on incomplete series expansions. Struct Multidisc Optim 36:547–570
Groenwold AA, Etman LFP (2008b) On the equivalence of optimality criterion and sequential approximate optimization methods in the classical topology layout problem. Int J Numer Methods Eng 73(3):297–316
Groenwold AA, Etman L (2010a) On the conditional acceptance of iterates in sao algorithms based on convex separable approximations. Struct Multidisc Optim 42(2):165–178
Groenwold AA, Etman L (2010b) A quadratic approximation for structural topology optimization. Int J Numer Methods Eng 82(4):505–524
Groenwold AA, Etman L, Snyman J, Rooda J (2007) Incomplete series expansion for function approximation. Struct Multidisc Optim 34(1):21–40
Groenwold AA, Etman L, Wood DW (2010) Approximated approximations for SAO. Struct Multidisc Optim 41(1):39–56
Haftka RT, Gürdal Z, Kamat MP (1991) Elements of structural optimization. Kluwer, Dordrecht
Kumar P (2022) Topology optimization of stiff structures under self-weight for given volume using a smooth heaviside function. Struct Multidisc Optim 65(4):1–17
Liu DC, Nocedal J (1989) On the limited memory BFGS method for large scale optimization. Math Program 45(1):503–528
Svanberg K (1987) The method of moving asymptotes-a new method for structural optimization. Int J Numer Methods Eng 24(2):359–373
Svanberg K (2002) A class of globally convergent optimization methods based on conservative convex separable approximations. SIAM J Optim 12(2):555–573
Acknowledgements
This note is in loving memory of Albert Groenwold, who passed away on August 3rd, 2022.
Funding
The research presented herein is the result of extracurricular activities—not funded.
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The author declares that he has no conflict of interest.
Replication of results
The codes used to generate the 2D results in the body and the appendix of this note, topqpsw.m, topqp2vsw.m, topqpmcsw.m, can be found in the Supplementary Material. Matlab R2022b was used throughout. Please contact the author for the code used to produce the 3D results.
Additional information
Responsible Editor: Jianbin Du
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Supplementary Information
Below is the link to the electronic supplementary material.
Appendix: The dual of Falk
Appendix: The dual of Falk
Bruyneel and Duysinx (2005) also study the more general problem with a constraint on each the minimum (\({{\check{v}}}\)) and maximum (\({{\hat{v}}}\)) amount of material (volume) to be distributed
in the presence of a fixed (constant) external load \(\textbf{f}\) in addition to the self-weight loads, \(\varvec{K}[\varvec{x}] \varvec{u}= \varvec{g}[\varvec{x}] + \textbf{f}\).
It should be mentioned that Problem (9) may be treated by simply adding a second QP update (8), but with the maximum volume constraint \(f_2\) in the (bisectioning) loop, if the minimum volume constraint \(f_1\) is not active. This is determined based on the value of the Lagrange multiplier (dual variable) lmid, e.g. if lmid \(<1e-9\). That is, we may implement, for example topqp2vsw.m (lines 93–118). (Further below an example is introduced with fixed external loading.) However, this manner of determining the active constraint is of course problem specific. It is also worth a mention that a single volume constraint may be treated as an equality constraint by setting l1 = -1e9 at initialization (line 93 in topqpsw.m) of the bisectioning algorithm. See Cronje et al. (2019) for a more complete description of equality constraints in dual subproblems.
The QP update presented in the body of this note is a specific case of a (strictly) convex approximate subproblem solved in dual form—in particular the dual due to Falk (1967)—a cornerstone of structural optimization. ‘Historically’, write Haftka et al. (1991), ‘optimality criteria methods preceded pure dual methods in their application to optimum structural design’, and, moreover, ‘dual methods have been used to examine the theoretical basis of some popular optimality criteria methods’. They continue to discuss dual methods, prior to discussing optimality criteria methods, ‘because of their theoretical significance’. In the canonical work on topology optimization by Bendsøe and Sigmund (2003), the OC update (1) is (rather unfortunately) referred to as ‘heuristic’, and the values selected for the parameter \(\eta\) is ‘chosen by experiment’. Groenwold and Etman (2008) have since demonstrated that the OC update with \(\eta = 0.5\) is exactly the same design update obtained in dual form, in classical minimum compliance topology design, when the objective function is linearized in terms of reciprocal intervening variables.
In topology optimization, in particular, the number of design variables n is typically significantly larger than the number of constraints m. The dual form is therefore attractive because solution of the subproblem reduces to a bound constrained maximization of a (or minimization of its negative) function of dimension m. The dual approximate subproblem is written as
wherein we rely on strict convexity of the primal approximate subproblem to obtain a closed-form expression for the primal (design) variables in terms of the dual variables, \(\varvec{x}:= \varvec{x}\left[ \varvec{\lambda }\right]\). That is the QP update (8), except that, in this case, multiple linear constraints form part of the relation
In general, second-order approximations to constraint functions may be accounted for, and non-convex curvature information may enter the subproblem without sacrificing the availability of the closed-form primal-dual relation, \(\varvec{x}[\varvec{\lambda }]\). The interested reader is referred to the work of Groenwold and co-workers, for example References Groenwold and Etman (2008a), Groenwold and Etman (2010b), Groenwold (2012), and the citations therein.
The implementation of Problem (9) and the associated QP update with multiple linear constraints (11), solved in the dual form (10), is provided in the Supplementary Material (topqpmcsw.m). The dual subproblem—the bound constrained maximization problem (10)—is solved with fmincon (line 98). (L-BFGS-B (Liu and Nocedal 1989) is typically used.) The dual function and its gradient is computed in the falkdual function (lines 118–129), and the QP update (11) is defined in lines 131–138. For the purpose of illustration, consider the beam structure of Bruyneel and Duysinx (Section 6.2) (Bruyneel and Duysinx 2005). First a solution to the problem with only self-weight is obtained with topqpsw(160,80,0.1,3.,5.,0). This yields a volume fraction of 0.16—see Fig. 5—which is equal to the total self-weight load due to the choice of the effective gravity and density. Line 53 in topqpmcsw.m may then be replaced with
to include an external load of magnitude 10% of the total weight at a volume fraction of 0.16. The volume fraction of 0.16 is then used for the maximum volume fraction \({{\hat{v}}}\), by executing a run with topqpmcsw(160,80,0.1,0.16,3.,5.,0). Using the same fractions of the total self-weight load as that of Bruyneel and Duysinx (2005), the solutions in Figs. 6, 7, 8, 9, and 10 are obtained.Footnote 3 For the result given in Fig. 10, the self-weight loads are zeroed gv = 0; (line 52). In all cases, the maximum volume constraint \({f}_2\) is active.
Interestingly, a large number of iterations (638) are required to converge to a solution of the classical minimum compliance problem (without self-weight loads)—see Fig. 10. However, the reader is encouraged to run the same problem with the original top88 code (Andreassen et al. 2011), with top88(160,80,0.16,3.,5.,2). Irrespective of the tolerance set in the bisectioning algorithm (e.g. \(1e-3\), \(1e-9\)),= and the move limit (e.g. 0.2, 0.1), a different topology with an inferior objective function value (\({f}_0 \approx 17\)) is returned, after about 500 iterations.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Munro, D. A simple QP modification of the OC update to permit treatment of the topology design problem of self-weight. Struct Multidisc Optim 67, 25 (2024). https://doi.org/10.1007/s00158-024-03753-7
Received:
Revised:
Accepted:
Published:
DOI: https://doi.org/10.1007/s00158-024-03753-7