getting started tutorial - sandia.gov

20
Getting Started Tutorial Getting Started Tutorial Sandia National Laboratories is a multimission laboratory managed and operated by National Technology and Engineering Solutions of Sandia LLC, a wholly owned subsidiary of Honeywell International Inc. for the U.S. Department of Energy’s National Nuclear Security Administration under contract DE-NA0003525. SAND2020-10947 TR

Upload: others

Post on 15-Jul-2022

13 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Getting Started Tutorial

Sandia National Laboratories is a multimission laboratory managed and operated by National Technology and Engineering Solutions of Sandia LLC, a wholly owned subsidiary of Honeywell International Inc. for the U.S. Department of Energy’s National Nuclear Security

Administration under contract DE-NA0003525.

SAND2020-10947 TR

Page 2: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Lantern Bracket Problem

• This tutorial will walk you through a simple topology optimization problem where we will design a bracket for mounting a lantern to a wall.

• The design domain is shown in the bottom image. The two holes at the top are where the bracket will mount to the wall and the hole where the red arrow is pointing is where the load from the weight of the lantern will be applied.

Page 3: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Create a New Model

• Choose File->New->Model in the menu

• Choose New Model then Next

• Choose Create From Templatethen Next

• Enter Lantern as the Model Name

• Choose the Plato Templates->Basic->Maximize Stiffness (SierraSD)template and then Finish

Page 4: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Create the Design Domain• At the CUBIT> command prompt copy and paste the

following (see Hint on next slide):brick x 5.5 y 5.5 z 5webcut volume all with plane zplane offset .5webcut volume all with plane zplane offset -.5brick x 1 y 5 z 1vol 4 move -2.25 .25 0subtract vol 4 from vol 2brick x 5.5 y 1.5 z 1vol 5 move -.5 2 0sub 5 from 2webcut volume 2 with sheet extended from surface 48webcut volume 6 with sheet extended from surface 45 cylinder radius .125 height 10vol 8 copy rotate 90 about xvol 9 move -2.25 0 0sub 9 from Volume 2vol 8 rotate 90 about yvol 8 move 0 2.375 0vol 8 copy move 0 -.75 0sub 10 8 from 6

• These are CUBIT commands that create the cad model representation of the design domain in which the optimized design can exist.

Page 5: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Hint: Cubit Console

• If you don’t see the CUBIT> prompt in the console window you are just looking at the wrong console (there may be multiple to choose from loaded in Plato that use the single console window). Click on the icon at the top right of the console window that looks like a computer screen to toggle through the different consoles that are currently loaded. Or you can click on the down arrow next to the computer screen icon to see all of the currently loaded consoles and choose one from the list.

Page 6: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Create the Design Domain

• At the CUBIT> command prompt copy and paste the following:

imprint allmerge allvol all size .2mesh vol allblock 1 vol 3 7 1block 2 vol 2 6

• These commands imprint the volumes onto each other and then merge the surfaces between them so that the mesh will be contiguous from volume to volume.

• Then the volumes are meshed and put in blocks based on whether they will be “fixed” or ”optimizable”. In our case we will fix the volumes where the bracket attaches to the wall and where the lantern will be attached.

• See the FixedBlocks tutorial for more info on fixed blocks.

Page 7: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Define Load Application Location

• Select and right-click the inner cylindrical surface where the lantern will be attached (shown highlighted in orange) and choose Exodus->Create Sideset. (see Entity Selection Hint on next slide)

• In the Create Sideset panel click the “Apply” button to accept the default values and create the sideset. Note that the id of the new sidset is 1. We will use this later on when creating the actual load that is applied to this sideset.

Page 8: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Hint: Entity Selection

• The selection filter toolbar is at the bottom left of the graphics window.

• There are 3 high level modes: Geometry, Mesh, and Exodus

• Within each high level mode there are various options for filtering what will get selected by clicks in the graphics window.

High level modes

Filter options for a given high level mode

Page 9: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Define BC Application Location

• Select the two inner cylindrical surfaces where the bracket will be attached to the wall. On Windows and Linux use Ctrl-Select to select multiple surfaces and on Mac use Command-Select. After selecting the two surfaces right-click and choose Exodus->Create Nodeset.

• In the “Create Nodeset” panel click the “Apply” button to accept the defaults and create the nodeset. Note the nodesetid is 1. We will use this in creating the fixed boundary condition.

Page 10: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Sidesets and Nodeset in the Model Tree

• The sideset and nodeset we just created can be seen in the Model tree under the “Geometry/Mesh” node.

Page 11: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Save the Geometry/Mesh

• Click on the “Geometry/Mesh” node in the tree and then click the Save icon in the toolbar.

Page 12: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Create the Lantern Load• Expand the “plato” node in the

Model tree and then expand the “Loads” node. In the template we used for this model there was already a load defined. Click on “load 1” in the tree to bring up its information in the Settings panel. The “location_id” is already set to “1” meaning it will be applied to sideset 1. Change the value to “0 -1e5 0” indicating there will be a traction load with a negative y component of 1e5 applied to sideset 1.

• Note: If the template did NOT already have a load defined, we could have created one by clicking on the “Load” hyperlink that shows up in the Settings panel when you click on the “Loads” node in the tree.

Page 13: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Create the Mounting Fixed BC• Expand the “plato” node in the Model

tree and then expand the “Boundary Conditions” node. In the template we used for this model there was already a boundary condition defined. Click on “boundary_condition 1” in the tree to bring up its information in the Settings panel. The “location_id” is already set to “1” meaning it will be applied to nodeset 1. The “degree_of_freedom” and “value” parameters specify that displacement in all 3 directions will be fixed so there is nothing to change.

• Note: If the template did NOT already have a boundary condition defined, we could have created one by clicking on the “Boundary condition” hyperlink that shows up in the Settings panel when you click on the “Boundary Conditions” node in the tree.

Page 14: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Assign Material and Element Type

• Click on the FEM Mesh node in the tree under plato->Finite Element Model

• In the Settings panel click in the Material area next to Block 1 and select 1 from the dropdown list

• Then click in the Element area next to Block 1 and select hex8 from the dropdown list

• Do the same for Block 2

Page 15: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Set the Volume Fraction Constraint• Click on the Constraints-

>Constraint node in the tree.

• The template used to create this model had a constraint already defined with the parameters shown in the top image on the right. We want to change the relative_target value to 0.1 indicating that we want to use 10% of the original volume in our final design. Click on the relative_target parameter and change the value to 0.1.

• Also, verify that the criterion being used in the constraint is a volume criterion by clicking on Criteria->criterion “2” in the tree (see bottom image on right).

Page 16: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Set the Filter Radius

• Click on the Optimization Parameters-> optimization parameters node in the tree

• In the Settingspanel click on filter_radius_scaleand type in 2.0 for the value and hit the return key. This will tell Plato to use a filter radius that is 2 times the average mesh edge length in the model. The filter radius will affect feature size as well as smoothness in the resulting design.

Page 17: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Add a Fixed Block

• Click on the Optimization Parameters-> optimization parameters node in the tree

• In the Settingspanel right-click anywhere in the Parameters area and choose Add->fixed_block_ids. Enter 2 for the fixed block id and hit the return key. This will tell Plato to not allow any of the material in Block 2 to be optimized away.

Page 18: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Set the Number of Processors

• Click on Services->service “2” in the tree

• In the Settingspanel change the number of processors used by this sierra_sdservice to 8 as shown in the right. This will speed up the optimization run.

Page 19: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Run the Optimization• Click on the plato node in the tree

to bring up the job submission panel in the Settings view

• Choose Plato as the code and then choose the machine and corresponding execution template. If you have a local installation of Sierra choose local as the machine and Plato_Salinas_Local as the execution template.

• In the Resources area make sure Lantern.gen is checked. This is the mesh file that will be used.

• In the Prune and Refine area make sure Prune Mesh is unchecked and Number Refines is 0. We will not use these features in this example.

• Choose any other preferences and launch the job by clicking on Submit Simulation Job toward the top of the panel

Page 20: Getting Started Tutorial - sandia.gov

Getting Started Tutorial

Results• Your results should look like

the image shown here.

• At this point you can try modifying parameters and resubmitting the job and each time it will just overwrite the results from the previous run.

• This tutorial should give you a general overview of the process. Try the other tutorials at www.sandia.gov/plato3d to learn about specific features.

• The coarseness or roughness of the result is related to mesh resolution. See the “Prune and Refine” tutorial to learn how to efficiently generate smooth results.