# Electromagnetically Driven Robot for Multipurpose Applications
## 3 Modelling and Kinematics  
Fundamentally, there are two main forces that affect the net force \(FM\) which is required to bend the segment into the desired angle. The first force is the magnetic force which is basically considered as an attractive force. The second force is the repulsive force from the spring \(FS\) which is responsible for maintaining the equilibrium status of the segment once no other forces are applied, as described in Equation (1). \[\sum F=0=FM_{k_{i_{j_{j}}}}-FS_{p_{k_{i_{j}}}} \tag{1}\]  
\(i\) represents the number of coils or springs, \(i=1,2,3\ldots n\);  
\(x_{j}\) represents the force direction;  
\(x_{j}=x_{1},x_{2},x_{3}=x,y,z\);  
\(k\) represents the number of segments in the robot;  
\(M\) represents the force of the electromagnets and \(S\) is the force of the springs. So if we consider one segment of the report, \(k=1\) as shown in Equation (2). \[\sum FM_{1_{i_{j_{j}}}}-\sum FS_{1_{i_{j_{j}}}}=0 \tag{2}\]  
The direction of the forces for four springs and four electromagnets is shown in Figure 4:  
Figure 4: Force direction. Figure 3: The proposed disassemble parts. Thus, the equation for one segment, which has three axes to move in, is shown in Equation (3):  
\[ \begin{split}\sum FM_{1_{i_{X_{1}}}}-\sum FS_{1_{i_{X_{1}}}}& =0\\ \sum FM_{1_{i_{X_{2}}}}-\sum FS_{1_{i_{X_{2}}}}&=0\\ \sum FM_{1_{i_{X_{3}}}}-\sum FS_{1_{i_{X_{3}}}}&=0\\ \end{split}  \tag{3}\]  
Since the balancing force is the spring force, the input force of the electromagnet will be set according to the force of the desired deflection of the spring. The magnetic force \(FM\) consists of two main components. The first component is the force produced by the electromagnet \(F_{e}\), shown in Equation (4), and the other component is from the permanent magnet \(F_{p}\). The force between the electromagnetic coil and the permanent magnet can be found with:  
\[F_{e}=\ M_{z}\cdot V\frac{\partial B_{z}}{\partial z} \tag{4}\]  
where \(B\) is the magnetic flux density of the electromagnetic coil, \(V\) is the volume of the permanent magnet \(P_{M}\), and \(M_{z}\) is the magnetization of the \(P_{M}\). To find the magnetic field of the electromagnet, a cylindrical coordinate system \((r,\phi,z)\) is introduced. As the electromagnet is azimuthally symmetric \((B_{\phi}=0)\), the magnetic field can be shortened into radial component \(B_{r}\) and axial component \(B_{z}\) as shown in Equation (5):  
\[B=\ B_{r}(r,z)\hat{r}+\ B_{z}(r,z)\hat{z} \tag{5}\]  
Also, the electromagnetic field B produced by an electromagnet can be found as vector potential \(\vec{A}\), as shown in Equation (6):  
\[\vec{B}=\
abla\times\vec{A} \tag{6}\]  
Then, by calculating the curl of the vector potential \(\vec{A}\), \(B_{r}\) and \(B_{z}\) can found, as shown in Equation (7):  
\[\left\{ \begin{array}{c}B_{r}=\frac{\partial A_{\theta}}{\partial z}\\ B_{z}=\frac{1}{r}\ \frac{\partial(rA_{\theta})}{\partial r}\end{array} \right\} \tag{7}\]  
The magnetic vector potential for an electromagnet with radius \(a\), a number of turns per unit length \(n\), current running in the electromagnet \(i\), and permeability can then be expressed as Equation (8):  
\[A_{\theta}=\frac{a\mu ni}{2\pi}\ \int_{\xi_{-}}^{\xi_{+}}d\xi\int_{0}^{\pi} \frac{\cos\mathcal{O}}{\sqrt{\xi^{2}+r^{2}+a^{2}-2 ar\ \cos\mathcal{O}}}d\mathcal{O} \tag{8}\]  
where \(r\) and \(z\) are the radial and axial distances, \(\xi=z\pm\frac{\xi}{2}\), and \(L\) is the length of the electromagnet.