Skip to content

Commit b56b20e

Browse files
committed
Added linear elastic and linear dynamic tutorial.
1 parent a006a3f commit b56b20e

File tree

6 files changed

+311
-0
lines changed

6 files changed

+311
-0
lines changed
Lines changed: 155 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,155 @@
1+
---
2+
title: Structural Dynamics
3+
permalink: /tutorials/Dynamics/
4+
---
5+
6+
| Written by | for Version | Revised by | Revision date | Revised version |
7+
| --- | --- | --- | --- | --- |
8+
| [@rsanfer](https://github.com/rsanfer) | 7.0.0 | [@rsanfer](https://github.com/rsanfer) | Jan 28, 2020 | 7.0.1 |
9+
10+
###### **At one glance**
11+
12+
###### Solver: ```ELASTICITY```
13+
###### Requires: ```SU2_CFD```
14+
###### Follows: [**Linear Elasticity**](../Linear_Elasticity/)
15+
###### Complexity: <span style="color: green;">**Basic**</span>
16+
17+
### Goals
18+
19+
Upon completion of the tutorial on [Linear Elasticity](../Linear_Elasticity/), this document will guide you throught the following capabilities of SU2:
20+
- Setting up a dynamic structural problem with small deformations
21+
- Time-dependent boundary conditions
22+
- Newmark integration method
23+
24+
The problem that we will be solving consists of a vertical, slender cantilever, clamped in its base, and subject to a horizontal, time-dependent load $$P$$ on its left boundary. This is shown in Fig. 1.
25+
26+
![ProblemSetup](../structural_mechanics/images/lin1.png)
27+
28+
### Resources
29+
30+
For this tutorial, it is assumed that you have first completed the guide on [Linear Elasticity](../Linear_Elasticity/) guide. You can find the resources for this tutorial in the same [structural_mechanics/cantilever](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever) folder in the [Tutorials repository](https://github.com/rsanfer/Tutorials). You can reuse the mesh file [mesh_cantilever.su2](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/mesh_cantilever.su2)
31+
but need a new config file, [config_dynamic.cfg](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/config_dynamic.cfg).
32+
33+
### Background
34+
35+
This tutorial covers the solution of structural dynamics problems. The equation of the problem is now
36+
37+
$$ \mathbf{M}\mathbf{\ddot{u}}+\mathbf{K}\mathbf{u}=\mathbf{F} $$,
38+
39+
where $$\mathbf{K}$$ and $$\mathbf{K}$$ are respectively the stiffness and mass matrices of the cantilever, $$\mathbf{u}$$ is the vector of displacements of the structural nodes, $$\mathbf{\ddot{u}}$$ is the vector of accelerations of the structural nodes, and $$\mathbf{F}$$ is the vector of applied forces, and the structural damping effects have been neglected.
40+
41+
This tutorial will be solved the for the cantilever with the following conditions:
42+
- Young's modulus: $$\mathrm{E = 5.0}$$ $$\mathrm{GPa}$$
43+
- Poisson ratio: $$\nu$$ $$\mathrm{= 0.35}$$
44+
- Solid density: $$\rho$$ $$\mathrm{= 1000}$$ $$\mathrm{kg/m^3}$$
45+
- Height: $$\mathrm{H = 10}$$ $$\mathrm{mm}$$
46+
- Thickness: $$\mathrm{t = 0.5}$$ $$\mathrm{mm}$$
47+
48+
#### Mesh Description
49+
50+
The cantilever is discretized using 1000 4-node quad elements with linear interpolation. The boundaries are defined as follows:
51+
52+
![Mesh](../structural_mechanics/images/lin2.png)
53+
54+
#### Configuration File Options
55+
56+
We start from the configuration options used on the tutorial on [Linear Elasticity]. However, for this case set the analysis to be dynamic using
57+
58+
```
59+
TIME_DOMAIN = YES
60+
TIME_STEP = 0.01
61+
TIME_ITER = 250
62+
```
63+
where the time step $$\Delta t$$ has been set to 10 ms, and the total time of the simulation is $$T = 2.5$$ s (250 time steps). We will be using the Newmark$$^1$$ method for time integration, which relies on the approximations
64+
65+
$$\mathbf{u}^{t} = \mathbf{u}^{t-1} + \Delta t \mathbf{\dot{u}}^{t-1} + [(\frac{1}{2} - \beta)\mathbf{\ddot{u}}^{t-1} + \beta \mathbf{\ddot{u}}^{t}] \Delta t^2$$
66+
67+
and
68+
69+
$$\mathbf{\dot{u}}^{t} = \mathbf{\dot{u}}^{t-1} + [(1 - \gamma)\mathbf{\ddot{u}}^{t-1} + \gamma \mathbf{\ddot{u}}^{t}] \Delta t,$$
70+
71+
to advance the problem in time. Further details about the implementation can be found on [this reference by Sanchez _et al_$$^2$$](https://arc.aiaa.org/doi/10.2514/6.2016-0205), available for download at [Spiral](https://spiral.imperial.ac.uk/handle/10044/1/28633).
72+
73+
We will be introducing a 2% numerical damping, to damp out higher frequencies in the problem. This is done by setting
74+
75+
```
76+
TIME_DISCRE_FEA = NEWMARK_IMPLICIT
77+
NEWMARK_BETA = 0.2601
78+
NEWMARK_GAMMA = 0.52
79+
```
80+
We maintain the structural properties from the previous example. In dynamic problems, inertial effects are incorporated throught the mass matrix $$\mathbf{M}$$. Therefore, it is necessary to define the density of the material, which is done through the following option,
81+
82+
```
83+
MATERIAL_DENSITY = 1000
84+
```
85+
86+
Finally, we define a sinusoidal load, $$\mathrm{P}(t) = A \sin(2\pi f t+\phi)\mathrm{P}$$, being $$f$$ the frequency of the sine wave in Hz, $$A$$ the amplitude and $$\phi$$ the phase angle in rad. This introduces some dynamic effects into the problem. We do so using
87+
88+
```
89+
SINE_LOAD = YES
90+
SINE_LOAD_COEFF = (1.5, 2.0, 4.7124)
91+
```
92+
93+
where ```SINE_LOAD_COEFF=``` ($$A$$, $$f$$, $$\phi$$). We have set a phase angle $$\phi = -3\pi/2$$ and an amplitude $$A = 1.5$$, which leads to a load $$P(t) = -1.5P = -1.5 \textrm{kPa}$$ at time $$t=0$$. The frequency is $$f=2$$ Hz, which leads to 5 full cycles of oscillation in our time span $$T = 5$$ s.
94+
95+
### Running SU2
96+
97+
This is a very small example that we can run in serial. To run this test case, follow these steps at a terminal command line:
98+
1. Move to the directory containing the config file ([config_dynamic.cfg](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/config_dynamic.cfg)) and the mesh file ([mesh_cantilever.su2](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/mesh_cantilever.su2)). Make sure that the SU2 tools were compiled, installed, and that their install location was added to your path.
99+
2. Run the executable by entering
100+
101+
```
102+
$ SU2_CFD config_dynamic.cfg
103+
```
104+
105+
at the command line.
106+
3. SU2 will print the residual of the linear solver for each time step, and the simulation will finish after 250 time steps.
107+
4. Files containing the results will be written upon exiting SU2. The flow solution can be visualized in ParaView (.vtk) or Tecplot (.dat for ASCII).
108+
109+
For this particular problem, the solver should have run very quickly. Please note, a large number of files (500) will be generated upon running SU2 for this case, 2 files corresponding for each time step.
110+
111+
The screen output of the code will go over your settings, before initializing the solver. Once done so, you will obtain an output to screen such as
112+
113+
```
114+
+---------------------------------------------------+
115+
| Time_Iter| rms[DispX]| rms[DispY]| VonMises|
116+
+---------------------------------------------------+
117+
| 249| -11.145342| -11.309566| 1.7175e+06|
118+
119+
----------------------------- Solver Exit -------------------------------
120+
Maximum number of time iterations reached (TIME_ITER = 250).
121+
-------------------------------------------------------------------------
122+
+-----------------------------------------------------------------------+
123+
| File Writing Summary | Filename |
124+
+-----------------------------------------------------------------------+
125+
|SU2 restart |restart_linear_dynamic_00249.dat |
126+
|Paraview binary |linear_dynamic_00249.vtk |
127+
+-----------------------------------------------------------------------+
128+
```
129+
130+
where ```rms[DispX]``` and ```rms[DispY]``` correspond to the residual of the linear solver in the x and y components of the displacements, and ```VonMises``` corresponds to the maximum Von Mises Stress in the structural domain.
131+
132+
### Results
133+
134+
135+
The output files append the time step as _linear_dynamic__*****.vtk_. They contain the displacement field, the nodal tensions $$\sigma_{xx}$$, $$\sigma_{yy}$$ and $$\sigma_{xy}$$ (as Sxx, Syy and Sxy), and the Von Misses stress. In order to visualize the deformation of the cantilever on Paraview, one can use the filter _Warp By Vector_ applied on the displacement field.
136+
137+
The solution of the problem is shown next, where the horizontal displacement at the tip is plotted on the right part of the figure, and the deformed configuration on the left.
138+
139+
![Linear Results](../structural_mechanics/images/dynamic_linear.gif)
140+
141+
### References
142+
$$^1$$ Newmark, N.M. (1959), A method of computation for structural dynamics, _J Eng Mech Div_, 85(3):67-94
143+
144+
### Attribution
145+
146+
If you are using this content for your research, please kindly cite the following reference (reference$$^2$$ in the text above) in your derived works:
147+
148+
Sanchez, R. _et al._ (2016), [Towards a Fluid-Structure Interaction solver for problems with large deformations within the open-source SU2 suite](https://spiral.imperial.ac.uk/handle/10044/1/28633), 57th AIAA/ASCE/AHS/ASC Structures, Structural Dynamics, and Materials Conference, 4-8 January 2016, San Diego, California, USA. DOI: [10.2514/6.2016-0205](https://doi.org/10.2514/6.2016-0205)
149+
150+
151+
<dl>
152+
This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>
153+
<br />
154+
<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons Licence" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a>
155+
</dl>
Lines changed: 156 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,156 @@
1+
---
2+
title: Linear Dynamics
3+
permalink: /tutorials/Linear_Dynamics/
4+
---
5+
6+
| Written by | for Version | Revised by | Revision date | Revised version |
7+
| --- | --- | --- | --- | --- |
8+
| [@rsanfer](https://github.com/rsanfer) | 7.0.0 | [@rsanfer](https://github.com/rsanfer) | Jan 28, 2020 | 7.0.1 |
9+
10+
###### **At one glance**
11+
12+
###### Solver: ```ELASTICITY```
13+
###### Requires: ```SU2_CFD```
14+
###### Complexity: <span style="color: green;">**Basic**</span>
15+
###### Follows: [**Linear Elasticity**](../Linear_Elasticity/)
16+
17+
18+
### Goals
19+
20+
Upon completion of the tutorial on [Linear Elasticity](../Linear_Elasticity/), this document will guide you throught the following capabilities of SU2:
21+
- Setting up a dynamic structural problem with small deformations
22+
- Time-dependent boundary conditions
23+
- Newmark integration method
24+
25+
The problem that we will be solving consists of a vertical, slender cantilever, clamped in its base, and subject to a horizontal, time-dependent load $$P$$ on its left boundary. This is shown in Fig. 1.
26+
27+
![ProblemSetup](../structural_mechanics/images/lin1.png)
28+
29+
### Resources
30+
31+
For this tutorial, it is assumed that you have first completed the guide on [Linear Elasticity](../Linear_Elasticity/) guide. You can find the resources for this tutorial in the same [structural_mechanics/cantilever](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever) folder in the [Tutorials repository](https://github.com/rsanfer/Tutorials). You can reuse the mesh file [mesh_cantilever.su2](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/mesh_cantilever.su2)
32+
but need a new config file, [config_dynamic.cfg](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/config_dynamic.cfg).
33+
34+
### Background
35+
36+
This tutorial covers the solution of structural dynamics problems. The equation of the problem is now
37+
38+
$$ \mathbf{M}\mathbf{\ddot{u}}+\mathbf{K}\mathbf{u}=\mathbf{F} $$,
39+
40+
where $$\mathbf{K}$$ and $$\mathbf{K}$$ are respectively the stiffness and mass matrices of the cantilever, $$\mathbf{u}$$ is the vector of displacements of the structural nodes, $$\mathbf{\ddot{u}}$$ is the vector of accelerations of the structural nodes, and $$\mathbf{F}$$ is the vector of applied forces, and the structural damping effects have been neglected.
41+
42+
This tutorial will be solved the for the cantilever with the following conditions:
43+
- Young's modulus: $$\mathrm{E = 5.0}$$ $$\mathrm{GPa}$$
44+
- Poisson ratio: $$\nu$$ $$\mathrm{= 0.35}$$
45+
- Solid density: $$\rho$$ $$\mathrm{= 1000}$$ $$\mathrm{kg/m^3}$$
46+
- Height: $$\mathrm{H = 10}$$ $$\mathrm{mm}$$
47+
- Thickness: $$\mathrm{t = 0.5}$$ $$\mathrm{mm}$$
48+
49+
#### Mesh Description
50+
51+
The cantilever is discretized using 1000 4-node quad elements with linear interpolation. The boundaries are defined as follows:
52+
53+
![Mesh](../structural_mechanics/images/lin2.png)
54+
55+
#### Configuration File Options
56+
57+
We start from the configuration options used on the tutorial on [Linear Elasticity]. However, for this case set the analysis to be dynamic using
58+
59+
```
60+
TIME_DOMAIN = YES
61+
TIME_STEP = 0.01
62+
TIME_ITER = 250
63+
```
64+
where the time step $$\Delta t$$ has been set to 10 ms, and the total time of the simulation is $$T = 2.5$$ s (250 time steps). We will be using the Newmark$$^1$$ method for time integration, which relies on the approximations
65+
66+
$$\mathbf{u}^{t} = \mathbf{u}^{t-1} + \Delta t \mathbf{\dot{u}}^{t-1} + [(\frac{1}{2} - \beta)\mathbf{\ddot{u}}^{t-1} + \beta \mathbf{\ddot{u}}^{t}] \Delta t^2$$
67+
68+
and
69+
70+
$$\mathbf{\dot{u}}^{t} = \mathbf{\dot{u}}^{t-1} + [(1 - \gamma)\mathbf{\ddot{u}}^{t-1} + \gamma \mathbf{\ddot{u}}^{t}] \Delta t,$$
71+
72+
to advance the problem in time. Further details about the implementation can be found on [this reference by Sanchez _et al_$$^2$$](https://arc.aiaa.org/doi/10.2514/6.2016-0205), available for download at [Spiral](https://spiral.imperial.ac.uk/handle/10044/1/28633).
73+
74+
We will be introducing a 2% numerical damping, to damp out higher frequencies in the problem. This is done by setting
75+
76+
```
77+
TIME_DISCRE_FEA = NEWMARK_IMPLICIT
78+
NEWMARK_BETA = 0.2601
79+
NEWMARK_GAMMA = 0.52
80+
```
81+
We maintain the structural properties from the previous example. In dynamic problems, inertial effects are incorporated throught the mass matrix $$\mathbf{M}$$. Therefore, it is necessary to define the density of the material, which is done through the following option,
82+
83+
```
84+
MATERIAL_DENSITY = 1000
85+
```
86+
87+
Finally, we define a sinusoidal load, $$\mathrm{P}(t) = A \sin(2\pi f t+\phi)\mathrm{P}$$, being $$f$$ the frequency of the sine wave in Hz, $$A$$ the amplitude and $$\phi$$ the phase angle in rad. This introduces some dynamic effects into the problem. We do so using
88+
89+
```
90+
SINE_LOAD = YES
91+
SINE_LOAD_COEFF = (1.5, 2.0, 4.7124)
92+
```
93+
94+
where ```SINE_LOAD_COEFF=``` ($$A$$, $$f$$, $$\phi$$). We have set a phase angle $$\phi = -3\pi/2$$ and an amplitude $$A = 1.5$$, which leads to a load $$P(t) = -1.5P = -1.5 \textrm{kPa}$$ at time $$t=0$$. The frequency is $$f=2$$ Hz, which leads to 5 full cycles of oscillation in our time span $$T = 5$$ s.
95+
96+
### Running SU2
97+
98+
This is a very small example that we can run in serial. To run this test case, follow these steps at a terminal command line:
99+
1. Move to the directory containing the config file ([config_dynamic.cfg](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/config_dynamic.cfg)) and the mesh file ([mesh_cantilever.su2](https://github.com/rsanfer/Tutorials/blob/master/structural_mechanics/cantilever/mesh_cantilever.su2)). Make sure that the SU2 tools were compiled, installed, and that their install location was added to your path.
100+
2. Run the executable by entering
101+
102+
```
103+
$ SU2_CFD config_dynamic.cfg
104+
```
105+
106+
at the command line.
107+
3. SU2 will print the residual of the linear solver for each time step, and the simulation will finish after 250 time steps.
108+
4. Files containing the results will be written upon exiting SU2. The flow solution can be visualized in ParaView (.vtk) or Tecplot (.dat for ASCII).
109+
110+
For this particular problem, the solver should have run very quickly. Please note, a large number of files (500) will be generated upon running SU2 for this case, 2 files corresponding for each time step.
111+
112+
The screen output of the code will go over your settings, before initializing the solver. Once done so, you will obtain an output to screen such as
113+
114+
```
115+
+---------------------------------------------------+
116+
| Time_Iter| rms[DispX]| rms[DispY]| VonMises|
117+
+---------------------------------------------------+
118+
| 249| -11.145342| -11.309566| 1.7175e+06|
119+
120+
----------------------------- Solver Exit -------------------------------
121+
Maximum number of time iterations reached (TIME_ITER = 250).
122+
-------------------------------------------------------------------------
123+
+-----------------------------------------------------------------------+
124+
| File Writing Summary | Filename |
125+
+-----------------------------------------------------------------------+
126+
|SU2 restart |restart_linear_dynamic_00249.dat |
127+
|Paraview binary |linear_dynamic_00249.vtk |
128+
+-----------------------------------------------------------------------+
129+
```
130+
131+
where ```rms[DispX]``` and ```rms[DispY]``` correspond to the residual of the linear solver in the x and y components of the displacements, and ```VonMises``` corresponds to the maximum Von Mises Stress in the structural domain.
132+
133+
### Results
134+
135+
136+
The output files append the time step as _linear_dynamic__*****.vtk_. They contain the displacement field, the nodal tensions $$\sigma_{xx}$$, $$\sigma_{yy}$$ and $$\sigma_{xy}$$ (as Sxx, Syy and Sxy), and the Von Misses stress. In order to visualize the deformation of the cantilever on Paraview, one can use the filter _Warp By Vector_ applied on the displacement field.
137+
138+
The solution of the problem is shown next, where the horizontal displacement at the tip is plotted on the right part of the figure, and the deformed configuration on the left.
139+
140+
![Linear Results](../structural_mechanics/images/dynamic_linear.gif)
141+
142+
### References
143+
$$^1$$ Newmark, N.M. (1959), A method of computation for structural dynamics, _J Eng Mech Div_, 85(3):67-94
144+
145+
### Attribution
146+
147+
If you are using this content for your research, please kindly cite the following reference (reference$$^2$$ in the text above) in your derived works:
148+
149+
Sanchez, R. _et al._ (2016), [Towards a Fluid-Structure Interaction solver for problems with large deformations within the open-source SU2 suite](https://spiral.imperial.ac.uk/handle/10044/1/28633), 57th AIAA/ASCE/AHS/ASC Structures, Structural Dynamics, and Materials Conference, 4-8 January 2016, San Diego, California, USA. DOI: [10.2514/6.2016-0205](https://doi.org/10.2514/6.2016-0205)
150+
151+
152+
<dl>
153+
This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>
154+
<br />
155+
<a rel="license" href="http://creativecommons.org/licenses/by/4.0/"><img alt="Creative Commons Licence" style="border-width:0" src="https://i.creativecommons.org/l/by/4.0/88x31.png" /></a>
156+
</dl>
19.3 MB
Loading
17.9 KB
Loading
3.94 KB
Loading
58.5 KB
Loading

0 commit comments

Comments
 (0)