Modified constrained adaptive formation control scheme for autonomous underwater vehicles under communication delays

: The performance of a formation control algorithm for a group of autonomous underwater vehicles (AUVs) may be degraded due to communication constraints between the leader and the follower AUVs. Moreover, as the distance between the AUVs change due to ocean waves, the delay in communication also varies. In this study, a modified constrained adaptive controller (CAC) is proposed to resolve the issue of variable-delay as well as actuator saturation. Due to the on-line reduction of the cost function, the gains of the CAC are updated at each sampling time taking into account the effects of communication delay. This improves the path-following accuracy of the leader AUV as well as follower AUVs. The effectiveness of the proposed control algorithm is demonstrated by implementing it on a prototype AUV (ODRA-I) model. The obtained simulation and experimental results show that the follower AUVs maintain a desired distance from the leader AUV to avoid a collision. For the proposed algorithm, the desired path-following performance of the follower AUV is maintained even when the delay is changed from 0 to 5 s. Moreover, the proposed control algorithm is efficient in avoiding actuator saturation.


Introduction
Owing to several interesting applications of autonomous underwater vehicles (AUVs), e.g. mapping of sea beds for monitoring and installation of pipelines, underwater survey for minerals, studying aquatic life, defence applications etc. a lot of research has been directed on their control during the past two decades. However, an AUV has non-linear, time-varying dynamics and uncertainties arise due to hydrodynamics effects and ocean currents. Hence, control of AUVs is very challenging. Various control algorithms such as adaptive control [1], robust control [2], model predictive control [3], sliding mode control [1], neurocontrol [4] etc. have been proposed for successful control of AUVs.
Most of the aforesaid applications turn out to be more economical and effective when the mission is carried out deploying a group of AUVs. In a co-operative motion plan, formation control [5] of AUVs is one of the effective co-operative control paradigms that makes the mission redundant and hence reduces the chance of mission failure. However, during formation control, the low data rate in underwater communication between the leader and the follower AUVs through acoustic modems poses a severe constraint on control design. In a decentralised leader-follower formation control approach, due to the presence of underwater network for communication, the follower AUV receives delayed leader states, which degrades the tracking performance of the follower, sometimes even making it unstable.
In [6], the communication scheme proposed minimises the inter-vehicular interaction by the selection of suitable formation approaches so as to reduce the adverse effects of delay. Similarly in [7], only position states are exchanged to reduce communication burden between the AUVs. In [8], a similar approach as [7] is used but the velocity information is estimated at every sampling interval via velocity observer. In [9,10] an event triggered intermittent communication scheme is adopted in which the follower decides the switching criterion between different modes of communication (continuous and periodic communication) for the leader. This technique also helps in reducing the communication burden. In [11], a graph theory-based approach is employed to handle the communication control issue. In [12], the communication constraints have been considered to design a robust controller based on a linearised AUV model. In [13], formation dynamics of AUVs are derived and decoupled into the dynamics of formation shape and formation centre. These couplings are treated as perturbations and a robust controller is designed to tolerate both the perturbations and the time delays. In [14], to avoid communication between AUVs, line of sight range sensor and bearing sensor are installed on AUVs so as to maintain formation without any mutual exchange of position information.
The delay in the received leader states depends on the distance between the leader and the follower AUVs and this distance is very often affected by the uncertain ocean currents. Due to this uncertainty, the various techniques for reducing the delay as mentioned in [6][7][8] can become ineffective, as even the smallest packet of states (only position) can get significantly delayed due to the increased distance. For formation control, in [9,10], a decentralised leader-follower approach has been used in which the inter-vehicular communication occurs only in case an AUV deviates from its desired path. Under the influence of ocean currents, the AUVs in formation are prone to deviation and in such situations, the delayed leader states may degrade the formation between AUVs. Though, the technique in [14] completely avoids inter-vehicular communication, but adds to the overall cost of the system as the number of sensors is increased. Moreover, in [12] the linearisation of the kinematic model for an off-line controller design may affect the real-time performance of the overall formation. Hence, in such a situation, an adaptive controller is necessitated which can adapt its gains at every sampling instant taking into account the delay to make it more effective. Also in case of co-operative control, the surge velocity of follower depends on the leader velocity. Therefore, in this paper, a leader-follower approach for co-operative control has been used. Two control schemes have been employed for kinematics and dynamics. The contributions of the paper are as follows.
• For kinematic control, a delay-based backstepping controller is designed, which takes into account error dynamics between delayed states of leader and follower AUVs. • In the previous research work [3], an adaptive controller is designed considering a constant surge velocity. However, during formation control, the surge velocity varies and hence we design a constrained self-tuning controller (CSTC) to relax the aforesaid assumption. • The proposed controller CSTC is designed to compensate for the effects of delayed leader states where the delay may vary due to the changes in distance between the leader and follower AUVs.
The paper is organised as follows. Kinematics and dynamics of AUV are described in Section 2. In Section 3, the problem statement is presented. The design of the proposed controller is described for both kinematics and dynamics which is presented in Section 4. In Section 5, simulation and experimental results with detailed analysis are presented. The paper is concluded in Section 6.

Kinematics and dynamics of AUV
A kinematic model of the leader AUV is developed in terms of Serret-Frenet (SF) frame. Consider SF frame is attached to the path as a body axis of the virtual target AUV. A similar formulation is made for the follower AUV considering leader AUV as the target vehicle. In this approach, an additional degree of freedom in terms of velocity of virtual target helps to relax the constraint [15] that the initial position error must be less than the smallest radius of curvature of the path. For heading control, the motion of AUV is studied only in the horizontal plane, hence z A/B is constant and w A/B = 0, ∀(A, B).

Kinematics of leader and follower AUVs
From Fig. 1, both the linear and angular inertial velocities of leader in terms of body frame linear (u L , v L ) and angular velocities (r L ) can be obtained as follows: Using the backward Euler rule, for a sampling time of T seconds, the discrete-time kinematics of Leader AUV can be represented as Similarly, kinematics of the follower AUV is given by

Dynamics of leader and follower AUVs
The dynamics deals with the body frame linear and angular velocity as well as acceleration. The dynamic controller design presented in this paper is identical for both leader as well as follower AUVs. This aids to simplify the representation of AUV dynamics. Thus, dropping the subscripts 'L' and 'F' from u, v and r for unification, the common continuous-time dynamics equations [16] for both the leader and follower AUVs can be written as follows: On discretising (4) by using backward Euler rule gives with . Where u, v, r are linear and angular velocities of the AUV in body frame, m represents system mass, I z represents moment of inertia w.r.t. z-axis, X…, Y… and N… represent hydrodynamic terms, F and δ r are the thruster force and rudder deflection, respectively.

Problem statement
Formation control problem between leader and follower AUVs is formulated considering the effects of delayed leader states received at the follower end.

Error coordinates for leader AUV
One of the uncertainties that an AUV is subjected to is the drift force. Due to ocean currents, waves and winds the AUV is drifted. This gives rise to side-slip angle β L (k) = arctan (v L (k))/(u L (k)) , which rotates leader AUV from the body frame {L} to wind frame {W}. When considering positive rotation of z axis by an angle β L , from (2), motion for the leader AUV can be expressed as follows: Fig. 1, consider M as an arbitrary point on the desired path. The velocity of M along the path is denoted as s M (k). Also, the angular velocity of path can be written as where c c (s M ) denotes curvature of the path. The velocity of M in The velocity of L in {O} can be computed as Equation (10) when multiplied with R O M can be written as Using (6) and (7) one can write and respectively. Also employing Euler's rule we have Substituting (8), (12), (13) and (14) in (11) and solving for x L/M (k) and y L/M (k) yields where

Error coordinates between leader and follower AUV
The reference for leader AUV is the desired path. For the follower AUV, the states of leader AUV acts as reference which are sent to the follower AUV via underwater communication medium (acoustic modem). The slow data rate of the medium incorporates network delay d(k) in communication of states which is shown in Fig. 2b. It shows that if states of the leader AUV are encapsulated as packet P and sent to the follower, the states are expected to reach the next instant. However, as a result of the delay incurred due to communication medium, leader states get delayed by d(k), when they are received by the follower AUV. In view of occurrence of the delay, the error co-ordinates between leader and follower AUV are computed. Similar to the leader AUV, the kinematics of follower AUV from (3) is written as follows: (see (17))  shown in Fig. 2a is that the follower AUV has to track the leader AUV without collision while maintaining a constant distance denoted by vector p f l = x f l , y f l from the leader AUV. Hence, from Fig. 1 Now rotation matrix R O L from frame O to L can be written as and the angular velocity of leader Also from (16) and (21) and respectively. Using Euler's rule one can write Substituting (12), (22), (23) and (24) in (19), one can write, the error-co-ordinates of the follower AUV w.r.t. leader AUV as follows: ,

Effects of communication delay
The delay info d(k) can be obtained if each packet is time-stamped when it is sent. Moreover, the clocks on both the AUVs need to be synchronised. Network time protocol can be used to synchronise the system clocks. Thus, using the time-stamp of packet P its actual delay can be calculated. If the maximum time-delay during communication is known, the follower states are stored in the memory up to that instant of maximum delay. Since packet P of states is received as for calculating consistent error equations as in (25), the correspondingly delayed follower states are used from the stored states. Thus, every state of both the leader and follower AUVs in (25) and other error equations are replaced with its delayed counterpart and these error equations with actual delay information are minimised in the cost function of the following sections.

Constrained adaptive controller design
In this paper, due to the presence of variable communication-delay in the system, an adaptive controller is designed. In the controller design, we consider the actual delay at every sampling interval and formulate the error equations (25) for the cost function. Thus, the cost function gets updated with the actual communication-delay at every sampling interval. When this cost function is minimised, the control input generated keeps the system stable while adapting to the actual delay in that interval. Fig. 3 depicts the block diagram of control structure. It comprises of a kinematic and dynamic controller. The kinematic controller takes inertial position and orientation (x(k), y(k), θ(k)) as input and computes desired linear and angular velocities. For both leader and follower, AUVs similar constrained adaptive dynamic controller is designed. The constraints in the aforesaid controller are applied to generate bounded inputs so as to prevent actuator saturation. The dynamic controller takes linear and angular velocity (u(k), v(k), r(k)) of AUVs as input and generates control input in the form of force F(k) and rudder angle δ r (k). The error equations in both controllers are consistently formed taking into account the delayed leader states and correspondingly delayed follower states.

Kinematic controller
A continuous-time counterpart of the backstepping controller in [16] has been discretised and used as a kinematic controller for the leader. For simplification, the terms involving T 2 has been neglected, as sampling time T is chosen to be small. With an objective of reducing the error-coordinates in (15) to zero, we choose a Lyapunov function as follows: Hence, if we choose ΔV can be made negative and hence asymptotically converging i.e.
Similarly, for follower AUV, to reduce the error co-ordinates in (25) to zero, the chosen Lyapunov function is Convergence of (30) can be ensured by making ΔV negative if we choose v tF (k − 1)cos θ F (k − 1) = v tL (k − 1) − r L (k − 1) and Thus, the desired velocity and approaching angle can be given by (17) and (18), respectively.

Adaptive dynamic controller
The adaptive dynamic controller proposed in this section adapts its gains at each sampling interval to control the effects of delayed leader AUV states received by the follower AUV. The error equations in this section also take into account the delayed leader and correspondingly delayed follower AUV states. Using (5), the error dynamics of heading motion is given by with u d (k) and r d (k) as desired linear and angular velocities respectively. For simplification, the desired linear velocity of leader AUV u d (k) is taken as constant. However, in the case of follower AUV since the desired forward velocity depends on the velocity of the leader, it can be obtained from (17). To reduce these heading errors a proportional control law can be written as Thus we can write (34) as Also where ψ wd (k) is the desired approaching angle which can be obtained from (28), (18) for leader and follower AUVs, respectively and β d (k) is the desired side-slip angle. β(k) can be determined from β(k) = arctan((v(k))/(u(k))) then With an objective of reducing the heading errors, a cost function is chosen as V = r e 2 (k) + u e 2 (k) + ψ e 2 (k) + β e 2 (k) Substituting the value of r e (k), u e (k), ψ e (k) and β e (k), the cost function can be represented in the form The range of K p1 and K p2 are defined based on the range of deflection angle δ r and thruster force F. For a given range of δ r and F, the practical limitation of yaw velocity can be computed and based on which Ξ r d (k) is chosen. Since, β(k) is assumed to be small, the range for Ξ β d (k) is chosen as −10°≤ Ξ β d (k) ≤ 10°. Due to the imposed constraints, the problem of actuator saturation is avoided, as K p1 , K p2 and r d (k) are always bounded as per the limits of actuators signals δ r and F. Converting the above two-sided constraints into single-side constraints we can write where and β dl are upper and lower limits of β d , r du and r dl are the upper and lower limits of r d , K p1u and K p1l are upper and lower limits of K p1 and K p2u and K p2l are upper and lower limits of K p2 . Now introducing slack variable S l , so as to convert the inequality constraints to equality constraints, i.e.
where S l ≥ 0. Thus, the optimisation problem can be re-written as sub. to AX − b + S l = 0, The Lagrangian of the above problem can be written as where λ i is the Lagrangian multiplier, f (X) = (1/2)X T SX + C T X + C f and g i (X) represents individual constraints within AX − b + S l = 0.
Solving the Lagrangian the necessary KKT (Karush Kuhn Tucker) [17] conditions can be obtained as where λ i and S li are individual components of vectors λ and S l , i = 18. To obtain the control variables, these conditions are solved using interior-point method. Optimisation toolbox MOSEK has been implemented for solving the necessary KKT conditions. Sufficient KKT condition: For sufficiency, we prove that the Hessian matrix of the Lagrange function is a positive semi-definite matrix, i.e.
Thus, to prove positive semi-definiteness of the matrix S, computing X T SX from (40) such that Since, every term in S is a square term, thus S is a positive semidefinite matrix. Hence, the sufficient condition is also satisfied, which implies solving the necessary condition, will yield result driving the system towards global minima. Hence, the system is stable.

Results and discussion
For simulation, the dynamics of AUV given in (5) are considered.
The parameter values of ODRA-I AUV are given in [18]. The kinematic controller gains are manually tuned so as to achieve faster convergence of AUVs to the desired path such that K 1 = 0.5, K δ = 1, K 11 = 0.003, K 12 = 0.1 and θ a = π/4. The desired surge velocity for a leader is constant 1 m/s, hence u d and ü d is zero. We have chosen a circular desired path given by where estimation of ϕ, [16] can be obtained from In order to avoid a collision, a constant distance to be maintained between the leader and follower AUVs is given by the desired path and the follower AUV follows the leader simultaneously maintaining the desired distance to avoid collision. When in open water, both leader as well as follower AUVs are subjected to ocean currents. This moves the AUVs apart. Hence, with the increase in the distance between the leader and follower AUVs, the delay in reception of leader states at the follower end also increases. For simulation, a maximum communication delay of 2 s is considered. For a sampling time of 0.2 s, d¯= 10, i.e. the maximum communication delay is of 10 sampling intervals. Thus, we have 0 ≤ d(k) ≤ 10. Fig. 4 shows the trajectories of leader and follower AUVs in case of proposed (follower AUV 1 and 2), robust controller [12] (follower AUV 3) as well as backstepping controller (follower AUV 4). Here, two cases of delay are considered. In the first case, the leader AUV states are received without any delay, whereas, in the second case, the maximum delay is considered. When the follower AUV receives delayed states of the leader AUV, in case of the proposed controller the follower AUV 1 follows the desired path within the accuracy of 5 cm whereas, in case of follower AUV 4, as the delay increases, the accuracy degrades with increase in time and the follower AUV 4 no longer follows the desired path. Moreover, follower AUV 3 runs a robust control algorithm in [12], thus following the desired path with accuracy. Both the proposed and robust algorithm perform well under the effects of communication delay, but in the case of follower AUV 3, the robust controller is designed with linearised kinematic model of the AUVs, hence in real-time scenarios, with the obtained gains, the desired performance may not be achieved as the kinematic model of AUV is non-linear. Fig. 5 shows the orientation of leader and follower AUVs. The transient response in case of follower AUV 4 is more oscillatory with maximum peak at 6 radians. The Tecnadynae thruster of ODRA-I AUV has a forward thrust and reverse thrust of 20 and 10 N, respectively whereas the fin deflection δ r ranges between −π/4 ≤ δ r ≤ π/4. For limiting the control input, the range of gains chosen are K p1 ≤ 1 and K p2 ≤ 6. Fig. 6 shows the force and fin deflection applied to the AUV which is bounded by the above mentioned constraints. The maximum δ r and force in case of follower AUV 1 is 0.2 radian and 1.4 N, respectively, whereas, for follower AUV 4 it is 3.8 radian and 7.5 N, respectively. Thus, both control inputs δ r and F in case of follower AUV 1 are constrained within the actuator limits, whereas, δ r in case of follower AUV 4 deviates from the specified bound resulting in actuator saturation. Based on actuator limitations, the range for the desired yaw velocity is chosen as r d (k) ≤ 1. The desired surge velocity for leader is constant 1 m/s. Figs. 7 and 8 show the surge and yaw velocities of both leader and follower AUVs. The maximum yaw velocity in case of follower AUV 1 is 0.37 rad/s which is well within the limit of 1 rad/s whereas r in case of follower AUV 4 is 4.6 rad/s. Next, the efficacy of the proposed control algorithm is tested on a prototype AUV developed in the lab as shown in Fig. 9. The prototype AUV is considered as a follower AUV. The control algorithm is developed in python on ROS (Robot Operating System) environment. For experimental validation of the proposed controller, a virtual leader AUV is developed. The desired orientation of the leader AUV is 45° for the first 9 s and then the orientation changes to 90°.
The dynamics of the Desert Star make acoustic modem is modelled to replicate the communication delay environment. The maximum data rate of the aforesaid modem is 23 bits/s. Considering (***.*,*.***) ∖n, be the packet of Leader AUV states, such that * represents the digits (total 10) of yaw angle and yaw velocity data of the leader AUV states. Every packet is wrapped under parenthesis, each data separated by a comma and every packet ends with a newline character (∖n). Thus, the size of packet is 14 bytes, i.e. 112 bits. Based on the data rate of the acoustic modem, the packet is delivered to the follower AUV in 5 s. Thus, the maximum communication-delay in the system of leader and follower AUVs is of 5 s, i.e. for a sampling time of 0.2 s, d¯= 25. Thus, 0 ≤ d(k) ≤ 25, as the number of digits in the packet might be less than 10 at certain instants (for smaller values of yaw angle and velocity). Thus in Fig. 10, the initial delay d(k) is taken to be 13, which changes to 25 when the orientation changes from 45° to 90°. Fig. 11 shows that the leader AUV maintains an orientation of 45° at the beginning which smoothly changes to 90° after 9.2 s. The figure also shows the follower AUV tracks the desired orientation. When the orientation changes from 45° to 90°, the effect of delayed leader AUV states is evident in the response of follower AUV. Fig. 12 shows the rudder angle δ r for both the leader and follower AUVs. It can be seen that the angle remains within the desired bound δ r (k) ≤ 0.785.
The yaw velocity of both the leader and follower AUVs, as shown in Fig. 13, also remains within the bound r(k) ≤ 1. The yaw velocity increases at the time of change in orientation, whereas it nearly goes to zero after about 5 s.
An Intel Atom dual-core processor is used as a platform for implementing the control algorithm. The computation time of the adaptive control algorithm is shown in Fig. 14. The sampling time (0.2 s) is larger than the computation time at every instant, thereby allowing the control algorithm to run smoothly.

Conclusions
In this paper, a co-ordinated control problem of AUVs has been developed considering communication delay between the leader and follower AUVs. From the results obtained, it is observed that the proposed optimisation based adaptive control algorithm effectively compensates for the effects of states delayed by 2 s during the simulation and 5 s during experimental validation. Despite communication delay, the follower AUVs, follow the desired path within the accuracy of 5 cm. The robust controller [12], also follows the desired path with accuracy but the linearisation of kinematics for controller design may hinder realtime applications. In case of backstepping control, the AUV no longer follows the desired path when the delay value is increased. Moreover, the proposed controller provides a bounded control action to avoid actuator saturation whereas in case of backstepping controller both δ r and r cause actuator saturation.