# Simulation of Magnetically-Actuated Functional Gradient Nanocomposites
## Appendix A  
In two-dimensional calculations, both the radial and axial force components are computed by [PERSON] et al. (2018):  
\[\begin{array}{l}F_{m}(r,z)=F_{mr}(r,z)\hat{r}+F_{mz}(r,z)\hat{z}\\ \text{where}\\ F_{mr}(r,z)=\mu_{0}V_{p}f(H_{a})\Big{[}H_{r}(r,z)\frac{\partial H_{r}(r,z)}{ \partial r}+H_{z}(r,z)\frac{\partial H_{r}(r,z)}{\partial z}\Big{]}\\ F_{mz}(r,z)=\mu_{0}V_{p}f(H_{a})\Big{[}H_{r}(r,z)\frac{\partial H_{z}(r,z)}{ \partial r}+H_{z}(r,z)\frac{\partial H_{z}(r,z)}{\partial z}\Big{]}\\ H_{a}=H_{ar}(r,z)\hat{r}+H_{az}(r,z)\hat{z}\end{array} \tag{1}\]  
The magnet is modeled as an equivalent current source, and the field distribution can be obtained via superposition ([PERSON] (1997)). If the magnet is magnetized to saturation \(M_{s}\), and centered on the \(z\) axis with its top surface at \(z=0\), its field is given by:  
\[\begin{array}{l}H_{ar}(r,z)=\frac{M_{s}}{2\pi}\int_{-h}^{0}\prod_{r}(r,z,z^{ \prime})dz^{\prime}\\ H_{az}(r,z)=\frac{M_{s}}{2\pi}\int_{-h}^{0}\prod_{z}(r,z,z^{\prime})dz^{\prime} \end{array} \tag{2}\]  
where  
\[\begin{array}{l}\prod_{r}(r,z,z^{\prime})=\frac{(z-z^{\prime})f(z,z^{\prime} )}{r}[R_{t}(z,z^{\prime})E(k)-K(k)]\\ \prod_{z}(r,z,z^{\prime})=f(z,z^{\prime})[Z_{t}(z,z^{\prime})E(k)+K(k)]\end{array} \tag{3}\]where \(K(k)\) and \(E(k)\) are the complete elliptic integrals of the first and second kind, respectively.  
\[\begin{array}{l}K(k)=\int\limits_{0}^{\frac{\pi}{2}}\frac{1}{\sqrt{1-k^{2}\sin^ {2}(\phi)}}d\phi\\ E(k)=\int\limits_{0}^{\frac{\pi}{2}}\sqrt{1-k^{2}\sin^{2}(\phi)}d\phi\end{array} \tag{10}\]  
where  
\[\begin{array}{l}d=(R_{m}-r)^{2}+\delta(z,z^{\prime})^{2}\\ f(z,z^{\prime})=\frac{1}{\left((R_{m}+r)^{2}+\delta(z,z^{\prime})^{2}\right)^ {1/2}}\\ k=\left(\frac{4 rR_{m}}{(R_{m}+r)^{2}+\delta(z,z^{\prime})^{2}}\right)^{1/2}\\ R_{t}(z,z^{\prime})=\frac{R_{m}^{2}+r^{2}+\delta(z,z^{\prime})^{2}}{d}\\ Z_{t}(z,z^{\prime})=\frac{R_{m}^{2}-r^{2}-\delta(z,z^{\prime})^{2}}{d}\\ \delta(z,z^{\prime})=(z-z^{\prime})\end{array} \tag{11}\]  
The field components are computed using numerical integration. The gradient of the field needs to be calculated to acquire the force, which is given by:  
\[\begin{array}{l}\frac{\partial H_{r}(r,z,z^{\prime})}{\partial r}=-\Big{(} \frac{1}{r}+(R_{m}+r)f^{2}\Big{)}\prod_{i}+\frac{(z-z^{\prime})f}{r}\Big{[} \frac{\partial R_{t}}{\partial r}E(k)+\frac{\partial k}{\partial r}(R_{t}dE(k )-dK(k))\Big{]}\\ \frac{\partial H_{r}(r,z,z^{\prime})}{\partial z}=-\Big{(}\frac{f^{2}(R_{m}+r )^{2}}{z-z^{\prime}}\Big{)}\prod_{r}+\frac{(z-z^{\prime})f}{r}\Big{[}\frac{ \partial R_{t}}{\partial z}E(k)+\frac{\partial k}{\partial z}(R_{t}dE(k)-dK(k ))\Big{]}\\ \frac{\partial H_{z}(r,z,z^{\prime})}{\partial r}=-\big{(}(R_{m}+r)f^{2}\big{)} \prod_{z}+f\Big{[}\frac{\partial Z_{t}}{\partial r}E(k)+\frac{\partial k}{ \partial r}(Z_{t}dE(k)+dK(k))\Big{]}\\ \frac{\partial H_{r}(r,z,z^{\prime})}{\partial z}=-\big{(}f^{2}(z-z^{\prime}) \big{)}\prod_{z}+f\Big{[}\frac{\partial Z_{t}}{\partial z}E(k)+\frac{\partial k }{\partial z}(Z_{t}dE(k)+dK(k))\Big{]}\end{array} \tag{12}\]  
The magnetic force is computed by substituting Equation (12) into Equation (10).