## 2 Materials and Methods
### Computational Fluid Dynamics Simulation
#### 2.3.3 Mathematical Kinematics Model for Forward Flight  
The flight motion of the butterfly mainly couples the motions of the wing flapping and the thorax pitching. The abdominal motion, which actively changes the pitch Angle of the thorax, is important for the stability of the flight. By pitching the body, the butterfly manipulates the stroke plane angle to adjust the direction of the flapping motion. The movement of wings is accompanied by clapping and peeling during the downstroke (DS) and upstroke (US), respectively.  
The flapping motion and the pitch motion of the real butterfly and the simulation model change periodically, as shown in Figure 3. The swing of the abdomen directly affects the pitch angle of the butterfly thorax. Thus, the wing kinematics can be expressed as the flapping motion \(\theta_{f}(t)\), the pitch motion \(\theta_{p}(t)\), and the phase difference \(\gamma\) between \(\theta_{f}\) and \(\theta_{p}\).  
\begin{table}
\begin{tabular}{c c c c} \hline \hline
**Parameters** & **s (Coarse)** & **s/2 (Medium)** & **s/4 (Fine)** \\ \hline Near wall (m) & \(1.25\times 10^{-3}\) & 6.25 \(\times\) 10\({}^{-4}\) & 3.125 \(\times\) 10\({}^{-4}\) \\ Far field (m) & 1.0 \(\times\) 10\({}^{-2}\) & 5.0 \(\times\) 10\({}^{-3}\) & 2.5 \(\times\) 10\({}^{-3}\) \\ Elements at t = 0.1 s & 223,862 & 1,475,111 & 10,915,276 \\ \hline \hline \end{tabular}
\end{table}
Table 3: Resolutions set-ups for the resolution-dependency study.  
The wing and body kinematics of four consecutive flapping cycles were recreated with our programs. To input the flight kinematics model of butterflies recorded from observation into a simulation, three cosine wave functions served to approach the flapping motion and pitch motion the same as in the experiment. The functions are expressed as  
\[\left\{\begin{array}{l}\theta_{f}(\mathrm{t})=A_{f}\cos(2\pi ft)+A_{0}\\ \theta_{p}(t)=A_{p}\cos(2\pi ft+\gamma)+B_{0}\\ \theta_{a}(t)=-A_{a}\cos(2\pi ft)+C_{0}\end{array}\right.. \tag{8}\]  
in which \(A_{f}\), \(A_{p}\), and \(A_{a}\) are the amplitudes of \(\theta_{f}(\mathrm{t})\), \(\theta_{p}(\mathrm{t})\), and \(\theta_{a}(\mathrm{t})\) from the experiment. The aerodynamic forces are calculated with mathematical sets of the kinematic parameter \(\mathbf{K}\) (\(f\), \(A_{f}\), \(A_{p}\), \(A_{a}\), \(A_{0}\), \(B_{0}\), \(C_{0}\), \(\gamma\), \(V_{\infty}\)). The observed results show that \(A_{f}\) of the wings is about \(60.0^{\circ}\); \(A_{p}\) of the thorax is about \(30.0^{\circ}\); and \(A_{a}\) of the thorax is about \(20.0^{\circ}\). \(\gamma\) is the phase difference between flapping and thoracic pitch motion about \(\pi/2\) rad or smaller. The initial flapping angle \(A_{0}\) of the wing in the balanced position is approximately \(20^{\circ}\). \(B_{0}\) is the initial pitch angle in the balanced position, approximately \(34^{\circ}\) in the simulation. \(C_{0}\) is the initial abdominal swing angle in the balanced position, which is approximately \(-35^{\circ}\). The lead-lag angle of the wings is approximately \(15^{\circ}\), which is determined by a three-dimensional model. To clearly describe the kinematics of the butterfly during flight, non-dimensional time is defined as \(\hat{t}{=}t/T\), \(T\) is the flapping period. Thus, the initial kinematic simulation equation can be obtained as follows.  
\[\left\{\begin{array}{l}\theta_{f}(\mathrm{t})=60^{\circ}\cos(2\pi ft)+20^{ \circ}\\ \theta_{p}(\mathrm{t})=30^{\circ}\cos(2\pi ft+\frac{\pi}{2})+34^{\circ}\\ \theta_{a}(\mathrm{t})=-20^{\circ}\cos(2\pi ft)-35^{\circ}\end{array}\right.. \tag{9}\]