NLMech  0.1.0
rnpBond.h
1 // Copyright (c) 2019 Prashant K. Jha
3 // Copyright (c) 2019 Patrick Diehl
4 //
5 // Distributed under the Boost Software License, Version 1.0. (See accompanying
6 // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
8 
9 #ifndef MATERIAL_PD_BONDMATERIAL_NEW_H
10 #define MATERIAL_PD_BONDMATERIAL_NEW_H
11 
12 #include "baseMaterial.h"
13 #include "util/point.h"
14 #include "util/matrixBlaze.h"
15 #include "geometry/neighbor.h"
16 #include "fe/mesh.h"
17 
18 #include <vector>
19 
20 #include <hpx/include/parallel_algorithm.hpp>
21 
22 // forward declaration
23 namespace inp {
24 struct MaterialDeck;
25 struct OutputDeck;
26 }
27 
28 // forward declaration
29 namespace data {
30 class DataManager;
31 }
32 
33 // forward declaration of class
34 namespace fe {
35 class Mesh;
36 } // namespace fe
37 
38 namespace material {
39 namespace pd {
40 class BaseInfluenceFn;
41 } // namespace pd
42 } // namespace material
43 
44 namespace material {
45 
46 namespace pd {
47 
85 class RNPBond : public BaseMaterial {
86 
87 public:
93  RNPBond(inp::MaterialDeck *deck,data::DataManager* dataManager);
94 
101  std::pair<util::Point3, double> getBondEF(size_t i, size_t j);
102 
109  double getS(const util::Point3 &dx, const util::Point3 &du);
110 
117  double getS(size_t i, size_t j);
118 
124  double getSc(const double &r);
125 
133  double getSc(size_t i , size_t j);
134 
142  const util::Point3 &du) const;
143 
150  double getInfFn(const double &r) const ;
151 
152 private:
185  void computeParameters(inp::MaterialDeck *deck, const double &M);
186 
199  void computeMaterialProperties(inp::MaterialDeck *deck, const double &M);
200 
207  double d_C;
208 
210  double d_beta;
211 
215  double d_rbar;
216 
218  double d_invFactor;
219 
226  double d_factorSc;
227 
230 
232  double d_contact_Kn = 0.;
233 
235  double d_contact_Rc = 0.;
236 
239 
242 
245 };
246 
247 } // namespace pd
248 
249 } // namespace material
250 
251 #endif // MATERIAL_PD_BONDMATERIAL_NEW_H
Data manager to collect the global simulation data.
Definition: DataManager.h:58
A base class for computing influence function.
Definition: influenceFn.h:22
A base class providing methods to compute energy density and force.
Definition: baseMaterial.h:26
A Class implementing regularized nonlinear peridynamic model.
Definition: rnpBond.h:85
double getS(const util::Point3 &dx, const util::Point3 &du)
Returns the bond strain.
Definition: rnpBond.cpp:303
data::DataManager * d_dataManager_p
Store pointer to datamanager.
Definition: rnpBond.h:241
util::Point3 getBondForceDirection(const util::Point3 &dx, const util::Point3 &du) const
Get direction of bond force.
Definition: rnpBond.cpp:330
double d_beta
Parameter .
Definition: rnpBond.h:210
std::pair< util::Point3, double > getBondEF(size_t i, size_t j)
Returns energy and force state between node i and node j.
Definition: rnpBond.cpp:216
bool d_irrevBondBreak
Flag which indicates if the breaking of bond is irreversible.
Definition: rnpBond.h:229
double d_factorSc
Factor to multiply to critical strain to check if bond is fractured.
Definition: rnpBond.h:226
void computeMaterialProperties(inp::MaterialDeck *deck, const double &M)
Computes elastic and fracture properties from the rnp material parameters.
Definition: rnpBond.cpp:191
const inp::MaterialDeck * d_deck
Pointer to the material deck.
Definition: rnpBond.h:238
double d_C
Parameter C.
Definition: rnpBond.h:207
double d_contact_Rc
Contact radius for normal contact force between broken bonds.
Definition: rnpBond.h:235
double getSc(const double &r)
Returns critical bond strain.
Definition: rnpBond.cpp:319
double getInfFn(const double &r) const
Returns the value of influence function.
Definition: rnpBond.cpp:335
material::pd::BaseInfluenceFn * d_baseInfluenceFn_p
Base object for influence function.
Definition: rnpBond.h:244
double d_rbar
Inflection point of nonlinear function = .
Definition: rnpBond.h:215
RNPBond(inp::MaterialDeck *deck, data::DataManager *dataManager)
Constructor.
Definition: rnpBond.cpp:23
double d_contact_Kn
Kn coefficient for normal contact force between broken bonds.
Definition: rnpBond.h:232
double d_invFactor
Inverse of factor = .
Definition: rnpBond.h:218
void computeParameters(inp::MaterialDeck *deck, const double &M)
Computes rnp material parameters from elastic constants.
Definition: rnpBond.cpp:99
Data mamanger to share the global simulation data between the classes.
Definition: DataManager.h:55
Collection of methods and data related to finite element and mesh.
Definition: baseElem.h:15
Collection of methods and database related to input.
Definition: main.cpp:21
Structure to read and store material related data.
Definition: materialDeck.h:226
A structure to represent 3d vectors.
Definition: point.h:29