Explorar el Código

fatigue

master
gtheler hace 5 años
padre
commit
c177638c22
Se han modificado 12 ficheros con 895 adiciones y 185 borrados
  1. +757
    -86
      mech-view1-annotated.svg
  2. +107
    -97
      nafems4.md
  3. +31
    -2
      references.bib
  4. BIN
      table-cuf-1.png
  5. BIN
      table-cuf-2.png
  6. BIN
      table-cuf-3.png
  7. BIN
      table-cuf-4.png
  8. BIN
      table-cuf.png
  9. BIN
      table-cufen-1.png
  10. BIN
      table-cufen-2.png
  11. BIN
      table-cufen-3.png
  12. BIN
      table-cufen-4.png

+ 757
- 86
mech-view1-annotated.svg
La diferencia del archivo ha sido suprimido porque es demasiado grande
Ver fichero


+ 107
- 97
nafems4.md Ver fichero

@@ -25,15 +25,15 @@ The very same difference between what I imagined studying a pendulum was and wha
In this regard, I am referring only to technical issues. The part of dealing with clients, colleagues, bosses, etc. which is definitely not taught in engineering schools (you can get an understanding in business schools, but again it would be a theoretical pendulum) is way beyond the scope of both this article and my own capabilities.

::::: {#fig:pendulum}
![Simple pendulum](simple.svg){#fig:simple width=35%}\
![Real pendulum](hamaca.jpg){#fig:hamaca width=60%}
![Simple pendulum.](simple.svg){#fig:simple width=35%}\
![Real pendulum.](hamaca.jpg){#fig:hamaca width=60%}

A [simple pendulum from college physics](https://www.seamplex.com/wasora/doc/realbook/012-mechanics/) and a real-life pendulum.
:::::

::::: {#fig:pipes}
![College pipe](infinite-pipe.svg){#fig:infinite-pipe width=40%}
![Real-life pipe](isometric.svg){#fig:isometric width=58%}
![College pipe.](infinite-pipe.svg){#fig:infinite-pipe width=40%}
![Real-life pipe.](isometric.svg){#fig:isometric width=58%}

Left: what we are taught in college. Right: a real-life isometric drawing.
:::::
@@ -46,7 +46,7 @@ Like the pendulums above, we will be swinging back and forth between a case stud
Finite elements are like magic to me. I mean, I can follow the whole derivation of the equations, from the strong, weak and variational formulations of the equilibrium equations for the mechanical problem (or the energy conservation for heat transfer) down to the [algebraic multigrid](https://en.wikipedia.org/wiki/Multigrid_method) [preconditioner](https://en.wikipedia.org/wiki/Preconditioner) for the inversion of the [stiffness matrix](https://en.wikipedia.org/wiki/Stiffness_matrix) passing through [Sobolev spaces](https://en.wikipedia.org/wiki/Sobolev_space) and the [grid generation](https://en.wikipedia.org/wiki/Mesh_generation). Then I can sit down and program all these steps into a computer, including the [shape functions](https://en.wikipedia.org/wiki/Finite_element_method_in_structural_mechanics#Interpolation_or_shape_functions) and its derivatives, the assembly of the discretised stiffness matrix ([@sec:building]), the numerical solution of the system of equations ([@sec:solving]) and the computation of the gradient of the solution (@sec:stress-computation). Yet, the fact that all these a-priori unconnected steps give rise to pretty pictures that resemble reality is still astonishing to me.
divert(0)

When finishing college, we feel we can solve and fix the world (if you did not finish yet, you will feel it shortly). But the thing is that we cannot (yet). Once again, take all this information as coming from a fellow that has already taken such a journey from college’s pencil and paper to real engineering cases involving complex numerical calculations. And developing, in the meantime, both an actual working finite-element [solver](https://www.seamplex.com/fino) and a [web-based pre and post-processor](https://www.caeplex.com) from scratch.dnl^[The dean of the engineering school I attended used to say “It is not the same to read than to write manuals, and we should aim at writing them.”]
After finishing college, we feel we can solve and fix the world (if you did not finish yet, you will feel it shortly). But the thing is that we cannot (yet). Once again, take all this information as coming from a fellow that has already taken such a journey from college’s pencil and paper to real engineering cases involving complex numerical calculations. And developing, in the meantime, both an actual working finite-element [solver](https://www.seamplex.com/fino) and a [web-based pre and post-processor](https://www.caeplex.com) from scratch.dnl^[The dean of the engineering school I attended used to say “It is not the same to read than to write manuals, and we should aim at writing them.”]


### Tips and hints
@@ -87,7 +87,7 @@ In each of the countries that have at least one nuclear power plant there exists

Why are pipes subject to fatigue? Well, on the one hand and without getting into many technical details, the most common nuclear reactor design uses liquid water too extract the heat generated in the fuel rods (coolant) and to slow down fast neutrons born in the fission process (moderator). Nuclear power plants cannot by-pass the thermodynamics of the [Carnot cycle](https://en.wikipedia.org/wiki/Carnot_cycle) thus in order to maximise the efficiency of the conversion of the energy stored in the uranium nuclei into electricity we need to reach temperatures as high as possible. So, if we want to have liquid water in the core as hot as possible, we need to increase the pressure. The limiting temperature and pressure are given by the [critical point of water](https://en.wikipedia.org/wiki/Critical_point_(thermodynamics)), which is around 374ºC and 22\ MPa. It is therefore expected to have temperatures and pressures near those values in many systems of the plant, especially in the primary circuit (which is in contact with the reactor core) and those that directly interact with it, such as pressure and inventory control system, decay power removal system, feedwater supply system, emergency core-cooling system, etc.

[@Fig:cad-figure] shows the three-dimensional CAD model of a non-real piping system of an imaginary nuclear power plant which will serve as our case study to illustrate the complexities that arise in real-life engineering projects as compared to theoretical pipes drawn on a blackboard. There is a valve with a 10-inch inlet and a 12-inch outlet. There are elbows and a tee. There are supports at the end of the pipes and at intermediate locations, etc. And, more importantly, the 12-inch pipe, the valve body and the inlet and outlet nozzles are made of stainless steel while the 10-inch pipe is made of carbon steel. So _differential_ thermal expansion leading to non-trivial mechanical stresses are expected to occur if the temperature distribution changes in time. This indeed happens a lot because nuclear power plants are not always working at 100% of their maximum power capacity. They need to be maintained and refuelled, they may undergo operational (and some incidental) transients, they might operate at a lower power due to load following conditions, etc.
[@Fig:cad-figure] shows the three-dimensional CAD model of a non-real piping system of an imaginary nuclear power plant which will serve as our case study to illustrate the complexities that arise in real-life engineering projects as compared to theoretical pipes drawn on a blackboard.^[This is one of the cases where using 2D elements cannot recover the physics of the real problem, as discussed by Łukasz Skotny in his [blog](https://enterfea.com/2d-vs-3d-finite-element-analysis/) [@lukasz].] There is a valve with a 10-inch inlet and a 12-inch outlet. There are elbows and a tee. There are supports at the end of the pipes and at intermediate locations, etc. And, more importantly, the 12-inch pipe, the valve body and the inlet and outlet nozzles are made of stainless steel while the 10-inch pipe is made of carbon steel. So _differential_ thermal expansion leading to non-trivial mechanical stresses are expected to occur if the temperature distribution changes in time. This indeed happens a lot because nuclear power plants are not always working at 100% of their maximum power capacity. They need to be maintained and refuelled, they may undergo operational (and some incidental) transients, they might operate at a lower power due to load following conditions, etc.

![3D\ CAD model for the (non-real) piping system used as the study case.](cad-figure-annotated.svg){#fig:cad-figure width=85%}

@@ -157,7 +157,7 @@ What does this all have to do with mechanical engineering? Well, once we know wh
> If you can compute the stress tensor at each point of your geometry, then... Congratulations! You have solved the solid mechanics problem.
divert(0)

The full solution involve the nine stresses, out of which there are only six that are different. If we manage to compute the principal stresses $\sigma_1$, $\sigma_2$ and $\sigma_3$ we reduce the number to three. We can go further and obtain a single scalar stress “intensity” value by using one of several material yield theories. The two most common ones are those by [Tresca](https://en.wikipedia.org/wiki/Henri_Tresca) and [von\ Mises](https://en.wikipedia.org/wiki/Richard_von_Mises). The former is the maximum absolute difference between all possible combination of principal stresses
The full solution involves the nine stresses, out of which there are only six that are different.^[There is a very interesting [blog post](https://nickjstevens.netlify.com/post/2019/stress-singularities/) by Nick Stevens that addresses the issue of stresses computed at sharp corners which is worth checking out to fully understand what this all means practically [@nick].] If we manage to compute the principal stresses $\sigma_1$, $\sigma_2$ and $\sigma_3$ we reduce the number to three. We can go further and obtain a single scalar stress “intensity” value by using one of several material yield theories. The two most common ones are those by [Tresca](https://en.wikipedia.org/wiki/Henri_Tresca) and [von\ Mises](https://en.wikipedia.org/wiki/Richard_von_Mises). The former is the maximum absolute difference between all possible combination of principal stresses

$$
\sigma_\text{Tr} = \max \Big[
@@ -190,7 +190,7 @@ Let us take to our second step, and consider the infinite pipe subject to unifor
Figures from [Timoshenko](https://en.wikipedia.org/wiki/Semyon_Timoshenko) seminal book [@timoshenko].
:::::

dnl Given the cylindrical symmetry of the problem, there can be no dependence on the angular coordinate\ $\theta$ (i.e. there can be no torsion). Also, due to the assumption that the pipe is infinite, no result can depend on the axial direction (i.e. it cannot bend along its axis) so there is only one independent variable, namely the radial coordinate $r$. Moreover, there are only two displacement fields that need to be considered: the axial $u_a(r)$ and the radial $u_r(r)$. The former is identically zero due to the fact that the cylinder is infinite so it makes no sense to assume the pipe can move any finite value along its axis, rendering a [plane strain condition](https://www.ramsay-maunder.co.uk/downloads/NBR03.pdf).
dnl Given the cylindrical symmetry of the problem, there can be no dependence on the angular coordinate\ $\theta$ (i.e. there can be no torsion). Also, due to the assumption that the pipe is infinite, no result can depend on the axial direction (i.e. it cannot bend along its axis) so there is only one independent variable, namely the radial coordinate $r$. Moreover, there are only two displacement fields that need to be considered: the axial $u_a(r)$ and the radial $u_r(r)$. The former is identically zero due to the fact that the cylinder is infinite so it makes no sense to assume the pipe can move any finite value along its axis, rendering a [plane strain condition](https://www.ramsay-maunder.co.uk/downloads/NBR03.pdf), which is thoroughly discussed in [@nbr03].

divert(-1)
The equilibrium equation along the radial direction $r$, also known as the [Lamé](https://en.wikipedia.org/wiki/Gabriel_Lam%C3%A9) equation, can be derived with the aid of [@fig:timoshenko-eq] as
@@ -298,9 +298,9 @@ Each of these methods (also called schemes) have of course their own features, p
Figure [-@fig:grids] illustrates how the same domain can be discretised using these two kind of grids. In the first case, we could identify any single cell by using just two indexes. We could even tell which nodes define each cell just from these indexes. In the second case, we need an explicit list just to know how many cells there are. Even more, there is no way to link the nodes with the cells (back and forth) other than having an explicit list of nodes and cells. Again, there are pros and cons for each of the grid types such as simplicity, flexibility, etc. In general, unstructured grids can better represent a certain geometry with the same number of cells. Structured grids suffer the so-called “staircase effect” that makes the unusable for discretising mechanical parts.

::::: {#fig:grids}
![Continuous domain](dominio-continuo.svg){#fig:continuous width=30%}\
![Structured grid](dominio-estructurado.svg){#fig:structured width=30%}\
![Unstructured grid](dominio-no-estructurado.svg){#fig:unstructured width=30%}
![Continuous domain.](dominio-continuo.svg){#fig:continuous width=30%}\
![Structured grid.](dominio-estructurado.svg){#fig:structured width=30%}\
![Unstructured grid.](dominio-no-estructurado.svg){#fig:unstructured width=30%}

Discretisation of a spatial domain, For the same number of cells, unstructured grids can better represent arbitrary shapes.
:::::
@@ -397,7 +397,7 @@ dnl As I wanted to illustrate in [@sec:five], it is very important to decide wha

Since we already agreed there is no way to obtain analytical expressions for the stresses in this general case, we need to employ a numerical scheme to solve the equations. Of course we are choosing the finite element method, but keep in mind that there are a lot of other methods for solving partial differential equations: finite differences, finite volumes, modal methods, etc. Even within finite elements there are many variation, such as displacement-based or mixed formulations, Galerkin or least-squares weighting, and so on. In particular, finite elements compute nodal values (i.e. displacements and stresses at discrete points in space) and then provide a way to interpolate back the results into any other arbitrary point of the domain. If the method is applied correctly, a mesh refinement will lead to improved results---at the cost of needing an exponentially-increasing computing power, measured in both CPU and RAM. In the limit of infinite number of nodes, the FEM results converge to the actual solution of the original PDEs.

For instance, [@fig:ur] shows how some results obtained with the finite element method using different number and order of elements compare to the analytical solution from the previous section. The bullets correspond to the nodal values of the radial displacements and stresses obtained with the finite element method [@pipe-linearized]. The more number of nodes employed, the more accurate the results are---at the expense of an increase of time and computational effort needed to solve the problem.
For instance, [@fig:ur] shows how some results obtained with the finite element method using different number and order of elements compare to the analytical solution from the previous section. The bullets correspond to the nodal values of the radial displacements and stresses obtained with the finite element method [@pipe-linearized] using an unstructured grid of almost-randomly oriented tetrahedra. The more number of nodes employed, the more accurate the results are---at the expense of an increase of time and computational effort needed to solve the problem.

:::: {#fig:pipe-linearized}
![$u_r(r)$ from [@sec:u].](ur.svg){#fig:ur width=90%}
@@ -443,7 +443,7 @@ All these effects will give rise to stresses that, if repeated over time, will c

![Location of four SCLs to asses fatigue at a material interface.](scls.svg){#fig:scls width=90%}

For the present case study, four SCLs were defined as illustrated in [@fig:scls]: at a distance of three millimetres from the carbon-stainless steel material interface at the valve inlet, on the vertical $x$-$z$ plane, two on each material, two at the bottom and two at the top of the pipes. It is at the internal point of these four SCLs that fatigue resistance is to be assessed.
For the present case study, four SCLs were defined as illustrated in [@fig:scls]: at a distance of three millimetres from the carbon-stainless steel material interface at the valve inlet, on the vertical $x$-$z$ plane, two on each material: two at the bottom and two at the top of the pipes. It is at the internal point of these four SCLs that fatigue resistance is to be assessed.



@@ -451,12 +451,12 @@ For the present case study, four SCLs were defined as illustrated in [@fig:scls]
### Thermal transient {#sec:thermal}

Let us invoke our imagination once again. Assume in a certain time interval of the transients the temperature of the water inside the pipes fell abruptly from say 250ºC down 250ºC in a few seconds, stayed cool for half an hour and then went back to 250ºC (similarly to [@fig:pt4]). The internal wall of the pipes would follow the transient temperature (it might be exactly equal or close to it through the [Newton’s law of cooling](https://en.wikipedia.org/wiki/Newton%27s_law_of_cooling))
Let us invoke our imagination once again. Assume in a certain time interval of the transients the temperature of the water inside the pipes fell abruptly from say 250ºC down to 150ºC in a few seconds, stayed cool for half an hour and then went back to 250ºC (similarly to [@fig:pt4]). The internal wall of the pipes would follow the transient temperature (it might be exactly equal or close to it through the [Newton’s law of cooling](https://en.wikipedia.org/wiki/Newton%27s_law_of_cooling))
If the pipe was in a state of uniform temperature, the ramp in the internal wall would start cooling the bulk of the pipe creating a transient thermal gradient. Due to thermal inertia effects, the temperature might have a non-trivial dependence when the ramps started or ended. First try to think and picture it! Then see @fig:valve-temp and the videos referenced at @sec:online. So we need to compute a transient heat transfer problem with convective boundary conditions because any other usual tricks like computing a sequence of steady-state computations for different times would not be able to recover these non-trivial distributions.

Remember the main issue of the fatigue analysis in these systems is to analyse what happens around the location of changes of piping classes where different materials (i.e. different expansion coefficients) are present, potentially causing high stresses due to differential thermal expansion (or contraction) under transient conditions. Therefore, even though we are dealing with pipes we cannot use beam or circular shell elements, because we need to take into account the three-dimensional effects of the temperature distribution along the pipe thickness, let alone to model what happens within the body of the valve.

On the one hand, a reasonable number of nodes^[Remember it is the number of degrees of freedom that defines the problem size, which in the finite element method is given by the number of nodes and not by the number of elements. Conversely, if we used finite volumes, it would be given by the number of elements and not by the number of nodes. The two meshes below have the same number of nodes but the one on the right has more nodes and will thus give far more accurate results.\newline![](distorted.png){width=100%}] in order to get a decent grid is around a couple of thousand for each piping system under study (@fig:mech). On the other hand, solving dozens of transient heat transfer problems during a few thousands of seconds over a couple hundred of thousands of nodes might take more time and storage space to hold the results than we might have.
On the one hand, a reasonable number of nodes^[Remember it is the number of degrees of freedom that defines the problem size, which in the finite element method is given by the number of _nodes_ and not by the number of elements. Conversely, had we used finite volumes, it would have been given by the number of elements and not by the number of nodes. The two meshes below have the same number of nodes but the one on the right has more nodes (and uses curved elements to better approximate the continuous geometry) and will thus give far more accurate results.\newline![](distorted.png){width=100%}] in order to get a decent grid is around a couple of thousand for each piping system under study (@fig:mech). On the other hand, solving dozens of transient heat transfer problems during a few thousands of seconds over a couple hundred of thousands of nodes might take more time and storage space to hold the results than we might have.

::: {#fig:mech}
![Full view of 200k nodes spanning $\approx$ 100k 2nd-order tetrahedra.](mech-view1-annotated.svg){width=95% #fig:mech-msh}
@@ -487,9 +487,9 @@ Instead of solving the transient heat-conduction problem on the full 200k-nodes
Reduced mesh around the valve including the carbon-steel nozzle.
:::::

![Generalization of the temperature distribution from [@fig:valve-temp] to [@fig:mech].](temperature-generalization.png){#fig:temp-generalization width=100%}
![Generalisation of the temperature distribution from [@fig:valve-temp] to [@fig:mech].](temperature-generalization.png){#fig:temp-generalization width=100%}

![Temperature evolution at the SCLs for transient #1.](temp-zoom.svg){#fig:temp-zoom width=100%}
![Temperature evolution at two SCLs for transient #1.](temp-zoom.svg){#fig:temp-zoom width=100%}


Note that there is no need to have a one-to-one correspondence between the elements from the reduced mesh with the elements from the original one. Actually, the reduced mesh contains first-order elements whilst the former has second-order elements. Also the grid density is different, yet both of them are locally refined around the material interface. Nevertheless, the finite-element solver [Fino](https://www.seamplex.com/fino)---used to solve both the heat and the mechanical problems---allows to read functions of space and time defined over one mesh and continuously evaluate and use them into another one even if the two grids have different elements, orders or even dimensions.
@@ -536,14 +536,14 @@ divert(0)
Since the computation of the loads that a certain earthquake gives rise to would add a significant amount of complexity to this already-complex case study (after all this is the main point of this chapter!), the details are skipped. In any case, we need to compute the first natural modes of oscillation of the piping section under study ([@fig:modes]) and then, after some cumbersome mathematics (which I encourage those brave readers to dig into), obtain an statically-equivalent load distribution. In effect, [@fig:modes] shows the first six natural modes of oscillation of the piping system under study. This information can be used to compute an acceleration distribution which, when multiplied by the steel density, give a load distribution which is---in a certain sense---“statically equivalent” to the dynamic solicitations created by the earthquake.

::::: {#fig:modes}
![$f_1 \approx 20$\ [Hz](https://www.seamplex.com/docs/nafems4/mode1.webm)](mode1.0000.png){width=48%}\
![$f_2 \approx 35$\ [Hz](https://www.seamplex.com/docs/nafems4/mode2.webm)](mode2.0000.png){width=48%}
![$f_1 \approx 20$\ Hz.](mode1.0000.png){width=48%}\
![$f_2 \approx 35$\ Hz.](mode2.0000.png){width=48%}

![$f_3 \approx 50$\ [Hz](https://www.seamplex.com/docs/nafems4/mode3.webm)](mode3.0000.png){width=48%}\
![$f_4 \approx 70$\ [Hz](https://www.seamplex.com/docs/nafems4/mode5.webm)](mode4.0000.png){width=48%}
![$f_3 \approx 50$\ Hz.](mode3.0000.png){width=48%}\
![$f_4 \approx 70$\ Hz.](mode4.0000.png){width=48%}

![$f_5 \approx 85$\ [Hz](https://www.seamplex.com/docs/nafems4/mode5.webm)](mode5.0000.png){width=48%}\
![$f_6 \approx 90$\ [Hz](https://www.seamplex.com/docs/nafems4/mode6.webm)](mode6.0000.png){width=48%}
![$f_5 \approx 85$\ Hz.](mode5.0000.png){width=48%}\
![$f_6 \approx 90$\ Hz.](mode6.0000.png){width=48%}

First natural oscillation modes. Videos available online ([@sec:online]).
:::::
@@ -614,11 +614,11 @@ $$


::::: {#fig:cube}
![Case B, pure-shear loads](cube-shear.png){#fig:cube-shear width=65%}
![Case B, pure-shear loads.](cube-shear.png){#fig:cube-shear width=65%}

![Case C, normal plus shear loads](cube-full.png){#fig:cube-full width=65%}
![Case C, normal plus shear loads.](cube-full.png){#fig:cube-full width=65%}

Spatial distribution of principal stress\ 3 for cases\ B and\ C. If linearity applied, case\ C would be equal to case\ B plus a constant
Spatial distribution of principal stress\ 3 for cases\ B and\ C. If linearity applied, case\ C would be equal to case\ B plus a constant.
:::::

In the second case, the principal stresses are not uniform and have a non-trivial distribution. Indeed, the distribution of\ $\sigma_3$ obtained by [CAEplex](https://www.caeplex.com) is shown in\ [@fig:cube-shear].
@@ -768,8 +768,8 @@ The first thing that has to be said is that, as with any interesting problem, th
10. etc.

::::: {#fig:quarter}
![Structured second-order hexahedra](quarter-struct.png){#fig:cube-struct width=50%}\
![Unstructured second-order tetrahedra](quarter-caeplex.png){#fig:quarter-caeplex width=50%}
![Structured second-order hexahedra.](quarter-struct.png){#fig:cube-struct width=50%}\
![Unstructured second-order tetrahedra.](quarter-caeplex.png){#fig:quarter-caeplex width=50%}

Two of the hundreds of different ways the infinite pressurised pipe can be solved using FEM. The axial displacement at the ends is set to zero, leading to a [plane-strain](https://en.wikipedia.org/wiki/Plane_stress#Plane_strain_(strain_matrix)) condition
:::::
@@ -794,10 +794,10 @@ dnl * The finite-element results for the displacements are similar to the analyt
* The error with respect to the analytical solutions as a function of the CPU time needed to compute the membrane stress is similar for both first and second-order grids. But for the computation of the membrane plus bending stress ([@fig:error-MB-vs-cpu]), first-order grids give very poor results compared to second-order grids for the same CPU time.

::::: {#fig:error-vs-cpu}
![Membrane $\text{M}$](error-M-vs-cpu-small.svg){#fig:error-M-vs-cpu width=49%}
![Membrane plus bending $\text{MB}$](error-MB-vs-cpu-small.svg){#fig:error-MB-vs-cpu width=49%}
![Membrane $\text{M}$.](error-M-vs-cpu-small.svg){#fig:error-M-vs-cpu width=49%}
![Membrane plus bending $\text{MB}$.](error-MB-vs-cpu-small.svg){#fig:error-MB-vs-cpu width=49%}

Error in the computation of the linearised stresses vs. CPU time needed to solve the infinite pipe problem using the finite element method
Error in the computation of the linearised stresses vs. CPU time needed to solve the infinite pipe problem using the finite element method.
:::::

An additional note should be added. The FEM solution, which not only gives the nodal displacements but also a method to interpolate these values inside the elements, does not fully satisfy the original equilibrium equations at every point (i.e. the strong formulation). It is an approximation to the solution of the [weak formulation](https://en.wikipedia.org/wiki/Weak_formulation) that is close (measured in the vector space spanned by the [shape functions](https://www.quora.com/What-is-a-shape-function-in-FEM)) to the real solution. Mechanically, this means that the FEM solution leads only to nodal equilibrium but not point-wise equilibrium.
@@ -846,10 +846,10 @@ The objective of the solver is to find the vector\ $\mathbf{u}$ of nodal displac
So the question is... how hard is it to solve a sparse linear problem? Well, the number of iterations and the complexity of the partial decompositions needed to attain convergence depends on the [spectral radius](https://en.wikipedia.org/wiki/Spectral_radius) of the stiffness matrix\ $K$, which in turns depend on the elements themselves, which depend mainly on the parameters of the elastic problem. But it also depends on how sparse\ $K$ is, which changes with the element topology and order. [@Fig:test] shows the structure of two stiffness matrices for the same linear elastic problem discretised using exactly the same number of nodes but using linear and quadratic elements respectively. The matrices have the same size (because the number of nodes is the same) but the former is more sparse than the latter. Hence, it would be harder (in computational terms of CPU and RAM) to solve the second-order case.

::::: {#fig:test}
![42k first-order elements](test1.png){#fig:test1 width=48%}\
![15k second-order elements](test2.png){#fig:test2 width=48%}
![42k first-order elements.](test1.png){#fig:test1 width=48%}\
![15k second-order elements.](test2.png){#fig:test2 width=48%}

Structure of the stiffness matrices for the same FEM problem with 10k nodes. Red (blue) are positive (negative) elements
Structure of the stiffness matrices for the same FEM problem with 10k nodes. Red (blue) are positive (negative) elements.
:::::

In a similar way, different types of elements will give rise to different sparsity patterns which change the effort needed to solve the problem. In any case, the base parameter that controls the problem size and thus provides a basic indicator of the level of difficulty the problem poses is the number of nodes. Again, not the number of elements, as the solver does not even know if the matrix comes from FEM, FVM or FDM.
@@ -890,10 +890,10 @@ dnl We have already risen a warning flag about stresses at material interfaces i
Besides all the open questions about [computing stresses at nodes](https://www.seamplex.com/fino/cases/050-tet10/), this case also adds the fact that the material properties (say the Young’s Modulus\ $E$) are different in the elements that are at each side of the interface.

::::: {#fig:two-cubes}
![Mesh with shared surface](two-cubes2.png){#fig:two-cubes2 width=48%}\
![Stress on warped displacements](two-cubes4.png){#fig:two-cubes4 width=48%}
![Mesh with shared surface.](two-cubes2.png){#fig:two-cubes2 width=48%}\
![Stress on warped displacements.](two-cubes4.png){#fig:two-cubes4 width=48%}

Two cubes of different materials share a face and a pressure is applied at the right-most face
Two cubes of different materials share a face and a pressure is applied at the right-most face.
:::::


@@ -984,26 +984,26 @@ The boundary conditions are
Three radial SCLs---namely cyan, yellow and green---are located at a distance of one thickness of the main line from the external wall of the branch into the main direction\ $x$ ([@fig:tee-scls]). In\ [@fig:tee-MB] we can see the results of the parametric computation, namely the linearised membrane and bending stresses computed in each of the three SCLs as a function of\ $d_b$. Note that\ $d_b$ is a continuous variable and even unreal values (such as 9-inches) were used to perform the parametric run. The thickness of such cases was interpolated using actual schedule-80 geometrical data from ASME\ B36.310M.

::::: {#fig:tee-scls}
![$y$-$z$ projection](tee-scls1.png){#fig:tee-scls1 width=29%}\
![$x$-$z$ projection](tee-scls2.png){#fig:tee-scls2 width=67%}\
![$y$-$z$ projection.](tee-scls1.png){#fig:tee-scls1 width=29%}\
![$x$-$z$ projection.](tee-scls2.png){#fig:tee-scls2 width=67%}\

Location of the three radial SCLs: cyan, yellow and green
Location of the three radial SCLs: cyan, yellow and green.
:::::

::::: {#fig:tee-MB}
![Membrane stress](M.svg){#fig:M width=48%}\
![Bending stress](B.svg){#fig:B width=48%}
![Membrane stress.](M.svg){#fig:M width=48%}\
![Bending stress.](B.svg){#fig:B width=48%}

Parametric stresses as a function of the nominal diameter\ $d_b$ of the branch
Parametric stresses as a function of the nominal diameter\ $d_b$ of the branch.
:::::


::::: {#fig:tee-post}
![$d_b=2$\ in](tee-post-2.png){#fig:tee-post-2 width=30%}\
![$d_b=5$\ in](tee-post-5.png){#fig:tee-post-5 width=30%}\
![$d_b=10$\ in](tee-post-10.png){#fig:tee-post-10 width=30%}\
![$d_b=2$\ in.](tee-post-2.png){#fig:tee-post-2 width=30%}\
![$d_b=5$\ in.](tee-post-5.png){#fig:tee-post-5 width=30%}\
![$d_b=10$\ in.](tee-post-10.png){#fig:tee-post-10 width=30%}\

Von\ Mises stress and 400x warped displacements for three values of\ $d_b$
Von\ Mises stress and 400x warped displacements for three values of\ $d_b$.
:::::

[@Fig:tee-post] illustrates how the pipes deform when subject to the internal pressure. When the branch is small, the problem resembles the infinite-pipe problem where the main pipe expands radially outward and there is only traction. For large values of\ $d_b$, the pressure in the branch bends down the main pipe, generating a complex mixture of traction and compression. The tipping point seems to be around a branch diameter\ $d_b\approx 5$\ in.
@@ -1030,14 +1030,14 @@ So here we are again with the case study where we have to compute the linearised

We then proceed to “shake” the pipes. That is to say, we obtain a distributed load vector\ $\mathbf{f}(x,y,z)$ which is statically equivalent to the design earthquake.

Finally we attempt to “break” the pipes successively solving many steady-state (i.e. quasi-static) elastic problems for different times\ $t$ of each of the operational transients from [@fig:pt]. The principal stresses at the internal points of two SCLs for the four transients juxtaposed into a single time history are shown in [@fig:sigmas]. Some remarks about this step:
Finally we attempt to “break” the pipes successively solving many steady-state (i.e. quasi-static) elastic problems for different times\ $t$ of each of the operational transients from [@fig:pt]. The linearised membrane plus bending stresses at the internal points of two SCLs for the four transients juxtaposed into a single time history are shown in [@fig:MB-scl]. Some remarks about this step:

:::: {#fig:MB-scl}
![SCL #1](mb-scl1.svg){#fig:MB-scl-1}
![SCL #1.](mb-scl1.svg){#fig:MB-scl-1}

![SCL #4](mb-scl4.svg){#fig:MB-scl-2}
![SCL #4.](mb-scl4.svg){#fig:MB-scl-2}

Juxtaposition of the linearized MB principal stresses at two SCLs.
Juxtaposition of the linearised MB principal stresses at two SCLs.
::::

1. The material properties are temperature-dependent (we use data from [ASME\ II](https://en.wikipedia.org/wiki/ASME_Boiler_and_Pressure_Vessel_Code#ASME_BPVC_Section_II_-_Materials) part\ D).
@@ -1087,15 +1087,15 @@ To recapitulate, the steps discussed so far include
4. creating a mesh for the main domain refining locally around the material interfaces ([@fig:mech])
5. computing a heat conduction (“bake”) transient problem with temperatures as a function of time from the operational transients in a simple domain using temperature-dependent thermal conduction coefficients ([@fig:valve])
6. performing a modal analysis (“shake”) on the main domain to obtain the main oscillation frequencies and modes ([@fig:modes])
7. obtaining a distributed force statically-equivalent to the earthquake load
7. obtaining a distributed force which is statically equivalent to the earthquake load
8. solving a quasi-static linear elastic problem for different reading the temperature $T(\vec{x},t)$ computed in step\ 4 taking into account
a. the dependence of the Young’s Modulus\ $E$ and the thermal expansion coefficient\ $\alpha$ with temperature,
b. the thermal expansion effect itself
c. the instantaneous pressure exerted in the internal faces of the pipes at the time\ $t$ according to the definition of each operational transient
d. the restriction of the degrees of freedom of those faces, lines or points that correspond to mechanical supports located both within and at the ends of the CAD model
a. the dependence of the [Young’s Modulus](https://en.wikipedia.org/wiki/Young%27s_modulus)\ $E$ and the [thermal expansion coefficient](https://en.wikipedia.org/wiki/Thermal_expansion#Coefficient_of_thermal_expansion)\ $\alpha$ with temperature,
b. the mechanical effects of the thermal expansion of the two steels^[After reading the last sentence of [@sec:in-water] remember to come back to this page.]
c. the instantaneous pressure\ $p$ exerted in the internal faces of the pipes at the time\ $t$ according to the definition of each operational transient
d. the restriction of the degrees of freedom of those faces, lines or points that correspond to mechanical supports located both within and at the ends of the CAD model ([@fig:mech-msh])
e. the earthquake load, which according to ASME should be present only during four seconds of the transient: two seconds with one sign and the other two seconds with the opposite sign.
9. computing the linearised stresses (membrane and membrane plus bending) at the SCLs
10. juxtaposing these linearised stresses for each time of the transient and for each transient so as to obtain a single time-history of stresses including all the operational and/or incidental transients under study, which is what stress-based fatigue assessment needs (@fig:sigmas).
10. juxtaposing these linearised stresses for each time of the transient and for each transient so as to obtain a single time-history of stresses including all the operational and/or incidental transients under study, which is what stress-based fatigue assessment needs (@fig:MB-scl).

A pretty nice list of steps, which definitely I would not have been able to tackle when I was in college. Would you?

@@ -1108,11 +1108,12 @@ Another comment I would like to add is that I had to learn fatigue practically f

\medskip

Back and distantly, in\ [@sec:case] we said that people noticed there were some environmental factors that affected the fatigue resistance of materials. The basic ASME approach does not take care of these factors, and it is regarded as fatigue “in air.” We are interested in taking them into account, so we follow the US\ Nuclear Regulatory Commission guidelines to evaluate fatigue “in water” [@nrc].

Back and distantly, in\ [@sec:case] we said that people noticed there were some environmental factors that affected the fatigue resistance of materials, which is exactly what happens in our case study: the internal faces of the piping system are in contact with water. Even more, possibly heavy water. The basic ASME approach does not take care of these factors, and it is regarded as fatigue “in air.” We are interested in taking them into account, so we follow the US\ Nuclear Regulatory Commission guidelines to evaluate fatigue “in water” [@nrc].

### In air (ASME’s basic approach) {#sec:in-air}

We already said in\ [@sec:fatigue] that the stress-life fatigue assessment method gives the limit number\ $N$ of cycles that a certain mechanical part can withstand when subject to a certain periodic load of stress amplitude\ $S_\text{alt}$. If the actual number of cycles\ $n$ the load is applied is smaller than the limit\ $N$, then the part is fatigue-resistant. In our case study there is a mixture of several periodic loads, each one expected to occur a certain number of times. ASME’s way to evaluate the resistance is first to build a juxtaposed stress history from all transients under consideration and then to break it up into partial stress amplitudes\ $S_{\text{alt},j}$ between a “valley” and a “peak.” Each valley-peak pair\ $j$ is assigned an individual usage factor\ $U_j$ as
We already said in\ [@sec:fatigue] that the stress-life fatigue assessment method gives the limit number\ $N$ of cycles that a certain mechanical part can withstand when subject to a certain periodic load of stress amplitude\ $S_\text{alt}$. If the actual number of cycles\ $n$ the load is applied is smaller than the limit\ $N$, then the part is fatigue-resistant. In our case study there is a mixture of several periodic loads, each one expected to occur a certain number of times. ASME’s way to evaluate the resistance is first to build a juxtaposed stress history from all transients under consideration and then to break it up into partial stress amplitudes\ $S_{\text{alt},j}$ between a “valley” and a “peak.” Each valley-peak pair\ $j$ is assigned an individual usage factor\ $U_j$ defined as

$$U_j = \frac{n_j}{N_j}$$

@@ -1132,7 +1133,7 @@ When\ $\text{CUF} < 1$, the part under analysis can withstand the proposed cycli
This cryptic paragraph is a clear example of stuff that cannot be learned at college. No matter how good your university is, there is no way to cover all theories and methodologies which a mechanical engineer could need in his or her professional life.


Let us start by taking into account the juxtaposed stress histories from [@fig:MC-scl-1]. ASME NB-3216 requires to take the $\text{MB}_1-\text{MB}_3$ difference with respect to the initial stress so as to start with a zero value. This differential stress history $\Delta \text{MB}^{\prime}_{31}$, which is shown in [@fig:extrema-1] for the SCL\ #1 along with the temperature and pressure transients for reference, is used to evaluate fatigue resistance “in air” as follows.
Let us start by taking into account the juxtaposed stress histories from [@fig:MB-scl-1]. ASME\ NB-3216 requires to take the $\text{MB}_1-\text{MB}_3$ difference with respect to the initial stress so as to start with a zero value. This differential stress history $\Delta \text{MB}^{\prime}_{31}$, which is shown in [@fig:extrema-1] for the SCL\ #1 along with the temperature and pressure transients for reference, is used to evaluate fatigue resistance “in air” as follows.

divert(-1)
| $t$ | $\Delta \text{MB}^{\prime}_{31}$ | $\Delta[\sigma_3 - \sigma_1]$ | Transient | Cycles | Extrema |
@@ -1149,7 +1150,7 @@ divert(-1)
: Extrema of the juxtaposed stress history of [@fig:extrema-1] {#tbl:extrema}
divert(0)

![Juxtaposition of primed stresses used for fatigue assessment for SCL\ #1](extrema-1.svg){#fig:extrema-1}
![Juxtaposition of primed stresses used for fatigue assessment for SCL\ #1.](extrema-1.svg){#fig:extrema-1}

```{=latex}
\rowcolors{1}{black!0}{black!10}
@@ -1183,7 +1184,7 @@ c
\bottomrule
\end{tabular}
\end{center}
\caption{\label{tbl:extrema} Extrema of the juxtaposed stress history of [@fig:extrema-1]}
\caption{\label{tbl:extrema} Extrema of the juxtaposed stress history of fig.~\ref{fig:extrema-1}}
\end{table}
```

@@ -1194,27 +1195,27 @@ $$
S_{\text{alt},j} = \frac{1}{2} \cdot k_{\nu,j} \cdot k_{e,j} \cdot \left| \Delta MB^\prime_{t_{1,j}} - \Delta MB^\prime_{t_{2,j}} \right| \cdot \frac{E_\text{SN}}{E(T_{\text{max}_j})}
$$

\noindent where $k_\nu$ and $k_e$ are plastic correction factor for large loads (part VIII div 2 sec 5.5.3.2 and part III NB-3228.5), $E_\text{SN}$ is the Young’s Modulus used to create the $S$-$N$ curve (provided in the ASME fatigue curves) and\ $E(T_{\text{max}_j})$ is the material’s Young’s Modulus at the maximum temperature within the\ $j$-th interval.
\noindent where $k_\nu$ and $k_e$ are plastic correction factors for large loads (ASME\ part VIII div 2 sec 5.5.3.2 and part III NB-3228.5, respectively), $E_\text{SN}$ is the Young’s Modulus used to create the $S$-$N$ curve (provided in the ASME fatigue curves) and\ $E(T_{\text{max}_j})$ is the material’s Young’s Modulus at the maximum temperature within the\ $j$-th interval.


We are now in a position where we can comply with ASME’s obscure note about the number of cycles to assign a proper value of\ $n_j$. Starting with the largest pair 0--352, we see that both extrema belong to transient #1 which has 250 cycles. This one is easy, because we associate directly $n_1=250$ and both of these times “dissappear” as they already consumed all their cycles. The second largest pair was 352--3131 but 352 has just vanished so it is not considered anymore. The following is 0--6523 but zero also consumed all its cycles, so this pair is also discarded. The next is now 331--6523 where the first one belongs to transient #2 (200 cycles) and the latter to transient #4 (100 cycles). We assign $n_2=\min(200,100)=100$ and subtract 100 to both the cycles remaining to each time. Point 6523 dissapears as it consumed all its initial cycles and 3131 remains with 100 cycles. The next pair is 3131--3262, with number of cycles 100 (because we just took away 100 out of the initial 200) and 150 so $n_3=100$, point 3131 disappears and 3262 remains with 50 cycles. And so on, down to the last pair. [@Tbl:table-cuf] shows the results of applying this algorithm to all the extrema in SCL\ #1. The columns try to match the “official” solution of the US\ NRC [@nrc] to a sample problem proposed by the Electric Power Research Institute [@epri], which is shown in [@tbl:cuf-nrc].
We are now in a position where we can comply with ASME’s obscure note about the number of cycles to assign a proper value of\ $n_j$. Starting with the largest pair 0--352, we see that both extrema belong to transient #1 which has 250 cycles. This one is easy, because we associate directly $n_1=250$ and both of these times “dissappear” as they already consumed all of their cycles. The second largest pair was 352--3131 but 352 has just vanished so it is not considered anymore. The following is 0--6523 but zero also consumed all its cycles, so this pair is also discarded. The next is now 331--6523 where the first one belongs to transient #2 (200 cycles) and the latter to transient #4 (100 cycles). We assign $n_2=\min(200,100)=100$ and subtract 100 to both the cycles remaining to each time. Point 6523 dissapears as it consumed all its initial cycles and 3131 remains with 100 cycles. The next pair is 3131--3262, with number of cycles 100 (because we just took away 100 out of the initial 200) and 150 so $n_3=100$, point 3131 disappears and 3262 remains with 50 cycles. And so on, down to the last pair. [@Tbl:table-cuf] shows the results of applying this algorithm to all the extrema in SCL\ #1. The columns try to match the “official” solution of the US\ NRC [@nrc] to a sample problem proposed by the Electric Power Research Institute [@epri], which is shown in [@tbl:cuf-nrc].

dnl One table is taken from a document issued by almost-a-billion-dollar-year-budget government agency from the most powerful country in the world and the other one is from a third-world engineering startup. Guess which is which.

dnl ::::: {#tbl:cuf}
![Results “in-air” for the current case study in SCL\ #1](table-cuf.png){#tbl:table-cuf width=100%}
![Results “in-air” for the current case study in SCL\ #1.](table-cuf-1.png){#tbl:table-cuf width=100%}

![Results by reported [@nrc] to the sample problem proposed in [@epri]](cuf-nrc.png){#tbl:cuf-nrc width=100%}
![Results by report [@nrc] to a similar sample problem proposed in [@epri].](cuf-nrc.png){#tbl:cuf-nrc width=100%}

dnl Tables of individual usage factors
dnl :::::

Why all these details? Not because I want to teach you how to perform fatigue evaluations just reading this section without fully understanding the ASME code, taking college courses on material fatigue, reading books on the subject and even asking other colleagues. It is to show that even though these computation can be made “by hand” (i.e. using a calculator or, God forbids, a spreadsheet) when having to evaluate a few SCLs within several piping systems it is far (and I mean really far) better to automate all these steps by writing a set of scripts. Not only will the time needed to process the information be reduced, but also the introduction of human errors will be minimised and repeatability of results will be assured---especially if working under a [distributed version control](https://en.wikipedia.org/wiki/Distributed_version_control) system such as [Git](https://en.wikipedia.org/wiki/Git). This is true in general, so here is another tip: learn to write scripts to post-process your FEM results (you will need to use a script-friendly FEM program) and you will gain considerable margins regarding time and quality. See [@sec:online] to obtain the set of scripts that detected, matched and sorted the extrema and built [@fig:extrema-1] and [@tbl:extrema] automatically.
Why all these details? Not because I want to teach you how to perform fatigue evaluations just reading this section without fully understanding the ASME code, taking college courses on material fatigue, reading books on the subject and even asking other colleagues. It is to show that even though these computation can be made “by hand” (i.e. using a calculator or, God forbids, a spreadsheet) when having to evaluate a few SCLs within several piping systems it is far (and I mean really far) better to automate all these steps by writing a set of scripts. Not only will the time needed to process the information be reduced, but also the introduction of human errors will be minimised and repeatability of results will be assured---especially if working under a [distributed version control](https://en.wikipedia.org/wiki/Distributed_version_control) system such as [Git](https://en.wikipedia.org/wiki/Git). This is true in general, so here is another tip: learn how to write scripts to post-process your FEM results (you will need to use a script-friendly FEM program) and you will gain considerable margins regarding time and quality. See [@sec:online] to obtain the set of scripts that detected, matched and sorted the extrema and built [@fig:extrema-1] and [@tbl:extrema] automatically.


### In water (NRC’s extension) {#sec:in-water}

The fatigue curves and ASME’s (both\ III and\ VIII) methodology to analyse cyclic operations assume the parts under study are in contact with air, which is not the case of nuclear reactor pipes. Instead of building a brand new body of knowledge to replace ASME, the NRC decided to modify the former by adding environmentally-assisted fatigue multipliers to the traditional usage factors, formally defined as
The fatigue curves and ASME’s (both\ III and\ VIII) methodology to analyse cyclic operations assume the parts under study are in contact with air, which is not the case of nuclear reactor pipes. Instead of building a brand new body of knowledge to replace ASME, the US\ NRC decided to modify the former by adding environmentally-assisted fatigue multipliers to the traditional usage factors, formally defined as

$$F_\text{en} = \frac{N_\text{air}}{N_\text{water}} \geq 1$$

@@ -1234,19 +1235,30 @@ environment
3. apply the $F_\text{en}$ factors to the incremental usage calculated for each
transient pair ($U_j$), to determine the $\text{CUF}_\text{en}$, using\ [@eq:cufen]

Again, if $\text{CUF}_\text{en} < 1$, then the system under study can withstand the assumed cyclic loads. Note that as\ $F_{\text{en},j}>1$, it might be possible to have $\text{CUF} < 1$ and $\text{CUF}_\text{en} > 1$ at the same time.
The NRC has performed a comprehensive set of theoretical and experimental tests to study and analyse the nature and dependence of the non-dimensional correction factors\ $F_\text{en}$ [@nrc]. They found that, for a given material, they depend on:
Again, if $\text{CUF}_\text{en} < 1$, then the system under study can withstand the assumed cyclic loads. Note that since\ $F_{\text{en},j}>1$, it might be possible to have $\text{CUF} < 1$ and $\text{CUF}_\text{en} > 1$ at the same time.
The NRC has performed a comprehensive set of theoretical and experimental tests to study and analyse the nature and dependence of the non-dimensional correction factors\ $F_\text{en}$ [@nrc]. It was found that, for a given material, they depend on:

a. the concentration\ $O(t)$ of dissolved oxygen in the water,
b. the temperature\ $T(t)$ of the pipe,
c. the strain rate\ $\dot{\epsilon}(t)$, and
d. the content of sulphur\ $S(t)$ in the pipes (only for carbon or low-allow steels).

Apparently it makes no difference whether the environment is composed of either light or heavy water. There are somewhat different sets of non-dimensional analytical expressions that estimate the value of\ $F_{\text{en}}(t)$ as a function of\ $O(t)$, $T(t)$, $\dot{\epsilon}(t)$ and $S(t)$. Although they are not important now, the actual expressions should be defined and agreed with the plant owner and the regulator. The main result to take into account is that\ $F_{\text{en}}(t)=1$ if\ $\dot{\epsilon}(t)\leq0$, i.e. there are no environmental effects during the time intervals where the material is being compressed.
Apparently it makes no difference whether the environment is composed of either light or heavy water. There are somewhat different sets of non-dimensional analytical expressions that fit the value of\ $F_{\text{en}}(t)$ as a function of\ $O(t)$, $T(t)$, $\dot{\epsilon}(t)$ and $S(t)$ to experimental data. Although they are not important now, the actual expressions should be defined and agreed with the plant owner and the regulator. The main result to take into account is that\ $F_{\text{en}}(t)=1$ if\ $\dot{\epsilon}(t)\leq0$, i.e. there are no environmental effects during the time intervals where the material is being compressed.

Without further diving into another level of mathematical complexities and raising a plethora of detailed technical considerations, it is enough to directly show what the results of this EAF analysis for the imaginary test case in [@tbl:table-cufen]. Actually, SCL\ #1 was chosen throughout this section because the min/max extrema was simple and thus the explanation of the procedure was easier. It is SCL \#4 the one that has a larger cumulative usage factor. Indeed, [@tbl:fatigue-scl-4-air] shows that the stress history at this location is more complex than in SCL\# 1 as the heat conduction is stainless steel is smaller than in carbon steel and thus the temperature is less uniform during the transients as we already noted in [@fig:valve-temp]. However, stainless steel is less prone to degrade its fatigue strength in contact with water so the $F_\text{en}$ factors are smaller.

![Environmentally-assisted fatigue results for SCL\ #1.](table-cufen-1.png){#tbl:table-cufen width=45%}

Without further diving into another level of mathematical complexities and raising a plethora of detailed technical considerations, it is enough to directly show what the results of this EAF analysis for the imaginary test case in [@tbl:table-cufen]. Actually, SCL \#1 was chosen throughout this section because the min/max extrema was simple and thus the explanation of the procedure was easier. It is SCL \#4 the one that has a larger cumulative usage factor

![EAF results for the current case study in SCL\ #1](table-cufen.png){#tbl:table-cufen width=45%}
::::: {#fig:fatigue-scl-4}
![Results “in air.”](table-cuf-4.png){#tbl:fatigue-scl-4-air width=100%}

![Results “in water.”](table-cufen-4.png){#tbl:fatigue-scl-4-water width=45%}

Results of fatigue assessment in air and in water for SCL\ #4
:::::

We have travelled a non-negligible distance since we started this text. We wandered around a lot of issues, trying to solve a made-up but still pretty real-life-like engineering problem using finite elements as a our primary tool. We tried to understand how a nuclear reactor worked, analysed transient thermal situation, involved modal analysis and solved the elastic quasi-static problems taking into account a complex temperature distribution. Was our effort and the troubles we needed to go through really needed? To conclude this section (and almost the case) let me illustrate the importance of our path with the following sentence which is the one you should understand in case you have the chance to choose only one to remember. Had we used an infinite [thermal diffusivity](https://en.wikipedia.org/wiki/Thermal_diffusivity)\ $\kappa=\infty$ for the materials, effectively treating the temperature as uniform throughout the pipes and the valve and equal to the instantaneous temperature $T(t)$ given in the transient definition, the worst-case SCL would have been\ #1 instead of SCL\ #4 as we recently found for the actual study case. The cumulative usage factors in air and in water would have been be approximately\ $0.007$ and\ $0.008$ respectively. And if instead of using an infinite diffusivity we had used a zero [thermal expansion coefficient](https://en.wikipedia.org/wiki/Thermal_expansion#Coefficient_of_thermal_expansion)\ $\alpha=0$ such that only mechanical stresses were present (even with material properties depending on the actual transient temperatures) the usage factors would go down to\ $8\times 10^{-9}$ and $2\times 10^{-8}$. So yes, all the fuss was actually necessary.

divert(-1)
Once we have the instantaneous factor\ $F_{\text{en}}(t)$, we need to obtain an average value\ $F_{\text{en},j}$ which should be applied to the\ $j$-th load pair. Again, there are a few different ways of lumping the time-dependent\ $F_{\text{en}}(t)$ into a single $F_{\text{en},j}$ for each interval. Both NRC and EPRI give simple equations that depend on a particular time discretisation of the stress histories that, in my view, are all ill-defined. My guess is that they underestimated their audience and feared readers would not understand the slightly-more complex mathematics needed to correctly define the problem. The result is that they introduced a lot of ambiguities (and even technical errors) just not to offend the maths illiterate. A decision I do not share, and a another reason to keep on learning and practising math.
@@ -1254,9 +1266,9 @@ Once we have the instantaneous factor\ $F_{\text{en}}(t)$, we need to obtain an
When faced for the first time with the case study, I have come up with a weighting method that I claim is less ill-defined (it still is for border-line cases) and which the plant owner accepted as valid. [@Fig:cufen] shows the reference results of the problem (based on computing two correction factors and then taking the maximum) and the ones obtained with the proposed method (by computing a weighted integral between the valley and the peak). Note how in\ [@fig:cufen-nrc], pairs 694-447 and 699-447 have the same\ $F_\text{en}$ even though they are (marginally) different. The results from\ [@fig:cufen-seamplex] give two (marginally) different correction factors.

::::: {#fig:cufen}
![Results according to the author of NUREG/CR-6909 corresponding to the latest draft of the document](cufen-nrc.png){#fig:cufen-nrc width=75%}
![Results according to the author of NUREG/CR-6909 corresponding to the latest draft of the document.](cufen-nrc.png){#fig:cufen-nrc width=75%}

![Results reproduced by the author using his own weighting scheme](cufen-seamplex.png){#fig:cufen-seamplex width=75%}
![Results reproduced by the author using his own weighting scheme.](cufen-seamplex.png){#fig:cufen-seamplex width=75%}

Tables of individual environmental correction and usage factors for the NRC/EPRI “EAF Sample Problem 2-Rev.\ 2 (10/21/2011).” The reference method assigns the same\ $F_\text{en}$ to the first two rows whilst the proposed lumping scheme does show a difference
:::::
@@ -1265,47 +1277,50 @@ divert(0)

## Conclusions

Back in college, we all learned how to solve engineering problems. And once we graduated, we felt we could solve and fix the world (if you did not graduate yet, you will feel it shortly). But there is a real gap between the equations written in chalk on a blackboard (now probably in the form of beamer slide presentations) and actual real-life engineering problems. This chapter introduces a real case from the nuclear industry and starts by idealising the structure such that it has a known analytical solution that can be found in textbooks. Additional realism is added in stages allowing the engineer to develop an understanding of the more complex physics and a faith in the veracity of the finite-element results where theoretical solutions are not available. Even more, a brief insight into the world of evaluation of stress-life fatigue using such results further illustrates the complexities of real-life engineering analysis, even though the presented case was simplified for the sake of clearness. Here is a list of the tips that arose throughout the text:
Back in college, we all learned how to solve engineering problems. We already said that after we graduated, we felt we could solve and fix the world (once again, if you did not graduate yet, you will have this feeling shortly). But there is a real gap between the equations written in chalk on a blackboard (now probably in the form of beamer slide presentations) and actual real-life engineering problems. This chapter introduces a made-up yet almost-real case from the nuclear industry and starts by idealising the structure such that it has a known analytical solution that can be found in textbooks. Additional realism was added in stages allowing the reader to develop an understanding of the more complex physics in order to build a finite-element model so results can be obtained for cases where theoretical solutions are not available. Even more, a brief insight into the world of evaluation of stress-life fatigue using such results further illustrates the complexities of real-life engineering analysis---even though the presented case was simplified for the sake of clearness.

divert(-1)
Here is a list of the tips and homeworks that arose throughout the text:

* use and exercise your imagination
* practise math
* start with simple cases first
* grasp the dependence of results with independent variables
* remember there are other methods beside finite elements
* take into account that even within the finite element method, there is a wide variety of complexity in the problems that can be solved
* remember there are other methods beside finite elements!
dnl * take into account that even within the finite element method, there is a wide variety of complexity in the problems that can be solved
dnl * follow the “five whys rule” before compute anything, probably you do not need to
dnl * use engineering judgement and make sure understand Asimov’s [“wronger than wrong”](https://en.wikipedia.org/wiki/Wronger_than_wrong) concept
* play with your favourite FEM solver (mine is [CAEplex](https://caeplex.com)) solving simple cases, trying to predict the results and picturing the stress tensor and its eigenvectors in your imagination
* prove (with pencil and paper) that even though the principal stresses are not linear with respect to summation, they are linear with respect to multiplication
dnl * play with your favourite FEM solver (mine is [CAEplex](https://caeplex.com)) solving simple cases, trying to predict the results and picturing the stress tensor and its eigenvectors in your imagination
dnl * prove (with pencil and paper) that even though the principal stresses are not linear with respect to summation, they are linear with respect to multiplication
* grab any stress distribution from any of your FEM projects, compute the iso-stress curves and the draw normal lines to them to get acquainted with SCLs
* search online for “stress linearisation” (or “linearization” if you want) and then get a copy of ASME\ VIII Div\ 2 Annex 5-A
* take into account that FEM solutions lead only to nodal equilibrium but not point-wise equilibrium
dnl * take into account that FEM solutions lead only to nodal equilibrium but not point-wise equilibrium
dnl * measure the time needed to generate grids of different sizes and kinds with your favourite mesher
dnl * learn this by heart: the complexity of a FEM problem is given mainly by the number of _nodes_, not by the number of elements
* remember that welded materials with different thermal expansion coefficients may lead to fatigue under cyclic temperature changes
dnl * if you have time, try to get out of your comfort zone and do more than what others expect from you (like parametric computations)
* try to find an explanation of the results obtained, just like we did when we explained the parametric curves from\ [@fig:tee-MB ] with two opposing effects which were equal in magnitude around $d_b=5$\ inches
* think thermal-mechanical plus earthquakes cases as “bake, break and shake” problems
* understand why the elastic problem of the case study is still linear after all
* keep in mind that finite-elements are a means to get an engineering solution, not an end by themselves
* learn to write scripts to post-process FEM results (from an script-friendly open-source FEM program)
* work under a [distributed version control](https://en.wikipedia.org/wiki/Distributed_version_control) system such as [Git](https://en.wikipedia.org/wiki/Git), even when just editing input files or writing reports
* do not write ambiguous reports by replacing appropriate mathematical formulae with words just not to offend the illiterate
* try to avoid [proprietary](https://en.wikipedia.org/wiki/Proprietary_software) programs and favour [free and open source](https://en.wikipedia.org/wiki/Free_and_open-source_software) ones.
dnl * work under a [distributed version control](https://en.wikipedia.org/wiki/Distributed_version_control) system such as [Git](https://en.wikipedia.org/wiki/Git), even when just editing input files or writing reports
dnl * do not write ambiguous reports by replacing appropriate mathematical formulae with words just not to offend the illiterate
dnl * try to avoid [proprietary](https://en.wikipedia.org/wiki/Proprietary_software) programs and favour [free and open source](https://en.wikipedia.org/wiki/Free_and_open-source_software) ones.
* try to find an explanation of the results obtained, just like we did when we explained why SCL\ #4 has a larger cumulative factor than SCL\ #1.

dnl You can ask for help in our mailing list at <wasora@seamplex.com>. There is a community of engineers willing to help you in case you get in trouble with the repositories, the script or the input files.

divert(-1)
About your favourite FEM program, ask yourself these two questions:

1. Does your favourite FEM program’s manual say what the program does?
2. Do you believe your favourite FEM program’s manual?
3. Do you trust your favourite FEM program?

divert(0)

And finally, make sure that at the end of the journey from college theory to an actual engineering problem your conscience is clear knowing that there exists a report with your signature on it. That is why we all went to college in the first place.
I have been pouring some hints throughout the text which I learned the hard way. But here comes the last and most important one: at the end of the journey from college theory to solving an actual engineering problem, there will be at least one report with your signature on it. Make sure you understand what the implications of that signature is. That is why we all went to college in the first place.

divert(0)

### Online stuff {#sec:online}

@@ -1313,9 +1328,9 @@ Here is a list of sub-problems and stuff to play with.

* The pendulum-swing video from [@sec:intro]
- <https://youtu.be/Q-lKK4A2OzA>
* “On convergence of linearized stresses in an infinite pipe computed using the finite element method” from [@sec:infinite-pipe;@sec:infinite-pipe]
- <https://www.seamplex.com/fino/doc/pipe-linearized/>
divert(-1)
* “On convergence of linearised stresses in an infinite pipe computed using the finite element method” from [@sec:infinite-pipe;@sec:infinite-pipe]
- <https://www.seamplex.com/fino/doc/pipe-linearized/>
* The three cubes from [@sec:linearity]
- case A: pure normal loads (<https://caeplex.com/p/d8fe>)
- case B: pure shear loads (<https://caeplex.com/p/b494>)
@@ -1327,19 +1342,14 @@ divert(-1)
divert(0)
* The videos of the thermal transients in\ [@fig:valve]
- <https://www.seamplex.com/docs/nafems4/temp-1.mpg>
- <https://www.seamplex.com/docs/nafems4/temp-1.mpg>
- <https://www.seamplex.com/docs/nafems4/temp-1.mpg>
* The animations of natural oscillations in [@fig:modes]
- <https://www.seamplex.com/docs/nafems4/mode1.webm>
- <https://www.seamplex.com/docs/nafems4/mode2.webm>
- ...
* A ready-to-play-with CAEplex case with the modal problem
- <https://caeplex.com/project/results.php?id=42180c3>

See <https://www.seamplex.com/nafems> for new material, updated links and the full version of this case with many more details about the case and the associated mathematics.


dnl # Concluding Remarks

# References
## References

+ 31
- 2
references.bib Ver fichero

@@ -189,5 +189,34 @@
language = "english",
}

# https://www.epri.com/research/products/1025823
#
@MISC{nick,
author = "Nick Stevens",
title = "Practical Tips for Dealing with Stress Singularities",
month = "June",
year = "2019",
url = "https://nickjstevens.com/Practical-Tips-for-Dealing-with-Stress-Singularities-9b70ee1c71564fdfa49e403ae5a09622",
langid = "english",
language = "english",
}

@MISC{lukasz,
author = "Łukasz Skotny",
title = "2D vs 3D Finite Element Analysis (with examples)",
month = "March",
year = "2020",
url = "https://enterfea.com/2d-vs-3d-finite-element-analysis/",
langid = "english",
language = "english",
}

@book{nbr03,
author = "Angus Ramsay",
title = "The {NAFEMS} Benchmark Challenge",
year = "2017",
publisher = "{NAFEMS}",
isbn = "9781910643419",
url = "https://www.ramsay-maunder.co.uk/downloads/NBR03.pdf",
langid = "english",
language = "english",
}


BIN
table-cuf-1.png Ver fichero

Antes Después
Anchura: 2092  |  Altura: 470  |  Tamaño: 35KB

BIN
table-cuf-2.png Ver fichero

Antes Después
Anchura: 2092  |  Altura: 527  |  Tamaño: 39KB

BIN
table-cuf-3.png Ver fichero

Antes Después
Anchura: 2092  |  Altura: 583  |  Tamaño: 43KB

BIN
table-cuf-4.png Ver fichero

Antes Después
Anchura: 2112  |  Altura: 978  |  Tamaño: 76KB

BIN
table-cuf.png Ver fichero

Antes Después
Anchura: 4174  |  Altura: 941  |  Tamaño: 78KB Anchura: 2088  |  Altura: 470  |  Tamaño: 35KB

BIN
table-cufen-1.png Ver fichero

Antes Después
Anchura: 964  |  Altura: 469  |  Tamaño: 22KB

BIN
table-cufen-2.png Ver fichero

Antes Después
Anchura: 964  |  Altura: 525  |  Tamaño: 24KB

BIN
table-cufen-3.png Ver fichero

Antes Después
Anchura: 964  |  Altura: 582  |  Tamaño: 26KB

BIN
table-cufen-4.png Ver fichero

Antes Después
Anchura: 998  |  Altura: 977  |  Tamaño: 45KB

Cargando…
Cancelar
Guardar