The Chrono::Engine software is a general-purpose simulator for three-dimensional multi-body problems. Specifically, the code is designed to support the simulation of very large systems such as those encountered in granular dynamics, where the number of interacting elements can be in the millions. Target applications include tracked vehicles operating on granular terrain, or the Mars rover operating on discrete granular soil.

A simulation in Chrono::Engine Software of a Mars rover-type wheeled vehicle operating on granular terrain. The vehicle is composed of a chassis and six wheels connected via revolute joints. The wheels of the rover are checkered blue and white to signify that the master copy of the rover assembly is in the blue sub-domain and the rover spans into adjacent sub-domains. Shared bodies (those that span sub-domain boundaries) are white.

In these applications, it is desirable to model the granular terrain as a collection of many thousands or millions of discrete bodies interacting through contact, impact, and friction. Such systems also include mechanisms composed of rigid bodies and mechanical joints. These challenges require an efficient and robust simulation tool, which has been developed in the Chronosimulation package.

Chrono::Engine was initially developed leveraging the Differential Variational Inequality (DVI) formulation as an efficient method to deal with problems that encompass many frictional contacts. This approach enforces non-penetration between rigid bodies through constraints, leading to a cone-constrained quadratic optimization problem that must be solved at each time step. Chrono::Engine has since been extended to support the Discrete Element Method (DEM) formulation for handling the frictional contacts present in granular dynamics problems. This formulation computes contact forces by penalizing small interpenetrations of colliding rigid bodies. Various contact force models can be used, depending on the application.

The core of Chrono::Engine is built around the concept of middleware; namely, a layer of classes and functions that can be used by third-party developers to create complex mechanical simulation software with little effort. Given the complexity of the project, approaching half a million lines of code, the software is organized in classes and namespaces as recommended by the Object Oriented Programming paradigm, targeting modularity, encapsulation, reusability, and polymorphism. The libraries of Chrono::Engine are thread-safe, fully re-entrant, and include more than 600 C++ classes. Objects from these classes can be instanced and used to define models and simulations that run in third-party software, including vehicle simulators, CAD tools, virtual reality applications, or robot simulators.

Chrono::Engine is platform-independent, so libraries are available for Windows, Linux, and Mac OSx, for both 32- and 64-bit versions. A modular approach splits the libraries in modules that can be dynamically loaded only if necessary, thus minimizing issues of dependency from other libraries and reducing memory footprint. For instance, libraries were developed for MATLAB interoperability, for real-time visualization through OpenGL, and for interfacing with post-processing tools.

Most C++ objects that define parts of the multi-body model are inherited from a base class called ChPhysicsItem, which defines the essential interfaces for all items that have some degrees of freedom. A set of more than 30 mechanical constraints is part of this class hierarchy. Furthermore, the architecture is open to further definition of new specialized classes for user-customized parts and joints. The software architecture has been designed to accommodate an expandable system for handling assets (meshes, textures, CAD models), with multiple paths from pre-processing to post-processing.

Chrono has been further extended to allow the use of CPU parallelism for certain problems. To efficiently simulate large systems, a domain decomposition approach has been developed to allow the use of many-core compute clusters. In this approach, the simulation domain was divided into a number of sub-domains in a lattice structure. Each sub-domain manages the simulation of all bodies contained therein. Bodies may span the boundary between adjacent sub-domains. In this case, the body is considered shared, and its dynamics may be influenced by the participating sub-domains. The implementation leverages the MPI standard to implement the necessary communication and synchronization between subdomains.

This approach enables the simulation of large systems in two ways. First, it relies on the power of parallel computing since one compute core can be assigned to each MPI process (and therefore to each sub-domain). These processes can execute in parallel, constrained only by the required communication and synchronization. Second, it allows access to the larger memory pool available on distributed memory architectures. Whereas a single node or GPU card may have about 6 GB of memory, a distributed memory cluster may have on the order of 1TB of memory, enabling the simulation of vastly larger problems.

This work was done by David Lamb of US Army TARDEC; Toby Heyn, Hammad Mazhar, Arman Pazouki, Daniel Melanz, Andrew Seidl, Justin Madsen, Andrew Bartholomew, and Dan Negrut of the University of Wisconsin; and Alessandro Tasora of the University of Parma. ARL-0158


This Brief includes a Technical Support Package (TSP).
Chrono: A Parallel Physics Library for Rigid-Body, Flexible-Body, and Fluid Dynamics

(reference ARL-0158) is currently available for download from the TSP library.

Don't have an account? Sign up here.



Aerospace & Defense Technology Magazine

This article first appeared in the April, 2014 issue of Aerospace & Defense Technology Magazine.

Read more articles from this issue here.

Read more articles from the archives here.