# Review on System Identification and Mathematical Modeling of Flapping Wing Micro-Aerial Vehicles
## 3 System Identification and Mathematical Modeling of Flapping Wing Micro Air Vehicles (FWMAVs)
### Tailless Flapping Wing Micro Air Vehicles
#### 3.2.1 System Identification of In-Flight Dynamics of Robotic Bee
In more detail, this equation can be expressed as follows:  
\[\frac{d}{dt}\left[ \begin{array}{c}\omega_{x}\\ \omega_{y}\end{array} \right]=\left[ \begin{array}{cc}\tau_{c},&xJ_{x}^{-1}\\ \tau_{c},yJ_{y}^{-1}\end{array} \right]+\left[ \begin{array}{cc}\left(J_{y}- J_{z}\right)J_{x}^{-1}&0\\ 0&(J_{z}-J_{x})J_{y}^{-1}\end{array} \right]\left[ \begin{array}{c}\omega_{x} \omega_{z}\\ \omega_{y}\omega_{z}\end{array} \right]+\left[ \begin{array}{c}-c_{x}\omega_{ x}+\beta_{x}\dot{y}\\ -c_{y}\omega_{y}-\beta_{y}\dot{x}\end{array} \right]+\left[ \begin{array}{c}d_{x} \\ d_{y}\end{array} \right]. \tag{20}\]  
The aforementioned Equations (18) and (20) are linear in their structures and therefore, the estimation of unknown parameters via the linear regression approach is the ultimate objective. The linear regression model could be expressed as follows:  
\[\Psi_{i}=\varphi_{0}+\sum_{j=1}^{n}\chi_{ij}\varphi_{j}+e_{i};\ i\in\{1,2, \ldots,N\}, \tag{21}\]  
where \(\varphi_{0}\) represents an unknown possible offset or affine term; \(e_{i}\) represents the residual of an \(i^{th}\) observation; \(N\) is the number of total observations; \(n\) is the number of unknown parameters; and \(\Psi\) is an \(N\times 1\) vector, which needs to be extracted. The following least square estimator is considered to provide the estimated parameters. \[\hat{\varphi}=\left(\chi^{T}\chi\right)^{-1}\chi^{T}\Psi,\ \text{and}\ R^{2}=1- \frac{\sum_{i=1}^{N}{e_{i}}^{2}}{\sum_{i=1}^{N}\left(\Psi_{i}-\frac{1}{N}\sum_ {j=1}^{N}\Psi_{j}\right)^{2}} \tag{22}\]  
where \(R^{2}\) indicates the goodness of the estimation using curve fitting with \(R^{2}\) close to 1 for a good estimation. The translational dynamics presented in (18) in the body fixed frame could be further subdivided into lateral and altitude dynamics. The estimates of the lateral dynamics into a merged equation can be expressed as  
\[\Psi_{i}= \begin{cases}\ddot{x}+\omega_{x}\dot{y}-\omega_{z}\dot{y}&\text{for }\chi_{i}= \left[\begin{array}{cccc}-R_{31}&-\dot{x}&-\omega_{y}&0&0\\ \ddot{y}+\omega_{z}\dot{x}-\omega_{z}\dot{z}&\text{for }\chi_{i}=\left[ \begin{array}{cccc}-R_{32}&0&0&-\dot{y}&-\omega_{x}\\ \end{array}\right]\end{cases}  \tag{23}\]  
and \(\varphi=\left[ \begin{array}{cccc}g&b_{x}&\alpha_{x}&b_{y}&\alpha_{y}\\ \end{array} \right]^{T}\) as the vector of parameters to be estimated. Furthermore, for altitude dynamics, it is expressed as follows  
\[\Psi_{i}=\left\{\ddot{z}+\omega_{x}\dot{y}-\omega_{y}\dot{x}\quad,\text{for }\chi_{i}= \left[ \begin{array}{cccc}\frac{T}{s\gamma^{-1}+1}&-R_{33}&-\dot{y}\\ \end{array} \right]\right. \tag{24}\]  
and \(\varphi=\left[ \begin{array}{cccc}\mu&g&b_{z}\\ \end{array} \right]^{T}\) as the vector of parameters to be determined. \(T\) is the commanded thrust and \(s\) is a Laplace variable. The rotational dynamics, because of the existence of coupling of the moment of inertia between the axes, are less sophisticated. These terms are lumped into \(v_{i}\) and \(k_{i}\) variables. The term \(v_{i}\), for example, indicates the inverse of the moments multiplied by some scaling factor, which represents the relation between the command torque and the actual torque. The factor \(\left(s\gamma^{-1}+1\right)^{-1}\) indicates the response time of the system, and is very much similar to the response time of the system to the thrust command. One may have the following expressions  
\[\Psi_{i}=\Big{\{}\frac{d}{dt}\omega_{x}\;,\quad\chi_{i}=\left[ \begin{array}{ ccc}\frac{\tau_{x}\;y}{s\gamma^{-1}+1}&\omega_{y}\omega_{z}&-\omega_{x}&\dot{y} \\ \end{array} \right]\Big{\}}, \tag{25}\]  
and \(\varphi=\left[ \begin{array}{cccc}v_{x}&k_{x}&c_{x}&\beta_{x}\\ \end{array} \right]^{T}\) as the vector of unknown parameters, and  
\[\Psi_{i}=\Big{\{}\frac{d}{dt}\omega_{y}\quad\chi_{i}=\left[ \begin{array}{ ccc}\frac{\tau_{x}\;y}{s\gamma^{-1}+1}&-\omega_{x}\omega_{z}&-\omega_{y}&-\dot{x} \\ \end{array} \right]\Big{\}}, \tag{26}\]  
and \(\varphi=\left[ \begin{array}{cccc}v_{y}&k_{y}&c_{y}&\beta_{y}\\ \end{array} \right]^{T}\).