PeriDyno 1.0.0
Loading...
Searching...
No Matches
LinearElasticitySolver.h
Go to the documentation of this file.
1
16#pragma once
18
19#include "Peridynamics/Bond.h"
20
21namespace dyno {
22
27 template<typename TDataType>
29 {
31
32 public:
33 typedef typename TDataType::Real Real;
34 typedef typename TDataType::Coord Coord;
35 typedef typename TDataType::Matrix Matrix;
36 typedef typename ::dyno::TBond<TDataType> Bond;
37
40
41 protected:
42 void constrain() override;
43
44 virtual void solveElasticity();
45
46 void preprocess() override;
47
52 virtual void enforceElasticity();
54
57
58 public:
63 DEF_VAR_IN(Real, Horizon, "");
64
65 DEF_VAR_IN(Real, TimeStep, "");
66
70 DEF_ARRAY_IN(Coord, X, DeviceType::GPU, "Rest Pos");
71
75 DEF_ARRAY_IN(Coord, Y, DeviceType::GPU, "Particle position");
76
80 DEF_ARRAY_IN(Coord, Velocity, DeviceType::GPU, "Particle velocity");
81
82
86 DEF_ARRAYLIST_IN(Bond, Bonds, DeviceType::GPU, "Peridynamic bonds");
87
88 public:
93 DEF_VAR(Real, Mu, 0.001, "Lame parameters: mu");
94
95 DEF_VAR(Real, Lambda, 0.01, "Lame parameters: lambda");
96
97 DEF_VAR(uint, IterationNumber, 30, "Iteration number");
98
99 protected:
102
105
108 };
109}
#define DECLARE_TCLASS(name, T1)
Definition Object.h:87
DEF_ARRAYLIST_IN(Bond, Bonds, DeviceType::GPU, "Peridynamic bonds")
Neighboring bonds.
virtual void enforceElasticity()
Correct the particle position with one iteration Be sure computeInverseK() is called as long as the r...
virtual void computeMaterialStiffness()
DEF_VAR(Real, Mu, 0.001, "Lame parameters: mu")
Lame parameters m_lambda controls the isotropic part while mu controls the deviatoric part.
DEF_VAR_IN(Real, TimeStep, "")
DEF_ARRAY_IN(Coord, X, DeviceType::GPU, "Rest Pos")
Reference position.
DEF_ARRAY_IN(Coord, Velocity, DeviceType::GPU, "Particle velocity")
Particle velocity.
virtual void solveElasticity()
::dyno::TBond< TDataType > Bond
DEF_ARRAY_IN(Coord, Y, DeviceType::GPU, "Particle position")
Deformed position.
DEF_VAR(Real, Lambda, 0.01, "Lame parameters: lambda")
DEF_VAR(uint, IterationNumber, 30, "Iteration number")
DEF_VAR_IN(Real, Horizon, "")
Horizon A positive number represents the radius of neighborhood for each point.
This is an implementation of AdditiveCCD based on peridyno.
Definition Array.h:25
Array< T, DeviceType::GPU > DArray
Definition Array.inl:89
unsigned int uint
Definition VkProgram.h:14