How to Do Topology Optimization With 3d Models in Ansys

by lobster_enthusiast in Design > 3D Design

74 Views, 1 Favorites, 0 Comments

How to Do Topology Optimization With 3d Models in Ansys

Screenshot 2025-08-13 221949.png

topology optimization (top opt) is super important in cases where you want to minimize material while maximizing strength (stiffness), or some other objective. especially when you're running out of filament and can't afford anymore... designs produced from top opt often look quite organic, so its most suited for additive manufacturing such as 3d printing. and, top opt is just super cool.


in chronological order, you'll need to know what top opt actually is, how it works, and where to conduct it. there's a lot of tutorials on topology optimization in fusion 360, however top opt in fusion 360 now costs cloud credits (aka money), and i'm not paying for something when it can be done for free.


Ansys, on the other hand, is a free finite element analysis software; it's tailored for FEA simulations such as structural analysis, or computational fluid dynamics, or even electromagnetism simulations. Ansys has a steeper learning curve, so I hope this instructable helps make working in Ansys more digestible.

Supplies

  1. understanding of topology optimization
  2. some experience with cad, meshes, working with faceted geometry, and basic physics knowledge
  3. ANSYS downloaded (step 2)
  4. step or stl file of the object you want to optimize
  5. (step is recommended because stl must be converted to solid in ansys, and geometry must be fixed before analysis)

Understand the Basics of Topology Optimization

hook_TO.jpg

Topology optimization is a type of structural optimization which aims to optimize both shape and size of a body according to a given load, while staying within specific restrictions, i.e. keep 30% of material while maximizing stiffness. The objective is to maximize stiffness, while a constraint is to retain 30% of the material.

  1. Crash course in the 3 types of structural optimization: size, shape, and topology optimization.
  2. In size optimization, the final shape is known but size of shape is unknown, and the objective is to determine the shape; for example, you know the length and position of a cantilever but not the cross-sectional thickness
  3. in shape optimization, the final size is known but shape (aka form, contour) is unknown, and objective is to determine size.
  4. topology optimization basically combines both size and shape optimization. the initial design (3d model) is given, a load is specified, and constraint(s), and topology optimization is used to find the optimal design according to the specified conditions. In this context, a load is a place where force acts on your system, such as a table subjected to a load of 100 N.
  5. There's multiple methods for topology optimization, which all work to solve the generalized topology optimization problem (see section 2 "General design problem"):
  6. Density (Bendsøe 1989; Zhou and Rozvany 1991; Mlejnek 1992)
  7. SIMP (Bendsøe and Kikuchi 1988; Rozvany and Zhou 1992)
  8. Level-set (Allaire et al. 2002, 2004; Wang et al. 2003)
  9. Topological derivative (Sokołowski and Zochowski 1999)
  10. Phase field (Bourdin and Chambolle 2003)
  11. Evolutionary approaches (Xie and Steven 1993)
  12. just to name a few
  13. Ansys offers level-set, SIMP, and lattice optimization methods


image link: https://www.flickr.com/photos/31274959@N08/6218546628

Download Ansys

ansys_student_homepage.png

If you already have ansys student downloaded and working, skip this step.


  1. Go to this link to download Ansys
  2. Download the option "Ansys Student"
  3. Before downloading, check the system and browser requirements, otherwise you may not be able to access it
  4. Follow the rest of the instructions on the website under "Installation Steps"
  5. Watch this video about getting started

Select an Object for Optimization

Screenshot 2025-08-12 211241.png

Choose and CAD an object; simpler is better for the first try. For instance, a bracket, beam, etc. Export the CAD as a step file once done (this is because stl files are meshes and so must be converted to solid before ready to analyze, and that's a huge pain especially if you have circles).

As an example, I'll use a triangular shelf support bracket shown above

Ansys Workbench and Static Structural Analysis

Screenshot 2025-08-13 221446.png

In Ansys, a static structural analysis of the geometry must be completed before topology optimization. This is to analyze the stress on the entire object when subjected to an intended load. Topology optimization can be used to remove areas with low stress, retaining areas subjected to high stress, and thus minimizing mass. Obviously, the situation might be different for different objectives, but that's the gist of it.


So

  1. Open Ansys Workbench and drag in a static structural analysis system from the toolbox, on the left hand side
  2. check your engineering data and change the material as necessary (I left mine as the default)
  3. Import your geometry by right clicking on the geometry option
  4. *optional but recommended step - check your geometry by rightclicking on it and selecting "edit geometry in spaceclaim"; make sure the geometry is correct
  5. the layout of spaceclaim is kind of similar to fusion 360
  6. make any edits as necessary and remember to save your chances (ctrl + s)
  7. Atp, you want to update your model by clicking on the update button at the top left/middle
  8. open your system in Ansys Mechanical by right-clicking on the "Model" option and selecting "Edit"
  9. In Mechanical, you want to set up your static structural analysis by defining fixed points (titled "Fixed supports"), loads, and/or moving joints
  10. Right-click on either "Static Structural (A5)" or "Analysis Settings" to insert your conditions
  11. Tip: a typical load is called a "Force" in Mechanical, and the force is evenly distributed among the selected surface; you can define it as either a vector or x-y-z component (in the example, I used component acting in the z-direction, -1300 N)
  12. Tip 2: hold down ctrl to select multiple geometries
  13. Insert the solution you need by right-clicking "Solution (A6)"
  14. In most cases, you want to analyze how your object distorts under load, so you could select "Stress" and then take the equivalent (von-Mises) stress as the solution; I use von
  15. keep in mind von-Mises stress is applicable to ductile materials such as metals while not very applicable for brittle materials (i.e. plastics), so adjust your analysis for your purpose; see this link for more about von-Mises stress and this link for more about selecting the right stress measure for your purpose
  16. Solve your system
  17. click solve in the top left area or just right click the Solution for the solve option
  18. Observe your solution
  19. look at the colors and corresponding values located as a bar on the left
  20. adjust the units as necessary (default should be Pa)
  21. observe that areas under less stress will likely be cut after topology optimization because it's unnecessary for maintaining structural integrity

And yay! you've completed a structural analysis. Now time to actually start the optimization.

Topology Optimization

Screenshot 2025-08-13 221601.png
Screenshot 2025-08-14 221339.png

Topology optimization in Ansys is called "Structural Optimization", but it's the same thing as topology optimization. You will need to share the data between the static structural analysis you just did and the structural optimization systems; any physics or settings created/defined in the static structural will be applied to the structural optimization system which saves a lot of time.

  1. Select the structural optimization analysis system from the toolbox and drag and drop it over the results (row 7) of the static structural system.
  2. This shares the information between them, such as engineering data, supports and loads, etc. More importantly, it tells the structural optimization the results of the static structural and therefore where to remove or keep material.
  3. Note how this is shown by the pink line indicating that the solution of the static structural analysis becomes the setup for the structural optimization
  4. Update the system as needed
  5. Enter Ansys mechanical by right-clicking on "Setup"
  6. Make sure that your system has the correct physical conditions and adjust any parameters as needed (i.e. units)
  7. Check your optimization region and make sure the included and excluded regions are correct
  8. Click on "Objective" and alter the objective as needed for your purpose (I left it as the default, which is to minimize compliance)
  9. Enter your response constraint in "Response Constraint"
  10. Again, choose a value as fits your need. I used mass response constraint, retaining 50% of the mass.
  11. Now everything should be set up, and you should see a green check on the left of each section. Click "Solve" to start solving, and observe your geometry by clicking the "Topology Density" tracker
  12. Once done solving, view your final product.
  13. You can also replay the animation of Mechanical solving the optimization, and view objective and mass convergence rates under "Solution Information"
  14. It's ready! You can export the solution, play around with other variables, or do a design validation system.
  15. To export your solution, right-click "Topology Density", export, and export it.
  16. To print your solution, see this video on cleaning up geometry in Ansys for 3d printing


Next is the design validation system.

Design Validation System

Screenshot 2025-08-19 223528.png

Design validation is super important for testing how well your design works under specific and intended conditions. In this case, it's another static structural analysis, with the object under the same load and fixed supports. In this case, it helps us gauge how well our newly optimized design works, before we start to print or manufacture it.


  1. Right click on the structural optimization results and select "Transfer to design validation system (geometry)"
  2. This creates another static structural optimization because you are testing if the new design is valid under the same conditions.
  3. We are selecting geometry because you need to smooth the stl produced by the topology optimization for the analysis and convert it to a solid
  4. Right-click on geometry and edit
  5. Smooth the stl object and convert to solid. Watch this video; it explains the process and provides good visual
  6. If the autoskin tool fails because sharp edges are detected, use the "Fix Sharps" tool under "Facets", on the right of the shrinkwrap option.
  7. be aware that if the autoskin tool doesn't turn your system into a solid, you'll have to expand it under the tree menu and turn the faceted body into a solid via the tools under the "Repair" tab
  8. Once done, update your system and then enter Mechanical
  9. Generate mesh
  10. if you face any errors with mesh, it's likely because of the geometry. Right click on the error(s) and select "show problematic geometry." It'll tell you which areas in the geometry are causing the problem, and know you know which to fix in Spaceclaim.
  11. look out for sneaky geometry that's very small or narrow and appears difficult to triangulate; try zooming in -- may help narrow down problem areas to fix
  12. Check that your fixed supports and loads are correct
  13. You may need to delete and redefine fixed supports and loads depending on the geometry
  14. Once all sections have a green check, solve your solution
  15. If you encounter the error "Your product license has numerical problem size limits, you have exceeded these problem size limits and the solver cannot proceed", it means your problem's number of nodes exceeded the 32k limit. You'll have to relax curvature refinement or increase element size, but play around with the mesh settings (i.e. mesh quality and sizing) and you'll get it.
  16. To check the details, including the number of nodes, select the geometry tab in the tree outline and under the "Home" tab, select "worksheet."
  17. Observe the results, look at animations, change loads, etc


Now you're completely finished! i hope this was helpful, because i certainly wished someone told me exactly what each step was for when i first started out. Ansys is a complicated software, so don't be discouraged if things don't solve/work out the first time -- keep trying and fixing errors. youtube and reddit have good answers to common problems, and ansys also has a learning forum for questions.