-
Notifications
You must be signed in to change notification settings - Fork 8
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
Impactor with contact #143
base: main
Are you sure you want to change the base?
Conversation
src/CabanaPD_Contact.hpp
Outdated
} | ||
}; | ||
|
||
template <class MemorySpace, class ContactType> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
template <class MemorySpace, class ContactType> | |
template <class MemorySpace, class ContactModelType> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed
src/CabanaPD_Contact.hpp
Outdated
|
||
template <class ForceType, class ParticleType, class ParallelType> | ||
void computeContactFull( ForceType& fc, const ParticleType& particles, | ||
const int n_local, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think n_local
here is an unused parameter, and should be removed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Kept to align with other force classes (should be removed separately though since it's available in the particle object)
src/CabanaPD_Contact.hpp
Outdated
// neigh_op_tag ); | ||
|
||
// Forces only atomic if using team threading | ||
if ( std::is_same<decltype( neigh_op_tag ), Cabana::TeamOpTag>::value ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if ( std::is_same<decltype( neigh_op_tag ), Cabana::TeamOpTag>::value ) | |
if constexpr ( std::is_same<decltype( neigh_op_tag ), Cabana::TeamOpTag>::value ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
src/CabanaPD_Solver.hpp
Outdated
// Update ghost particles. | ||
comm->gatherDisplacement(); | ||
|
||
// Compute internal forces. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// Compute internal forces. | |
// Compute internal (PD) forces. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Planning for this to be PD or DEM, depending on which force type is passed in
src/CabanaPD_Solver.hpp
Outdated
using neighbor_type = typename base_type::neighbor_type; | ||
using force_model_type = ForceModel; | ||
using force_type = typename base_type::force_type; | ||
using neigh_iter_tag = Cabana::SerialOpTag; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume you'll mean to expose neigh_iter_tag
to allow for TeamOpTag
at a later time.
src/CabanaPD_Contact.hpp
Outdated
mesh_min[d] = particles.ghost_mesh_lo[d]; | ||
mesh_max[d] = particles.ghost_mesh_hi[d]; | ||
} | ||
const auto y = particles.sliceCurrentPosition(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing a particles migrate step here to ensure that the current positions are up-to-date?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pretty big update here - contact is now embedded in the main solvers and neighbor lists belong to the force objects to simplify how the PD/contact/DEM works
src/CabanaPD_Contact.hpp
Outdated
} | ||
}; | ||
|
||
template <class MemorySpace, class ContactType> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed
src/CabanaPD_Contact.hpp
Outdated
|
||
template <class ForceType, class ParticleType, class ParallelType> | ||
void computeContactFull( ForceType& fc, const ParticleType& particles, | ||
const int n_local, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Kept to align with other force classes (should be removed separately though since it's available in the particle object)
src/CabanaPD_Contact.hpp
Outdated
// neigh_op_tag ); | ||
|
||
// Forces only atomic if using team threading | ||
if ( std::is_same<decltype( neigh_op_tag ), Cabana::TeamOpTag>::value ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
src/CabanaPD_Solver.hpp
Outdated
// Update ghost particles. | ||
comm->gatherDisplacement(); | ||
|
||
// Compute internal forces. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Planning for this to be PD or DEM, depending on which force type is passed in
associated issues in using contact at all
Still a bit messy, but rebased on main from the very old original version in #59