Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Solver] extended MPM #34

Draft
wants to merge 174 commits into
base: master
Choose a base branch
from
Draft
Changes from 2 commits
Commits
Show all changes
174 commits
Select commit Hold shift + click to select a range
90c00e1
:tada::sparkles:creat xmpm solver and ParticleXMPM class
yliang-sn Aug 1, 2020
06f4331
:construction: creat and initialise nodal properties for discontinuity
yliang-sn Aug 2, 2020
28c684f
:construction:update nodal properties function and update nodal enric…
yliang-sn Aug 2, 2020
8ba5a31
:construction:update:external force,internal force, compute strain rate
yliang-sn Aug 2, 2020
e5a61ed
:construction:apply velocity constraints discontinuity
yliang-sn Aug 2, 2020
07bd480
:construction:compute updated position
yliang-sn Aug 2, 2020
2beb5ac
:hammer:
yliang-sn Aug 3, 2020
2ddda95
:hammer::construction:self contact for XMPM and boundary condation
yliang-sn Aug 5, 2020
e4a1265
:hammer:move the node_xmpm function to a separate file
yliang-sn Aug 5, 2020
e185bb4
:bug:miss some functions for node_xmpm.tcc
yliang-sn Aug 5, 2020
c399266
:hammer:add const
yliang-sn Aug 5, 2020
cf3a06b
:construction:clang format
yliang-sn Aug 6, 2020
32b51bb
:constructor:discontinuity function
Aug 15, 2020
67ae1db
:hammer::construction:clean xmpmparticle class
Aug 16, 2020
6f9da8b
:hammer:change discontinuouty_point_line name
Aug 16, 2020
030993a
:hammer:separate the discontinuity functions into different files
Aug 16, 2020
f4792f4
:pencil::hammer::construction:clean up particleXMPM class
Aug 17, 2020
701cdd9
:pencil::hammer::construction:clean the discontinuity base class
Aug 17, 2020
7c58d82
:pencil:clean discontinuity3d class
Aug 17, 2020
c3ad208
:constructuin:assign friction coefficient for nodes
Aug 17, 2020
ce0c7b3
Update include/mesh.h
yliang-sn Aug 25, 2020
2d95f12
:tada::sparkles:creat xmpm solver and ParticleXMPM class
yliang-sn Aug 1, 2020
41a05a1
:construction: creat and initialise nodal properties for discontinuity
yliang-sn Aug 2, 2020
54e7b4d
:construction:update nodal properties function and update nodal enric…
yliang-sn Aug 2, 2020
332e940
:construction:update:external force,internal force, compute strain rate
yliang-sn Aug 2, 2020
c24c3f4
:construction:apply velocity constraints discontinuity
yliang-sn Aug 2, 2020
faec00b
:construction:compute updated position
yliang-sn Aug 2, 2020
d94e611
:hammer:
yliang-sn Aug 3, 2020
4a8deb6
:hammer::construction:self contact for XMPM and boundary condation
yliang-sn Aug 5, 2020
ab32ab3
:hammer:move the node_xmpm function to a separate file
yliang-sn Aug 5, 2020
d7a5c85
:bug:miss some functions for node_xmpm.tcc
yliang-sn Aug 5, 2020
3b9b316
:hammer:add const
yliang-sn Aug 5, 2020
fee31b7
:construction:clang format
yliang-sn Aug 6, 2020
835db0a
:constructor:discontinuity function
Aug 15, 2020
201f6cf
:hammer::construction:clean xmpmparticle class
Aug 16, 2020
c1850df
:hammer:change discontinuouty_point_line name
Aug 16, 2020
6494559
:hammer:separate the discontinuity functions into different files
Aug 16, 2020
8152840
:pencil::hammer::construction:clean up particleXMPM class
Aug 17, 2020
71179ea
:pencil::hammer::construction:clean the discontinuity base class
Aug 17, 2020
435dccd
:pencil:clean discontinuity3d class
Aug 17, 2020
a62c285
:constructuin:assign friction coefficient for nodes
Aug 17, 2020
684f192
Update include/mesh.h
yliang-sn Aug 25, 2020
f1f6af3
:pencil::construction:delete the compute_strain function in XMPM
Aug 28, 2020
7869f64
:hammer:modify the solver scheme
Aug 31, 2020
91ff382
:hammer:use assert instead of if
Aug 31, 2020
84158b6
:hammer:update some comments and fix some code
Sep 1, 2020
f8cb643
:hammer:
Sep 1, 2020
0c86c24
:construction:xmpm solver test functions for 3d
Sep 7, 2020
2734df6
:construction:particle_xmpm test functions
Sep 7, 2020
85a8d68
:construction:check discontinuity in mesh
Sep 7, 2020
66332b0
add width of the discontinuity
Oct 1, 2020
48755b6
:construction:assign the levelset width and coefficient
Oct 4, 2020
ff7ff15
:construction:node_xmpm test functions
Oct 4, 2020
3be07a8
:hammer:modify node default enriched type
Oct 4, 2020
c2d9142
:hammer:modify the level set computation
Oct 4, 2020
44afbe0
:construction:output level set values
Oct 4, 2020
0af8791
:hammer:fix the issue about friction coefficient
Oct 5, 2020
8decf2b
:construction:compute the principal stress and strain
Oct 5, 2020
77b115f
Merge remote-tracking branch 'origin/refactor/resume' into solver/xmpm
Oct 5, 2020
2d64ccd
:hammer:velocity update by the enriched nodes
Oct 6, 2020
2372c0a
Merge remote-tracking branch 'origin/refactor/resume' into solver/xmpm
Oct 6, 2020
026ca2a
xmpm solver
yliang-sn Sep 8, 2021
c4140ea
xmpm solver
yliang-sn Sep 8, 2021
edf16fc
merge develop
yliang-sn Sep 8, 2021
512a160
clean oso part
yliang-sn Oct 7, 2021
8ce7850
clean oso hardcode
yliang-sn Oct 7, 2021
a71f048
clean hard code
yliang-sn Oct 8, 2021
3f8f0b0
Update cell.h
yliang-sn Oct 8, 2021
8316654
apply the clang format
yliang-sn Oct 8, 2021
8b5f813
make a separate file mesh_xmpm
yliang-sn Oct 18, 2021
b9d6385
find the cells at nodes
yliang-sn Oct 20, 2021
26291c8
make a separate file cell_xmpm.tcc
yliang-sn Oct 20, 2021
9aa5404
tidy the mark points generation
yliang-sn Oct 20, 2021
91fe5d5
merge master into xmpm
yliang-sn Oct 21, 2021
0ba0c01
solve the conflicts about hdf5
yliang-sn Oct 21, 2021
2462fe8
tidy the code and comments
yliang-sn Nov 3, 2021
138dd64
merge master into solver/xmpm
yliang-sn Nov 3, 2021
98d5aa3
add P3DXMPM particle type
yliang-sn Nov 4, 2021
128ea5c
clang formating
bodhinandach Nov 4, 2021
50138ee
clean the unsed variables
yliang-sn Nov 5, 2021
4f7965d
Merge branch 'xmpm_crackbranch' into solver/xmpm
yliang-sn Nov 5, 2021
b178b13
clean the unsed variables
yliang-sn Nov 5, 2021
f27b51c
clean the unsed variables
yliang-sn Nov 5, 2021
5aa3fbd
fix particle cc
bodhinandach Nov 5, 2021
730b803
Merge branch 'solver/xmpm' of https://github.com/geomechanics/mpm int…
yliang-sn Nov 5, 2021
652dec6
remove hardcode in mohr_coulomb.tcc
yliang-sn Nov 5, 2021
7daa8d8
remove typo
yliang-sn Nov 5, 2021
170658c
update write_mesh_particles.cc
yliang-sn Nov 5, 2021
99179d8
update write_mesh_particles.cc
yliang-sn Nov 5, 2021
302708d
resolve bugs in test part
yliang-sn Nov 5, 2021
708682d
define XMPM group for XMPM functions and variables
yliang-sn Nov 6, 2021
93497aa
add comment "\ingroup XMPM" and initialise_xmpm function
yliang-sn Nov 6, 2021
76fbda1
delete discontinuity_enrich_ initialization in the node.tcc
yliang-sn Nov 7, 2021
1bb55d5
defgroup xmpm
yliang-sn Nov 7, 2021
3b72509
tidy the code
yliang-sn Nov 7, 2021
288371e
add the pod_particle_xmpm class
yliang-sn Nov 7, 2021
66da947
Merge branch 'master' of https://github.com/geomechanics/mpm into sol…
yliang-sn Nov 15, 2021
533f5f8
clang format
bodhinandach Nov 16, 2021
70112b5
xmpm modification after discussions
bodhinandach Nov 17, 2021
ecb6523
Merge branch 'master' into solver/xmpm
yliang-sn Nov 18, 2021
7f2a4c5
fix mpi bug
yliang-sn Nov 19, 2021
72cda05
add build* in the gitignore file
yliang-sn Nov 19, 2021
cf74a4c
build class NodeXMPM
yliang-sn Nov 24, 2021
e94af7c
fix momentum computation bug
yliang-sn Dec 2, 2021
2f3c90c
refactor the input
yliang-sn Dec 7, 2021
5861c38
construction of the XMPM framework
yliang-sn Feb 10, 2022
5fbd843
Merge branch 'master' into xmpm-branch
yliang-sn Feb 10, 2022
d1a1fa8
contact detection criterion 2
yliang-sn Feb 11, 2022
0c39cd6
determine the cell type for each discontinuity with the node level se…
yliang-sn Feb 12, 2022
a6047c9
swithch to use function compute_elastic_tensor and compute_elasto_pla…
yliang-sn Feb 12, 2022
55372a3
remove debug code
yliang-sn Feb 13, 2022
f8a50b6
move unsed variables and functions
yliang-sn Feb 13, 2022
fa144ed
update nodal level set values
yliang-sn Feb 20, 2022
9b2488f
construction
yliang-sn Feb 20, 2022
65c4ae6
construction
yliang-sn Feb 20, 2022
f656347
remove unused functions and adjust the order
yliang-sn Feb 21, 2022
9596cac
add mls to compute the nodal level set values
yliang-sn Feb 25, 2022
2197fa9
Cleanup git and cmakelist
bodhinandach Feb 25, 2022
cac768b
Make elastic plastic tensor calculation public
bodhinandach Feb 25, 2022
92519ab
Add minor modifications
bodhinandach Feb 25, 2022
440c0c4
revert apply_velocity_constraints to pure virtual
bodhinandach Feb 25, 2022
b082bda
Some cleanups
bodhinandach Feb 25, 2022
42a88ac
minor correction until initialization
bodhinandach Feb 26, 2022
1f6db40
finish initiation_discontinuity
bodhinandach Feb 27, 2022
f4d38bc
Finishing check without propagation
bodhinandach Feb 27, 2022
0d47e70
Commit 1 for propagation of discontinuity
bodhinandach Feb 28, 2022
268629f
Commit 2 of propagation of discontinuity
bodhinandach Feb 28, 2022
02a898b
add mls option in the input file
yliang-sn Feb 28, 2022
855c2b7
perform initialise after initiation
yliang-sn Feb 28, 2022
baa7214
refactor to add usl/usf/musl option
yliang-sn Mar 1, 2022
d47e787
add musl option 2
yliang-sn Mar 1, 2022
5641025
Fix error in velocity/displacement update in explicit XMPM solver
yliang-sn Mar 1, 2022
319ce31
add irregular cell and fix a bug in check particle levelset function
yliang-sn Mar 1, 2022
e320983
merge master into xmpm-branch
yliang-sn Mar 1, 2022
35c6e91
out put in XMPM Solver
yliang-sn Mar 1, 2022
64cc03f
Merge branch 'master' into xmpm-branch
yliang-sn Mar 2, 2022
c450f90
fix bug in displacement update in xmpm
yliang-sn Mar 2, 2022
7b70a30
small bug to determine the initiation region
yliang-sn Mar 3, 2022
66bd670
don't update cell type after inserting mark points
yliang-sn Mar 4, 2022
7183f3f
modify single to multiple for spurious potential tip cell
yliang-sn Mar 7, 2022
172b4ba
Merge branch 'xmpm-branch' into xmpm-interaction
yliang-sn Mar 7, 2022
f2e020b
adjust the order of discontinuity search and update for multiple she…
yliang-sn Mar 7, 2022
14735de
create point class
yliang-sn Mar 8, 2022
ab00445
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 8, 2022
f021f56
define variables list for point class
yliang-sn Mar 8, 2022
ac07f3e
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 8, 2022
e57b7d2
change output name of points
yliang-sn Mar 8, 2022
8612256
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 8, 2022
26e68f2
fix bug: input parameters in the function
yliang-sn Mar 8, 2022
cd6d611
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 8, 2022
9b66da7
add variables in pointbase class
yliang-sn Mar 8, 2022
a6a4803
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 8, 2022
e1bccda
fix error
yliang-sn Mar 9, 2022
8731c37
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 9, 2022
2394798
define the parameters to const
yliang-sn Mar 9, 2022
1cae4bb
Merge branch 'master-point' into xmpm-interaction
yliang-sn Mar 9, 2022
a1bc394
create discontinuity point class instead of structure
yliang-sn Mar 9, 2022
5b0bcec
clean duplicate code in pointbase construction function
yliang-sn Mar 9, 2022
4c214da
output discontinuity point in XMPM solver
yliang-sn Mar 9, 2022
460f2b4
add option to output discontinuity_id for discontinuity points
yliang-sn Mar 10, 2022
054e1ba
interaction strategy for multiple shear band
yliang-sn Mar 11, 2022
9842a8f
termination of the discontinuity propagation
yliang-sn Mar 15, 2022
218fb56
interaction between discontinuities
yliang-sn Mar 17, 2022
fe6eb04
merge with master
yliang-sn Sep 3, 2022
eeaf5f1
merge with master
yliang-sn Sep 3, 2022
ed34610
OpenMP Works correctly
bodhinandach Sep 4, 2022
97eee3f
Some optimizations
bodhinandach Sep 11, 2022
b342f1f
major refactor for mesh_xmpm
bodhinandach Sep 12, 2022
9d39cba
optimize cell node and particle xmpm
bodhinandach Sep 12, 2022
b21ebf2
OMP work in progress:optimization and fix an assign node type bug in …
yliang-sn Sep 19, 2022
29dc37e
fix a bug: detect the node type and assign the correct discontinuity id
yliang-sn Sep 21, 2022
9e7ccb6
Merge branch 'master' of https://github.com/geomechanics/mpm into xmp…
bodhinandach Sep 25, 2022
3d2c044
Make codecov works
bodhinandach Sep 25, 2022
f78245a
test functions in progress
yliang-sn Oct 10, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions include/solvers/mpm_base.h
Original file line number Diff line number Diff line change
@@ -112,7 +112,7 @@ class MPMBase : public MPM {
void write_vtk(mpm::Index step, mpm::Index max_steps) override;
//! Write VTK files for points
void write_point_vtk(mpm::Index step, mpm::Index max_steps,
mpm::Vector<PointBase<Tdim>>& points);
const mpm::Vector<PointBase<Tdim>>& points);
#endif

#ifdef USE_PARTIO
@@ -127,29 +127,32 @@ class MPMBase : public MPM {
//! Return coordinates of points
//! \param[in] points the list of points
std::vector<Eigen::Matrix<double, 3, 1>> points_coordinates(
mpm::Vector<PointBase<Tdim>>& points);
const mpm::Vector<PointBase<Tdim>>& points);

//! Return point scalar data
//! \param[in] attribute Name of the scalar data attribute
//! \param[in] points the list of points
//! \retval scalar_data Vector containing scalar properties from points
std::vector<double> points_scalar_data(
const std::string& attribute, mpm::Vector<PointBase<Tdim>>& points) const;
const std::string& attribute,
const mpm::Vector<PointBase<Tdim>>& points) const;

//! Return points vector data
//! \param[in] attribute Name of the tensor data attribute
//! \param[in] points the list of points
//! \retval vector_data Vector containing vector properties from points
std::vector<Eigen::Matrix<double, 3, 1>> points_vector_data(
const std::string& attribute, mpm::Vector<PointBase<Tdim>>& points) const;
const std::string& attribute,
const mpm::Vector<PointBase<Tdim>>& points) const;

//! Return points tensor data
//! \param[in] attribute Name of the tensor data attribute
//! \param[in] points the list of points
//! \retval tensor_data Vector containing tensor properties from points
template <unsigned Tsize>
std::vector<Eigen::Matrix<double, Tsize, 1>> points_tensor_data(
const std::string& attribute, mpm::Vector<PointBase<Tdim>>& points) const;
const std::string& attribute,
const mpm::Vector<PointBase<Tdim>>& points) const;
/**@}*/

private:
15 changes: 9 additions & 6 deletions include/solvers/mpm_base.tcc
Original file line number Diff line number Diff line change
@@ -703,8 +703,9 @@ void mpm::MPMBase<Tdim>::write_vtk(mpm::Index step, mpm::Index max_steps) {

//! Write VTK files for points
template <unsigned Tdim>
void mpm::MPMBase<Tdim>::write_point_vtk(mpm::Index step, mpm::Index max_steps,
mpm::Vector<PointBase<Tdim>>& points) {
void mpm::MPMBase<Tdim>::write_point_vtk(
mpm::Index step, mpm::Index max_steps,
const mpm::Vector<PointBase<Tdim>>& points) {

// VTK PolyData writer
auto vtk_writer = std::make_unique<VtkWriter>(points_coordinates(points));
@@ -1687,7 +1688,7 @@ void mpm::MPMBase<Tdim>::initialise_nonlocal_mesh(const Json& mesh_props) {
//! Return point coordinates
template <unsigned Tdim>
std::vector<Eigen::Matrix<double, 3, 1>> mpm::MPMBase<Tdim>::points_coordinates(
mpm::Vector<PointBase<Tdim>>& points) {
const mpm::Vector<PointBase<Tdim>>& points) {
std::vector<Eigen::Matrix<double, 3, 1>> point_coordinates;
for (auto pitr = points.cbegin(); pitr != points.cend(); pitr++) {
Eigen::Vector3d coordinates;
@@ -1703,7 +1704,8 @@ std::vector<Eigen::Matrix<double, 3, 1>> mpm::MPMBase<Tdim>::points_coordinates(
//! Return point scalar data
template <unsigned Tdim>
std::vector<double> mpm::MPMBase<Tdim>::points_scalar_data(
const std::string& attribute, mpm::Vector<PointBase<Tdim>>& points) const {
const std::string& attribute,
const mpm::Vector<PointBase<Tdim>>& points) const {
std::vector<double> scalar_data;
scalar_data.reserve(points.size());
// Iterate over points and add scalar value to data
@@ -1715,7 +1717,8 @@ std::vector<double> mpm::MPMBase<Tdim>::points_scalar_data(
//! Return point vector data
template <unsigned Tdim>
std::vector<Eigen::Matrix<double, 3, 1>> mpm::MPMBase<Tdim>::points_vector_data(
const std::string& attribute, mpm::Vector<PointBase<Tdim>>& points) const {
const std::string& attribute,
const mpm::Vector<PointBase<Tdim>>& points) const {
std::vector<Eigen::Matrix<double, 3, 1>> vector_data;
// Iterate over points
for (auto pitr = points.cbegin(); pitr != points.cend(); pitr++) {
@@ -1737,7 +1740,7 @@ template <unsigned Tsize>
std::vector<Eigen::Matrix<double, Tsize, 1>>
mpm::MPMBase<Tdim>::points_tensor_data(
const std::string& attribute,
mpm::Vector<PointBase<Tdim>>& points) const {
const mpm::Vector<PointBase<Tdim>>& points) const {
std::vector<Eigen::Matrix<double, Tsize, 1>> tensor_data;
// Iterate over points
for (auto pitr = points.cbegin(); pitr != points.cend(); pitr++) {