src/OpenFOAM logo
The Open Source CFD Toolbox
  Search
  
  Back to OpenFOAM Home
 
  OpenCFD®
  Company profile
  OpenFOAM support
  OpenFOAM development
  OpenFOAM training
  Solutions
  Contact OpenCFD
  Recruitment
  Recommended links
 
  OpenFOAM®
  Features
  Download
  Documentation
  * User Guide
  * C++ Source Guide
  * README file
  * Release notes
  * Upgrading to 1.5
 
  Our trade mark policy
 
  © 2000-2008 OpenCFD Ltd
SourceForge.net Logo
OpenCFD® Solutions Contact OpenFOAM®
OpenFOAM 1.5 User Guide © 2000-2008 OpenCFD Ltd

2.2 Stress analysis of a plate with a hole

This tutorial describes how to pre-process, run and post-process a case involving linear-elastic, steady-state stress analysis on a square plate with a circular hole at its centre. The plate dimensions are: side length 4 m  \special {t4ht= and radius R =  \special {t4ht= 0.5 m  \special {t4ht=. It is loaded with a uniform traction of s =  \special {t4ht= 10  k  \special {t4ht=Pa \special {t4ht= over its left and right faces as shown in 2.15. Two symmetry planes can be identified for this geometry and therefore the solution domain need only cover a quarter of the geometry, shown by the shaded area in 2.15.


                              y
s=10kPa         symmetry plane         x                         s =  10 kPa



                      R = 0.5 m




                                  symmetry plane


                              4.0 m
\special {t4ht=


Figure 2.15: Geometry of the plate with a hole.


The problem can be approximated as 2-dimensional since the load is applied in the plane of the plate. In a Cartesian coordinate system there are two possible assumptions to take in regard to the behaviour of the structure in the third dimension: (1) the plane stress condition, in which the stress components acting out of the 2D plane are assumed to be negligible; (2) the plane strain condition, in which the strain components out of the 2D plane are assumed negligible. The plane stress condition is appropriate for solids whose third dimension is thin as in this case; the plane strain condition is applicable for solids where the third dimension is thick.

An analytical solution exists for loading of an infinitely large, thin plate with a circular hole. The solution for the stress normal to the vertical plane of symmetry is

               (     R2    3R4 )
           { s   1 + --2-+ ---4    for|y| > R
(sxx)x=0 =           2y    2y
             0                     for|y| < R
\special {t4ht=
(2.14)

Results from the simulation will be compared with this solution. At the end of the tutorial, the user can: investigate the sensitivity of the solution to mesh resolution and mesh grading; and, increase the size of the plate in comparison to the hole to try to estimate the error in comparing the analytical solution for an infinite plate to the solution of this problem of a finite plate.

2.2.1 Mesh generation

The domain consists of four blocks, some of which have arc-shaped edges. The block structure for the part of the mesh in the x - y  \special {t4ht= plane is shown in 2.16. As already mentioned in 2.1.1.1, all geometries are generated in 3 dimensions in OpenFOAM even if the case is to be as a 2 dimensional problem. Therefore a dimension of the block in the z  \special {t4ht= direction has to be chosen; here, 0.5 m  \special {t4ht= is selected. It does not affect the solution since the traction boundary condition is specified as a stress rather than a force, thereby making the solution independent of the cross-sectional area.

  8          up         7                 up                   6





left

                                                               right
            4                             3

      x2


  9      x1
                          x2
left
            0          4                                       3
                             x1
            x
 10          2     x
                    1                         2                right
             5          1
          hole
      y             x2            x2


         x        0    x1        1    x1    down              2
                        down
\special {t4ht=


Figure 2.16: Block structure of the mesh for the plate with a hole.


The user should change into the plateHole case in the $FOAM_RUN/tutorials/solidDisplacementFoam directory and open the constant/polyMesh/blockMeshDict file in an editor, as listed below


17  convertToMeters 1;
18  
19  vertices
20  (
21      (0.5 0 0)
22      (1 0 0)
23      (2 0 0)
24      (2 0.707107 0)
25      (0.707107 0.707107 0)
26      (0.353553 0.353553 0)
27      (2 2 0)
28      (0.707107 2 0)
29      (0 2 0)
30      (0 1 0)
31      (0 0.5 0)
32      (0.5 0 0.5)
33      (1 0 0.5)
34      (2 0 0.5)
35      (2 0.707107 0.5)
36      (0.707107 0.707107 0.5)
37      (0.353553 0.353553 0.5)
38      (2 2 0.5)
39      (0.707107 2 0.5)
40      (0 2 0.5)
41      (0 1 0.5)
42      (0 0.5 0.5)
43  );
44  
45  blocks
46  (
47      hex (5 4 9 10 16 15 20 21) (10 10 1) simpleGrading (1 1 1)
48      hex (0 1 4 5 11 12 15 16) (10 10 1) simpleGrading (1 1 1)
49      hex (1 2 3 4 12 13 14 15) (20 10 1) simpleGrading (1 1 1)
50      hex (4 3 6 7 15 14 17 18) (20 20 1) simpleGrading (1 1 1)
51      hex (9 4 7 8 20 15 18 19) (10 20 1) simpleGrading (1 1 1)
52  );
53  
54  edges
55  (
56      arc 0 5 (0.469846 0.17101 0)
57      arc 5 10 (0.17101 0.469846 0)
58      arc 1 4 (0.939693 0.34202 0)
59      arc 4 9 (0.34202 0.939693 0)
60      arc 11 16 (0.469846 0.17101 0.5)
61      arc 16 21 (0.17101 0.469846 0.5)
62      arc 12 15 (0.939693 0.34202 0.5)
63      arc 15 20 (0.34202 0.939693 0.5)
64  );
65  
66  patches
67  (
68      symmetryPlane left
69      (
70          (8 9 20 19)
71          (9 10 21 20)
72      )
73      patch right
74      (
75          (2 3 14 13)
76          (3 6 17 14)
77      )
78      symmetryPlane down
79      (
80          (0 1 12 11)
81          (1 2 13 12)
82      )
83      patch up
84      (
85          (7 8 19 18)
86          (6 7 18 17)
87      )
88      patch hole
89      (
90          (10 5 16 21)
91          (5 0 11 16)
92      )
93      empty frontAndBack
94      (
95          (10 9 4 5)
96          (5 4 1 0)
97          (1 4 3 2)
98          (4 7 6 3)
99          (4 9 8 7)
100          (21 16 15 20)
101          (16 11 12 15)
102          (12 13 14 15)
103          (15 14 17 18)
104          (15 18 19 20)
105      )
106  );
107  
108  mergePatchPairs
109  (
110  );
111  
112  // ************************************************************************* //

Until now, we have only specified straight edges in the geometries of previous tutorials but here we need to specify curved edges. These are specified under the edges keyword entry which is a list of non-straight edges. The syntax of each list entry begins with the type of curve, including arc, simpleSpline, polyLine etc., described further in 5.3.1. In this example, all the edges are circular and so can be specified by the arc keyword entry. The following entries are the labels of the start and end vertices of the arc and a point vector through which the circular arc passes.

The blocks in this blockMeshDict do not all have the same orientation. As can be seen in 2.16 the x2   \special {t4ht= direction of block 0 is equivalent to the - x1   \special {t4ht= direction for block 4. This means care must be taken when defining the number and distribution of cells in each block so that the cells match up at the block faces.

6 patches are defined: one for each side of the plate, one for the hole and one for the front and back planes. The left and down patches are both a symmetry plane. Since this is a geometric constraint, it is included in the definition of the mesh, rather than being purely a specification on the boundary condition of the fields. Therefore they are defined as such using a special symmetryPlane type as shown in the blockMeshDict.

The frontAndBack patch represents the plane which is ignored in a 2D case. Again this is a geometric constraint so is defined within the mesh, using the empty type as shown in the blockMeshDict. For further details of boundary types and geometric constraints, the user should refer to 5.2.1.

The remaining patches are of the regular patch type. The mesh should be generated using blockMesh and can be viewed in paraFoam as described in 2.1.2. It should appear as in 2.17.



\special {t4ht=


Figure 2.17: Mesh of the hole in a plate problem.


2.2.1.1 Boundary and initial conditions
Once the mesh generation is complete, the initial field with boundary conditions must be set. For a stress analysis case without thermal stresses, only displacement D needs to be set. The 0/D is as follows:

17  dimensions      [0 1 0 0 0 0 0];
18  
19  internalField   uniform (0 0 0);
20  
21  boundaryField
22  {
23      left
24      {
25          type            symmetryPlane;
26      }
27      right
28      {
29          type            tractionDisplacement;
30          traction        uniform ( 10000 0 0 );
31          pressure        uniform 0;
32          value           uniform (0 0 0);
33      }
34      down
35      {
36          type            symmetryPlane;
37      }
38      up
39      {
40          type            tractionDisplacement;
41          traction        uniform ( 0 0 0 );
42          pressure        uniform 0;
43          value           uniform (0 0 0);
44      }
45      hole
46      {
47          type            tractionDisplacement;
48          traction        uniform ( 0 0 0 );
49          pressure        uniform 0;
50          value           uniform (0 0 0);
51      }
52      frontAndBack
53      {
54          type            empty;
55      }
56  }
57  
58  // ************************************************************************* //

Firstly, it can be seen that the displacement initial conditions are set to (0,0, 0)  \special {t4ht= m  \special {t4ht=. The left and down patches must be both of symmetryPlane type since they are specified as such in the mesh description in the constant/polyMesh/boundary file. Similarly the frontAndBack patch is declared empty.

The other patches are traction boundary conditions, set by a specialist traction boundary type. The traction boundary conditions are specified by a linear combination of: (1) a boundary traction vector under keyword traction; (2) a pressure that produces a traction normal to the boundary surface that is defined as negative when pointing out of the surface, under keyword pressure. The up and hole patches are zero traction so the boundary traction and pressure are set to zero. For the right patch the traction should be (1e4,0, 0)  \special {t4ht= Pa  \special {t4ht= and the pressure should be 0 Pa  \special {t4ht=.

2.2.1.2 Mechanical properties
The physical properties for the case are set in the mechanicalProperties dictionary in the constant directory. For this problem, we need to specify the mechanical properties of steel given in 2.1. In the mechanical properties dictionary, the user must also set planeStress to yes.


Property Units Keyword Value




Density kg m- 3   \special {t4ht= rho 7854
Young’s modulus Pa  \special {t4ht= E 2 × 1011   \special {t4ht=
Poisson’s ratio -- nu 0.3





Table 2.1: Mechanical properties for steel

2.2.1.3 Thermal properties
The temperature field variable T is present in the solidDisplacementFoam solver since the user may opt to solve a thermal equation that is coupled with the momentum equation through the thermal stresses that are generated. The user specifies at run time whether OpenFOAM should solve the thermal equation by the thermalStress switch in the thermalProperties dictionary. This dictionary also sets the thermal properties for the case, e.g. for steel as listed in 2.2.


Property Units Keyword Value




Specific heat capacity J  \special {t4ht=  -1
kg   \special {t4ht=K- 1   \special {t4ht= C 434
Thermal conductivity W  \special {t4ht=m- 1   \special {t4ht=K -1   \special {t4ht= k 60.5
Thermal expansion coeff. K -1   \special {t4ht= alpha 1.1 × 10-5   \special {t4ht=





Table 2.2: Thermal properties for steel

In this case we do not want to solve for the thermal equation. Therefore we must set the thermalStress keyword entry to no in the thermalProperties dictionary.

2.2.1.4 Control
As before, the information relating to the control of the solution procedure are read in from the controlDict dictionary. For this case, the startTime is 0 s  \special {t4ht=. The time step is not important since this is a steady state case; in this situation it is best to set the time step deltaT to 1 so it simply acts as an iteration counter for the steady-state case. The endTime, set to 100, then acts as a limit on the number of iterations. The writeInterval can be set to 20  \special {t4ht=.

The controlDict entries are as follows:


17  application     solidDisplacementFoam;
18  
19  startFrom       startTime;
20  
21  startTime       0;
22  
23  stopAt          endTime;
24  
25  endTime         100;
26  
27  deltaT          1;
28  
29  writeControl    timeStep;
30  
31  writeInterval   20;
32  
33  purgeWrite      0;
34  
35  writeFormat     ascii;
36  
37  writePrecision  6;
38  
39  writeCompression uncompressed;
40  
41  timeFormat      general;
42  
43  timePrecision   6;
44  
45  graphFormat     raw;
46  
47  runTimeModifiable yes;
48  
49  // ************************************************************************* //

2.2.1.5 Discretisation schemes and linear-solver control
Let us turn our attention to the fvSchemes dictionary. Firstly, the problem we are analysing is steady-state so the user should select SteadyState for the time derivatives in timeScheme. This essentially switches off the time derivative terms. Not all solvers, especially in fluid dynamics, work for both steady-state and transient problems but solidDisplacementFoam does work, since the base algorithm is the same for both types of simulation.

The momentum equation in linear-elastic stress analysis includes several explicit terms containing the gradient of displacement. The calculations benefit from accurate and smooth evaluation of the gradient. Normally, in the finite volume method the discretisation is based on Gauss’s theorem The Gauss method is sufficiently accurate for most purposes but, in this case, the least squares method will be used. The user should therefore open the fvSchemes dictionary in the system directory and ensure the leastSquares method is selected for the grad(U) gradient discretisation scheme in the gradSchemes sub-dictionary:


17  d2dt2Schemes
18  {
19      default     steadyState;
20  }
21  
22  gradSchemes
23  {
24      default         leastSquares;
25      grad(D)         leastSquares;
26      grad(T)         leastSquares;
27  }
28  
29  divSchemes
30  {
31      default         none;
32      div(sigmaD)     Gauss linear;
33  }
34  
35  laplacianSchemes
36  {
37      default         none;
38      laplacian(DD,D) Gauss linear corrected;
39      laplacian(DT,T) Gauss linear corrected;
40  }
41  
42  interpolationSchemes
43  {
44      default         linear;
45  }
46  
47  snGradSchemes
48  {
49      default         none;
50  }
51  
52  fluxRequired
53  {
54      default         no;
55      D               yes;
56      T               no;
57  }
58  
59  // ************************************************************************* //

The fvSolution dictionary in the system directory controls the linear equation solvers and algorithms used in the solution. The user should first look at the solvers sub-dictionary and notice that the GAMG solver is included with entries listed below. The solver tolerance should be set to   -6
10   \special {t4ht= for this problem. The solver relative tolerance, denoted by relTol, sets the required reduction in the residuals within each iteration. It is uneconomical to set a tight (low) relative tolerance within each iteration since a lot of terms are explicit and are updated as part of the segregated iterative procedure. Therefore a reasonable value for the relative tolerance is 0.01  \special {t4ht=, or possibly even higher, say 0.1  \special {t4ht=, or in some case even 0.9  \special {t4ht=.


17  solvers
18  {
19      D GAMG
20      {
21          tolerance        1e-06;
22          relTol           0.9;
23  
24          smoother         GaussSeidel;
25  
26          cacheAgglomeration true;
27  
28          nCellsInCoarsestLevel 20;
29  
30          agglomerator     faceAreaPair;
31          mergeLevels      1;
32      };
33  
34      T GAMG
35      {
36          tolerance        1e-06;
37          relTol           0.9;
38  
39          smoother         GaussSeidel;
40  
41          cacheAgglomeration true;
42  
43          nCellsInCoarsestLevel 20;
44  
45