# Bio-Inspired Design of an Underwater Robot Exploiting Fin Undulation Propulsion
## 2 Materials and Methods
### Dynamic Analysis and Motor Sizing
#### 2.4.1 Hydrodynamic Forces Estimation  
The objective of this CFD analysis was to estimate the forces acting on a cownose ray fin moving with a prescribed motion law and immersed in a constant speed flow.  
The numerical simulation was 3D and unsteady, and it was performed using a moving mesh. Unsteady-Reynolds-Average-Navier-Stokes (URANS)equations were solved, and the \(k-\omega SST\) method was used to model turbulence. \(k-\omega SST\) is a well-established turbulence model since it combines the best features of \(k-\omega\) and \(k-e\) methods: a \(k-\omega\) formulation was adopted in the inner parts of the boundary layers and a \(k-e\) formulation was adopted in the free stream [22]. Considering the symmetry of the fish, only one fin was present in the simulation, and symmetry plane boundary conditions were imposed on the middle plane of the body for every variable. In Figure 10, it is possible to see the domain of the simulation with the imposed boundary conditions.  
A constant fluid velocity of 1 m/s was imposed at the inlet and as an initial condition for the internal flow, a moving wall velocity condition was imposed on the fin, and a zero gradient boundary condition for velocity was present at all the other boundaries. As far as pressure is concerned, a fixed pressure of 0 Pa was imposed at the outlet and a zero gradient condition was imposed everywhere else.  
Figure 10: Domain of the CFD analysis and boundary conditions.  
The mesh was composed of 1,005,416 cells, with 7 levels of refinement around the surface of the fin. The mesh motion on the fin surface was imposed with a custom function that moves the points of the mesh according to Equations (1) and (2). The rest of the mesh was deformed using a Laplacian motion solver with a quadratic inverse distance diffusivity. In Figure 11, the deformed mesh is shown at different positions of the fin motion.  
In this analysis, the fin moved with a frequency of 1 Hz, 0.4 waves were present on the fin, and one period, i.e., 1 s, was simulated. The pressure distribution on the fin at different instants of fin motion is shown in Figure 12. As it is possible to observe, the motion created a negative pressure in front of the fin and a positive pressure behind it, so that the fish was pushed forward by the surrounding fluid.  
The major contribution to this pressure difference was given by the area near the fin tip, where the fin motion featured a greater amplitude. It can be noted also that, at the area near the leading edge, the pressure difference is higher than in the area near the trailing  
Figure 11: Deformable mesh in different positions: fin at the upper extremity of its motion (**a**), fin in the middle of its motion (**b**), fin at the lower extremity of its motion (**c**).  
Figure 12: Pressure distribution on a plane at half span of the fin.  
edge. The propulsive force is maximum at the middle of the fin motion, both during upstroke and during downstroke, when fin velocity is maximum; conversely, when the fin tip reaches the top and the bottom extremities, it has zero velocity, so its propulsive force is minimum.  
To analyze the effect of such a pressure distribution on the torque and on the power required by the motors, the surface of the fin was divided in six smaller regions and, in each of them, the resultant force and moment vectors were extracted, as shown in Figure 13. These forces and moments were then exported to Simulink and applied in the correspondent positions of the robot.