Skip to main content
Log in

An 88-line MATLAB code for the parameterized level set method based topology optimization using radial basis functions

  • EDUCATIONAL ARTICLE
  • Published:
Structural and Multidisciplinary Optimization Aims and scope Submit manuscript

Abstract

This paper presents a compact and efficient 88-line MATLAB code for the parameterized level set method based topology optimization using radial basis functions (RBFs), which is applied to minimize the compliance of a two-dimensional linear elastic structure. This parameterized level set method using radial basis functions can maintain a relatively smooth level set function with an approximate re-initialization scheme during the optimization process. It also has less dependency on initial designs due to its capability in nucleation of new holes inside the material domain. The MATLAB code and simple modifications are explained in detail with numerical examples. The 88-line code included in the appendix is intended for educational purposes.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Institutional subscriptions

Fig. 1
Fig. 2
Fig. 3
Fig. 4
Fig. 5
Fig. 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13
Fig. 14
Fig. 15
Fig. 16

References

  • Allaire G (2009) A 2-d Scilab Code for shape and topology optimization by the level set method. http://www.cmap.polytechnique.fr/∼allaire/levelset_en.html

  • Allaire G, Jouve F, Toader AM (2004) Structural optimization using sensitivity analysis and a level-set method. J Comput Phys 194(1):363–393

    Article  MathSciNet  MATH  Google Scholar 

  • Allaire G, De Gournay F, Jouve F, Toader AM (2005) Structural optimization using topological and shape sensitivity via a level set method. Control Cybern 34(1):59–80

    MathSciNet  MATH  Google Scholar 

  • Andreassen E, Clausen A, Schevenels M, Lazarov BS, Sigmund O (2011) Efficient topology optimization in MATLAB using 88 lines of code. Struct Multidiscip Optim 43(1):1–16

    Article  MATH  Google Scholar 

  • Bendsøe M, Sigmund O (2003) Topology optimization. Theory, methods and applications. Springer, Berlin

    MATH  Google Scholar 

  • Burger M, Osher SJ (2005) A survey on level set methods for inverse problems and optimal design. Eur J Appl Math 16(2):263–301

    Article  MathSciNet  MATH  Google Scholar 

  • Burger M, Hackl B, Ring W (2004) Incorporating topological derivatives into level set methods. J Comput Phys 194(1):344–362

    Article  MathSciNet  MATH  Google Scholar 

  • Cecil T, Qian J, Osher S (2004) Numerical methods for high dimensional Hamilton-Jacobi equations using radial basis functions. J Comput Phys 196(1):327–347

    Article  MathSciNet  MATH  Google Scholar 

  • Challis VJ (2010) A discrete level-set topology optimization code written in MATLAB. Struct Multidiscip Optim 41(3):453–464

    Article  MathSciNet  MATH  Google Scholar 

  • Chan TF, Vese LA (2001) Active contours without edges. IEEE Trans Image Process 10(2):266–277

    Article  MATH  Google Scholar 

  • Choi KK, Kim NH (2005) Structural sensitivity analysis and optimization 1. Springer, Berlin

    Google Scholar 

  • Deaton JD, Grandhi RV (2014) A survey of structural and multidisciplinary continuum topology optimization: post 2000. Struct Multidiscip Optim 49(1):1–38

    Article  MathSciNet  Google Scholar 

  • Dijk NPV, Maute K, Langelaar M, van Keulen F (2013) Level-set methods for structural topology optimization: a review. Struct Multidiscip Optim 48(3):437–472

    Article  MathSciNet  Google Scholar 

  • Emre B, To AC (2015) Proportional topology optimization: a new non-sensitivity method for solving stress constrained and minimum compliance problems and its implementation in MATLAB. PLoS One 10(12):e0145041

    Article  Google Scholar 

  • Gain AL, Paulino GH (2013) A critical comparative assessment of differential equation-driven methods for structural topology optimization. Struct Multidiscip Optim 48(4):685–710

    Article  MathSciNet  Google Scholar 

  • Huang X, Xie YM (2010) Evolutionary Topology Optimization of Continuum Structures: Methods and Applications. Wiley, New York

    Book  MATH  Google Scholar 

  • Kansa EJ, Power H, Fasshauer GE, Ling L (2004) A volumetric integral radial basis function method for time-dependent partial differential equations. I. Formulation. Eng Anal Bound Elem 28(10):1191–1206

    Article  MATH  Google Scholar 

  • Kharmanda G, Olhoff N, Mohamed A, Lemaire M (2004) Reliability-based topology optimization. Struct Multidiscip Optim 26(5):295–307

    Article  Google Scholar 

  • Liu K, Tovar A (2014) An efficient 3d topology optimization code written in MATLAB. Struct Multidiscip Optim 50(6):1175–1196

    Article  MathSciNet  Google Scholar 

  • Mei Y, Wang X (2004) A level set method for structural topology optimization and its applications. Adv Eng Softw 35(7):415–441

    Article  MATH  Google Scholar 

  • Morse BS, Yoo TS, Chen DT, Rheingans P, Subramanian KR (2001) Interpolating implicit surfaces from scattered surface data using compactly supported radial basis functions. Int Conf Shape Model Appl 15(2):89–98

    Article  Google Scholar 

  • Olesen LH, Okkels F, Bruus H (2006) A high-level programming-language implementation of topology optimization applied to steady-state navier-stokes flow. Int J Numer Methods Eng 65(7):975–1001

    Article  MathSciNet  MATH  Google Scholar 

  • Osher S, Fedkiw R (2002) Level set methods and dynamic implicit surfaces. Springer, New York

    MATH  Google Scholar 

  • Osher S, Santosa F (2001) Level set methods for optimization problems involving geometry and constraints: i. Frequencies of a two-density inhomogeneous drum. J Comput Phys 171(1):272–288

    Article  MathSciNet  MATH  Google Scholar 

  • Osher S, Sethian JA (1988) Fronts propagating with curvature-dependent speed: algorithms based on HamiltonJacobi formulations. J Comput Phys 79(1):12–49

    Article  MathSciNet  MATH  Google Scholar 

  • Otomori M, Yamada T, Izui K, Nishiwaki S (2014) MATLAB code for a level set-based topology optimization method using a reaction diffusion equation. Struct Multidiscip Optim 51(5):1159–1172

    Article  MathSciNet  Google Scholar 

  • Peng D, Merriman B, Osher S, Zhao H.& Kang M. (1999) A PDE-based fast local level set method. J Comput Phys 155(2):410–438

    Article  MathSciNet  MATH  Google Scholar 

  • Rochafellar RT (1973) The multiplier method of Hestenes and Powell applied to convex programming. J Optim Theory Appl 12:555–562

    Article  MathSciNet  Google Scholar 

  • Schmidt S, Schulz V (2011) A 2589 line topology optimization code written for the graphics card. Comput Vis Sci 14(6):249–256

    Article  MathSciNet  MATH  Google Scholar 

  • Sethian JA (1999) Level set methods and fast marching methods: evolving interfaces in computational geometry, fluid mechanics, computer vision, and materials science. Cambridge University Press, Cambridge

    MATH  Google Scholar 

  • Sethian JA, Wiegmann A (2000) Structural boundary design via level set and immersed interface methods. J Comput Phys 163(2):489–528

    Article  MathSciNet  MATH  Google Scholar 

  • Sigmund O (2001) A 99 line topology optimization code written in MATLAB. Struct Multidiscip Optim 21(21):120–127

    Article  Google Scholar 

  • Sigmund O, Maute K (2013) Topology optimization approaches. Struct Multidiscip Optim 48(6):1031–1055

    Article  MathSciNet  Google Scholar 

  • Sokołowski J, Żochowski A (1999) On the topological derivative in shape optimization. SIAM J Control Optim 37(4):1251–1272

    Article  MathSciNet  MATH  Google Scholar 

  • Sokołowski J, Zolésio JP (1992) Introduction to shape optimization: shape Sensitity analysis. Introduction to shape optimization : shape sensitivity analysis. Springer-Verlag, Berlin

    MATH  Google Scholar 

  • Suresh K (2010) A 199-line MATLAB code for Pareto-optimal tracing in topology optimization. Struct Multidiscip Optim 42(5):665–679

    Article  MathSciNet  MATH  Google Scholar 

  • Talischi C, Paulino GH, Pereira A, Menezes IFM (2012) Polytop: a MATLAB implementation of a general topology optimization framework using unstructured polygonal finite element meshes. Struct Multidiscip Optim 45(3):329–357

    Article  MathSciNet  MATH  Google Scholar 

  • Tavakoli R, Mohseni SM (2014) Alternating active-phase algorithm for multimaterial topology optimization problems: a 115-line MATLAB implementation. Struct Multidiscip Optim 49(4):621–642

    Article  MathSciNet  Google Scholar 

  • Van Dijk NP, Maute K, Langelaar M, Van Keulen F (2013) Level-set methods for structural topology optimization: a review. Struct Multidiscip Optim 48(3):437–472

    Article  MathSciNet  Google Scholar 

  • Wang SY, Wang MY (2006a) Radial basis functions and level set method for structural topology optimization. Int J Numer Meth Engng 65:2060–2090

    Article  MathSciNet  MATH  Google Scholar 

  • Wang SY, Wang MY (2006b) Structural shape and topology optimization using an implicit free boundary parameterization method. Comput Model Eng Sci 13(2):119–147

    MathSciNet  MATH  Google Scholar 

  • Wang MY, Wei P (2005) Topology optimization with level set method incorporating topological derivative. 6th World Congress on Structural & Multidisciplinary Optimization, Rio de Janeiro, Brazil

  • Wang MY, Wang X, Guo D (2003) A level set method for structural topology optimization. Comput Methods Appl Mech Eng 192(1–2):227–246

    Article  MathSciNet  MATH  Google Scholar 

  • Wang MY, Chen SK, Xia Q (2004) TOPLSM, 199-line version. http://ihome.ust.hk/~mywang/download/TOPLSM_199.m

  • Wang SY, Lim KM, Khoo BC, Wang MY (2007) An extended level set method for shape and topology optimization. J Comput Phys 221(1):395–421

    Article  MathSciNet  MATH  Google Scholar 

  • Wei P, Wang MY (2006) The augmented Lagrangian method in structural shape and topology optimization with RBF based level set method, The 4th China-Japan-Korea Joint Symposium on Optimization of Structural and Mechanical Systems, Kunming, China

  • Wei P, Wang MY (2009) Piecewise constant level set method for structural topology optimization. Int J Numer Methods Eng 78(4):379–402

    Article  MathSciNet  MATH  Google Scholar 

  • Wendland H (1995) Piecewise polynomial, positive definite and compactly supported radial functions of minimal degree. Adv Comput Math 4(1):389–396

    Article  MathSciNet  MATH  Google Scholar 

  • Xia L, Breitkopf P (2015) Design of materials using topology optimization and energy-based homogenization approach in MATLAB. Struct Multidiscip Optim 52(6):1229–1241

    Article  MathSciNet  Google Scholar 

  • Xie X, Mirmehdi M (2011) Radial basis function based level set interpolation and evolution for deformable modelling. Image Vis Comput 29(2–3):167–177

    Article  Google Scholar 

  • Yamada T, Izui K, Nishiwaki S, Takezawa A (2010) A topology optimization method based on the level set method incorporating a fictitious interface energy. Comput Methods Appl Mech Eng 199(45–48):2876–2891

    Article  MathSciNet  MATH  Google Scholar 

  • Zegard T, Paulino GH (2015) GRAND3 - ground structure based topology optimization for arbitrary 3D domains using MATLAB. Struct Multidiscip Optim 52(6):1161–1184

    Article  Google Scholar 

  • Zhang W, Yuan J, Zhang J, Guo X (2016) A new topology optimization approach based on moving Morphable components (MMC) and the ersatz material model. Struct Multidiscip Optim 53(6):1243–1260

    Article  MathSciNet  Google Scholar 

  • Zhao HK, Chan T, Merriman B, Osher S (1996) A variational level set approach to multiphase motion. J Comput Phys 127:179–195

    Article  MathSciNet  MATH  Google Scholar 

  • Zhou S, Cadman J, Chen Y, Li W, Xie YM, Huang X et al (2012) Design and fabrication of biphasic cellular materials with transport properties – a modified bidirectional evolutionary structural optimization procedure and MATLAB program. Int J Heat Mass Transf 55(25–26):8149–8162

    Article  Google Scholar 

  • Zuo ZH, Xie YM (2015) A simple and compact python code for complex 3D topology optimization. Adv Eng Softw 85:1–11

    Article  Google Scholar 

Download references

Acknowledgements

This research was supported by the National Natural Science Foundation of China under Grant Nos. 11372004, 11002056, 11002058 and the State Key Laboratory of Subtropical Building Science under Grant No. 2016 KB13.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Peng Wei.

Electronic supplementary material

ESM 1

(M 5.82 kb)

Appendix

Appendix

figure afigure a

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Wei, P., Li, Z., Li, X. et al. An 88-line MATLAB code for the parameterized level set method based topology optimization using radial basis functions. Struct Multidisc Optim 58, 831–849 (2018). https://doi.org/10.1007/s00158-018-1904-8

Download citation

  • Received:

  • Revised:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s00158-018-1904-8

Keywords

Navigation