« View all new features in Mathematica 9  previous  |  next 
New in Mathematica 9Advanced Hybrid and Differential Algebraic Equations

Seven-Link Mechanical System 

In[1]:=
Click for copyable input
X
In[10]:=
Click for copyable input
X
In[11]:=
Click for copyable input
X
In[12]:=
Click for copyable input
X

Model Andrew's squeezer mechanism.

Click for copyable input
X

The system consists of seven links of various shapes, with one of the links attached to a spring. The shortest link is driven by a motor, which in turn moves all the other links.

The dimensions associated with the various links are shown below. The seven links are labeled -. The notation for the parameters used in the model and their description can be found in the following reference.

E. Hairer and G. Wanner, Solving Ordinary Differential Equations II, Stiff and Differential-Algebraic Problems, 2nd ed., Springer Series in Computational Mathematics, Vol. 14, New York: Springer, 1996.

Click for copyable input
X

The motion of the system can be defined using seven angles. The angles are defined as - here. The equations of motion can be derived using Hamiltonian principles, resulting in a a system of equations of the form where is a mass matrix, is a vector of forces, is a vector of constraints, and is Lagrange multipliers.

In[2]:=
Click for copyable input
X

Define the mass matrix associated with the system.

In[3]:=
Click for copyable input
X

Define the various forces associated with the system.

In[4]:=
Click for copyable input
X
In[5]:=
Click for copyable input
X

Define the constraint vector associated with the various links.

In[6]:=
Click for copyable input
X

Construct the equations and the constraint equations with particular values of the parameters.

In[7]:=
Click for copyable input
X

Define the initial state of the system to be at rest, with a particular set of angles.

In[8]:=
Click for copyable input
X

Solve the system and plot the angles and the forces. The motion of the links becomes faster as time progresses. The lines are color coded based on the color of the links.

In[9]:=
Click for copyable input
X
Out[10]=
Out[11]=
Out[12]=
Play Animation »
Stop Animation »
Click to play animation