Skip to content

A phase field brittle fracture code coupled to a dummy place-holder FEniCS script providing material parameters

License

Notifications You must be signed in to change notification settings

uekerman/Coupled-Brittle-Fracture

Repository files navigation

Coupled Phase-Field Brittle Fracture Simulation

A phase-field brittle fracture mechanics code written in Nutils is coupled to a Poisson equation in FEniCS or DOLFIN. The FEniCS code is a place-holder for a proper corrosion model. The coupling is realized with preCICE. The purpose of this code is to showcase how preCICE could be used to volume-couple between an electro-chemistry model (here the FEniCS code) and a fracture mechanics model. Currently, meaningless data is exchanged.

The original fracture mechanics code was developed by Clemens Verhoosel. The model is documented in this publication:

Singh, N., Verhoosel, C.V., De Borst, R. and Van Brummelen, E.H., 2016. A fracture-controlled path-following technique for phase-field modeling of brittle fracture. Finite Elements in Analysis and Design, 113, pp.14-29.

The coupling prototype was developed by Benjamin Uekermann. Contact Benjamin for questions about this code. Furthermore, the following support channels might be helpful: Nutils matrix chat room, preCICE forum.

Dependencies

Docker

Instead of installing all dependencies on your system you can run the simulation in a docker container.

$ docker build -t brittle-fracture:1.0 -f brittle-fracture.dockerfile .
$ docker run -it --name bf brittle-fracture:1.0

Building the docker image will take some time.

Then, just clone this repository again within the container.

git clone https://github.com/uekerman/Coupled-Brittle-Fracture.git

and continue below.

Folder structure

  • Allclean: a bash script to clean the case (incl. build artifacts)
  • corrosion.py: the dummy corrosion model, implemented with FEniCS, using the FEniCS-preCICE adapter for coupling
  • precice-adapter-config.json: the FEniCS-preCICE adapter configuration file
  • corrosion.cpp: a similar dummy corrosion model, implemented with DOLFIN, directly using preCICE for coupling
  • Poisson.ufl: the corresponding DOLFIN unified form language file
  • CMakeLists: cmake specification to build the DOLFIN code
  • dummy.py: an alternative dummy code, which can also provide material parameters
  • fracture.py: the fracture mechanics, implemented with Nutils
  • precice-config.xml: the preCICE configuration file, describing the coupled setup
  • README.md

Building

The DOLFIN code is the only one that needs building

ffc -l dolfin Poisson.ufl
cmake .
make

Be sure to use the same ffc version as used for the linked libdolfin.

How to run

Open two terminals and start one program in each directly from the root directory:

  • Either python3 corrosion.py (the FEniCS variant) or ./demo_corrosion (the DOLFIN variant)
  • python3 fracture.py

If you only have one terminal (e.g. in an interactive docker container):

./demo_corrosion & python3 fracture.py

Visualization

Both codes write vtk data, which can be visualized for example with Paraview.

On the characteristic length scale l0

l0 acts as a numerical regularization parameter for the phase field model. It controls the width of the smooth approximation of the crack. In the limit case of l0 going to zero, the phase-field approximation converges to the discrete fracture surface. The parameter could, however, also be regarded as a model parameter: the critical stress for which crack nucleation occurs depends on it. For smaller l0, the critical stress increases. For the limit case, fracture nucleation is impossible in the absence of stress singularities. For too large values of l0, on the other hand, the complete damage field is already above the critical damage value. Whatever happens then could be regarded as unphysical model artifacts. In particular, fractures cannot be localized properly. Given the total load, the Lamé parameters, and the fracture toughness, l0 needs to be tuned such that the initial virgin damage field is below the critical damage value (approximately 0.25, better below 0.1). Additionally, l0 still needs to be larger than the local mesh size.

Please see section 2 (in particular section 2.3.1) of: Borden, M.J., Verhoosel, C.V., Scott, M.A., Hughes, T.J. and Landis, C.M., 2012. A phase-field description of dynamic brittle fracture. Computer Methods in Applied Mechanics and Engineering, 217, pp.77-95. PDF

About

A phase field brittle fracture code coupled to a dummy place-holder FEniCS script providing material parameters

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published