mast-multiphysics
mast-multiphysics copied to clipboard
Templated Compute Kernel Foundation
The purpose of the code in this PR is to provide a foundation to enable the following features in MAST:
- Automatic differentiation evaluation of sensitivity and Jacobian quantities
- Complex-step evaluation of sensitivity and Jacobian quantities
- Shape sensitivity analysis
- Plug-and-play functionality to add/remove new physics/terms in finite-element variational form
- Quadrature/material point evaluations of nonlinear material models, which will be implemented as the compute-kernel derived classes.
- Minimize the reinitialization of FE and Quadrature objects for computation of element residual/matrix quantities.
- Maximize reuse of computed quantities and minimize movement of data in memory.
- Future support for GPGPUs though Kokkos. This requires the adoption of concepts of memory-views and definition of functions that serve as kernels that can execute in parallel on multiple CPU/GPU cores. (The modifications in this PR do not support this, but support for this will be added in future).
This requires the definition of a templated compute kernel, currently implemented in the compute_kernel.h file. A number of additional classes have been defined here, which will be moved to independent files in forthcoming commits. Currently, only a skeleton implementation is included to hash out the API for various classes/functionality.
A skeleton implementation is included for strain energy kernel for elasticity computations and a code to set this up. These classes are instantiated for different combinations of variable types in example 6.