## 6 Finite Element Formulation  
The finite element formulation of the floating frame of reference formulation is different from the common finite element modeling as the former separates the elastic coordinates from the rigid (undeformed) coordinates. In other words, the elastic displacement is presented exclusively by using each body frame as reference. Using the finite elements, each body is discretized into a number of elements. The displacement field \(w\) is given by:  
\[w=Se, \tag{107}\]  
where \(S\) and \(e\) are the element shape function and the nodal coordinates, respectively. The element shape function as well as the number and types of the nodal coordinates depends on the element type. The nodal coordinates \(e\) can be written as:  
\[e=e_{o}+e_{f}, \tag{108}\]  
where \(e_{o}\) is the undeformed nodal coordinates whereas \(e_{f}\) is the elastic nodal coordinates. In the finite element formulation of the floating frame of reference formulation, four coordinate systems are used as shown in Figure 6--(1) the global coordinate system \(\mathbf{X_{1}X_{2}X_{3}}\), (2) the body \(i\) coordinate system \(x_{1}^{i}x_{2}^{i}x_{3}^{i}\), (3) the element coordinate system \(x_{1}^{i}x_{2}^{i}x_{3}^{i}\) and (4) the intermediate element coordinate system \(x_{1}^{i}x_{i2}^{i}x_{3}^{i}\). The global coordinate system is inertially fixed. The body \(i\) coordinate system, one in each body \(i\), is not rigidly attached to a point in the body. The element coordinate system, one in each element, has an origin rigidly attached to a point in the element. As a result, it translates and rotates with the element. The intermediate element coordinate system, one in each element, has an origin rigidly attached to the origin of the body \(i\) coordinate system \(\mathbf{O^{i}}\). This coordinate system has a fixed orientation with respect to the body \(i\) coordinate system. Its orientation is selected such that it is initially parallel to the axes of the element coordinate system. Figure 6: Frames in the finite element formulation. The displacement field in the element \(j\) expressed in the body \(i\) coordinate system is:  
\[u^{ij}=N^{ij}q_{n}{}^{ij}, \tag{109}\]  
where:  
\[N^{ij}=C^{ij}S^{ij}\overline{C}^{ij}B_{1}{}^{ij} \tag{110}\]  
and \(q_{n}{}^{ij}\) is the vector of nodal coordinates in the body \(i\), that is,  
\[q_{n}{}^{i}=\left[ \begin{array}{ccc}e_{1}{}^{i}&e_{2}{}^{i}&\cdots&e_{n_{n}-1 }{}^{i}&e_{n_{n}}{}^{i}\end{array} \right]^{T} \tag{111}\]  
For a 2D beam element, that is, a beam element with only longitudinal and transversal translations and a rotation about its longitudinal axis,  
\[C^{ij}=\left[ \begin{array}{cc}\cos\beta^{ij}&-\sin\beta^{ij}\\ \sin\beta^{ij}&\cos\beta^{ij}\end{array} \right] \tag{112}\]  
\[\overline{C}^{ij}=\left[ \begin{array}{cc}\overline{C}_{1}{}^{ij}&0\\ 0&\overline{C}_{1}{}^{ij}\end{array} \right] \tag{113}\]  
\[\overline{C}_{1}{}^{ij}=\left[ \begin{array}{ccc}\cos\beta^{ij}&\sin\beta^{ ij}&0\\ -\sin\beta^{ij}&\cos\beta^{ij}&0\\ 0&0&1\end{array} \right] \tag{114}\]  
where \(\beta^{ij}\) is the fixed angle between the intermediate element coordinate system and the body coordinate system. In other words, the matrix \(C^{ij}\) is the constant rotation matrix between the intermediate element coordinate frame and the body coordinate frame. In a planar case, the matrix \(C^{ij}\) is a \(2\times 2\) elementary rotation matrix such as that given in Equation (112). In a spatial case, the matrix \(C^{ij}\) is a \(3\times 3\) rotation matrix.