GEAR (Geometric Engine for Articulated Rigid-body simulation)
GEAR is a C++
library for kinematics and dynamics of articulated rigid body systems.
It uses efficient algorithms based on Lie group and screw theory to solve the following problems:
Forward dynamics
for calculating the resulting joint accelerations when the known joint
torques or forces are applied to the mechanical system.
Inverse dynamics
for
calculating the joint torques that are necessary to make the system
follow prescribed joint accelerations at the current state (position
and velocity).
Hybrid dynamics for
calculating the torques for prescribed joints, and the
accelerations for unprescribed joints where 'prescribed' means joint
acceleration is prescribed and 'unprescribed' (or
'torque-specified') means joint torque is known or given. A joint can
be either
'prescribed' or 'unprescribed'. Hybrid dynamics is a generalization of
the forward and inverse dynamics, i.e., they can be regarded as the
extreme cases of hybrid dynamics when all of the joints are
'unprescribed' and when all of the joints are 'prescribed'
respectively.
Analytical derivatives of the forward/inverse/hybrid dynamics with respect to an arbitrary parameter.
Constraints such
as closed-loops can be considered in solving forward/inverse/hybrid
dynamics. (Closed loops are automatically detected and included to the
list of system constraints when building a system.)
GEAR uses a joint coordinate system to describe the degree of freedom
of an articulated rigid body system. Thus, the joint constraints are
inherently
considered in the algorithms without having to consider them
separately. Closed joint loops are automatically detected and handled
as constraints. Additional constraints can also be added to the system.
See "Lie group formulation of articulated rigid body dynamics" for the detail of the implemented algorithms.
How to compile:
CMake and a C++ compiler are necessary to build GEAR.
On Linux, do make in the terminal to compile the library under gear/build_release
On Windows, execute runcmake_win.bat to create a Visual Studio solution file under gear/build.
On Mac, execute runcmake_xcode to create an XCode project file
under gear/build_xcode. Alternatively, you can do make in the terminal
to compile using gcc.
Usage: See gear/examples for
a simple 2 dof two-link system and a closed-loop system consisting of 4
revolute joints and 1 prismatic joint. (You might also want to check GMOV and SLOOP which are small projects using GEAR.)
Related Projects: GEAR has been used in the following projects: