OS-HM-T: 10000 Hook with Stress Constraints

Tutorial Level: Intermediate In this tutorial, a topology optimization is performed on a bracket-hook modeled with shell elements.

The structural model with loads and constraints applied is shown in Figure 1. The objective is to minimize the volume of the material used in the model subject to certain stress constraints. Topology optimization is performed to find the optimal material placement and reduce the volume. This optimization normalizes each element according to its density and you can remove elements that have low density.

Before you begin, copy the file(s) used in this tutorial to your working directory.
Figure 1. FEA Model

hook_model

The structural model is loaded into HyperMesh Desktop. The constraints, loads, subcases and material properties are already defined in the model. The topology design variables and the optimization problem setup are defined using HyperMesh, and OptiStruct is used to determine the optimal material layout. The results can then be reviewed in HyperView.

The optimization problem is stated as:
Objective Function
Minimize mass.
Constraints
Minimum Member Size = 1.0
Von Mises stress < 1000
Design Variables
The density of each element in the design space.
The following exercises are included:
  • Set up the optimization problem in HyperMesh.
  • Post-process the results in HyperView.

Launch HyperMesh

  1. Launch HyperMesh.
  2. In the New Session window, select HyperMesh from the list of tools.
  3. For Profile, select OptiStruct.
  4. Click Create Session.
    Figure 2. Create New Session


    This loads the user profile, including the appropriate template, menus, and functionalities of HyperMesh relevant for generating models for OptiStruct.

Import the Model

  1. On the menu bar, select File > Import > Solver Deck.
  2. In the Import File window, navigate to and select hook.fem you saved to your working directory.
  3. Click Open.
  4. In the Solver Import Options dialog, ensure the Reader is set to OptiStruct.
    Figure 3. Import Base Model in HyperMesh


  5. Accept the default settings and click Import.
    Tip: Alternatively, you can drag and drop the file from your file browser into the application window to open the model file.

Set Up the Optimization

Set the View

  1. In the Model Browser, right-click on Components and select Isolate.
    Only the components are displayed.
  2. In the modeling window, click the View Cube to fit the model to the window.
    Figure 4. Orient Model to Front


  3. Use the arrows below the View Cube to orient the model to Front view, so the Front face is visible.

Create the Design Variables

In this step, create design variables for topology optimization.

  1. Open the Optimize ribbon and click Topology.
    Figure 5. Topology Tool


  2. For Name, enter shells.
  3. For Config, verify topology is selected.
  4. For Property Type, select PSHELL.
  5. For List of Properties, click 0 Properties > to open Advanced Selection.
  6. Select the base and hook on the model.
    Figure 6. Select Base and Hook


  7. Click .
  8. For Mindim, enter 1.0.
  9. For Stress Constraint, enter 1000.
  10. Click Close.
    Figure 7. Topology Design Variable (DESVAR) is Created


    This sets the optimization to optimize the shell elements in the Design and Base components to create structural members with minimum member size of 1.0 unit in width and thicknesses that vary between zero and the thickness of the shell. The optimization uses 1000 as the maximum stress for any element within the design region when validating the design.

Create Responses

A detailed description is available in the Responses section of the User Guide.

  1. On the Optimize ribbon, click Responses.
    Figure 8. Responses Tool


  2. For Name, enter mass.
  3. For Response Type, accept the default of mass.
    Figure 9. Mass Optimization Response


  4. Click Close.
    A response, mass, is defined for the total volume of the model.

Apply Constraints

There is no need for additional constraints, since setting a stress target in the design variable serves as a constraint that limits the amount of material used in the optimized model.

Define the Objective Function

In this step, the objective is to minimize the mass response defined in the Create Responses step.

  1. On the Optimize ribbon, click Objectives.
    Figure 10. Objectives Tool


  2. Verify the Objective Type is set to Minimize.
  3. For Response ID, click Unspecified.
  4. Click the Search tool and select mass.
  5. Click Close.
    The objective function is now defined.

Save the HyperMesh Database

  1. From the ribbon, File tool group, select the Save .hm file icon.
    Figure 11. Save


  2. Select the directory where you would like to save the database.
  3. For File name, enter hook_opt.hm.
  4. Click Save.

Run the Optimization

  1. From the Optimize tool, click Run.
    Figure 12. Run Optimization


  2. Select the directory where you want to write the OptiStruct model file.
  3. For File name, enter hook_opt.
    The .fem filename extension is the recommended extension for Bulk Data Format input decks.
  4. Click Save.
  5. For Export, select All.
  6. Click Export.
  7. In the Altair Compute Console, click Run.
    If the job is successful, the following message appears in the window:
    OPTIMIZATION HAS CONVERGED.
    FEASIBLE DESIGN (ALL CONSTRAINTS SATISFIED).
    New results files are seen in the directory where the model file was written. The hook_opt.out file is a good place to look for error messages that could help debug the input deck if any errors are present.
    The following default files are written to your run directory:
    hook_opt_des.h3d
    HyperView binary results file containing the iso surface.
    hook_opt_s--.h3d
    HyperView binary results file containing the displacement and stress results from each loadcase.
    hook_opt.mvw
    Contains the design results and the displacement and stress results from the *_des.h3d and *_s1.h3d files.
    hook_opt_hist.mvw
    Contains the iteration history of the objective, constraints, and the design variables. It can be used to plot curves in HyperGraph, HyperView, and MotionView.
    hook_opt.out
    OptiStruct output file containing specific information on the file setup, the setup of the optimization problem, estimates for the amount of RAM and disk space required for the run, information for all optimization iterations, and compute time information. Review this file for warnings and errors that are flagged from processing the cclip_complete.fem file.
    hook_opt.sh
    Shape file for the final iteration. It contains the material density, void size parameters, and void orientation angle for each element in the analysis. This file can be used to restart a run.
    hook_opt.hgdata
    HyperGraph file containing data for the objective function, percent constraint violations, and constraint for each iteration.
    hook_opt.oss
    OSSmooth file with a default density threshold of 0.3. You can edit the parameters in the file to obtain the desired results.
    hook_opt.stat
    Contains information about the CPU time used for the complete run and also the break-up of the CPU time for reading the input deck, assembly, analysis, convergence, and so on.

Post-process the Results

View the Iso Surface Plot of the Density Results

  1. In the Altair Compute Console Solver Window, click Results.
    Figure 13. Open Results


    HyperView opens and the results of the optimization run and corresponding linear static subcases are loaded.
  2. Click Contour.
    Figure 14. Contour Tool


  3. In the Results Browser, select the final iteration number, Iteration 26, from the drop-down menu.
  4. For Result type, select Element Densities (s) and click Apply.
    Figure 15. Element Densities Contour Plot


  5. On the ribbon, click Iso.
  6. Select the Result type: Element densities (s).
  7. Click Apply.
  8. Change the Current value to see the results with varying density values.
    Figure 16. Change Current Value


    Figure 17. Isosurface Plot. The isosurface post-processing feature is an excellent tool to use for viewing the density results from OptiStruct (Current value = 0.460).


    The isosurface in the modeling window interactively update when you change it to a new value. Use this tool to get a better look at the material layout and the load paths from OptiStruct.

View the Element Stress Results

To load the results of the linear static loadcases as well, click File > Session > Open, and select hook_opt.mvw. Click Open, and then click Yes.
  1. Expand the page selection dialog.
    This is located at the top right of the window, near the search tool.
    Figure 18. Expand Page Selection


  2. Select Subcase 19 - Subcase 1.
    Figure 19. Select Subcase


    The next page is displayed with results loaded from hook_opt_s19.h3d. This contains the linear static results for the 1st subcase.
  3. On the ribbon, click Contour.
    Figure 20. Contour Tool


  4. For Results type, first drop-down menu, select Element stresses(2D&3D)(t).
    Figure 21. Select Results Type


  5. In the second drop-down menu, select vonMises.
  6. In the Results Browser, set the displayed iteration to the last iteration, Iteration 26.
    Figure 22. Display Last Iteration
  7. Click Apply.
  8. Similarly, use this process to view results from the other subcase.
    Figure 23. von Mises Stress Results


    Notice that there are some local regions where the stresses are still high; this is because topology stress constraints should be interpreted as global stress control or global stress target.
    The functionality has some ways to filter out the artificial or local stresses caused by point loading or boundary conditions, but those artificial stresses are not completely removed unless the geometry is changed by shape optimization.
    Note: There might still be high local stress regions that can be improved more effectively with local shape and size optimization.