cb-geo / mpm

CB-Geo High-Performance Material Point Method
https://www.cb-geo.com/research/mpm
Other
238 stars 82 forks source link

Feature/multiphase material #675

Closed bodhinandach closed 4 years ago

bodhinandach commented 4 years ago

Describe the PR This PR added an enhancement to deal with multiphase material initialization from file, which is essential for two_phase_particle either in explicit or implicit solver, or later on three_phase_particle. The current proposal will work ok with MPI transfer or read from hdf5 for the single-phase particle as I am using a default phase argument to be solid. However, hdf5 initialization and MPI transfer process for two-phase is not yet implemented. This should be integrated after we find an approach to deal with multiphase hdf5 output (@kks32 is investigating that).

Related Issues/PRs

633

Additional context I also added a small modification of pressure smoothing. @tianchiTJ @WeijianLIANG Can we store pore_pressure as a state variable in the fluid material? By doing so, we can use the same smoothing routine as we use in the single-phase pressure.

codecov[bot] commented 4 years ago

Codecov Report

Merging #675 into develop will increase coverage by 0.03%. The diff coverage is 93.75%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #675      +/-   ##
===========================================
+ Coverage    96.62%   96.66%   +0.03%     
===========================================
  Files          123      122       -1     
  Lines        25318    25352      +34     
===========================================
+ Hits         24463    24504      +41     
+ Misses         855      848       -7     
Impacted Files Coverage Δ
include/mesh.h 100.00% <ø> (ø)
include/solvers/mpm_base.h 0.00% <ø> (ø)
include/solvers/mpm_explicit.tcc 63.20% <ø> (+5.11%) :arrow_up:
tests/io/write_mesh_particles.cc 87.67% <0.00%> (ø)
include/solvers/mpm_base.tcc 73.69% <84.21%> (+0.16%) :arrow_up:
include/particles/particle.tcc 94.13% <90.57%> (-0.23%) :arrow_down:
include/mesh.tcc 83.90% <100.00%> (+0.56%) :arrow_up:
include/particles/particle.h 100.00% <100.00%> (ø)
include/particles/particle_base.h 100.00% <100.00%> (ø)
tests/io/write_mesh_particles_unitcell.cc 88.10% <100.00%> (ø)
... and 7 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 72bbd93...1e1b8f7. Read the comment docs.

bodhinandach commented 4 years ago

@kks32 I added another enhancement in the material_sets which has been recently merged so that user can specify the phase_id for assigning material using material set. If they don't specify the phase_id, mpm::ParticlePhase::Solid is used as default.