optimization of crane hook meta integrations · a) select project / dv file generated by ansa b)...

30
1 Tutorial optiSLang Optimization of crane hook – ANSA & META integrations

Upload: others

Post on 07-Mar-2020

9 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

1

Tutorial

optiSLang

Optimization of crane hook –ANSA & METAintegrations

Page 2: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

2ANSA & META

Tutorial optiSLang © Dynardo GmbH

Problem definition

• Structural optimization of the crane hook

• 4 design variables (morphing parameter)

• Static analysis of the crane hook geometry using MSC Nastran

• Optimization criteria

Outer width

Section A Section B

Section C

morphing box & desgin variables

20 kN

Max von Mises stress

Boundary conditions for static analysis

𝑚 → min

maxi

𝜎𝑉𝑀𝑖 ≤ 0.4𝑘𝑁/𝑚𝑚2

𝜎𝑉𝑀𝑖 : nodal von Mises stress

Page 3: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

3ANSA & META

Tutorial optiSLang © Dynardo GmbH

I. Prepare the ANSA model & Optimization task:(see ANSA tutorials, e.g. tutorials/tutorials-morph_optimization/optimization_with_ANSA_META.pdf)

a) Prepare geometry and setup boundary conditions b) Create morphing boxes c) Define the design variables and setup optimization task

1. Open task manager

3. Define location of the reference DV file

4. Define optimization variables

2. Switch to “Definition” mode

5. Define FE output file & output deckinfocontaining mass information

Page 4: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

4ANSA & META

Tutorial optiSLang © Dynardo GmbH

Reference value and ranges for the design variables can already be defined in ANSA

Page 5: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

5ANSA & META

Tutorial optiSLang © Dynardo GmbH

Switch to “Execution” mode

Page 6: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

6ANSA & META

Tutorial optiSLang © Dynardo GmbH

II. Define response values with META post:(Load simulation results from baseline geometry)

a) Load geometry b) Load result values

1.2.

3.

4.

5.

1. 2.

3.

4.

5.

Page 7: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

7ANSA & META

Tutorial optiSLang © Dynardo GmbH

c) Calculate maximum nodal stress

1. Switch to last time step

2. Fringe: show stress values for each node

3. Create annotation

4. Choose function

5. Pick solid part

Page 8: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

8ANSA & META

Tutorial optiSLang © Dynardo GmbH

d) Define response & export session file

1. Open OptimizerSetup Dialog (User Toolbars/Optimization)

2. Add annotation as response (area select annotation & confirm with middle mouse button)

4. Export session to session file, e.g. META_post.ses

3. Optionally give the response a proper name

Page 9: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

9ANSA & META

Tutorial optiSLang © Dynardo GmbH

• hook.ansa: ANSA project file

• hook.nas: FE output file / Nastran deck file

• hook.op2: Result of the finite element analysios of the baseline hook geometry

• mass.txt: Results from exporting deck info of the base geometry containing mass information

• hook_DV.txt: ANSA Design variables and optimization task definition

• hook_META_resp.ses: Meta-post session file to extract max stress response

• hook_META_resp.ses.results: Meta-post results containing max stress value of the baseline geometry

III.Setup of the baseline optiSLang workflow:

a) Summary of the baseline files

Page 10: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

10ANSA & META

Tutorial optiSLang © Dynardo GmbH

b) Setup of the ANSA pre-processing using optiSLang solver Wizard:

2. Create new system withANSA wizard

1. Start optiSlang and createnew empty project

Page 11: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

11ANSA & META

Tutorial optiSLang © Dynardo GmbH

3. Follow wizard instructions

a) Select project / DV file generated by ANSA b) Select ANSA executable (only once)

c) Select FE output / Nastran deck file d) Select response file from ANSA –if you don‘t have a response file press Cancel

Page 12: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

12ANSA & META

Tutorial optiSLang © Dynardo GmbH

Baseline parametric system generated by the wizard

The design variables are read from the DV file and together with the range and reference values registered as parameter on the parametric system

Optionally change the name of the system, e.g., to “Hook”

Page 13: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

13ANSA & META

Tutorial optiSLang © Dynardo GmbH

4. Register mass as response value

a) Enable advanced settings and change delimiter from space to comma

Page 14: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

14ANSA & META

Tutorial optiSLang © Dynardo GmbH

b) Select response value

d) Use as responsec) Specify variable name

Page 15: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

15ANSA & META

Tutorial optiSLang © Dynardo GmbH

Optionally edit ANSA run script, e.g., modify license server settings, change FE output file or change number of max parallel ANSA calls.

Page 16: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

16ANSA & META

Tutorial optiSLang © Dynardo GmbH

c) Setup of the META post-processing using optiSLang solver Wizard:

2. Add post-processing nodesusing OSL META post wizard

1. Drag and drop the solver wizard into the “Hook“ system

Page 17: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

17ANSA & META

Tutorial optiSLang © Dynardo GmbH

3. Follow wizard instructions

a) Select META-post session file b) Select META-post executable (only once)

c) Select session output / response file

Page 18: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

18ANSA & META

Tutorial optiSLang © Dynardo GmbH

Updated baseline parametric system

Responses that are written to the META default response file format are automatically registered on the parametric system

4. Re-name the respone(alterantively change thename in META post)

Page 19: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

19ANSA & META

Tutorial optiSLang © Dynardo GmbH

d) Add solver node:

1. Drag and drop solver node into the system: we use a bash script node to call Nastran (to rename the node, once selected, press F2)

Leave the “Initialize Integration“ dialog as is and conform with ok

Page 20: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

20ANSA & META

Tutorial optiSLang © Dynardo GmbH

2. Edit bash script to run NASTRAN

Page 21: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

21ANSA & META

Tutorial optiSLang © Dynardo GmbH

3. Connect solver node:

a) Connect slot ANSA oDesign withNASTRAN iDesign

b) Connect slot NASTRAN oDesign withMETA iDesign

Page 22: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

22ANSA & META

Tutorial optiSLang © Dynardo GmbH

4. Re-align nodes & press play to run the baseline system:

a)b)

Page 23: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

23ANSA & META

Tutorial optiSLang © Dynardo GmbH

5. Verify the results: double click on the Hook system and change to “Result designs” tab

Page 24: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

24ANSA & META

Tutorial optiSLang © Dynardo GmbH

IV. Setup optimization task with Evolution Strategy:

1. Drop the Optimization wizard onto the Hook system

Page 25: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

25ANSA & META

Tutorial optiSLang © Dynardo GmbH

2. Define the optimization parameter (we use parameter ranges as is, as defined in ANSA)

3. Define optimization criteria:a) objective: minimize mas b) Less than constraint:

max_stress <= 0.4

Page 26: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

26ANSA & META

Tutorial optiSLang © Dynardo GmbH

4. In the last steps of the wizard select the optimization method: Evolutionary Algorithm

5. Leave additional options as is

Page 27: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

27ANSA & META

Tutorial optiSLang © Dynardo GmbH

6. EA settings: Open the settings dialog of the EA and change to “local” predefined settings in the “Other” tab to run a local search strategy

Page 28: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

28ANSA & META

Tutorial optiSLang © Dynardo GmbH

7. Run the optimization

Page 29: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

29ANSA & META

Tutorial optiSLang © Dynardo GmbH

Once finished, optiSLang post-processing will open up for analyzing the optimization history. By default the best design from the optimization is pre-selected.

Page 30: Optimization of crane hook META integrations · a) Select project / DV file generated by ANSA b) Select ANSA executable (only once) c) Select FE output / Nastran deck file d) Select

30ANSA & META

Tutorial optiSLang © Dynardo GmbH

a) Baseline hook geometry b) optimized hook geometry

Comparison of the baseline and optimized hook design using META post

<0.4 <0.4 Mass: -10.8%