Open-Source MATLAB Code for Hotspot Identification and Feeder Generation

  • William E. WarrinerEmail author
  • Charles A. Monroe


An open-source code for identifying metal casting hotspots and generating feeder geometries is outlined. The code takes two inputs and produces feeder information and an interactive visualization. The analysis requires no human interaction. The effects of the code applied to three example geometries are shown. Explanations of code choices, alternatives, assumptions, limitations, and extensions are discussed. A method for using the code to automate casting optimization workflows is also discussed. The code is made available verbatim, both in text and at a publically available repository online.


solidification hotspot feeder riser simulation design for manufacturability image analysis 



  1. 1.
    W.E. Warriner, C.A. Monroe, Locating solidification hot spots and feeder positions in casting geometries by image analysis. Int. J. Metalcast. 12(2), 224–234 (2017). Google Scholar
  2. 2.
    O. Sigmund, A 99 line topology optimization code written in Matlab. Struct. Multidiscip. Optim. 21(2), 120–127 (2001). Google Scholar
  3. 3.
    N. Chvorinov, Theory of the solidification of castings. Die Giesserei 27, 177–186 (1940)Google Scholar
  4. 4.
    A. Heuvers, Stahl und eisen kreismethode. Die Giesserei 30, 201 (1943)Google Scholar
  5. 5.
    R.M. Kotschi, C.R. Loper Jr., Design of T and X sections for castings. AFS Trans. 82, 535–542 (1974)Google Scholar
  6. 6.
    C.R. Loper Jr., R.M. Kotschi, Design of bosses and L sections for castings. AFS Trans. 83, 173–184 (1975)Google Scholar
  7. 7.
    R.W. Heine, J.J. Uicker, Risering by geometric modeling, in Gating and Risering, Chapter VI, ed. by J.M. Svoboda, G.S. Meiners (Steel Founders’ Society of America, Des Plaines, 1982), pp. 164–183Google Scholar
  8. 8.
    R.M. Kotschi, L. Plutshack, An easy and inexpensive technique to study the solidification of castings in three dimensions. AFS Int. Cast Met. J. 7(2), 29–37 (1982)Google Scholar
  9. 9.
    S.J. Neises, Use of casting section modulus in the geometric computer simulation of directional solidification wavefronts. Thesis (1982)Google Scholar
  10. 10.
    R.W. Heine, J.J. Uicker, D. Gantenbein, Geometric modeling of mold aggregate, superheat, edge effects, feeding distance, chills, and solidification macrostructure. AFS Trans. 92, 135–150 (1984)Google Scholar
  11. 11.
    C.R. Loper Jr., M. Copur, R.M. Kotschi, Analysis of the solidification order in selected casting sections. AFS Trans. 94, 529–535 (1986)Google Scholar
  12. 12.
    S.J. Neises, J.J. Uicker, R.W. Heine, Geometric modeling of directional solidification based on section modulus. AFS Trans. 95, 25–30 (1987)Google Scholar
  13. 13.
    T. Shih, M. Li, Geometric modeling of casting solidification. J. Chin. Soc. Mech. Eng. 11(1), 75–84 (1990)Google Scholar
  14. 14.
    N. Sirilertworakul, P.D. Webster, T.A. Dean, Computer prediction of location of heat centres in castings. Mater. Sci. Technol. 9(10), 923–928 (1993)Google Scholar
  15. 15.
    B. Ravi, M.N. Srinivasan, Casting solidification analysis by modulus vector method. Int. J. Cast Met. Res. 9, 1–8 (1996)Google Scholar
  16. 16.
    V.L. Rvachev et al., Implicit function modeling of solidification in metal castings. J. Mech. Des. 119(4), 466–473 (1997)Google Scholar
  17. 17.
    V.R. Voller, Estimating the last point to solidify in a casting. Numer. Heat Transf. B 33(4), 417–432 (1998)Google Scholar
  18. 18.
    W.K.S. Pao et al., A medial-axes-based interpolation method for solidification simulation. Finite Elem. Anal. Des. 40, 577–593 (2004)Google Scholar
  19. 19.
    W.K.S. Pao et al., A new geometric reasoning technique for hot spot prediction in sand casting. IEEE ECTI Trans. Electr. Eng. Electron. Commun. 4(1), 34–38 (2005)Google Scholar
  20. 20.
    R.S. Ransing et al., Enhanced medial axis interpolation algorithm and its application to hotspot prediction in a mould-casting assembly. Int. J. Cast Met. Res. 18(1), 1–12 (2005)Google Scholar
  21. 21.
    R.S. Ransing, M.P. Sood, W.K.S. Pao, Computer implementation of Heuvers’ circle method for thermal optimisation in castings. Int. J. Cast Met. Res. 18(2), 119–126 (2005)Google Scholar
  22. 22.
    X. Yan et al., An improved geometric model to predict hot spots of castings. Mater. Sci. Forum 689, 29–32 (2011)Google Scholar
  23. 23.
    W.M. Wells III, Medical Image Analysis—past, present, and future. Med. Image Anal. 33, 4–6 (2016). Google Scholar
  24. 24.
    W. Warriner, C. Monroe, A geometric algorithm for automatic riser determination and shrinkage identification in directionally solidifying castings, in IOP Conference Series: Materials Science and Engineering, vol. 84. MCWASP XIV, p. 012002Google Scholar
  25. 25.
    K.D. Carlson, C. Beckermann, Prediction of shrinkage pore volume fraction using a dimensionless Niyama criterion. Metall. Mater. Trans. A 40(1), 163–175 (2009)Google Scholar
  26. 26.
    R. Wlodawer, Directional Solidification of Steel Castings (Pergamon Press, Oxford, 1966). ISBN: 9781483149110Google Scholar
  27. 27.
    GrabCAD User: RiBKa aTIKA. Casting by catia, Stereolithography file, Generic (2014).
  28. 28.
    GrabCAD User: Christian Mele. Steering Column Mount, Stereolithography file, Generic (2018).
  29. 29.
    The MathWorks, Inc. MATLAB and Image Processing Toolbox, Release 2018b, Computer Program (2018)Google Scholar
  30. 30.
    Y. Mishchenko, 3D Euclidean Distance Transform for Variable Data Aspect Ratio. Computer Program (2015).
  31. 31.
    S. Holcombe, stlwrite(filename, varargin), Computer Program (2015).
  32. 32.
    A.H. Aitkenhead, Mesh voxelization. Computer Program (2013).
  33. 33.
    T. Holy, Generate maximally perceptually-distinct colors. Computer Program (2011).
  34. 34.
    W. Warriner, matlab_capped_cylinder. Computer Program (2018).
  35. 35.
    S. Patil, B. Ravi, Voxel-based representation, display and thickness analysis of intricate shapes, in Ninth International Conference on Computer Aided Design and Computer Graphics. IEEE.
  36. 36.
    Y. Mishchenko, A fast algorithm for computation of discrete euclidean distance transform in three or more dimensions on vector processing architectures. Signal Image Video Process. 9(1), 19–27 (2015)Google Scholar
  37. 37.
    C.R. Maurer Jr., R. Qi, V. Raghavan, A linear time algorithm for computing exact euclidean distance transforms of binary images in arbitrary dimensions. IEEE Trans. Pattern Anal. Mach. Intell. 25(2), 265–270 (2003)Google Scholar
  38. 38.
    J.A. Sethian, Fast marching methods. SIAM Rev. 41(2), 199–235 (1999)Google Scholar
  39. 39.
    H. Zhao, A fast sweeping method for Eikonal equations. Math. Comput. 74(250), 603–627 (2005)Google Scholar
  40. 40.
    P. Soille, Morphological Image Analysis: Principle and Applications (Springer, Berlin, 2004). ISBN: 9783540429883Google Scholar
  41. 41.
    F. Meyer, Topographic distance and watershed lines. Signal Process. 38(1), 113–125 (1994)Google Scholar
  42. 42.
    J. Cousty et al., Watershed cuts: thinnings, shortest path forests, and topological watersheds. IEEE Trans. Pattern Anal. Mach. Intell. 32(5), 925–939 (2010)Google Scholar
  43. 43.
    K.D. Carlson et al., Development of new feeding-distance rules using casting simulation: part I. Methodology. Metall. Mater. Trans. B 33(5), 731–740 (2002)Google Scholar
  44. 44.
    S. Ou et al., Development of new feeding-distance rules using casting simulation: part II. The new rules. Metall. Mater. Trans. B 33(5), 741–755 (2002)Google Scholar
  45. 45.
    Steel Founders’ Society of America. Feeding and Risering Guidelines for Steel Castings. Electronic Book (2001).
  46. 46.
    J. Yeh, vtkwrite: exports various 2D/3D data to ParaView in VTK file format. Computer Program (2016).
  47. 47.
    J. Ahrens, B. Geveri, C. Law, ParaView: An End-User Tool for Large Data Visualization (Elsevier, Amsterdam, 2005). ISBN: 978-0123875822Google Scholar
  48. 48.
    MAGMA Giessereitechnologie GmbH. MAGMASOFT v5.3.1.0. Computer Program (2017)Google Scholar
  49. 49.
    D. Joshi, B. Ravi, Quantifying the shape complexity of cast parts. Comput. Aided Des. Appl. 7(5), 685–700 (2010)Google Scholar
  50. 50.
    N. Willis, et al. Automatic risering using Redbook rules with application to order of magnitude cost analysis, in SFSA Technical and Operating Conference Google Scholar
  51. 51.
    C.A. Monroe et al., Improving the directional solidification of complex geometries through taper addition. Int. J. Metalcast. 8(3), 23–27 (2014). Google Scholar
  52. 52.
    T.E. Morthland et al., Optimal riser design for metal castings. Metall. Mater. Trans. B 26(4), 871–885 (1995). Google Scholar
  53. 53.
    R. Tavakoli, P. Davami, Automatic optimal feeder design in steel casting process. Comput. Methods Appl. Mech. Eng. 197, 921–932 (2008)Google Scholar

Copyright information

© American Foundry Society 2019

Authors and Affiliations

  1. 1.University of Alabama at BirminghamBirminghamUSA

Personalised recommendations