https://mooseframework.inl.gov
PeridynamicsKernelBase.h
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
10 #pragma once
11 
12 #include "Kernel.h"
13 #include "Assembly.h"
14 #include "SystemBase.h"
15 #include "PeridynamicsMesh.h"
16 
21 {
22 public:
24 
26 
27  virtual void computeResidual() override;
28  virtual void computeJacobian() override;
29  virtual Real computeQpResidual() override { return 0.0; }
30 
31 protected:
35  virtual void computeLocalResidual() = 0;
36 
40  virtual void computeNonlocalResidual(){};
41 
45  virtual void computeLocalJacobian(){};
46 
50  virtual void prepare();
51 
54 
56  const bool _use_full_jacobian;
57 
60  const unsigned int _dim;
61  const unsigned int _nnodes;
62  std::vector<Real> _node_vol;
63  std::vector<Real> _dg_vol_frac;
64  std::vector<Real> _horizon_radius;
65  std::vector<Real> _horizon_vol;
67 
70 
73 };
Base kernel class for peridynamic models.
virtual Real computeQpResidual() override
std::vector< Real > _node_vol
Real _bond_status
Bond status of current bond/edge2.
Peridynamics mesh class.
virtual void computeNonlocalResidual()
Function to compute nonlocal contribution to the residual at the current nodes.
std::vector< Real > _horizon_radius
std::vector< Real > _dg_vol_frac
virtual void computeLocalJacobian()
Function to compute local contribution to the diagonal Jacobian at the current nodes.
PeridynamicsKernelBase(const InputParameters &parameters)
static InputParameters validParams()
const bool _use_full_jacobian
Option to use full jacobian including nonlocal constribution or not.
virtual void computeLocalResidual()=0
Function to compute local contribution to the residual at the current nodes.
virtual void prepare()
Function to precalculate data which will be used in the derived classes.
virtual void computeJacobian() override
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
std::vector< Real > _horizon_vol
RealGradient _origin_vec
Vector for current bond under undefored configuration.
const InputParameters & parameters() const
MooseVariable * _bond_status_var
Bond_status variable.
virtual void computeResidual() override
PeridynamicsMesh & _pdmesh
Parameters for peridynamic mesh information.