Skip to content
Elijah Andrews edited this page Oct 15, 2019 · 10 revisions

Welcome to the DEMOranges Wiki. This contains all of the documentation and information about DEMOranges.

DEMOranges is a Discrete Element Method implementation written in C with OpenCL. Building and compiling is handled by CMake.

This implementation was created for my Individual Project, the project report can be found here. The report contains a lot of useful background and mathematics that aren't documented here. If you're interested in how the DEM works then that is the place to look, if you're interested in how the code works then you're in the right place already.

The purpose of this implementation is to achieve a functional DEM implementation for large numbers of particles (10^7) that runs in O(N) time.

Why 'DEMOranges'?

My first DEM implementation was in Python, called 'DEMApples' ("How do you like dem apples?") and DEMOranges seemed like the natural progression.

Naming Conventions

The naming conventions used in this project are a bit of a mess, trapped between C and OpenCL. Many of the OpenCL functions use camelCase but data types use_underscores as do C convention variables. I have attempted to follow each of these where appropriate but it does end up with some ugly function names like pp_collisionsToDevice (pp_collision being a struct data type and ToDevice following OpenCL function conventions) for which I wholeheartedly apologize.