Localization of a leading robotic fish using a pressure sensor array on its following vehicle

The tail-flapping propulsion of a robotic fish forms a hydrodynamic pressure field that depends primarily on the flapping frequency and amplitude. In a two-robot aligned group, the tail of the front robot generates an oscillating pressure that is detectable by its follower. This paper proposes a position estimator for the follower to locate the position of the leading robotic fish. The position estimator uses the hydrodynamic pressure measured on a sensor array installed on the forefront of the following vehicle body. We derive a potential flow model to describe the pressure field of the leader in the presence of the follower. Using this pressure field model, we further derive an observability measure which is used to determine the relative positions of the leader and follower for which the position estimator will produce a reliable estimate. The position estimator employs the Levenberg–Marquardt algorithm, due to the nonlinearity of the pressure model. Results from the observability analysis show that a satisfactory estimation of the leader position is achieved when the leader is located directly ahead, on the starboard-bow, or the port-bow of the follower, similar to the formation pattern generally found in a school of fish. The observability analysis also shows that poor estimation is obtained when the leader is abeam of the follower. Tank experiments confirm the observability analysis and also demonstrate the use of the position estimator for feedback control by the follower.


Introduction
Recently, the research on underwater exploration has attracted much attention, especially in the development of autonomous underwater vehicles (AUVs). To increase the efficiency of data collection, scientists have begun using groups of AUVs to sample the oceans [1]. Using AUVs to perform team tasks requires the ability to position and track the engaged vehicles, which will allow them to maintain their group structure. Equipment that could assist with this positioning and tracking includes the various sensors, including sonars and cameras, which have been developed to detect environmental features [2]. However, to increase the operational time of the vehicles, passive sensory systems might be a solution to reduce power consumption.
The passive sensory systems of fish have evolved over millions of years. Biological research has found that fish use their sensory organ, called the lateral line, to obtain near-field information, e.g., variations of flow velocity and pressure gradient. Several studies revealed that, by virtue of this hydrodynamic sensory system, the fish that have a lateral line system can detect both static [3] and dynamic objects [4], and, further, form a school [5] under low visibility conditions. While schooling, the structure of a fish group depends on the vision of members to either detect a predator or monitor other neighbors [6]. Research also shows that some fish tend to form a diamond shape pattern such that they can utilize the vortices generated by the front fish to increase their propulsive efficiency [7,8]. Even for a school of two fish, the neighboring fish tends to be within a specific range of the focal fish [9]. Motivated by these results, the function of the lateral line system on fish schooling has the potential to be adopted to the navigation of a group of AUVs for long-term operation. Note that both the detection range and hydrodynamic mechanism are essential factors of the structure of schooling fish, suggests that these factors should be considered for a group of the AUVs maintaining their formation using hydrodynamic feedback. Therefore, we propose a localization method based on hydrodynamic sensing for an AUV following a fish robot. The effect of the relative position between two vehicles on localization is described based on an observability measure.
Inspired by the lateral line system, scientists have tried to understand/mimic various aspects of this system. Using modeling approaches, Hassan provides the hydrodynamic flow-patterns along the surface of a fish-shaped body near an oscillating sphere [10]. His results show that distinguishable velocity and pressure distributions over the fish body occur as the position or oscillation of the sphere changes, which reveals that the features of an object can be extracted by processing the measurement from the lateral line system. Bouffanais et al investigated the object recognition of a stationary obstacle using hydrodynamic sensing [11]. Ren and Mohseni developed an analytical model to describe how the lateral line of a fish could obtain the characteristics of a nearby Kármán vortex street [12]. For the applications of the lateral line system in underwater vehicles, Yang et al developed an MEMSbased lateral line to locate a dipole source and a crayfish [13]. Fernandez et al demonstrated the potential of using a pressure sensor array to track a stationary and a moving cylinder and to identify their shapes [14]. Abdulsadda and Tan used an array of ionic polymer-metal composite flow sensors to track a moving dipole source [15].
To further advance the hydrodynamic sensory techniques for underwater vehicles, recent research is devoted to the design of sensor placements and the feedback control of the vehicles. Ahrari et al investigated the optimal design of the flow sensors distributed on foil-shaped bodies to estimate dipole source characterization in three-dimensional space based on a parametric fitness function [16]. Verma et al investigated the optimal placement of shear and pressure sensors for stationary and self-propelled swimmers localizing oscillating D-shaped cylinders based on information gain [17], and Weber et al investigated the optimal placement for localizing a leading group of swimmers [18]. Salumäe and Kruusmaa demonstrated that a robotic fish equipped with pressure sensors could detect the existence of a Kármán vortex street and maintain its position inside this street [19]. Using pressure feedback, Free and Paley controlled a foil to follow an observabilitybased path in a Kármán vortex street and showed an accurate estimation of the vortex street [20]. Zheng et al equipped a robotic fish with pressure sensors to sense the reverse Kármán vortex street generated by an adjacent robotic fish, and therefore could obtain the attitude and the tail motion of the adjacent robot [21]. They further presented an identification method for the hydrodynamic pressure model describing two swimming robotic fish in a leader-follower formation [22,23]. Our previous work demonstrated that a robotic fish could swim along a straight wall [24] and synchronize its tail motion to a source oscillation [25] using feedback control from hydrodynamic sensing.
Although the previous research has demonstrated that hydrodynamic sensing can be used for object detection and tracking, few studies have applied this system to free-running AUVs performing leader-follower formations. Their results provide the flow field information around the formation but often lack the implementation for controlling free-running vehicles. Controlling an AUV to locate and follow its neighbors requires a priori information about how the relative position affects the position estimation. Therefore this study aims to develop an estimator for the AUV using pressure variations generated by the leading robotic fish and to investigate how the relative position affects the estimation. Compared with hydrodynamic pressure sensing of shed vortices, the pressure variations resulted from a dipole generated by an oscillatory propulsion is a distinctive flow feature near the propulsion source since the frequency content of the pressure variations is the same as its oscillating frequency. The hydrodynamic model of the follower and leader is derived based upon two-dimensional (2D) potential flow theory. The follower is approximated by a foil mapped from a circle using the Joukowski transform, and then the Milne-Thomson circle theorem [26] is used to derive the flow field. Since the leader performs a body and/or tail (caudal fin) locomotion to swim [27], its hydrodynamic model is approximately described by a dipole [24,28]. The pressure variations due to the motions of the follower and the leader are derived from Bernoulli's equation, then the variations induced by the leader are extracted by a bandpass filter. Because the magnitude of these variations varies with the relative position of the leader to the follower, the leader position is estimated using the Levenberg-Marquardt (LM) algorithm [29]. To obtain the preferred following position relative to the leader, the observability of the leader at different positions was quantified using an empirical observability gramian.
We have further validated the method using experiments performed in a water tank: a robotic fish, which is self-propelled by a flapping tail, is followed by an AUV, which is self-propelled by a propeller. The pressure variations were measured by sensors distributed at the forefront of the follower body. The estimated positions of the leader with respect to the follower were obtained from these pressure signals using the LM algorithm. The estimated result was compared to the data measured by a laser scanner attached to the wall of the water tank. Furthermore, a case of the follower following the leader via hydrodynamic pressure feedback control is presented.
The contributions of our study are (1) application of a dipole model for near-field localization of a leading robotic fish, (2) design of a position estimator for localizing the leading fish using hydrodynamic pressure measurements with observability analysis, and (3) implementation of a hydrodynamic feedback controller on a free-running AUV. By controlling an AUV to follow a leading robotic fish, we can further extend our previous work [25] to synchronize the motion of an AUV or a robotic fish to its neighbor. Thus, this study lays the groundwork for developing the formation control strategy for a group of underwater vehicles.
The paper is organized as follows. Section 2 presents the pressure model of the leader and the follower. Section 3 derives the empirical observability gramian for measuring the observability of leader at different positions, describes the LM algorithm for estimating the leader position, and provides a feedback control algorithm to steer the follower to the desired position. Section 4 describes the experimental setup and presents the experimental results. Finally, conclusions and suggestions are summarized in section 5.

Modeling flow over a follower in a leader-generating dipole field
This section derives a 2D potential flow model for describing the pressure field of a fish-shaped AUV moving behind a tail-propelled robotic fish. First, we assume that the leading robotic fish generates a dipole field while propelled by an oscillating tail [24,28]. Then, the fish-shaped AUV is approximated as an airfoil in the physical xy-plane (referred to as the z-plane) [12,30] which is mapped from a circle in the ζ-plane through the Joukowski transformation [26]. The dipole model is modified via the Milne-Thomson circle theorem when the follower is in the immediate vicinity of the leader [31]. Finally, the strength of the dipole is solved by a regression analysis of the data taken from the experiments performed in a water tank.

Complex potential of the leader and shape model of the follower
According to [24,28], the complex potential field generated by the tail-propelled robotic fish is approximated as a dipole located at the center of the tail, neglecting the vortices shed in the wake. Assuming the flow field is an inviscid, incompressible and irrotational fluid, the potential field for the quasi-static leader with the center of flapping tail located at ζ l can be written, in the ζ-plane, as [31] F leader (ζ; ζ l ) = − μ 2π where μ, α, and ω are the strength, the angle, and the oscillating angular frequency of the dipole, respectively.
The Joukowski transformation is applied to build the shape model of the follower since its shape is similar to an airfoil [30]. The transformation of a circle in the ζ-plane to a foil in the z-plane is where the real number a and the complex number ζ c describe the size and shape of the foil. The circle has a radius of r c = |a − ζ c |. When ζ c is real, a symmetric foil is obtained. Figure 1(a) shows the top-view photo of the follower AUV used in this study. The shape of the AUV is approximated by a Joukowski foil (indicated by the blue line) with parameter values of a = 0.21 and ζ c = −0.06. The corresponding circle in the ζ-plane is shown in the inset of figure 1(a). The flow velocity or hydrodynamic pressure at the points in the z-plane can be calculated from their corresponding points in the ζ-plane via the inverse Joukowski transform where the sign of the square root should be chosen, so that z lies on or outside the foil, corresponding to |ζ| r c .
There are a total of seven pressure sensors placed on the follower AUV. The positions of the sensors are indicated by the solid circles in figure 1(a). To locate the leading robotic fish, the sensors are distributed around the forefront of the follower body: one sensor on the tip, labeled as S1, and three sensors on each side. The sensors on the positive y-direction from the tip to the trailing edge are labeled as S2, S4, and S6, while the sensors on the negative y-direction are labeled as S3, S5, and S7. No sensors are next to the tip because of the area being occupied by the cameras. The origin of the z-plane (indicated by the circled plus symbol in figure 1

Pressure measurement equation
To obtain the complex potential of the follower present in the dipole field generated by the leader, we use the Milne-Thomson circle theorem [26]. From this theorem, if the complex potential F 1 (ζ) represents the original flow with no singularities for |ζ| < r c , then its complex potential in the presence of a circle-shaped follower becomes where the overbar symbol represents the complex conjugate operator. Since the field generated by the leader is a dipole and the shape of the follower is a circle in the ζ-plane, we substitute (1) into (4) to obtain the total complex potential [31]: where φ is the velocity potential and ψ is the stream function.
Due to the presence of the circle, the field generated by the flow past the circle can be solved by placing a strength-reduced image source inside the circle. Let ζ = ζ x + iζ y and ζ l = ζ x,l + iζ y,l , using Bernoulli's equation the pressure field of the leader in the presence of the follower becomes where 2 +ζ y,l 2 , and ρ is the density of the fluid and is 1000 kg m −3 . In (6), we have neglected the convective term as we only need the information from the signals with the same frequency as the oscillating frequency of the leading robotic fish.
For the measured pressure signals, a bandpass filter is introduced to remove this leader-induced convective pressure as well as the pressure induced by the propeller and the movement of the follower, referred to as the self-motion of the follower. Further, the pressure generated by the leader is time-dependent because the distance between the leader and the follower varies with time. The procedure is simplified, assuming that the effect due to the rate of change of the relative distance is small over a short time interval compared with the pressure variation due to the tail oscillation.
Since only the magnitude part of the measured pressure is considered as the measurement, the phase of the modeled signal is neglected by taking the absolute value, as follows: where ζ j = ζ x,j + iζ y,j indicates the position of sensor j.

Strength of the dipole
To apply the proposed pressure model for localization of the leader, the strength of the dipole μ is obtained first. μ was estimated using the pressure signals measured by the seven sensors while the follower was swimming in the vicinity of the leader. Using a linear regression method to model the variation of the magnitude of measured pressure against the modeled pressure, the estimated dipole strength is μ = 7 × 10 −3 . The standard deviations of the strength and the predicted pressure magnitude are 3.69 × 10 −4 and 14 Pa, respectively. The goodness of fit is about 0.53 due to the approximation of the proposed dipole model and uncertainty in measurements. Figure 2 shows the modeled pressure fields using (6) with t = 0.75 s when the leader is (a) on the starboard bow, (b) ahead, and (c) abeam of the follower, respectively, using the estimated dipole strength μ = 7 × 10 −3 , the assumed oscillating angular frequency ω = 2π, and the assumed oscillating angle α = π/2. The left and right panels display the pressure fields in the pre-transform ζ-plane and in the post-transform z-plane, respectively. To solve for the pressure field of a given leader position in the physical plane (z-plane), the corresponding leader position ζ l is calculated via the inverse Joukowski transform, (3). The resulting fields in the ζ-plane include not only the pressure in the flow field but also the virtual field inside the circle, which is shown for illustrative purposes. We see that the image dipole source has a reduced strength and a different oscillating angle to satisfy the wall boundary condition of the circle. The pressure fields in the z-plane indicate that when the leader is not on the x-axis, spatial variations (a pressure difference of 5 Pa between adjacent sensors) are observed around the head of the follower, especially at the sensors placed facing the leader side, figures 2 (a-2) and (c-2). When the leader is along the x-axis, the magnitudes of pressures are symmetric along the centerline of the follower body, with a minimum value at the tip, figure 2(b-2).

Observability, estimation and controller design
This section presents the observability of the localization system, devises the algorithm for estimating the leader position, and designs a closed-loop controller using the estimated position to steer the follower. First, we derive an unobservability index based on the empirical observability gramian for measuring the observability of the localization system [32]. Then, we describe the use of the LM algorithm [29] to obtain the relative position of the leader from the pressure measurements. Furthermore, we analyze the dynamic model of the follower AUV [33,34], and

Observability measure
For a dynamic system, observability is a measure of how the initial states can be obtained from the outputs [35]. The traditional way to check the observability of a system is to calculate the observability rank condition, but the method only provides information on whether the system is observable. To quantify the observability of the system, an unobservability index is defined as [32] v = 1/σ min , where σ min is the minimum singular value of the observability gramian. For a dynamic system, small σ min indicates that the problem is potentially illconditioned, and may lead to unreliable results, particularly in the presence of noise. So the unobservability index defined in (8) provides a measurement of how well a scheme can estimate the initial state of a system. A small value v implies the measurement noise has less impact on the estimation error and vice versa. Consider the nonlinear system where G(m) is the modeled pressure field (7) for a leader/dipole located at the position parameter vector m = x l , y l T and the pressure field is evaluated at N pressure sensors located on the body of the follower, such that the system output is To obtain the observability of the nonlinear system for locating the leader in the xy-plane, the empirical observability gramian is calculated following [32]. Let ε j be a small disturbance of the jth position parameter along the unit vector n j , where j = 1, 2, the perturbed parameter vector m ±j = m 0 ± ε j n j produces the corresponding output d ±j . Following [32,36], for a set of time-invariant parameters, the j, k th component of the 2 × 2 empirical observability gramian W O can be expressed as where ·, · is an inner product operator. As ε j → 0, it can be shown that Following [36], the empirical observability gramian W O for a given leader position m 0 approximates to Then, the unobservability index ν is calculated using the smallest singular values of the local observability gramian W O . After calculating the unobservability indices for all the potential positions, we can build a map for evaluation of the observability of the leader localization.

Selection for the placement of pressure sensors
This study uses the placement of pressure sensors, referred to as the standard placement, shown in figure 1(a). No sensors are on the sides near the tip of the follower because of the presence of cameras. To evaluate how the sensors around the cameras affect the localization performance, we built the observability maps of the standard sensor placement and the placement with extra sensors around the cameras. The observability map of the leader at different positions is built based upon (8) and (12). Figures 3(a) and (b) show the results of those two observability maps using the shape parameters of the follower a = 0.21 and ζ c = −0.06, the dipole strength, oscillating angular frequency, and angle are μ = 7 × 10 −3 , ω = 2π, and α = π/2, respectively. In both panels, the blue color indicates a smaller value of the unobservability index, corresponding to higher observability, while the green indicates a higher value of the unobservability index, implying lower observability. We see that higher observability is obtained if the leader is in the fan-shaped range in front of the follower, consistent with the result of [9]. Although the range of higher observability increases with extra sensors, the standard placement of sensors provides acceptable estimates of the position of the leader.

Estimation of the leader position
Due to the nonlinear relationship between the pressure signals and the leader position, the LM algorithm is used. The LM algorithm [29] is a hybrid technique that uses both Gauss-Newton (GN) and steepest descent methods to converge to an optimal solution. Given the measured pressure signals at the  N sensors d 1 , . . . , d j , . . . , d N , the optimal leader position m = x l , y l T is obtained via minimizing the cost where G j (m) = P m (z j ; z l ) is the modeled pressure at the position z j (= x j + iy j ) assuming the leader is at z l (= x l + iy l ). Since the modeled pressure field (7) is calculated in the ζ-plane, the inverse Joukowski transform (3) is used to find the sensor and leader positions, ζ j and ζ l , in the ζ-plane. The data error terms σ j may be described by independent and identically distributed (IID) Gaussian random variables with a common value σ [29]. Defining a vector of the data residuals where m 0 is an initial guess of the leader position for the iteration. Then, (13) can be written as To find the desired solutionm that minimizes the cost function f(m), an iteration is processed: suppose a sequence of m 0 , m 1 , . . .converges to the solutionm, then the Taylor expansion about the starting estimation m 0 is leads to Newton's method for minimizing f(m). The gradient of f(m) in (17) can be written in matrix notation as where the Jacobian matrix J(m) is the derivatives of the residuals with respect to the parameters as follows As for the Hessian matrix H f (m) , it is approximated using the cross-product Jacobian Substituting (19) and (20) into (17), Δm for the kth step of iteration is then derived for the LM method with an additional positive scaling factor, referred to as the damping parameter, λ k , which is adjusted during the iterations such that the matrix left-hand side of (21) is nonsingular. The iteration is usually started with a relatively large value of λ k and its value is gradually decreased by a factor q. By solving (21), the estimation is updated At each step, λ k is updated based on the reduction of the residual norm f(m). If m k + Δm leads to a reduction of the residual norm, then the update of m k+1 is accepted and λ k is decreased; if the residual norm does not decrease, λ k is increased and the process repeats until a value of Δm which decreases the residual norm is found. We see that for a very large λ k the LM method is similar to the steepest-descent method, which gives slow but certain convergence to a local minimum. While for a very small λ k the LM method is similar to the GN method, which gives fast but uncertain convergence [29]. The whole iteration stops when either f(m) converges, or when the maximum number of iteration steps is reached.
As a part of the estimation, uncertainty of the estimated leader position is obtained using the approximate covariance matrix [29]. For the nonlin- Then the relationship between the changes in e and the changes in m is Because the data error terms are IID, and the Hessian matrix is approximated by (20), the covariance matrix of the nonlinear least squares is approximated by Cov(m) ≈ (J(m) T J(m)) −1 .
The diagonal elements and off-diagonal elements of the covariance matrix are the variances and the covariances of two variables x l and y l , respectively.

Controller design of the follower
The model of the system dynamics for the follower AUV is analyzed as follows. To simplify the modeling procedure, we assumed that the shape of the body and the distribution of mass are symmetric about the x B z B -plane. Then, the follower moves in a horizontal x B y B -plane with the centers of mass and buoyancy at the same location. Figure 4 defines the coordinates and all the related forces acting on the follower. X S Y S is the space-fixed coordinate system, while x B y B is the body-fixed coordinate system with its origin located at the buoyancy center B of the body. Note that the x B y B coordinate defined here is different than the xy coordinate used in section 2. T and M are the thrust and moment acting on the hinge of the propeller, respectively; θ f0 is the heading angle of the follower in the X S Y S frame, and θ f1 is the angle of the propeller in the x B y B frame. α f is the angle of the follower velocity V f with respect to the x B -axis; f D and f L are the hydrodynamic drag and lift forces acting on the body, respectively.
Based on [33], the equations of motion of the follower can be expressed as where m and I are the mass and the moment of inertia, respectively. u and v are the local velocities parallel to the x B -and y B -axis, respectively. −Xu, −Yv and −Nθ represent the effects of the added mass along the x B -, y B -axis and about the rotating axis, respectively. The external forces X E and Y E , and the external moment N E are described as In (27), the hydrodynamic drag f D , lift f L , and moment m H are expressed as follows [34] where S is the wet surface area. C D , C L , C Mα , and C Mr are the coefficients of drag, lift, hydrodynamic restoring moment, and dynamic viscous moment, respectively.
To determine certain physical parameters of the follower, a series of propeller thrust tests were performed with a load scale attached to the follower. The relationship between the control input voltage and the measured output thrust of the propeller is established using a linear regression method. Then, for the remaining parameters in (26), values were determined with the nonlinear grey-box model object of the MATLAB system identification toolbox [34] by representing (26) as a set of first-order nonlinear differential equationṡ c 1 , c 2 , . . . , c 7 ) , (29) where where c 1 , c 2 , and c 3 describe the added mass effects which are pre-estimated using the derivations in [37], with the assumption of the ellipsoid shape. The values of c 4 , . . . , c 7 are obtained by minimizing the difference between the predicted model output and the experimental data. The outputs of the model are the time series of surge velocity u, sway velocity v, and yaw ratė θ f0 of the follower. The experimental data were collected using a top-view camera to record the motions of the surge, sway, and yaw of the follower. The details of the motion model of the follower can be found in [38].
To maintain a specific relative position to the leader, referred to as a target position, (x lt , y lt ), we use the estimated leader position (x l ,ŷ l ) from the pressure signals as the control feedback for the follower. Adjusting the propeller angle θ f1 and the input voltage provides control of the heading and the forward speed of the follower, respectively. A proportional integral derivative controller adjusts the propeller angle θ f1 for controlling the lateral position of the follower to the leader as θ f1 = − K py e y + K iy t 0 e y dt + K dyėy , (31) where the proportional gain K py , integral gain K iy , and derivative gain K dy are all positive values. e y is the lateral position error e y = y lt −ŷ l .
A proportional-only controller is designed to control the longitudinal position of the follower to the leader, the control input of the propeller u p is as follows where u p0 is a constant input which controls the stable forward motion of the follower and K px is the positive proportional gain. e x is the longitudinal position error e x = x lt −x l . To tune the controller gains K py , K iy , K dy , and K px , we first simulate the preestimated model and use a trial-and-error method to tune the gains until the errors e x and e y converge. The controller gains were further tuned based on the results of additional experiments in a water tank.

Results and discussion
The water tank experiments were carried out to demonstrate the proposed position estimation. First, we describe the experimental setup. Then, to confirm the feasibility of the localization method presented in this study, we describe the water tank experiment conducted for three different relative positions of the leader and follower. Two relative positions associated with good observability are chosen: (1) the leader on the starboard bow of the follower and (2) the leader ahead of the follower. One relative position with poor observability is chosen with leader abeam of the follower. Finally, its applicability is demonstrated in a leader-followed experiment.

Experimental setup
The water tank experiments were performed with two underwater vehicles. The leader used in the experiments is a robotic fish with an overall length l = 1.2 m and a dry mass of 35 kg (see figure 5). The shell of the leader is made of buoyant materials. Inside the shell is a waterproof aluminum box containing the batteries and the electric systems. Movements of the fish's body and tail propel the leader through the water, resulting in a periodic motion. The sinusoidal motion of its tail has an oscillating frequency of 1 Hz with an amplitude of 0.13 m. The periodic motion of the leader results in a zigzag trajectory. As the leader swims, it generates periodic pressure variations which can be used for the localization. In this study, the average forward velocities of both the leader and follower were about 0.4 m s −1 , resulting in a Reynolds number [27] of approximately 10 5 , for both the leader and the follower.
The follower AUV has an overall length of 0.9 m and a dry mass of 19.5 kg (see figure 1). The shell of the follower is made of acrylic fiber. Inside the shell is a waterproof aluminum box containing batteries, an Advantech industrial PC AIMB-272G2-00A1E with Intel Core i7 processor, and all the electric systems. A propeller is mounted on a rotatable fixture at the aft side to provide thrust and direction control. The environmental sensors consist of two cameras, a depth sensor, a compass, and seven commercial pressure sensors (model MS5803-01BA) whose positions are indicated in figure 1(a). Each sensor module is supplied with internal factory calibrated coefficients that are used to calculate temperature-compensated  pressure for achieving the optimum accuracy. The oversampling ratio of the sensor was set to 4096, resulting in a resolution of 1.2 Pa. The circuit boards of these pressure sensors are covered by epoxy resin. Both the sampling frequency of the pressure signals and the computation frequency of the position estimate are 10 Hz. Figure 6 shows an example of the pressure signals collected from the separate experiments in the absence of the leader. Figure 6(a) shows that the pressure variation due to the self-motion of the follower has frequency components (<0.5 Hz) which are smaller than those generated by the leader (about 1 Hz). Because of this frequency relationship, a finite impulse response filter was applied to the pressure signals to eliminate the variations induced by the follower's self-motion, see the filtered signal (black line) in figure 6(b). Then, only the magnitude of the filtered signals is used for the position estimation (13). For some other applications, the selfmotion effects might not be removed by a filter and regression methods can be used, for example, [22,39].
The dimensions of the water tank are 120 m long, 8 m wide, and 8 m deep. The depth of the leader and follower was about 0.30 m below the water surface. A laser scanner was fixed on the wall of the tank. To record the positions of the leader and follower, the laser scanner uses the tips of the corresponding dorsal fins as the reference points. The position offset for the leader was corrected from the recorded value to the dipole center (indicated by the circled plus symbol in figure 5), while the offset for the follower was corrected to the origin of z-plane (the circled plus symbol in figure 1(b)). For all the experiments, the origin of the space-fixed X S Y S coordinate is the position of the laser scanner. The corrected positions of the leader and follower are transformed into the xy coordinate. Note that for each experiment the initial time (t = 0 s) was set when the follower entered the detection range of the laser scanner.

Experiments for position estimation
Here we present experimental results for three different relative positions of the leader and follower: the leader on the starboard bow of the follower (referred to as case 1), the leader directly ahead of the follower (case 2), and the leader abeam of the follower (case 3). During these experiments, the distance between the leader and follower was uncontrolled. These experiments estimate the leader position relative to the follower using pressure data measured by sensors on the follower using the proposed LM algorithm, as described in section 3.2. In the LM algorithm, the iteration starts with the damping parameter λ 0 = 0.01 and its value is either decreased or increased by a fixed factor q = 10; the initial guess m 0 is (−0.5, 0.3) m for the cases presented below. Uncertainty associated with the estimate is calculated using (25), with the value of the common data error σ set to 15 Pa, to account for the measurement and modeling errors. Figure 7 shows the results for case 1. Panel (a) shows the trajectories of both leader and follower measured by the laser scanner in the X S Y S coordinate for 7 s. The solid circles with RGB colors from blue to red indicate the time series. Panel (b) shows the corresponding relative positions of the leader on the map of the unobservability index. Panels (c) and (d) are the estimated leader positions using the measured pressures (red solid line) in the x-and the y-directions, respectively, along with the corresponding uncertainties (red shaded area).

Case 1: leader on the starboard bow of the follower
At the beginning of the experiment, the leader was at (−0.83, 0.32) m in the xy coordinate (z-plane). During the entire experimental period, the position of leader was on the starboard bow of the follower, as indicated by the blue dashed line in figures 7(c) and (d). The interval of the vertical axis for these two panels is from −3 to 3 m to accommodate the range of estimated values (red solid line) with the corresponding uncertainties (red shaded area). We see that the estimation of the leader position is consistent with the direct measurements (blue dashed line). During the 7 s of the experiment, the distance between the leader and the follower increased from 0.89 to 1.28 m (0.74l to 1.07l), resulting in an increase of the position uncertainties in both x and y directions. This result is due to the leader moving outside the area of higher observability (see the circles in figure 7(b)). Thus, it becomes difficult to locate the leader. Figure 8 shows the results for case 2. During the initial 2 s, the leader was approximately directly ahead of the follower, starting at (−0.49, −0.06) m. Then, the follower moved to the port side ( figure 8(a)), probably due to a pressure difference induced by the dipole. The leader was subsequently on the port side of the follower with the distance between the leader and follower progressively increasing. During the 8 s of the experiment, the distance of the leader to follower rises from 0.49 to 0.74 m (0.41l to 0.62l). Due to the shorter distance compared with that of case 1, the vertical axis of figures 8(c) and (d) is from −1 to 1 m. We see that the uncertainties of estimated positions in both directions grow with increasing distance. After 5 s elapsed in the experiment, the uncertainty started to intensify when the leader entered an area of lower observability (see the green-yellow to red circles in figure 8(b)). Furthermore, the difference between the estimated and the actual positions in both directions increases accordingly. Figure 9 shows the results for case 3. At the beginning of the experiment, the leader was at (−0.30, 0.43) m. During the experiment, the distance in x-direction gradually reduced to zero, while the distance in ydirection increased with time. For figures 9(c) and (d), the vertical axis has a broader range of −4 to 4 m, compared with that of case 2. Although the variation of the distance for case 3 (from 0.52 to 0.84 m, or from 0.43l to 0.70l) is similar to that of case 2, the position estimation for case 3 shows considerable uncertainty. The increased uncertainty mainly results from the higher value of the unobservability index, when the leader is on the abeam side, figure 9(b).

Cases 1, 2 and 3: summary
The standard errors [40] of the position estimate for cases 1, 2, and 3 are 0.30 m, 0.24 m, and 0.37 m, respectively. The results are consistent with the map of the unobservability index. For all three cases, as the distance increases, the spatial variation of the pressure generated by the leader may be too weak to be detected, resulting in dramatically reduced observability. In contrast, when the distance is less than one body length of the leader, the follower can locate the leader with a relatively small uncertainty, especially on the starboard bow (case 1) or ahead of the follower (the initial 2 s of case 2). However, when the follower is directly behind and close to the leader, an external force affects the movements of the follower and alters its heading. In general, our finding is similar to the swimming formation commonly observed for a group of two fish: the leading fish tends to be located ahead, on the starboard bow, or the port-bow of the trailing fish, rather than on the abeam side [9]. The map of the unobservability index using a passive pressure-sensing method could facilitate the formation design for robotic fish or path planning.

Application for following the leader
The applicability of this position estimator is demonstrated via a leader-followed experiment, referred to as case 4. The control algorithm described in section 3.3 was used to maintain the follower at a target position relative to the leader. The values of control gains were set to K py = 2, K iy = 0.01, K dy = 2, and K px = 10. The target position was chosen based upon the map of unobservability index shown in figure 3. Figure 10 presents the results from the experiment with a constant target position of (−0.6, 0.3) m, which is in an area of higher observability. The control loop was run at a frequency of 10 Hz. The results suggest that the controlled positions of the leader (blue dashed line in figures 10(c) and (d)) are consistent with the target values (black dotted line) except for a deviation that begins shortly after 10 s into the experiment. Shortly after that time, the follower adjusted its heading and moved toward the leader to maintain the target position. The standard error of the estimate for this case is 0.21 m, which is less than the results for cases 1-3 where following control was not present. This reduction in standard error shows that the localization result is improved when the follower maintains a position with high observability. The fluctuation of the controlled position, also indicated by the colored circles shown in figure 10(b), might be due to (1) the uncertainty of the estimated leader position, and/or (2) the coupled dynamics between the lateral and longitudinal motion of the follower. During the process of the following control, the follower successfully follows the leader and keeps the leader within the proper following range. Therefore, choosing a preferred target position based on the observability map is a feasible strategy for control.

Discussion
In this study, the hydrodynamic model to estimate the position of the leading robotic fish is derived based on 2D potential flow. Localization of a tail-flapping propelled robotic fish is achieved by obtaining information from signals with the same frequency as the frequency of the oscillatory propulsion. The proposed method is applicable under the following conditions: (1) the distance between the leader and follower is less than one body length of the leader; (2) the forward directions of both the leader and follower are aligned in the same plane; and (3) both the leader and follower move with a steady forward velocity without any abrupt motions.
Other configurations, such as localizing a leading AUV powered by propellers, would require a different hydrodynamic model of the leader [41] and a high sampling rate for measuring hydrodynamic variations induced by the propeller. In this alternate configuration, a filter design can be applied to remove the effect of the noises emitted by the motor and propeller on the signals measured on the follower. In other configurations, both the leader and follower could be powered by the same type of propulsion and generate the hydrodynamic variations with the same frequency, the effect of self-motion could be removed by using data-driven approaches [22,39].
For a real-world implementation, where the fluid environment is full of hydrodynamic disturbances, including various kinds of flow features, obstacles, and boundaries, a model-based feedback control method can be difficult to implement. A potential way to solve this problem is to measure the hydrodynamic disturbances directly and then compensate for the disturbances by a feedback controller [42].

Conclusions
In this study, we proposed a position estimator for locating a leading robotic fish using the hydrodynamic pressure measured by pressure sensors on a following underwater vehicle and demonstrated its utility in feedback control by the follower. We derived a pressure measurement equation, from 2D potential flow theory and Bernoulli's equation, using a dipole to model the pressure field produced by the leading robotic fish in the presence of the foil-shape following vehicle. Using the modeled pressures on the follower's body, the observability of various leader positions is developed. The resulting observability map illustrates an improved ability to locate the leader position exists when the leader is ahead or on the starboard/port bow of the follower. The leader position is estimated from the measured pressure signals using the LM algorithm. Tank experiments, using a tailpropelled robotic fish and an AUV follower equipped with distributed pressure sensors, demonstrate position estimates consistent with the observability analysis. These results suggest relative leader-follower positions which will allow the follower to locate and follow the leader. A leader-followed experiment shows that, given a target position with high observability as indicated by the observability map, the follower can successfully follow the leader.
Future work will extend our leader-follower sensing framework to a group of underwater vehicles, allowing them to maintain group formations via local information. To achieve this goal, ongoing efforts are devoted to the development of the measurement equation for multiple pressure sources and developing the corresponding localization method which will provide feedback to control the vehicles' positions.
108-2638-M-002-002-MY2; MOST 108-2221-E-002-061) and the National Museum of Marine Science and Technology, Taiwan. The authors acknowledged financial support provided by National Taiwan University under the Higher Education Sprout Project by the Ministry of Education of Taiwan.