PDF

Optimization of an Extruded MBB Beam
Introduction
Topology and shape optimization can be used to find and improve the design of products, but sometimes manufacturing constraints dictate that the design most be invariant in one of the dimensions, that is, an extruded geometry is desired. If 3-dimensional effects play little role, a 2D optimization can be used. Otherwise, one has to perform a 3D simulation and restrict the optimization to preserve the extruded property of the geometry.
This model is inspired by Topology Optimization of an MBB Beam, but the geometry is forced to be invariant in the z direction. The result is transferred to a second component in which shape optimization is performed, while still preserving the invariance in the z direction.
Model Definition
The model uses the Density Model feature to impose a minimum length scale on the filtered material volume factor. This is only defined on a symmetry plane, but it can be accessed as a z-invariant field in the volume by defining a General Extrusion operator.
The shape optimization uses equation-based modeling to define control variables and Helmholtz filters on the edges that form the intersection of a symmetry plane and the optimized boundaries. A second General Extrusion operator is used to transfer the variables of the Helmholtz filters from the edges to the optimized boundaries. Dirichlet boundary conditions are imposed on the Helmholtz filter to restrict the shape optimization to the box of the topology optimization.
Results and Discussion
The result of the topology optimization is shown in Figure 1. The model accounts for out-of-plane displacements, but the design is identical to the 2D result in the model Topology Optimization of an MBB Beam.
Figure 1: The filtered material volume factor is plotted on the z symmetry plane associated with the Density Model. An extrusion operator is used to transfer the variable to the volume.
The second General Extrusion will be more robust if it is used on an extruded design. There are several ways to achieve this, but in this model we will combine a Filter dataset, a Mesh part and a geometry Import feature to transfer a 2D version of the design. This is then extruded as shown in Figure 2.
Figure 2: ‘The topology optimized design has been transferred to a second component using an extrusion operator and a filter dataset pointing to a cut plane dataset.
Finally, the result of the shape optimization is shown in Figure 3 as the initial volume in gray on top of the optimized volume in red (transparency is enabled). The 90-degree angle near the top boundary is removed, because it is an artifact of the Helmholtz filter and thus not optimal (similar to Shape Optimization of an MBB Beam).
Figure 3: The plot shows the initial and optimized geometries in gray and red, respectively.
Notes About the COMSOL Implementation
This model combines the Optimization, Solid Mechanics and Deforming Geometry interfaces. The model uses a Filter dataset to transfer the geometry between components. An alternatively method is to export the edges as a a text file with a section-wise format and import them as an interpolation curve. The interpolation curve has a parameter that can be used to straighten out the wiggles, but this approach requires more geometry operations to identify and delete the void domain.
Finally, the plot with transparency suffers from z-fighting artifacts on the Symmetry/Roller boundaries, but this is rectified by shrinking one of the volumes slightly.
Application Library path: Optimization_Module/Design_Optimization/mbb_beam_extruded_optimization
Modeling Instructions
From the File menu, choose New.
New
In the New window, click  Model Wizard.
Model Wizard
1
In the Model Wizard window, click  3D.
2
In the Select Physics tree, select Structural Mechanics>Solid Mechanics (solid).
3
Click Add.
4
Click  Study.
5
In the Select Study tree, select General Studies>Stationary.
6
Global Definitions
Parameters 1
1
In the Model Builder window, under Global Definitions click Parameters 1.
2
In the Settings window for Parameters, locate the Parameters section.
3
Geometry 1
Work Plane 1 (wp1)
In the Geometry toolbar, click  Work Plane.
Work Plane 1 (wp1)>Plane Geometry
In the Model Builder window, click Plane Geometry.
Work Plane 1 (wp1)>Rectangle 1 (r1)
1
In the Work Plane toolbar, click  Rectangle.
2
In the Settings window for Rectangle, locate the Size and Shape section.
3
In the Width text field, type a.
4
In the Height text field, type b.
Work Plane 1 (wp1)>Point 1 (pt1)
1
In the Work Plane toolbar, click  Point.
2
In the Settings window for Point, locate the Point section.
3
In the yw text field, type L1.
Work Plane 1 (wp1)>Point 2 (pt2)
1
In the Work Plane toolbar, click  Point.
2
In the Settings window for Point, locate the Point section.
3
In the xw text field, type a-L1/2.
4
In the yw text field, type b.
Extrude 1 (ext1)
1
In the Model Builder window, under Component 1 (comp1)>Geometry 1 right-click Work Plane 1 (wp1) and choose Extrude.
2
In the Settings window for Extrude, locate the Distances section.
3
Symmetry z Boundary
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Symmetry z Boundary in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Boundary.
4
Locate the Box Limits section. In the z maximum text field, type c*0.001.
5
Locate the Output Entities section. From the Include entity if list, choose Entity inside box.
6
In the Geometry toolbar, click  Build All.
The model geometry is now complete.
Add Material
1
In the Home toolbar, click  Add Material to open the Add Material window.
2
Go to the Add Material window.
3
In the tree, select Built-in>Structural steel.
4
Click Add to Global Materials in the window toolbar.
5
In the Home toolbar, click  Add Material to close the Add Material window.
Materials
Material Link 1 (matlnk1)
In the Model Builder window, under Component 1 (comp1) right-click Materials and choose More Materials>Material Link.
Solid Mechanics (solid)
Roller 1
1
In the Model Builder window, under Component 1 (comp1) right-click Solid Mechanics (solid) and choose Roller.
2
Prescribed Displacement 1
1
In the Physics toolbar, click  Boundaries and choose Prescribed Displacement.
2
3
In the Settings window for Prescribed Displacement, locate the Prescribed Displacement section.
4
Select the Prescribed in y direction check box.
This is effectively a roller condition along the x-axis, but it is applied on a vertical boundary to avoid bending stiffness.
Boundary Load 1
1
In the Physics toolbar, click  Boundaries and choose Boundary Load.
2
3
In the Settings window for Boundary Load, locate the Force section.
4
From the Load type list, choose Total force.
5
Specify the Ftot vector as
Mesh 1
Create a swept mesh along the extrusion direction of the geometry.
Free Triangular 1
1
In the Mesh toolbar, click  Boundary and choose Free Triangular.
2
In the Settings window for Free Triangular, locate the Boundary Selection section.
3
From the Selection list, choose Symmetry z Boundary.
Size
1
In the Model Builder window, click Size.
2
In the Settings window for Size, locate the Element Size section.
3
From the Predefined list, choose Extremely fine.
Swept 1
1
In the Mesh toolbar, click  Swept.
2
In the Settings window for Swept, click  Build All.
Solid Design
1
In the Model Builder window, click Study 1.
2
In the Settings window for Study, type Solid Design in the Label text field.
3
In the Home toolbar, click  Compute.
Results
Initial Design
1
In the Results toolbar, click  Evaluation Group.
2
In the Settings window for Evaluation Group, type Initial Design in the Label text field.
Initial Objective
1
Right-click Initial Design and choose Global Evaluation.
2
In the Settings window for Global Evaluation, type Initial Objective in the Label text field.
3
Click Add Expression in the upper-right corner of the Expressions section. From the menu, choose Component 1 (comp1)>Solid Mechanics>Global>solid.Ws_tot - Total elastic strain energy - J.
4
In the Initial Design toolbar, click  Evaluate.
Global Definitions
Parameters 1
1
In the Model Builder window, under Global Definitions click Parameters 1.
2
In the Settings window for Parameters, locate the Parameters section.
3
Definitions
Density Model 1 (dtopo1)
1
In the Definitions toolbar, click  Optimization and choose Density Model.
2
In the Settings window for Density Model, locate the Geometric Entity Selection section.
3
From the Geometric entity level list, choose Boundary.
4
From the Selection list, choose Symmetry z Boundary.
5
Locate the Control Variable Initial Value section. In the θ0 text field, type volfrac.
Use an extrusion operator to transfer the filtered design variable, theta_f_bnd, to the volume. This approach guarantees an extruded geometry.
General Extrusion 1 (genext1)
1
In the Definitions toolbar, click  Nonlocal Couplings and choose General Extrusion.
2
In the Settings window for General Extrusion, locate the Source Selection section.
3
From the Geometric entity level list, choose Boundary.
4
From the Selection list, choose Symmetry z Boundary.
5
Locate the Destination Map section. In the x-expression text field, type X.
6
In the y-expression text field, type Y.
7
In the z-expression text field, type 0.
8
Locate the Source section. From the Source frame list, choose Material  (X, Y, Z).
Variables 1
1
In the Model Builder window, right-click Definitions and choose Variables.
2
In the Settings window for Variables, locate the Geometric Entity Selection section.
3
From the Geometric entity level list, choose Domain.
4
From the Selection list, choose All domains.
5
Locate the Variables section. In the table, enter the following settings:
Solid Mechanics (solid)
Linear Elastic Material 2
1
In the Physics toolbar, click  Domains and choose Linear Elastic Material.
2
In the Settings window for Linear Elastic Material, locate the Domain Selection section.
3
From the Selection list, choose All domains.
4
Locate the Linear Elastic Material section. From the E list, choose User defined. In the associated text field, type E_SIMP.
Solid Design
Step 1: Stationary
1
In the Model Builder window, under Solid Design click Step 1: Stationary.
2
In the Settings window for Stationary, locate the Physics and Variables Selection section.
3
Select the Modify model configuration for study step check box.
4
In the Physics and variables selection tree, select Component 1 (comp1)>Solid Mechanics (solid)>Linear Elastic Material 2.
5
Click  Disable.
Add Study
1
In the Home toolbar, click  Add Study to open the Add Study window.
2
Go to the Add Study window.
3
Find the Studies subsection. In the Select Study tree, select General Studies>Stationary.
4
Click Add Study in the window toolbar.
5
In the Home toolbar, click  Add Study to close the Add Study window.
Topology Optimization
1
In the Model Builder window, click Study 2.
2
In the Settings window for Study, type Topology Optimization in the Label text field.
Topology Optimization
1
Right-click Topology Optimization and choose Optimization>Topology Optimization.
2
In the Settings window for Topology Optimization, locate the Optimization Solver section.
3
In the Maximum number of iterations text field, type 25.
4
Click Add Expression in the upper-right corner of the Objective Function section. From the menu, choose Component 1 (comp1)>Solid Mechanics>Global>comp1.solid.Ws_tot - Total elastic strain energy - J.
Change the objective function expression to include the normalization constant.
5
Locate the Objective Function section. In the table, enter the following settings:
6
Click Add Expression in the upper-right corner of the Constraints section. From the menu, choose Component 1 (comp1)>Definitions>Density Model 1>Global>comp1.dtopo1.theta_avg - Average material volume factor.
7
Locate the Constraints section. In the table, enter the following settings:
Initialize the study to create a default plot to display while solving.
8
In the Study toolbar, click  Get Initial Value.
The surface plot can visualize intermediate design variables, but now that the optimization has finished, it makes sense to change the filter dataset so that the thresholded volume plot represents the optimized geometry.
9
In the Model Builder window, click Topology Optimization.
10
In the Settings window for Topology Optimization, locate the Output While Solving section.
11
Select the Plot check box.
12
From the Plot group list, choose Output material volume factor.
13
In the Study toolbar, click  Compute.
Results
Topology Optimization
In the Model Builder window, expand the Results>Topology Optimization node.
Surface 1
1
In the Model Builder window, expand the Results>Topology Optimization>Output material volume factor node, then click Surface 1.
2
In the Output material volume factor toolbar, click  Plot.
Filter
1
In the Model Builder window, expand the Results>Datasets node, then click Filter.
2
In the Settings window for Filter, locate the Expression section.
3
In the Expression text field, type theta_f.
Threshold
1
In the Model Builder window, click Threshold.
2
In the Threshold toolbar, click  Plot.
Create a Cut Plane dataset for a 2D plot group, so that the design can be exported.
Cut Plane 1
1
In the Results toolbar, click  Cut Plane.
2
In the Settings window for Cut Plane, locate the Data section.
3
From the Dataset list, choose Topology Optimization/Solution 2 (sol2).
4
Locate the Plane Data section. From the Plane list, choose XY-planes.
Filter 2
1
In the Results toolbar, click  More Datasets and choose Filter.
2
In the Settings window for Filter, locate the Data section.
3
From the Dataset list, choose Cut Plane 1.
4
Locate the Expression section. In the Expression text field, type theta_f.
5
Locate the Filter section. In the Lower bound text field, type 0.5.
6
Locate the Evaluation section. From the Smoothing list, choose None.
7
Clear the Use derivatives check box.
8
Right-click Filter 2 and choose Create Mesh Part.
Mesh Part 1
1
In the Model Builder window, under Global Definitions>Mesh Parts right-click Mesh Part 1 and choose Build All.
2
Right-click Global Definitions>Mesh Parts>Mesh Part 1 and choose Create Geometry from Mesh.
Geometry 2
Import 1 (imp1)
1
In the Settings window for Import, locate the Import section.
2
Clear the Form solids from surface objects check box.
3
Locate the Selections of Resulting Entities section. Select the Resulting objects selection check box.
4
From the Show in physics list, choose Boundary selection.
Extrude 1 (ext1)
1
In the Geometry toolbar, click  Extrude.
2
In the Settings window for Extrude, locate the General section.
3
From the Input faces list, choose Import 1.
4
Locate the Distances section. In the table, enter the following settings:
5
Select the Reverse direction check box.
Line Segment 1 (ls1)
1
In the Geometry toolbar, click  More Primitives and choose Line Segment.
2
In the Settings window for Line Segment, locate the Starting Point section.
3
From the Specify list, choose Coordinates.
4
In the y text field, type L1.
5
Locate the Endpoint section. From the Specify list, choose Coordinates.
6
In the y text field, type L1.
7
In the z text field, type c.
Line Segment 2 (ls2)
1
In the Geometry toolbar, click  More Primitives and choose Line Segment.
2
In the Settings window for Line Segment, locate the Starting Point section.
3
From the Specify list, choose Coordinates.
4
In the x text field, type a-L1/2.
5
In the y text field, type b.
6
Locate the Endpoint section. From the Specify list, choose Coordinates.
7
In the x text field, type a-L1/2.
8
In the y text field, type b.
9
In the z text field, type c.
10
In the Geometry toolbar, click  Build All.
The geometry should now look like that in Figure 1.
Moving Boundaries
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Moving Boundaries in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Boundary.
4
Locate the Box Limits section. In the x minimum text field, type a*0.001.
5
In the x maximum text field, type a*0.999.
6
In the y minimum text field, type b*0.001.
7
In the y maximum text field, type b*0.999.
8
In the z minimum text field, type c*0.001.
9
In the z maximum text field, type c*0.999.
Symmetry x Boundary
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Symmetry x Boundary in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Boundary.
4
Locate the Box Limits section. In the x minimum text field, type a*0.999.
5
Locate the Output Entities section. From the Include entity if list, choose Entity inside box.
Roller Support
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Roller Support in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Boundary.
4
Locate the Box Limits section. In the x maximum text field, type a*0.001.
5
In the y maximum text field, type L1*1.001.
6
Locate the Output Entities section. From the Include entity if list, choose Entity inside box.
Symmetry z Edges
1
In the Geometry toolbar, click  Selections and choose Adjacent Selection.
2
In the Settings window for Adjacent Selection, type Symmetry z Edges in the Label text field.
3
Locate the Input Entities section. From the Geometric entity level list, choose Boundary.
4
Locate the Output Entities section. From the Geometric entity level list, choose Adjacent edges.
5
Locate the Input Entities section. Click  Add.
6
In the Add dialog box, select Import 1 in the Input selections list.
7
Moving Boundaries Edges
1
In the Geometry toolbar, click  Selections and choose Adjacent Selection.
2
In the Settings window for Adjacent Selection, type Moving Boundaries Edges in the Label text field.
3
Locate the Input Entities section. From the Geometric entity level list, choose Boundary.
4
Locate the Output Entities section. From the Geometric entity level list, choose Adjacent edges.
5
Locate the Input Entities section. Click  Add.
6
In the Add dialog box, select Moving Boundaries in the Input selections list.
7
Load Boundary
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Load Boundary in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Boundary.
4
Locate the Box Limits section. In the x minimum text field, type a-L1/1.999.
5
In the y minimum text field, type b*0.999.
6
Locate the Output Entities section. From the Include entity if list, choose Entity inside box.
Roller Design
1
In the Geometry toolbar, click  Selections and choose Complement Selection.
2
In the Settings window for Complement Selection, type Roller Design in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Boundary.
4
Locate the Input Entities section. Click  Add.
5
In the Add dialog box, in the Selections to invert list, choose Moving Boundaries and Load Boundary.
6
Roller Design Edges
1
In the Geometry toolbar, click  Selections and choose Adjacent Selection.
2
In the Settings window for Adjacent Selection, type Roller Design Edges in the Label text field.
3
Locate the Input Entities section. From the Geometric entity level list, choose Boundary.
4
5
In the Add dialog box, select Roller Design in the Input selections list.
6
7
In the Settings window for Adjacent Selection, locate the Output Entities section.
8
From the Geometric entity level list, choose Adjacent edges.
Moving Boundaries Lower Edges
1
In the Geometry toolbar, click  Selections and choose Intersection Selection.
2
In the Settings window for Intersection Selection, type Moving Boundaries Lower Edges in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Edge.
4
Locate the Input Entities section. Click  Add.
5
In the Add dialog box, in the Selections to intersect list, choose Symmetry z Edges and Moving Boundaries Edges.
6
Lower Points
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Lower Points in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Point.
4
Locate the Box Limits section. In the y maximum text field, type 0.001*b.
Upper Points
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Upper Points in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Point.
4
Locate the Box Limits section. In the y minimum text field, type b*0.999.
Upper and Lower Points
1
In the Geometry toolbar, click  Selections and choose Union Selection.
2
In the Settings window for Union Selection, type Upper and Lower Points in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Point.
4
Locate the Input Entities section. Click  Add.
5
In the Add dialog box, in the Selections to add list, choose Lower Points and Upper Points.
6
Left Points
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Left Points in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Point.
4
Locate the Box Limits section. In the x maximum text field, type b*0.001.
Right Points
1
In the Geometry toolbar, click  Selections and choose Box Selection.
2
In the Settings window for Box Selection, type Right Points in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Point.
4
Locate the Box Limits section. In the x minimum text field, type a*0.999.
Left and Right Points
1
In the Geometry toolbar, click  Selections and choose Union Selection.
2
In the Settings window for Union Selection, type Left and Right Points in the Label text field.
3
Locate the Geometric Entity Level section. From the Level list, choose Point.
4
Locate the Input Entities section. Click  Add.
5
In the Add dialog box, in the Selections to add list, choose Left Points and Right Points.
6
Component 2 (comp2)
Add the physics necessary for performing the shape optimization.
Add Physics
1
In the Home toolbar, click  Add Physics to open the Add Physics window.
2
Go to the Add Physics window.
3
In the tree, select Structural Mechanics>Solid Mechanics (solid).
4
Find the Physics interfaces in study subsection. In the table, clear the Solve check boxes for Solid Design and Topology Optimization.
5
Click Add to Component 2 in the window toolbar.
6
In the tree, select Mathematics>Optimization and Sensitivity>General Optimization (opt).
7
In the table, clear the Solve check boxes for Solid Design and Topology Optimization.
8
Click Add to Component 2 in the window toolbar.
9
In the tree, select Mathematics>PDE Interfaces>Lower Dimensions>Coefficient Form Edge PDE (ce).
10
Click to expand the Dependent Variables section. In the Field name text field, type move.
11
Click  Add Dependent Variable.
12
In the Dependent variables table, enter the following settings:
13
Click Add to Component 2 in the window toolbar.
14
In the Home toolbar, click  Add Physics to close the Add Physics window.
Materials
Material Link 2 (matlnk2)
In the Model Builder window, under Component 2 (comp2) right-click Materials and choose More Materials>Material Link.
General Optimization (opt)
Add control variable fields and Helmholtz filters on the edges shared by the z symmetry plane and the boundaries to be optimized.
1
In the Model Builder window, under Component 2 (comp2) click General Optimization (opt).
Control Variable Field 1
1
In the Physics toolbar, click  Edges and choose Control Variable Field.
2
In the Settings window for Control Variable Field, locate the Edge Selection section.
3
From the Selection list, choose Moving Boundaries Lower Edges.
4
Locate the Control Variable section. In the Control variable name text field, type movex.
5
Locate the Discretization section. Find the Base geometry subsection. From the Element order list, choose Linear.
Control Variable Bounds 1
1
In the Physics toolbar, click  Attributes and choose Control Variable Bounds.
2
In the Settings window for Control Variable Bounds, locate the Bounds section.
3
In the Lower bound text field, type -1.
4
In the Upper bound text field, type 1.
Control Variable Field 2
1
In the Model Builder window, under Component 2 (comp2)>General Optimization (opt) right-click Control Variable Field 1 and choose Duplicate.
2
In the Settings window for Control Variable Field, locate the Control Variable section.
3
In the Control variable name text field, type movey.
Topology Optimization
Topology Optimization
1
In the Model Builder window, under Topology Optimization click Topology Optimization.
2
In the Settings window for Topology Optimization, locate the Control Variables section.
3
In the table, clear the Solve for check boxes for General Optimization (opt)/Control Variable Field 1 and General Optimization (opt)/Control Variable Field 2.
Coefficient Form Edge PDE (ce)
1
In the Model Builder window, under Component 2 (comp2) click Coefficient Form Edge PDE (ce).
2
In the Settings window for Coefficient Form Edge PDE, locate the Edge Selection section.
3
From the Selection list, choose Moving Boundaries Lower Edges.
4
Locate the Units section. In the Source term quantity table, enter the following settings:
5
Click to expand the Discretization section. From the Frame list, choose Geometry.
Global Definitions
Parameters 1
Add the shape optimization parameters.
1
In the Model Builder window, under Global Definitions click Parameters 1.
2
In the Settings window for Parameters, locate the Parameters section.
3
Coefficient Form Edge PDE (ce)
Coefficient Form PDE 1
1
In the Model Builder window, under Component 2 (comp2)>Coefficient Form Edge PDE (ce) click Coefficient Form PDE 1.
2
In the Settings window for Coefficient Form PDE, locate the Diffusion Coefficient section.
3
In the c text-field array, type Lmin^2 in the first column of the first row.
4
In the c text-field array, type Lmin^2 in the second column of the second row.
5
Locate the Absorption Coefficient section. In the a text-field array, type 1 in the first column of the first row.
6
In the a text-field array, type 1 in the second column of the second row.
7
Locate the Source Term section. In the f text-field array, type movex on the first row.
8
In the f text-field array, type movey on the second row.
This completes the setup of the Helmholtz filter on an edge with a filter radius of Lmin. Next setup boundary conditions to prevent the shape from moving outside the box of the topology optimization.
Dirichlet Boundary Condition 1
1
In the Physics toolbar, click  Points and choose Dirichlet Boundary Condition.
2
In the Settings window for Dirichlet Boundary Condition, locate the Point Selection section.
3
From the Selection list, choose Upper and Lower Points.
4
Locate the Dirichlet Boundary Condition section. Clear the Prescribed value of dXg check box.
Dirichlet Boundary Condition 2
1
In the Physics toolbar, click  Points and choose Dirichlet Boundary Condition.
2
In the Settings window for Dirichlet Boundary Condition, locate the Point Selection section.
3
From the Selection list, choose Left and Right Points.
4
Locate the Dirichlet Boundary Condition section. Clear the Prescribed value of dYg check box.
Definitions (comp2)
Add a nonlocal integration coupling to enforce the volume constraint.
Integration 1 (intop1)
1
In the Definitions toolbar, click  Nonlocal Couplings and choose Integration.
2
In the Settings window for Integration, locate the Source Selection section.
3
From the Selection list, choose All domains.
Once again use an extrusion operator to transfer the filtered field from the edges to the boundaries.
General Extrusion 2 (genext2)
1
In the Definitions toolbar, click  Nonlocal Couplings and choose General Extrusion.
2
In the Settings window for General Extrusion, locate the Source Selection section.
3
From the Geometric entity level list, choose Edge.
4
From the Selection list, choose Moving Boundaries Lower Edges.
5
Locate the Destination Map section. In the x-expression text field, type Xg.
6
In the y-expression text field, type Yg.
7
In the z-expression text field, type 0.
8
Locate the Source section. From the Source frame list, choose Geometry  (Xg, Yg, Zg).
Variables 2
1
In the Model Builder window, right-click Definitions and choose Variables.
2
In the Settings window for Variables, locate the Geometric Entity Selection section.
3
From the Geometric entity level list, choose Boundary.
4
From the Selection list, choose Moving Boundaries.
5
Locate the Variables section. In the table, enter the following settings:
Deforming Domain 1
1
In the Definitions toolbar, click  Deformed Geometry and choose Deforming Domain.
2
In the Settings window for Deforming Domain, locate the Domain Selection section.
3
From the Selection list, choose All domains.
Prescribed Normal Mesh Displacement 1
1
In the Definitions toolbar, click  Deformed Geometry and choose Prescribed Normal Mesh Displacement.
2
In the Settings window for Prescribed Normal Mesh Displacement, locate the Boundary Selection section.
3
From the Selection list, choose Roller Design.
Prescribed Mesh Displacement 1
1
In the Definitions toolbar, click  Deformed Geometry and choose Prescribed Mesh Displacement.
2
In the Settings window for Prescribed Mesh Displacement, locate the Boundary Selection section.
3
From the Selection list, choose Moving Boundaries.
4
Locate the Prescribed Mesh Displacement section. Specify the dx vector as
Solid Mechanics 2 (solid2)
In the Model Builder window, under Component 2 (comp2) click Solid Mechanics 2 (solid2).
Roller 1
1
In the Physics toolbar, click  Boundaries and choose Roller.
2
In the Settings window for Roller, locate the Boundary Selection section.
3
From the Selection list, choose Symmetry x Boundary.
Roller 2
1
In the Physics toolbar, click  Boundaries and choose Roller.
2
In the Settings window for Roller, locate the Boundary Selection section.
3
From the Selection list, choose Import 1.
Prescribed Displacement 1
1
In the Physics toolbar, click  Boundaries and choose Prescribed Displacement.
2
In the Settings window for Prescribed Displacement, locate the Boundary Selection section.
3
From the Selection list, choose Roller Support.
4
Locate the Prescribed Displacement section. Select the Prescribed in y direction check box.
Boundary Load 1
1
In the Physics toolbar, click  Boundaries and choose Boundary Load.
2
In the Settings window for Boundary Load, locate the Boundary Selection section.
3
From the Selection list, choose Load Boundary.
4
Locate the Force section. From the Load type list, choose Total force.
5
Specify the Ftot vector as
Mesh 2
Once again create a swept mesh along the extrusion direction of the geometry.
Free Triangular 1
1
In the Mesh toolbar, click  Boundary and choose Free Triangular.
2
In the Settings window for Free Triangular, locate the Boundary Selection section.
3
From the Selection list, choose Import 1.
Size
1
In the Model Builder window, click Size.
2
In the Settings window for Size, locate the Element Size section.
3
From the Predefined list, choose Extremely fine.
4
Click to expand the Element Size Parameters section. In the Curvature factor text field, type 2.
Swept 1
1
In the Mesh toolbar, click  Swept.
2
In the Settings window for Swept, click  Build All.
Add Study
1
In the Home toolbar, click  Add Study to open the Add Study window.
2
Go to the Add Study window.
3
Find the Physics interfaces in study subsection. In the table, clear the Solve check box for Solid Mechanics (solid).
4
Find the Studies subsection. In the Select Study tree, select General Studies>Stationary.
5
Click Add Study in the window toolbar.
6
In the Model Builder window, click the root node.
7
In the Home toolbar, click  Add Study to close the Add Study window.
Solid Design
Step 1: Stationary
1
In the Settings window for Stationary, locate the Physics and Variables Selection section.
2
In the Physics and variables selection tree, select Component 2 (comp2)>Definitions>Deformed Geometry, Controls material frame.
3
Click  Disable in Solvers.
Topology Optimization
Step 1: Stationary
1
In the Model Builder window, under Topology Optimization click Step 1: Stationary.
2
In the Settings window for Stationary, locate the Physics and Variables Selection section.
3
In the table, clear the Solve for check box for Deformed geometry (Component 2).
Shape Optimization
1
In the Model Builder window, click Study 3.
2
In the Settings window for Study, type Shape Optimization in the Label text field.
Shape Optimization
1
Right-click Shape Optimization and choose Optimization>Shape Optimization.
2
In the Settings window for Shape Optimization, locate the Optimization Solver section.
3
In the Maximum number of iterations text field, type 20.
4
Clear the Move limits check box.
5
Click Replace Expression in the upper-right corner of the Objective Function section. From the menu, choose Component 2 (comp2)>Solid Mechanics 2>Global>comp2.solid2.Ws_tot - Total elastic strain energy - J.
Change the objective function expression to include the normalization constant.
6
Locate the Objective Function section. In the table, enter the following settings:
7
Locate the Control Variables section. In the table, clear the Solve for check box for Density Model 1 (dtopo1).
8
Click Add Expression in the upper-right corner of the Constraints section. From the menu, choose Component 2 (comp2)>Definitions>Nonlocal couplings>comp2.intop1(expr) - Integration 1.
9
Locate the Constraints section. In the table, enter the following settings:
Initialize the study to create a plot for use while solving.
10
In the Study toolbar, click  Get Initial Value.
The default solver groups the filtered boundary displacements separate from the volume material displacements and this breaks the sensitivity analysis. This issue can be solved by grouping them together or by using a Fully Coupled solver.
Results
3D Plot Group 9
1
In the Model Builder window, expand the Results>3D Plot Group 9 node, then click 3D Plot Group 9.
2
In the Settings window for 3D Plot Group, locate the Plot Settings section.
3
From the Color list, choose Gray.
4
From the Frame list, choose Geometry  (Xg, Yg, Zg).
5
In the Model Builder window, collapse the 3D Plot Group 9 node.
Line 1
1
In the Model Builder window, expand the 3D Plot Group 9 node, then click Line 1.
2
In the Settings window for Line, locate the Coloring and Style section.
3
From the Coloring list, choose Uniform.
4
From the Color list, choose Black.
Arrow Line 1
1
In the Model Builder window, right-click 3D Plot Group 9 and choose Arrow Line.
2
In the Settings window for Arrow Line, locate the Expression section.
3
In the X component text field, type dXg*Lmax.
4
In the Y component text field, type dYg*Lmax.
5
In the Z component text field, type 0.
6
Locate the Coloring and Style section. From the Arrow base list, choose Head.
7
Select the Scale factor check box.
8
Locate the Arrow Positioning section. From the Placement list, choose Mesh nodes.
Selection 1
1
Right-click Arrow Line 1 and choose Selection.
2
In the Settings window for Selection, locate the Selection section.
3
From the Selection list, choose Moving Boundaries Lower Edges.
Color Expression 1
1
In the Model Builder window, right-click Arrow Line 1 and choose Color Expression.
2
In the Settings window for Color Expression, locate the Expression section.
3
In the Expression text field, type max(abs(dXg),abs(dYg)).
4
Click to expand the Range section. Select the Manual color range check box.
5
In the Maximum text field, type 1.
Shape Optimization
1
In the Model Builder window, under Results click 3D Plot Group 9.
2
In the Settings window for 3D Plot Group, type Shape Optimization in the Label text field.
Shape Optimization
Shape Optimization
1
In the Model Builder window, under Shape Optimization click Shape Optimization.
2
In the Settings window for Shape Optimization, locate the Output While Solving section.
3
Select the Plot check box.
4
From the Plot group list, choose Shape Optimization.
Solver Configurations
In the Model Builder window, expand the Shape Optimization>Solver Configurations node.
Solution 3 (sol3)
1
In the Model Builder window, expand the Shape Optimization>Solver Configurations>Solution 3 (sol3)>Optimization Solver 1>Stationary 1>Segregated 1 node.
2
Right-click Material frame coordinates and choose Disable.
3
In the Model Builder window, click Merged variables.
4
In the Settings window for Segregated Step, locate the General section.
5
Under Variables, click  Add.
6
In the Add dialog box, select Material mesh displacement (comp2.material.disp) in the Variables list.
7
8
In the Study toolbar, click  Compute.
Results
Applied Loads (solid) 1, Topology Optimization 1
1
In the Model Builder window, under Results, Ctrl-click to select Applied Loads (solid) 1 and Topology Optimization 1.
2
Create a dataset in the geometry frame, so that the initial and optimized volumes can be plotted on top of each other. The plot illustrates the shape change in an alternative way, but it only makes sense with transparency enabled.
Solid Design/Solution 1 (5) (sol1)
1
In the Results toolbar, click  More Datasets and choose Solution.
2
In the Settings window for Solution, locate the Solution section.
3
From the Solution list, choose Solution 3 (sol3).
4
From the Component list, choose Component 2 (comp2).
5
From the Frame list, choose Geometry  (Xg, Yg, Zg).
Volumetric (for transparent view)
1
In the Results toolbar, click  3D Plot Group.
2
In the Settings window for 3D Plot Group, locate the Data section.
3
From the Dataset list, choose Shape Optimization/Solution 3 (4) (sol3).
4
Locate the Plot Settings section. Clear the Plot dataset edges check box.
5
In the Label text field, type Volumetric (for transparent view).
Volume 1
1
Right-click Volumetric (for transparent view) and choose Volume.
2
In the Settings window for Volume, locate the Coloring and Style section.
3
From the Coloring list, choose Uniform.
Volume 2
1
In the Model Builder window, right-click Volumetric (for transparent view) and choose Volume.
2
In the Settings window for Volume, locate the Data section.
3
From the Dataset list, choose Shape Optimization/Solution 3 (5) (sol3).
4
Locate the Coloring and Style section. From the Coloring list, choose Uniform.
5
From the Color list, choose Gray.
6
Click the  Transparency button in the Graphics toolbar.
7
In the Volumetric (for transparent view) toolbar, click  Plot.
There are some z-fighting artifacts on the Symmetry/Roller boundaries, but this can be avoided by shrinking one of the plots slightly.
Deformation 1
1
In the Model Builder window, right-click Volume 1 and choose Deformation.
2
In the Settings window for Deformation, locate the Expression section.
3
In the X component text field, type -1e-3*(Xg/a-0.5).
4
In the Y component text field, type -1e-3*(Yg/b-0.5).
5
In the Z component text field, type -1e-3*(Zg/c-0.5).
6
Locate the Scale section. Select the Scale factor check box.
7
8
In the Volumetric (for transparent view) toolbar, click  Plot.
Stress (solid) Topology Optimization
1
In the Model Builder window, under Results click Stress (solid) 1.
2
In the Settings window for 3D Plot Group, type Stress (solid) Topology Optimization in the Label text field.
3D Plot Group 10
In the Model Builder window, right-click 3D Plot Group 10 and choose Delete.