geoelements / geoelements/diffmpm

Code not working for multiple particle objects

Open
#31 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
48
Forks
5
PR merge metrics
No merged PRs in 30d

Description

Steps to generate the issue.
1. Generate an example with a single cell and a single particle object and run the solver.
2. Generate an example with exactly same configuration except have 2 particle objects having same material properties and element_ids.
The results does not match.
Issue in the code:- In this line of the code [scheme.py](https://github.com/geoelements/diffmpm/blob/8bb0bb3fafed0088d24c516cd8abba8c0a788f11/diffmpm/scheme.py#L26-L27) , [compute_nodal_mass](https://github.com/geoelements/diffmpm/blob/8bb0bb3fafed0088d24c516cd8abba8c0a788f11/diffmpm/element.py#L122) function will be called [same number of times](https://github.com/geoelements/diffmpm/blob/8bb0bb3fafed0088d24c516cd8abba8c0a788f11/diffmpm/mesh.py#L42-L43) as the number of particle objects and in this function [this](https://github.com/geoelements/diffmpm/blob/8bb0bb3fafed0088d24c516cd8abba8c0a788f11/diffmpm/element.py#L143) line will set the nodal mass to 0 every time the function is called hence the nodal mass for the last called Particle object would remain. Similar issue with the compute_nodal_momentum function.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.