-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor the way the DEM PropertiesIndex are managed using templates (#…
…1399) Description The deal.II ParticleHandler class supports storing a number of properties as double within the a PropertyPool. The issue is that this PropertyPool is nothing more than an array of double and associating the elements of that array to a physical meaning (e.g. knowing that property 8 is the diameter) can be challenging. To alleviate this issue, we have always used an enum of type int to do the link between the properties and their index. This is convenient, but it also hardcodes at compile time the properties. This has forced us to have the same number of properties in DEM and CFD-DEM. This is wasteful, because all of the hydrodynamic forces and torques, which are just zero in DEM, have the be stored anyway in a DEM simulation. This PR changes this issue by templating ALL of the DEM classes that use the properties of the particle with a typename that is an enum. This typename PropertiesIndex is then used within the class to do the calculation with the adequate properties index. This essentially enable the contact models, the integrators, or whatever you actually want, to be reused with ParticleHandler that have a different amount of properties. Some of the planned usage for this are notably heat transfer within particles, but also the addition of more properties on the particle within CFD-DEM (e.g. previous particle velocity like we discussed with @voferreira ). This PR opens all of these possibilities. This is a major change because it changes everything in the code everywhere, but does not change the logic. The DEM results are unchanged, but the CFD-DEM results are changed. This is because, now CFD-DEM requires translating a DEM ParticleHandler to a CFD-DEM ParticleHandler. To achieve this, I read the ParticleHandler from the DEM simulation and transform it into a CFD-DEM ParticleHandler using a new conversion function I wrote. This essentially opens-up the possibility of reading particles that were created on a different mesh and converting it on a new one. This is what i will do in the next PR and this will essentially disconnect the mesh used for DEM and for CFD-DEM. Enabling us to change the CFD-DEM mesh without redoing a DEM insertion (which is cool). @voferreira this feature will be useful for your mesh convergence work Testing The CFD-DEM test results have changed because of the aforementioned issue Documentation This does not modify the documentation except for a minor parameter that was added. Co-authored-by: OGaboriault <[email protected]> Co-authored-by: Victor Oliveira Ferreira <[email protected]>
- Loading branch information
1 parent
a31a90c
commit b676be5
Showing
180 changed files
with
4,182 additions
and
2,509 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
applications_tests/lethe-fluid-particles/adaptive_sparse_contacts_files/dem_0.particles
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0 0 350 78 350 | ||
0 0 350 75 350 |
Binary file modified
BIN
+0 Bytes
(100%)
...tests/lethe-fluid-particles/adaptive_sparse_contacts_files/dem_0.triangulation_fixed.data
Binary file not shown.
Binary file modified
BIN
-19.1 KB
(69%)
...ts/lethe-fluid-particles/adaptive_sparse_contacts_files/dem_0.triangulation_variable.data
Binary file not shown.
78 changes: 0 additions & 78 deletions
78
applications_tests/lethe-fluid-particles/conserve_phase_volumes.mpirun=1.output
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.