cb-geo / mpm

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

Particle injection with pset_id change doesn't generate particles #593

Closed kks32 closed 4 years ago

kks32 commented 4 years ago

Describe the bug Particle injection method of generating particles is not working

To Reproduce

  1. In the input file set:
      "generator": {
        "check_duplicates": true,
        "particle_type": "P3D",
        "cset_id": 0,  
        "pset_id": 0,
        "material_id": 1,
        "nparticles_per_dir": 2,
        "velocity": [0.0, 0.0, -5.0],
        "duration": [0.01, 0.02],
        "type": "inject"
      }

Expected behavior Generation of particles when using injection type insertions.

Additional context VTK and HDF5 files are empty

kks32 commented 4 years ago

The issue is found to be because of ParaView rendering. In the3D particle injection example (https://github.com/cb-geo/mpm-benchmarks), the duration at which injection starts is 0.01, until then there will be no particles in the system. This means that when the vector or tensor field for the particles are opened in ParaView there is nothing to visualize. The solution is to navigate to the time-step where we expect to have particles and this will allow us to view the particles.

Please also note injected particles don't have an automatically defined particle set ids.