1 Introduction

With the increasing complexity of underwater tasks, multiple Autonomous Underwater Vehicle (AUV) systems have become a hot topic. The multi-AUV system collaborates between multiple AUVs instead of a simple superposition of a single AUV [1, 2]. Multiple AUVs' task planning and collaboration control have been reported to occupy a large proportion of the underwater task [3]. Task planning and collaboration control play a vital role in developing underwater robots. As shown in Fig. 1, the underwater robots are randomly distributed at first. Subsequently, the underwater robots form the desired formation to surround a target, such as a fish. Maintaining formation while moving along the desired path and adapting to environmental constraints, such as obstacles, limited space, ocean current, and communication constraints, is required.

Fig. 1
figure 1

Underwater target detection of multiple spherical underwater robots

The task planning and collaboration control of multi-AUV systems have received considerable attention from researchers worldwide in recent years. Several methods, such as behavior-based methods, reinforcement learning control methods, and the leader–follower method, have been reported. Clear feedback to achieve various behavioral functions are the advantages of behavior-based methods [4, 5]; its shortcoming is that the fuzzy definition of behavior rules increases the risk of system instability. The method based on reinforcement learning control was presented by [6,7,8]. This method embodies adaptive control under an enhanced signal rather than supervised control. However, the control process is lengthy. There is also a collaborative control method called the leader–follower method [9,10,11,12]. In the leader–follower method, the leader controls the movement of the entire agent system. The agent's behavior as the whole group can be maintained only by a given trajectory, which significantly simplifies the control system [1, 13]. The leader–follower method is a widely used framework for robot collaboration control [14,15,16,17]. Nevertheless, the leader in the system exhibits wrong behavior, the followers will also exhibit incorrect behavior, and then the entire system will collapse. For example, when the scale of the system is too large, the tremendous amount of information is a significant burden on the robot; this affects the system's efficiency and can even paralyze it.

In our previous research, we designed the Fourth-generation Spherical Underwater Robot (SUR IV). The diameter of the SUR IV is 600 mm. A waterproof box is placed in the center of the robot. The SUR IV with hybrid propulsion devices realizes fast switching between movement speeds. A collaboration controller based on the leader–follower frame for SUR IVs is proposed in this paper. The first contribution of this paper is autonomous control for the multi-robot control system. Compared with the traditional leader–follower framework, each SUR is a leader or follower of a formation depending on the controller, unless specified manually. The formation can continue to work despite the failure of a specific SUR. In the proposed collaboration strategy, an integral sliding mode controller is introduced. This controller can drive the leader and follower SURs to the desired formation while tracking the reference trajectory. Due to the particularity of the underwater environment, there is a delay in transmitting information between underwater machines. This strategy accentuates reducing the info transmitted between each SUR. During formation tracking, all SURs track the leader by the longitudinal controller and the heading controller of the formation. The proposed method provides better communication efficiency. This constitutes the second contribution of this study.

The rest of the paper is organized as follows. Section 2 introduces the system overview of the multiple spherical underwater robots. The collaboration controller is proposed in this paper, and the simulation results are introduced in Sect. 3. Underwater evaluation experiments of the multiple spherical underwater robot collaborative control are presented in Sect. 4. Finally, Sect. 5 concludes this paper.

2 System Overview of the Multiple Spherical Underwater Robots

2.1 Inspiration for Design of SUR IV

SUR's movement mechanism uses a hybrid propulsion system is composed of a propeller and a water-jet thruster. The design of the water-jet thruster was inspired by the propulsion mechanism of jellyfish. The natural jellyfish generates propulsion through the constant compression and deformation of the body's umbrella membrane. Ninety-five percent of the jellyfish's body is water, and the reflection of the water spray in the body is used to achieve movement. Most jellyfish have three main parts: a round umbrella or bell-shaped body, tentacles, and mouth and wrist. There are some particular muscles under the bell-shaped body of the jellyfish that can expand and then contract quickly, expelling the water from the body. By spraying water, the jellyfish can swim in the opposite direction. Some jellyfish have a cortex that shrinks the bell-shaped body, allowing the jellyfish to move quickly. The inner cavity expands, the water flow is slowly sucked in, filling the internal niche; the inner hole shrinks rapidly, pushing the water flow out of the crater. The thrust generated by the water flow ejects the jellyfish along the body axis [18]. As shown in Fig. 2, the jellyfish creates areas with different pressure levels around the body and then moves from high to low pressure. The diagram is presented in a longitudinal section, and you can see that the vortex (blue) is like two water wheels. The jellyfish contracts, higher pressure is generated on the inside of the bell-shaped body, and the body is pulled to a lower pressure direction and advances. By bending the edges of the bell-shaped body, the jellyfish causes the vortex to roll down below the body. These vortices push up the water as they rotate and also give thrust to the jellyfish. The movement of jellyfish is one of the most efficient. SUR aims to imitate the efficient movement of jellyfish and its advantages in symmetry, stability, and performance.

Fig. 2
figure 2

Propulsion mechanism of the Jellyfish

2.2 Problem Statement

A collaboration example (triangular) with the randomly distributed SURs is depicted, as shown in Fig. 3. For the convenience of explanation, we use three SURs. All the randomly distributed robots move to their desired position in the formation. The simulation process is more easily explained with the small group SURs in detail. During the collaboration control process, the position of the SURs is limited by the algorithm. After composing the desired shape, the robot will maintain the original form without transformation unless disturbed. Note that SUR IV is an underactuated system that cannot automatically maintain a fixed position in space. Therefore, our control objective is to obtain the desired formation and retain it as the SUR IVs move to their destination.

Fig. 3
figure 3

A triangular formation example collaboration control strategy with the randomly distributed SURs

2.3 The Control and Communication System of Multi-SUR IVs

Here, we first introduce the control and communication system of the SUR IV. Figure 4 shows the prototype of the SUR IV. A detailed description of the robot can be found in Ref. [19, 20]. The hardware structure of the SUR IV is shown in Fig. 5. The SUR IV is equipped with sensors for environmental perception, including a depth sensor, a high precision 9-DOF Inertial Measurement Unit (IMU), and a Micron Data Modem as the acoustic communication module [21,22,23]. Arduino Mega 2560 is selected as the central controller and uses the serial I2C bus to communicate with the IMU sensors, which obtain the location information and velocity information of the SURs underwater [24,25,26]. The depth sensor can receive the depth information of the underwater robots. As for the Global Positioning System (GPS) is used to obtain the initial position of the robot. The positioning system of the underwater robots consists of the IMU sensor, the depth sensor, and the GPS sensor. By processing the information obtained from sensors, the position and orientation of SURs can be obtained, thus enabling to realize the localization of the SUR. The position of robots is determined by obtaining the information of heading navigation and depth control. The initial position of the robot is initialized using the last known position before the robot starts moving. By fusing data from the onboard IMU sensor through complementary filters, the posture and acceleration of the SUR are estimated. The angular velocity information output by the IMU is used to obtain the attitude information of the robot by integrating the angular velocity information. The relative depth information of the robot that obtained by the depth sensor. And then, the attitude information is used to convert the specific force output from the accelerometer to the body coordinate system to the navigation coordinate system. Finally, the relative velocity and position information are obtained by integrating the acceleration information. Therefore, the displacement from the initial position to the current position can be obtained by the sensor and thus realize the positioning of the robot. Since IMU is susceptible to the effect of duration, we have corrected the IMU to improve the accuracy of it in previous research [27].

Fig. 4
figure 4

The prototype of the SUR IV

Fig. 5
figure 5

The hardware structure of the SUR IV

To realize communication control between multiple SURs, this study uses an acoustic communication module that can recognize two-way communication and has a long communication distance and a strong transmission signal. The Micron Data Modem as the communication module of the whole system enables multiple robots to communicate with each other. Table 1 lists the technical specifications of the acoustic communication module. A dedicated bracket is used to install the Micron Data Modem at the bottom of SURs. The Modem is suitable for our SUR has been verified confirmed and can be used for acoustic communication to realize signal communication between robots [28, 29].

Table 1 The technical specification of the acoustic communication module

2.4 Principle of Multi-SUR IVs System

Following the underwater modeling methods in Ref. [30] to clearly describe the reference of a SUR, the navigation frame (E-frame) and the body frame (B-frame) are shown in Fig. 6. The body reference frame is attached to the vehicle, with the origin selected to be the center of gravity x, y, and z are the coordinate positions, and \(\omega\), \(\theta\), and \(\varphi\) are the Euler angles of the roll (along the x- axis), pitch (along the y- axis), and yaw (along the z- axis), respectively. SUR IV is a six-degree-of-freedom motion carrier in space [20], the mathematical model of SUR IV in the coordinate system as following

$$\left\{ {\begin{array}{*{20}c} {\dot{x} = \cos \left( \varphi \right)u - \sin \left( \varphi \right)v,} \\ {\dot{y} = \sin \left( \varphi \right)u - \cos \left( \varphi \right)v,} \\ {\dot{\varphi } = r,} \\ {\dot{u} = \frac{{m_{{22}} }}{{m_{{11}} }}vr - \frac{{m_{{11}} }}{{m_{{11}} }}u + \frac{{\tau _{u} + \tau _{{w1}} }}{{m_{{11}} }},} \\ {\dot{v} = - \frac{{m_{{11}} }}{{m_{{22}} }} - \frac{{d_{{22}} }}{{m_{{22}} }}v + \frac{{\tau _{{w2}} }}{{m_{{22}} }},} \\ {\dot{r} = \frac{{m_{{11}} - m_{{22}} }}{{m_{{33}} }}vr - \frac{{d_{{33}} }}{{m_{{33}} }}r + \frac{{\tau _{r} + \tau _{{w3}} }}{{m_{{33}} }},} \\ \end{array} } \right.$$
(1)

where x and y are the longitudinal position vector and the horizontal position vector of the SUR. \(\tau\) u and \(\tau\) r is the vectors of forces in x- and y-. mii and dii is the hydrodynamic parameters of SUR. u, v, and r are longitudinal velocity, lateral velocity, and heading angular, respectively. \(\tau\) w1, \(\tau\) w2 and \(\tau\) w3 are external interference forces or torques. According to the mathematical model of the SUR, the integral sliding mode control rate is designed to drive the SUR so that it can reach the desired position or move on the desired path at the desired velocity. Through the real-time information of attitude and position between the virtual follower robot Rv and its follower robot Rf, the error equation of the collaboration strategy is obtained. The reference coordinate system of SURs collaboration strategy can be obtained from Fig. 7. It shows the relationship between the virtual follower robot Rv and its follower robot Rf. According to the error equations obtained, a response collaboration strategy is designed. The design steps of the specific strategy will be explained in detail in Chapter 3. The virtual leader robot and the follower robot are randomly assigned. Each follower robot will have at least one virtual leader robot to ensure the fault tolerance of the entire system.

Fig. 6
figure 6

The reference coordinate system

Fig. 7
figure 7

The coordinate system of SURs collaboration control

3 Collaboration Strategy of Multi-SURs System

3.1 Design of the Collaboration Controller

The purpose of the controller design is to drive the robot according to the mathematical model of the SUR so that it can reach its desired position or move on the desired path at the desired velocity. The proposed control structure is illustrated in Fig. 8. The complex nonlinear system is gradually decomposed into multiple subsystems by adopting the design idea of gradual recursion, and then for each subsystem, we separately design functions and control variables. We reverse the entire system until the control law design of the closed-loop control system is completed. The Lyapunov analysis is employed to design the final control law. The whole system model of a SUR is as follows:

$$\eta = f\left( \eta \right) + g\left( \eta \right)\zeta ,~~\xi = V,$$
(2)
Fig. 8
figure 8

Control structure of SURs collaboration control

Here, \(\left[ {\eta ^{T} ,\xi ^{T} } \right] \in R^{{N + 1}}\) are the state variables of the system, and \(V \in R\) are the input variables of the system. The functions \(f\left( \eta \right)\) and \(g\left( \eta \right)\) are smooth. According to the desired trajectory, the desired state values of the yaw of SUR can be obtained as follows:

$$\varphi _{d} = arc\tan \left( {\frac{{\dot{y}_{d} }}{{\dot{x}_{d} }}} \right),$$
(3)

where xd and yd are the desired vertical position vector and horizontal position vector, respectively, of the SUR. We define the error variable, xe, ye and \(\varphi\) e, and combine them with the error differential equation:

$$\left\{ {\begin{array}{*{20}c} {\mathop {x_{e} }\limits^{} = u - u_{d} \cos \left( {\varphi _{e} } \right) + ry_{e} ,} \\ {\mathop {y_{e} }\limits^{} = v + u_{d} \sin \left( {\varphi _{e} } \right) - rx_{e} ,} \\ {\mathop {\varphi _{e} }\limits^{} = r - r_{d} ,} \\ \end{array} } \right.$$
(4)

where \(u_{d} = \sqrt {\dot{x}_{d} ^{2} + \dot{y}_{d} ^{2} }\), u is the linear velocity in the x- and r is the angular velocity around the z- axis. rd is the desired angular velocity around the z- axis.

Consider Eq. (4), we select the Lyapunov function

$$V_{1} = \frac{1}{2}\left( {x_{e} ^{2} + y_{e} ^{2} } \right)$$
(5)

Taking the derivative of Eq. (6) and combining it with Eq. (5), we can get

$$\dot{V}_{1} = x_{e} \left( {u - u_{d} cos\varphi _{e} } \right) + y_{e} \left( {v + u_{d} sin\varphi _{e} } \right)$$
(6)

Define the variable of the longitudinal velocity \(\alpha\) u and the yaw angle \(\alpha\) r as follows,

$$\alpha _{u} = u_{d} \cos \left( {\varphi _{e} } \right) - k_{x} x_{e} - \delta _{{ye}} ,$$
(7)
$$\alpha _{r} = r_{d} - u_{d} y_{e} - k_{\varphi } \sin \left( {\varphi _{e} } \right),$$
(8)

where \(\delta _{{ye}} = \frac{{sgnx_{e} }}{{e_{p} + \left| {x_{e} } \right|}}k_{y} \left| {y_{e} } \right|\). kx, ky and \({\mathrm{k}}_{\varphi }\) are the constant. ep is a positive constant tending to zero. Substitute Eq. (7) into Eq. (6) to obtain

$$\mathop {V_{1} }\limits^{} = x_{e} \left( {u_{e} - k_{x} x_{e} - \frac{{sgnx_{e} }}{{e_{p} + \left| {x_{e} } \right|}}k_{y} \left| {y_{e} } \right|} \right) + y_{e} \left( {v + u_{d} sin\varphi _{e} } \right)$$
(9)

where \(u_{e} = u - \alpha _{u}\). Based on Eq. (5), the Lyapunov function is designed

$$V_{2} = \frac{1}{2}\varphi _{e} ^{2}$$
(10)

Take the derivative of Eq. (10) and combine with Eq. (5) to obtain

$$\dot{V}_{2} = \varphi _{e} \dot{\varphi }_{e} = \varphi _{e} \left( {r - r_{d} } \right)$$
(11)

Assuming that \(\alpha _{r} = r_{d} - u_{d} y_{e} - k_{\varphi } \sin \left( {\varphi _{e} } \right)\), where \({\mathrm{k}}_{\varphi }\) is the constant. By substituting Eq. (12) into Eq. (10) to obtain

$$\mathop {V_{2} }\limits^{} = \varphi _{e} \mathop {\varphi _{e} }\limits^{} = \varphi _{e} \left( {u_{r} - u_{d} y_{e} - k_{\varphi } sin\varphi _{e} } \right)$$
(12)

where \(u_{r} = r - \alpha _{r}\). The integral sliding mode controller makes the whole system in the sliding stage by obtaining a suitable position, which ensures the robustness of the system and avoids the shortcomings of the approaching stage of the ordinary sliding mode controller. Integral sliding mode surface is designed based on the error variable ue. The integral sliding surface is defined as

$$s_{1} = u_{e} + \int u_{e}$$
(13)

The Lyapunov function is designed based on (13)

$$V_{3} = \frac{1}{2}m_{{11}} s_{1} ^{2}$$
(14)

where m11 is the hydrodynamic parameter of the underwater robot. Take the derivative of Eq. (14), and substitute the Eq. (1), thus we can get

$$\mathop {V_{3} }\limits^{} = m_{{11}} s_{1} \mathop {s_{1} }\limits^{} = m_{{11}} s_{1} \left( {\dot{u} - \mathop {\alpha _{u} }\limits^{} + u_{e} } \right) = s_{1} \left( {m_{{22}} ur - d_{{11}} u + \tau _{u} - m_{{11}} \alpha _{u} + m_{{11}} u_{e} } \right)$$
(15)

where m22 and d11 is the hydrodynamic parameter of the underwater robot. \(\tau\)u is the thrust of the robot in the x-. If this control law \(\tau\)u from Eq. (1) is given as

$$\tau _{u} = - m_{{22}} vr + d_{{11}} u - m_{{11}} \lambda _{1} u_{e} - \varepsilon _{1} sgn\left( {s_{1} } \right)$$
(16)

where \(\lambda\)1 and \(\varepsilon\)1 is the constant. Substitute Eq. (16) into Eq. (15) to obtain

$$\mathop {V_{3} }\limits^{} = s_{1} \left( {m_{{22}} vr - d_{{11}} u - m_{{22}} vr + d_{{11}} u - m_{{11}} \lambda _{1} u_{e} - \varepsilon _{1} sgn\left( {s_{1} } \right) - m_{{11}} \mathop {\alpha _{u} }\limits^{} + m_{{11}} u_{e} } \right) = s_{1} \left( {m_{{11}} \left( {1 - \lambda _{1} } \right)u_{e} - \varepsilon _{1} sgn\left( {s_{1} } \right) - m_{{11}} \mathop {\alpha _{u} }\limits^{} } \right)$$
(17)

Integral sliding mode surface is designed based on the error variable re. The integral sliding mode surface can be represented as

$$s_{2} = r_{e} + \int r_{e} ~$$
(18)

The Lyapunov function is designed based on Eq. (18)

$$V_{4} = \frac{1}{2}m_{{33}} s_{2} ^{2}$$
(19)

where m33 is the hydrodynamic parameter of the underwater robot. Taking the derivative of Eq. (19) and with the mathematical model results in

$$\mathop {V_{4} }\limits^{} = m_{{33}} s_{2} \mathop {s_{2} }\limits^{} = m_{{33}} s_{2} \left( {\mathop {r_{2} }\limits^{} - \mathop {\alpha _{r} }\limits^{} + u_{r} } \right) = s_{2} \left( {\left( {m_{{11}} - m_{{22}} } \right)uv - d_{{33}} r + \tau _{r} - m_{{33}} \mathop {\alpha _{r} }\limits^{} + m_{{33}} u} \right)$$
(20)

where d33 is the hydrodynamic parameter of the underwater robot and \(\tau\)r is the thrust of the robot in the y-. If this control law \(\tau\)r from Eq. (1) is given as

$$\tau _{r} = - \left( {m_{{11}} - m_{{22}} } \right)uv + d_{{33}} r - m_{{33}} \lambda _{2} u_{r} - \varepsilon _{2} sgn\left( {s_{2} } \right)$$
(21)

where \(\lambda\)2 and \(\varepsilon\)2 is the constant. Substitute Eq. (21) into Eq. (20) to obtain

$$\mathop {V_{4} }\limits^{} = s_{2} \left( {m_{{33}} \left( {1 - \lambda _{2} } \right)u_{r} - \varepsilon _{2} sgn\left( {s_{2} } \right) - m_{{33}} \mathop {\alpha _{r} }\limits^{} } \right)$$
(22)

Taking the summarize of the Lyapunov function of Eq. (9), Eq. (12), Eq. (17) and Eq. (22), the total Lyapunov function

$$\mathop {V_{5} }\limits^{} = \mathop {V_{1} }\limits^{} + \mathop {V_{2} }\limits^{} + \mathop {V_{3} }\limits^{} + \mathop {V_{4} }\limits^{} \le - k_{x} x_{e} ^{2} - k_{\psi } \psi _{e} ^{2} - \varepsilon _{1} \left| {s_{1} } \right| - \varepsilon _{2} \left| {s_{2} } \right| \le 0$$
(23)

Considering the horizontal plane model formula and control law Eqs. (16) and (21) of the underwater vehicle, the desired trajectory can be guaranteed to be tracked eventually. The follower robot controller is similar to the virtual leader robot controller, and the control law of the follower robot is Eqs. (16) and (21). The controller executes a loop until all the points in the formation are reached by a SUR. To achieve the task and collaboration control of SUR, we present Algorithm 1. We make use of the simple but efficient Ant Colony Optimization (ACO) to generate the shortest path [31, 32].

3.2 Simulation Results

In this subsection, we demonstrate the effectiveness of the proposed controller. Simulations are carried out with several SURs randomly distributed at the initial state. In the simulation verification, it is necessary to know the hydrodynamic parameters of the robot. In our previous research [20], the spherical underwater robot was analyzed in detail. The hydrodynamic parameters of the spherical underwater robot are as follows:

$$m = 6.9~kg,~M_{A} = \left[ {\begin{array}{*{20}c} {16.75} & 0 & 0 \\ 0 & {16.75} & 0 \\ 0 & 0 & {0.3864} \\ \end{array} } \right],v_{x} = v_{y} = 0.15m/s,~C_{1} = 1 \times 10^{{ - 4}} ,R_{e} = 6 \times 10^{4} ,C_{d} = 0.4.$$

where m is the MA is the mass of a fluid sphere. vx, vy are the maximum velocity in surge motion of the SUR. C1 is the linear viscous coefficient, Re is the Reynolds number and Cd is the drag coefficient. Parameters are modified during our simulation to obtain the best effects. The shortest path of the whole formation is generated by the ACO method. The parameters of the controller are as follows:

$$k_{x} = k_{y} = 5,~k_{\varphi } = 15,~e = 0.001,~\theta = \frac{1}{4}\pi .$$

First, we performed three randomly distributed SUR cases, and these SURs formed the desired equilateral triangle and kept the formation moving to the target point. The target point parameters of the virtual leader are (0, 0) (0, 100) (100, 100) (100, 0) (0, 0) polyline segments. In the expected formation, where the virtual navigator is located at the vertex, the two followers form the base; the base length is 50 cm. In real-world tasks, the desired path is generated by the ACO path planning algorithms. At the starting point in this task, a group of 3 SURs is randomly distributed in two-dimensional space. The algorithm produces the triangular formation. Then the triangular formation as a whole and moves along the desired path. In the initial state, there has an error between the underwater robots and their expected position in the formation; however, under the designed controller, the follower can quickly reach its desired position, and all SURs can maintain the formation during subsequent movement. The center of the formation passes through the three target points in turn, and it returns to the starting point. The whole process is illustrated in Fig. 9a, and the tracking error is shown in Fig. 9b. The counterclockwise direction is shown in Fig. 10.

Fig. 9
figure 9

Diagram of the proposed controller for 3 SURs collaboration in clockwise movement

Fig. 10
figure 10

Diagram of the tracking errors for 3 SURs collaboration in a counterclockwise movement

In real marine environments, collaborative tasks of underwater robots require the different shapes of the formation depending on the underwater task. For example, for a wide range of search tasks in a wide waterway, a linear formation is more appropriate than a triangular formation. In the linear formation task, a set of three SURs are randomly distributed in two dimensions at the starting point of the task, as in the triangular formation task. The linear formation then moves as a whole and along the desired path. Here, the target points of the linear formation are the same as those of the triangular formation. Similarly, with the controller designed in this paper, the three SURs move from random positions to the desired position of the formation, and all SURs can maintain the linear formation in subsequent movements. The center of the formation passes through the three target points in turn and finally returns to the starting point. The whole process is shown in Fig. 11.

Fig. 11
figure 11

The trajectory of 3 SURs in the line formation

At present, in actual practice, due to the high cost of underwater vehicles, there are usually less than 10 in the group. The current underwater tasks are becoming more and more complex. It is also significant to study the collaborative control of large SUR teams as the cost of underwater vehicles decreases. We also carried out a large group of SURs for explanations. For the convenience of description, we select 15 robots for the report. Table 2 compares the results of the proposed and traditional methods. From Table 2 that the proposed method in this paper, a shorter formation time and travel length. From the result, the advantage of a large swarm of SURs is more significant in the proposed form. The whole process for a 15 SUR team is illustrated in Fig. 12a, and the tracking error is presented in Fig. 12b. After completing the turning movement, the formation resumed its triangular shape. During the forward motion, the formation remained intact, and the simulation effect was good.

Table 2 Comparison results
Fig. 12
figure 12

Diagram of the proposed controller for 15 SURs collaboration control

Fault tolerance is an essential characteristic for multiple SUR task planning and collaboration. In the traditional leader–follower method, the whole group of underwater robots will stop working when the leader of the robot is broken. The proposed method in this paper solves this problem. In a large SUR team, only this broken SUR is deleted from the formation, and the remaining SURs can still work typically under this collaborative strategy proposed in this paper. To verify the fault tolerance of the controller proposed in this paper, we conducted experiments with the different numbers of robots and different formation shapes for the same path. First, we performed experiments with eight robots in a linear formation. We assume that one SUR malfunction during the execution of the task, as shown in Fig. 13. The broken SUR is the follower of one leader robot, and at the same time, is also the leader of the other two SURs. Note that this SUR has randomly happened. The group of SURs could continue to move despite the broken of a single SUR. It can be found in Fig. 13, in the examples of 8 SURs, the robots that stop moving exclusions, the formation can continue to move according to the desired trajectory, and the shape of the formation does not change. To further demonstrate the fault tolerance of the controller proposed in this paper, we changed the formation shape to a triangle formation with 15 robots. The experimental results are shown in Fig. 14, where a random SUR fails, and the formation can continue to move according to the desired trajectory, and the shape of the formation does not change. The faulty robot was excluded from the formation. Thus, the fault tolerance of the controller is verified.

Fig. 13
figure 13

Fault tolerance based on the collaboration control with the line formation

Fig. 14
figure 14

Fault tolerance based on the collaboration control with the triangle formation

4 Experimental Evaluation

To evaluate the formation control strategy for spherical underwater robots, we conduct several surfaces of water experiments. An experimental environment, shown in Fig. 15, contains a water pool, four markers, and a ruler. The underwater experiments are completed in a swimming pool 25 m × 11 m × 1.1 m (length × width × depth). The pool tile specifications are 0.23 m in length and 0.1 m in width. The experiments are divided into the following: trajectory tracking experiment with a single robot, collaboration localization experiment with multiple robots, and collaborative movement experiment with multiple robots. The state information of the SUR, which includes the position, surge velocity, and yaw velocity, is crucial for developing the collaboration control algorithm. The position, surge velocity, and yaw velocity of the SUR are measured using a high-precision IMU and depth sensor mounted on the robot. The real-time localization system is achieved using the integral method and use Kalman filter for filtering. Based on the position information and the yaw information at each sampling time, the difference method computed the surge velocity and yaw velocity. This paper takes the triangular formation as an example for analysis, and the experiment was repeated more than five times.

Fig. 15
figure 15

Experiment setup for SUR

4.1 Trajectory Tracking Experiment of the Single Robot

In this experiment, the SUR IV moves in the pool using two opposing water jet thrusters at 0.1 m/s. Here, we track the desired square-shaped trajectory. The target point parameters of the underwater robot are, respectively (0, 0), P1 (0, 100), P2 (100, 100), P3 (100, 0), (0, 0). The rectangle trajectory tracking experiment from 0 to 72 s is shown in Fig. 16; the total distance moved t is 8 m, and the red line indicates the desired trajectory. Figure 16b shows the experimental result of the single underwater robot trajectory tracking. The solid line is the desired trajectory, and the dotted line is the controller response. The yellow line is the clockwise trajectory and the moving direction of start point → P1 → P2 → P3 → start point.

Fig. 16
figure 16

Experiment of the tracking trajectory for a SUR

The green line is the counterclockwise trajectory and the moving direction of start point → P3 → P2 → P1 → start point. It can be observed that the strategy proposed in this paper can keep the robot on the desired course. During tracking, the yaw angle of the robot exhibits three sudden changes, whereas the x and y positions are continuous, even at three corners. When the yaw angle of the robot changes suddenly, the controller drives the robot to reach the desired state as quickly as possible. The following maximum error of the position is less than 15 cm (1/4 of the diameter of the robot).

4.2 Collaboration Localization Experiment of Multi-robots

To maximize the use of the overall strength of the SUR team, reducing the workload of each robot is necessary. Workload control mainly depends on the actual moving length of the robot. Under this workload balance strategy, the total travel distance of each robot when reaching the preset target point in the formation is the shortest by judging the distance between the preset target point and each. At first, the robot occupies a random position. When the robots are instructed to enter a formation, the three robots move to their assigned points by using the shortest path. The whole process of the experiment, as shown in Fig. 17.

Fig. 17
figure 17

Video snapshots of the SURs collaboration localization control

4.3 Collaboration Movement Experiment of Multi-robots

The third experiment involves formation tracking with multiple robots. We set 3 target points as P1 [150,0], P2 [150,100], and P3 [100,0]. Due to the pool’s depth limitation in the experimental condition, we mainly show the robot’s horizontal motion performance. The three robots (Robot 1, Robot 2, and Robot 3), as an example, conducted the collaboration control experiment. The three robots should maintain the initial shape of the robot during the movement, and the center point of the formation shape formed by the robots should pass through the target point in turn and return to the initial point.

First, we conducted clockwise experiments and the moving direction is start point → P1 → P2 → P3 → start point. Figure 18 shows the clockwise experimental results. The total distance moved is 5 m, and the purple line is the desired trajectory of the center of the formation. The trajectory of the SURs for collaboration control is shown in Fig. 19a. We record the position information of the three robots every 5 s. At the starting place, the multi-SUR system constructs the desired triangular formation, and the whole formation moves along the desired shortest path. The same collaboration control is applied at the corner position. The formation moves to the next target point after the multi-SUR system at the corner. In another word, the proposed controller has the ability to avoid obstacles while maintaining formation. The tracking errors are shown in Fig. 19b, c. The convergence of the trajectory tracking error is similar to the overall fluctuation presented in Fig. 9b. Still, the overall error is some differences due to the influence of water flow interference and swimming pool size on the robot’s movement. The robot maintains the formation shape like the initial during forwarding movement. The yaw angle of the robot exhibits three sudden changes at the three corners, impacting its x- axis and y- axis positions. The total tracking error is less than 10 cm and 11 cm in the x- axis and y- axis, respectively. We also conducted counterclockwise experiments. The counterclockwise experimental results as shown in Fig. 20 and the moving direction is start point → P3 → P2 → P1 → start point. The total tracking error is less than 10 cm and 12 cm in the x- axis and y- axis, respectively, which further validates the effectiveness of the collaboration control algorithm proposed in this paper.

Fig. 18
figure 18

Video snapshots of the SURs collaboration control

Fig. 19
figure 19

The experiments result of the SURs for collaboration control in clockwise movement

Fig. 20
figure 20

The experiments result of the SURs for collaboration control in a counterclockwise movement

5 Discussion

Underwater robots are beneficial for underwater research and exploration in different fields. The spherical shape allows the robot to make flexible turns underwater, even in narrow spaces. Nevertheless, the scope and ability of a single underwater robot are limited, and it is necessary to realize the collaboration tasks of underwater robots. Based on this situation, a multi-underwater robot control strategy based on a leader–follower scheme was proposed in this paper. Simulations and underwater experiments are carried out to demonstrate the feasibility of this collaboration between multiple spherical underwater robots. The simulation results of collaboration control were able to drive the robot to the desired path and maintain the initial formation according to the requirements of the task.

The progress of the collaboration control experiment and the trajectory of the SURs showed in Figs. 18 and 19a, respectively. According to the analysis of the experimental results above, the improved leader–follower scheme-based collaboration controller can make the multiple SURs move along the desired path and maintain the initial formation shape. For the measurement standard description, the center point of the formation is taken as the measurement standard to reach the target point. In addition, the center point of the formation travels to the desired trajectory. Figure 19b, c show the tracking error in x- and y- of the SURs for collaboration control, respectively, in a clockwise movement. The error in the initial position and corner motion is the largest. In the initial position and corner position, the stability of the coordinated control is destroyed, the position state does not meet the expected formation shape, and real-time adjustment is required. And even though we have calibrated the sensor, there are still some errors. On the one hand, these state errors of the robot mainly originate from the localization algorithm and the sensors. In our previous research, the error evaluated of distance that the total length is 250 cm is d = 3.52 cm \(\pm\) 1.2 cm and φ = 2.36 \(\pm\) 0.96 as the error estimated of yaw angle. On the other hand, we choose the hybrid thrusters as the drive device. The thrusters have minor differences, in which different thrusts are outputted under the same PWM signal. In addition, because the target point is too close to the swimming pool boundary, it will also affect the practical effect. The maximum error of the actual trajectory and the desired trajectory in the underwater experiment is less than 12 cm. In general, these errors are acceptable relative to the size of the SUR.

A comparison experiment result that verifies the advantages of the proposed method is shown in Table 3. The SUR formed the same initial formation(triangle) and reached the same target points using the proposed controller and the traditional controller. The comparison experiment is only conducted in the direction of clockwise movement, as an example. The proposed controller has a significate improvement in tracking errors. At the corner, the tracking error based on the traditional controller deviates from the desired trajectory more seriously than the proposed controller. The lack of stability constraints is the main reason for the above results. Meanwhile, the proposed controller performs well and stably in the traveling time and the traveling length. Although there are some errors in the corners during the formation movement, robots can converge to the desired shape and trajectory during the linear motion.

Table 3 Comparison results

In this paper, the underwater experiments were carried out in an outdoor swimming pool. Due to restrictions on the size of the swimming pool, the SUR is subject to an external disturbance of the reflective waves that the swimming pool boundary. Thus, a collaboration controller with the ability to reject an external disorder will be designed in the future. In addition, a series of field experiments will be conducted to verify the robustness and autonomy of the robot control system. In general, the scope and ability of a single underwater robot are limited, and it is necessary to multiply underwater robot collaboration for many further underwater complex tasks. We can add more underwater robots to adapt to complex aquatic environments and perform specific tasks in the future.

6 Conclusion

In this study, a multi-underwater robot controller based on a leader–follower frame is proposed for a collaboration control for multiple under-driven SUR IVs, improving the automatic capability of the biomimetic spherical underwater robot. In the proposed collaboration controller, the dynamics and kinematics were combined to establish a mathematical model. The error state values were designed based on the desired state values of the SUR. The Lyapunov analysis is employed to design the final control law. During the simulation and the underwater experiments, the collaboration controller was able to drive the robot to the desired path with the initial formation with acceptable errors. All SURs can maintain the formation during subsequent movement, which indicates the effectiveness of the proposed control method. In addition, the comparison experiment illustrated that the tracking error based on the proposed method is decreased compared with that of the traditional controller. The proposed controller has the following advantages: (1) it can guide multiple SURs to destinations along desired paths; (2) the integral sliding mode controller realizes the formation control of a large group of robots; and (3) this strategy accentuates the reduction of the information transmitted between SURs and thus provides better communication efficiency. Underwater collaboration control is a crucial ability to accomplish complex underwater tasks. For example, the robot needs to surround and capture the target object. In actual underwater complex tasks, it is necessary to have the capabilities of collaboration control for underwater robots.