Towﬁsh Attitude Control: A Consideration of Towing Point, Center of Gravity, and Towing Speed

: This paper deals with the attitude control of a towﬁsh (underwater towed vehicle) with two elevators and a single rudder to improve the image quality of an attached sound navigation ranging (sonar) system. Image distortion can occur if the towﬁsh shakes excessively. Since a towﬁsh is connected to the mother ship through a towing cable and the motion of the towﬁsh is affected not only by the motion of the cable, but also by the position of the center of gravity, towing point, and towing speed, it is necessary to analyze how these factors affect the towﬁsh to appropriately control its attitude. In this study, a method for obtaining a feasible region of the towing point in accordance with the variations in the center of gravity and towing speed is proposed, and the feasible region obtained can ensure that pitch control can be achieved using the installed elevators. In addition, the allowable range of disturbances for yaw control was also investigated. Simulations were conducted using the dynamic models of the towﬁsh and cable to check the obtained feasible region/range, and it was conﬁrmed that there is a region/range where the attitude control can be carried out with relative ease.


Introduction
Unmanned underwater vehicles (UUVs) are frequently used for marine environmental data collection, submarine topography mapping, and military purposes, among other uses [1]. Autonomous underwater vehicles (AUVs) and towfish (underwater towed vehicles) are widely used. An AUV has the advantage of being able to move freely and can operate autonomously without operator intervention [2][3][4]; however, the power supply is limited, making it difficult to apply for long-term missions [5,6]. By contrast, the towfish is connected to the mother ship through the towing cable and its motion is constrained; however, the observation data can be transmitted to the mother ship in real-time, and the power is supplied by the mother ship continuously, allowing real-time, long-term, and wide-area observations [7][8][9]. We are currently developing a towfish with a sonar system, and this paper deals with its attitude control to improve the quality of the sonar image.
The towfish is usually designed to be stable in movement; however, it is difficult to fully respond to unpredictable underwater environments and various operating conditions. In particular, if an interferometric synthetic aperture sonar (InSAS) with 10-times the resolution of the existing side scan sonar (SSS) is mounted onto the towfish, the irregular motion of the towfish causes distortion or defocusing of the InSAS image [10]. Thus, precise attitude control is required to improve the image quality.
In Section 2, we first describe the specifications of our target towfish. An InSAS system is mounted on the towfish, and two elevators and a single rudder are attached to the right and left horizontal wings and the vertical wing, respectively, for attitude control. In Section 3, the dynamic models of towfish and towing cable are formulated. The towing cable was modeled using the lumped-mass method [29,30]. In Section 4, we analyze how the towing point, center of gravity, and towing speed affect the pitch motion of the towfish and present a method to find a feasible region of the towing point for pitch control in accordance with the position of the center of gravity and towing speed. The allowable range of disturbances for yaw control was also discussed. The feasible region/range allows us to control the attitude much more easily with the given elevators and rudders.
Finally, to verify the feasible region obtained, simulations using the dynamics of the towfish and cable are presented in Section 5. The simulation results show that the feasible region of the towing point and the allowable range of the disturbance in yaw control are correctly selected, and there is a region/range where the attitude control can be achieved with relative ease. Figure 1 shows the target towfish, and its detailed specifications are listed in Table 1. For attitude control, two elevators and one rudder were attached to the left and right horizontal tail wings and the vertical tail wing for pitch and yaw control, respectively.   Figure 2 shows the forces acting on the towfish. Let f c ∈ R 3 be the towed force, f a ∈ R 3 be the actuator forces, such as the drag forces generated by the elevator angles δ r and δ l , and the rudder angle δ R , and f b ∈ R 6 be the force generated by the weight and buoyant force. Then, the six degree-of-freedom equations of motion of the towfish can be expressed as follows:

Dynamic Towfish Model
where ν = (u, v, w, p, q, r) T ∈ R 6 , (u, v, w) is the linear velocity of the towfish with respect to the body frame, (p, q, r) is the angular velocity, and r c , r a ∈ R 3 are the position vectors from the center of gravity to the towing point and the center of the actuators, respectively.
. Sci. Eng. 2021, 9, x FOR PEER REVIEW 3 of 22 Figure 2 shows the forces acting on the towfish. Let ∈ be the towed force, ∈ be the actuator forces, such as the drag forces generated by the elevator angles and , and the rudder angle , and ∈ be the force generated by the weight and buoyant force. Then, the six degree-of-freedom equations of motion of the towfish can be expressed as follows:

Dynamic Towfish Model
where = ( , , , , , ) ∈ , ( , , ) is the linear velocity of the towfish with respect to the body frame, ( , , ) is the angular velocity, and , ∈ are the position vectors from the center of gravity to the towing point and the center of the actuators, respectively. Assuming that the shape of the towfish is a symmetrical cylinder, , ( ) and ( ) are given as follows [31,32]: where and are the rigid-body inertia matrix and hydrodynamic added mass matrix, respectively; is the mass; ( , , ) is the position of the center of gravity; , , and are the moments of inertia; and the diagonal components of are the hydrodynamic added mass coefficients. Assuming that the shape of the towfish is a symmetrical cylinder, M, C(ν) and D(ν) are given as follows [31,32]: where M RB and M A are the rigid-body inertia matrix and hydrodynamic added mass matrix, respectively; m is the mass; (x g , y g , z g ) is the position of the center of gravity; I xx , I yy , and I zz are the moments of inertia; and the diagonal components of M A are the hydrodynamic added mass coefficients.
−m z g r + x g p m z g q + u −I zz r m x g r + v m y g r − u −m x g p + y g q I yy q −m x g q − w −m x g r + v m z g r + x g p −m y g r − u −m z g q + u m x g p + y g q I zz r −I yy q 0 where C RB (ν) and C A (ν) are the rigid-body Coriolis and centripetal matrix and the hydrodynamic Coriolis and centripetal matrix, respectively. Because the towing speed of the target towfish is not high (less than 2 m/s), nonlinear damping with a quadratic form of the towing speed can be neglected. The damping terms can then be simplified as follows [33]: where D and D n (ν) are the linear damping matrix and nonlinear damping matrix, respectively, and the diagonal components of D are negative scalar coefficients. Let a × b = S(a)b, a = (a x , a y , a z ) T , and b ∈ R 3 , where S(a) is a skew symmetric matrix and is given as follows: Then, the right side of Equation (1) can be rewritten as where (x b , y b , z b ) is the position of the center of buoyancy, and c, s, φ, and θ are the cosine function, sine function, roll angle, and pitch angle, respectively. Meanwhile, the position of the underwater towfish cannot be obtained directly using the global positioning system (GPS), as shown in Figure 3. Thus, we used the USBL system mounted on the mother ship and towfish for underwater positioning, and the attitude with respect to the body frame is obtained through the IMU. Let and η 2 = (φ, θ, ψ) T , where (x, y, z) is the position with respect to the fixed frame, and (φ, θ, ψ) are the roll, pitch, and yaw (heading) angles, respectively. The linear and angular velocities with respect to the fixed frame are given by where t represents the tangent function.

Dynamic Model of the Towing Cable
The mathematical model of the towing cable is frequently formulated using the lumped-mass method. The concept of the lumped-mass method is shown in Figure 4a. The towing cable is modeled as (n − 1) discrete masses interconnected by linear springs that do not have weight, and it is assumed that the drag force, weight, and added mass force acting on the towing cable are concentrated on each mass [34]. As shown in Figure 4a, the forces acting on the j th node (mass) consist of drag forces, tension, and weight. Let f dxj , f dyj , and f dzj be the drag forces along the x, y, and z-axes, and T j and T j−1 be the tensions at the j th node and (j + 1) th node, respectively. In addition, δ j is the weight in water, and l j is the length between the j th node and the (j + 1) th node.
In Figure 4b, xyz is the earth-fixed frame, and ξ xj ξ yj ξ zj is the body frame attached to the j th node, where the ξ xj -axis is defined as the tangential direction of the towing cable, and the ξ yj and ξ zj -axes are defined as the normal directions with respect to the ξ xj -axis; in addition, the ξ xj ξ yj ξ zj frame is determined by rotating the xyz frame by α j around the z-axis and β j around the y-axis, α j is the angle between the x − z plane and the cable formed by the j th and (j + 1) th nodes, and β j is the angle formed by the x − y plane. Therefore, the ξ xj ξ yj ξ zj frame at the j th node can be obtained by The drag forces in the tangential ( f dtj ) and normal ( f dnj ) directions can be expressed as follows: where ρ is the water density, D j is the outer diameter of the cable, C Dtj and C Dnj are the drag force coefficients, and u tj are u nj are the tangential and normal speed components, respectively. The drag force components acting on the ξ xj ξ yj ξ zj frame are given by In addition, the drag force components acting on the xyz frame are given by Next, we determine how to calculate the added mass acting on the j th node. Letting the acceleration components at the j th node be ..

x,
.. y, and .. z, the corresponding acceleration component on the ξ xj ξ yj ξ zj frame is obtained as follows [35]: where the acceleration component in the tangential direction a ξ xj is expressed by a tj and the ξ yj and ξ zj axis acceleration components in normal directions a ξ yj and a ξ j are expressed by a nj cγ j and a nj sγ j . Thus, the added mass forces f atj , f aξ yj , and f aξ zj acting on the j th node are expressed as follows: where C atj and C anj are the added mass coefficients, and A tj and A nj are the tangential and normal added mass on the j th node, respectively. The components of the added mass force on the xyz frame are then obtained by Using Equations (23) and (24), f axj is calculated as follows: f axj = −cα j cβ j A tj a tj + sα j A nj a ξ yj + cα j sβ j A nj a ξ zj , = −cα j cβ j A tj cα j cβ j ..
z, X xj , X yj , and X zj can be obtained by The mathematical model of the towing cable at the j th node can be obtained by calculating the added mass forces along the yand z-axes in the same way.
Here, the cable tension T j can be obtained by where E j is the Young's modulus of the towing cable, A j is the cross-sectional area, and l j is the length without deformation.

Feasible Region of the Towing Point for Attitude Control
The roll motion is stabilized automatically by the weight and vertical towing force; thus, we discuss the pitch and yaw control in connection with the positions of the towing point, the center of gravity, and the towing speed. Figure 5 shows the forces acting on the towfish in the x − z plane. Here, f c = ( f cx , f cz ) T is the towing force, f e = ( f ex , f ez ) T is the drag force generated by the elevators, and r c = (r cx , r cz ) T and r e = (r ex , 0) T are the position vectors from the center of gravity to the towing position and from the center of gravity to the center of the elevators, respectively. The pitching moment generated by these forces can be expressed as follows:

Feasible Towing Point for Pitch Control
here, f b5 is the fifth component in Equation (12), and ⊗ is the outer product in the plane and is calculated as follows: where E is the rotation matrix that rotates 90 • counterclockwise on a plane. When controlling the attitude of the towfish, it is difficult to secure the stability of the towfish if the center of gravity is behind the center of buoyancy. Thus, as shown in Figure 6, five cases (cases (a)-(e)) in which the position of the center of gravity is the same as that at or before the center of buoyancy are selected and discussed. In the following, it is assumed that the center of buoyancy is located at the center of the body of the towfish. In cases (a) and (b), the center of gravity is located at the center of the buoyancy. As a difference between these two cases, the towing point is located before and behind the center of gravity. Here, the effect of the restoring force term f b5 in Equation (12) can be ignored because z g = z b = x g = x b = 0. Therefore, r cx in equilibrium with the maximum elevator forces in the positive and negative directions in Equation (29) can be obtained as follows: where f + ez max and f − ez max are defined as the maximum drag forces of elevators in the positive and negative directions, respectively, and r + cx max and r − cx max are defined as the maximum towing points where the pitching moment occurs in the positive and negative directions, respectively. In addition, if the towing point is located outside of r + cx max and r − cx max , the pitch motion cannot be controlled by the drag forces of the given elevators.

When the Center of Gravity Is Before the Center of Buoyancy (Cases (c)-(e))
Cases (c)-(e) are classified according to the position of the towing point. Case (c) is the case in which the towing point is before the center of gravity, Case (d) is between the center of gravity and the center of buoyancy, and Case (e) is behind the center of buoyancy. Because the center of gravity and the center of buoyancy are at different positions, the restoring force must be considered. Assuming that the changes in the pitch and roll motions are extremely small, that is, in Equation (12) can be simplified to −x g W. Hence, the towing points in equilibrium with the maximum elevator forces in the positive and negative directions can be obtained as follows: To find the feasible region of the towing point, numerical simulations were conducted using Equations (31) and (32). In addition, f cx , f − ez max , and f + ez max were determined according to the towing speed, and other components except f cz are given by the specifications of the towfish (as illustrated in Table 1). Moreover, f cz was set to be equal to the underwater weight of the towfish, and these two forces are assumed to be in static equilibrium. The underwater weight (W − B) is 2450 N, r cz = 0.2 m, and r ex = 1.7 m if x g is at the center of body. In addition, the drag forces of the elevators were calculated using Equation (35) given in Section 5. Figure 7a shows the feasible region of the towing point when the towing speed changes from 1 to 2 m/s and x g changes from 0 to 0.5 m. The curved plane determined by the red lines (r + cx max ) contains the maximum value of r cx generating a moment in the positive direction, and the curved plane r − cx max contains the maximum value of r cx generating a moment in the negative direction. On the two curved planes, the elevators are required to exert maximum drag forces f − ez max and f + ez max for pitch control; this implies that pitch control is difficult to accomplish if r cx lies on the two curved planes. Therefore, we need to choose the value of r cx (the position of the towing point) in the area between the two curved planes to control the pitch motion more easily. Figure 7b shows the feasible regions obtained for the five cases shown in Figure 6. The feasible region for Case (c) is wider than that of other cases; in addition, cases (d) and (e) have narrow feasible regions, which means that the pitch control is difficult to achieve owing to the narrow range of f + ez max . Meanwhile, cases (a) and (b) are special cases in which x g = 0 and the range of the towing point for the pitch control is similarly assigned in the positive and negative directions. In addition, for all cases, the feasible region of the towing point widens as the towing speed increases because the drag force generated by the elevator is proportional to the square of the towing speed.

Yaw Control
The pitching moment is closely related to the positions of the center of gravity, center of buoyancy, and towing point; however, the yawing moment does not occur if there is no initial error or disturbance. In what follows, we investigate the range of the disturbance in which the yaw control can be achieved using the drag force of the rudder. Note that this discussion is based on the feasible region of the towing point described in Section 4.1.  Let f cx and f cy be the towing forces in the longitudinal and lateral directions, respectively, and f cy be regarded as a disturbance ( f dis ), that is, f cy = f dis . The yawing moment can then be given by where r rx is a vector from the center of gravity to the center of the rudder, and f b6 is the sixth component of f b in Equation (12). Assuming that the changes in the pitch and roll motions are extremely small, that is, be simplified to zero. Therefore, f dis in equilibrium with the maximum rudder force in the positive and negative directions can be obtained as follows: where f + ry max and f − ry max are defined as the maximum drag forces of the rudder in the positive and negative directions, respectively, and f + dis max and f − dis max are the maximum disturbances in the positive and negative directions, which can be handled by the rudder. Numerical simulations were conducted using Equation (34) to determine the allowable range of the magnitude of the disturbance. In addition, f − ry max and f + ry max are determined according to the towing speed, r rx is determined by the specifications of the towfish, and r + cx max and r − cx max are the values obtained in Section 4.1. If x g is at the center of the body, r rx = 1.7 m. Figure 9 shows the allowable range of the disturbance when x g = 0.3 m and the towing speed and towing point change. For reference, the allowable ranges for different values of x g are shown in Figure 10. As shown by the thick red and blue lines, the maximum drag forces of the rudder in the positive and negative directions are required for yaw control; thus, the lines indicate whether the yaw control can be conducted sufficiently. From this figure, we know that yaw control can be accomplished in the area marked with a black solid line. Similar to the pitch motion, the rudder can respond to larger disturbances as the towing speed increases.   Figure 10 shows the allowable range of the disturbance where the rudder can perform yaw control according to the changes in towing speed and towing point for each center of gravity position. The allowable range of the disturbance decreases as the position of the center of gravity moves forward; this is because if the center of gravity moves forward, the value of r cx increases, as shown in Figure 7. Thus, a smaller value of r cx is better for yaw control when the same magnitude of disturbance is applied. In addition, as shown in Figure 10a, when the center of gravity is 0 m, there are cases in which the allowable range includes negative values of r cx .

Simulation Conditions
For the simulations, the drag forces generated by the elevators and rudder are obtained as follows: where f ax , f ay , and f az are the forces exerted by the actuators (elevators and rudder) acting on the x, y, and z-axes, respectively; s H and s V are the areas of a single elevator and rudder; and ρ, u, and α are the density of the water, towing speed, and angle of attack, respectively. In addition, C D and C L are the drag and lift coefficients, respectively. The National Advisory Committee for Aeronautics (NACA) provides values of C D and C L according to the shape of the airfoil. Because the angle of attack is the same as the angle of the actuator [36], f ax , f ay , and f az are expressed as functions of the actuator angles. Letting δ r and δ l be the angles of the left and right elevators, and δ R be the rudder angle, from Equations (1) and (11), the mathematical model of the towfish can be expressed as where 0.065 and 0.11 are the slope of the drag and lift coefficients according to changes in the elevator and rudder angles, respectively, and can be linearized by referring to the values for the NACA 0018 model. In addition, the attitude controller used for this study is given by where K p _P, K d _P, and K i _P are the control gains of a proportional-integral-derivative (PID) controller used for pitch control, and θ re f and θ are the target pitch angle (reference value) and current pitch angle, respectively. In addition, K p _Y, K d _Y, and K i _Y are the control gains of the PID controller used for yaw control, and ψ re f and ψ are the reference and current yaw angles, respectively. Table 2 lists the parameter values used in the simulations. The moments of inertia I xx , I yy , and I zz were calculated from cylindrical features; X . u , Y . v , Z . w , K . p , M . q , and N . r were obtained using the specifications of the towfish, and the remaining parameters X u , Y v , Z w , K p , M q , and N r were selected through simulations.  Table 3 lists the parameter values of the towing cables. The shape of the cable can be considered as a circular cylinder, and the normal and tangential added mass coefficients C an and C at are set to 1 and zero, respectively. The tangential drag force coefficient C Dt is assumed to be extremely small and set as 0.01, and the normal drag force coefficient C Dn was determined to be 2.5 through simulations. The length of the cable L was selected as 200 m and the length between each node l without tension was set to 20 m. The control gains for pitch control K p _P, K d _P, and K i _P are chosen as 3, 5, and 0.01, respectively, and the gains for yaw control K p _Y, K d _Y, and K i _Y are 4, 5, and 0.01, respectively. In addition, the angles in the positive and negative directions of the elevators and rudder were limited to 30 • . Table 4 shows the maximum values of the towing point generating pitching moment in the positive and negative directions when the center of gravity changes and the towing speed is 1.5 m/s. For the simulation, r cx was selected as 0.35 m in Case (c) and −0.06 m in Case (e).  Figure 11 shows the simulation results for Cases (c) and (e). The actual size of the towfish is 3.5 m in length and 0.4 m in height, although the length and height were enlarged by approximately 10-fold in the figure to make it easier to understand the motion of the towfish. The synchronous elevator angle δ S is given by δ s = (δ r + δ l )/2. The reference value θ re f was changed to 0 • , −5 • , −10 • , −5 • , 0 • , and 5 • in order, and the current pitch angle tracks the reference value well; however, Case (e) has a narrow region of the towing point, as shown in Figure 7a, and a large elevator angle is required to perform the pitch control. Hence, if a disturbance is applied, it is difficult to achieve the pitch. By contrast, in Case (c), we can also observe that pitch control can be achieved with small elevator angles. Moreover, there is a large spare range of the elevator angles, which means that we can control the pitch motion sufficiently if a disturbance occurs. Figure 11. Simulation results when pitch control is applied for Cases (c) and (e). Here, δ s = (δ r + δ l )/2.

Pitch Control for Cases (c) and (e)
In addition, note that the pitch angle of the towfish changed significantly at the beginning part of the simulation because the towing cable is in a transition stage and the towing force is thus unstable at that time.

Pitch Control for Cases (c) and (e) When Disturbance Is Applied
Case (c) has a spare range and is able to respond to additional disturbances, and Case (e) was considered to have difficulty responding to additional disturbances because there was little spare range of the elevator angles. Therefore, in Section 5.3, it is shown that the elevators can handle disturbances in both cases (c) and (e). The simulation was carried out under the same conditions as in Table 4, and a pitching moment of −200 Nm was continuously applied for cases (c) and (e) as a disturbance. Figure 12 shows the simulation results when a disturbance of −200 Nm is applied in Case (c). The animation for this case is analogous to that in Figure 11 and is therefore omitted. The pitch angle can track the reference value θ re f accurately if a disturbance is applied.   From the results, we know that Case (c) is more advantageous for pitch control than Case (e) because there is enough spare range of elevator angles that can respond to unexpected disturbance. Figure 14 shows the allowable range of disturbance where the yaw control can be achieved under the same conditions as Case (c) in Table 4. The simulation was conducted by selecting points marked with a circle and triangle in the controllable and uncontrollable areas, respectively.

At the Point Marked with a Circle
In this case, the rudder can sufficiently respond to disturbances because the point is located inside the controllable area. First, to emphasize the importance of yaw control, the towfish was towed without controlling the yaw. It is assumed that a yawing moment of 200 Nm is applied continuously as a disturbance. Figure 15 shows the simulation results. For clearer understanding, the 20 m length of cable from the mother ship and the 20 m length of cable from the towfish are drawn by thick blue lines. If the yaw control is not applied (rudder angle = 0 • ), the yaw angle of the towfish varies in the form of a sine wave, and this motion can distort the image of the sonar, for example, InSAS attached to the towfish. Thus, yaw control is necessary to improve the quality of sonar images.  Figure 16 shows the simulation results when the yaw control is performed. The reference value ψ re f was set to 0 • . We can confirm that the yaw angle was controlled to 0 • ; however, the towfish moved while maintaining an offset in the y-axis direction owing to the disturbance. To address this problem, the yaw controller in Equation (37) is slightly modified as follows such that it can control the sway (the motion along the y-axis) and the yaw angle.
where y re f and y are the target and current y-axis positions, respectively, and K P _S is the control gain for sway control. The control gains K p _Y, K d _Y, K i _Y, and K p _S are chosen as 10, 5, 0.015, and 3, respectively. Figure 16 also shows the simulation results when yaw and sway control were performed. The towfish can move without an offset error in the y-axis position. Figure 17 shows the simulation results at the point marked with a triangle with a disturbance of 350 Nm. The controller in Equation (37) was used for yaw control. The triangle is located in an uncontrollable area, and the yaw angle cannot be controlled even if the maximum angle is −30 • . J. Mar. Sci. Eng. 2021, 9, x FOR PEER REVIEW 19 of 22 Figure 16 shows the simulation results when the yaw control is performed. The reference value was set to 0°. We can confirm that the yaw angle was controlled to 0°; however, the towfish moved while maintaining an offset in the -axis direction owing to the disturbance. To address this problem, the yaw controller in Equation (37) is slightly modified as follows such that it can control the sway (the motion along the -axis) and the yaw angle.

Conclusions
This paper discussed an attitude control method for a towfish with two elevators and a single rudder to improve the quality of the image of a sonar system attached to the towfish. A feasible region of the towing point for pitch control in accordance with the variations in the center of gravity and towing speed was presented, and the allowable range of disturbance for yaw control was investigated. Through simulations with the dynamics of the towfish and towing cable, it was demonstrated that the feasible region of the towing point obtained and the allowable range of the disturbance were both correctly selected, and there was a region/range where the attitude control can be applied with relative ease. The results can be summarized as follows.
(1) When the feasible towing point is located before the center of gravity, attitude control can be achieved even if disturbance is applied; (2) When the feasible towing point is located behind the center of gravity, attitude control is difficult to be accomplished sufficiently because there is small spare range of the elevator angles; (3) The yaw control is required. Otherwise, the towfish can move in the form of a sine wave if disturbance is applied consistently; (4) To track a given path accurately, sway control is required together with the yaw control.
Especially, the results (1) and (2) can be used as an index to determine the position of the towing point and the capacity of the actuators (elevators and rudder) for attitude control at the design stage and in the field. In addition, the results of this study will be applied to the towfish under development and therefore our future work involves performing experiments in the sea using the towfish.