Online Predictive Visual Servo Control for Constrained Target Tracking of Fixed-Wing Unmanned Aerial Vehicles

[ad_1]

3.1. MPC Optimization Problem Formulation

This part aims to solve Problem 1.

Based on our previous work [7], a reference state named the Ideal State was proposed to construct the relationship between the image feature vector and u ψ . As for the reference state, it has the following constant state:

θ p = π 2 , θ t = α , θ = 0 , ϕ = 0 .

Note that α ( 0 , π 2 ] is a given constant. When given the desired circling radius R d , α can be expressed as α = arctan ( H R d ) . Denote the coordinates of the feature point in F i by ( u 1 , v 1 ) , and in the reference state by ( u 2 , v 2 ) ; then, the relationship can be written as:

u ˙ 2 v ˙ 2 = f 2 + u 2 2 f · c o s α v 2 · s i n α f z c u 2 · v 2 f · c o s α + u 2 · s i n α 0 · u ψ V t .

Simultaneously, u p and u t can be obtained from (20) in [7], which is

u p = arctan ( u ˙ 1 f ) ,

u t = arctan ( v ˙ 1 f ) .

Define s 2 = [ u 2 , v 2 ] and based on (8), the discrete time state-space model can be expressed as

s 2 ( k + 1 ) = s 2 ( k ) + s ˙ 2 ( k ) · Δ t ,

where Δ t is the sampling time.

For convenience of subsequent analysis, the discrete form is rewritten as

s 2 ( k + 1 ) = f s ( s 2 , u ψ , k ) ,

Since the yaw rate of the fixed-wing UAV is restricted, then the following constraint needs to be satisfied:

u ψ U s e t , U s e t = [ u max , u max ] .

In order to guarantee that the change in u ψ can be smooth, the acceleration constraint is also given:

Δ u ψ a s e t , a s e t = [ a max , a max ] .

where

Δ u ψ ( k + i ) = u ψ ( k + i ) u ψ ( k + i 1 ) .

Furthermore, the perception capability of the camera is taken into consideration as well. Under the condition of invariant camera parameters, whether the target can be detected correctly usually depends on the amount of feature information contained in the image. More specifically, it is related to the maximum perceived distance of the camera, which is denoted by L M . Therefore, the clear perception range of the camera is equivalent to a cone, as shown in Figure 3.
In order to determine whether the target is within the cone, the feature point in the current image plane is first mapped into that in the horizontal image plane. Define the feature point in the latter plane as ( u 3 , v 3 ) , considering that θ t = α of (7) in the Ideal State; then, ( u 3 , v 3 ) can be obtained from ( u 2 , v 2 ) based on the following transformation:

u 3 v 3 f = k 3 1 0 0 0 sin α cos α 0 cos α sin α u 2 v 2 f ,

where k 3 R + . After solving the above three equations, the value of u 3 and v 3 can be obtained.

Since the flight altitude H of the UAV is constant in this paper, the maximum perceived distance can be converted into the maximum horizontal distance, which is denoted by R M . Therefore, the target is recognized to be within the perception range if, and only if, the following condition is met:

u 3 2 + v 3 2 f R M H .

After that, in order to keep the target within the perception range when the UAV circles around it, α in (7) needs to satisfy the following condition:

tan ( π 2 α ) R M H ,

Simultaneously, considering the constraint of u ψ in (12), there exists

tan ( π 2 α ) V t u max · H .

Define η 1 = arctan R M H , η 2 = arctan V t u max · H , then α [ π 2 η 1 , π 2 η 2 ] . Based on (16), the perception constraint at time-step k can be defined as

where

g 1 : = u 3 2 + v 3 2 f 2 R M 2 H 2

Denote the error of the feature point by

Δ s 2 ( i | k ) = s d s 2 ( i | k ) ,

where s d = [ 0 , 0 ] is the desired value of s 2 , and s 2 ( 0 | k ) = s 2 ( k )

is the observed value at time-step k. Since Δ u ψ ( 0 | k ) = u ψ ( 0 | k ) u ψ ( k 1 )

, then the cost function can be defined as follows:

J 1 ( k ) = i = 1 N p Δ s 2 ( i | k )

Q s 2 + Δ u ψ ( i 1 | k )

Q u 2 = i = 1 N p J r ( i | k ) ,

where Δ s 2 Q s 2 = Δ s 2 · Q s · Δ s 2

and similar to Δ u ψ Q u 2

, Q s = d i a g { q 1 , q 2 }

is positive definite and Q u R + . The control sequence is

U = { u ψ ( 0 | k ) , u ψ ( 1 | k ) , , u ψ ( N p 1 | k ) } ,

N p R + is the prediction horizon.

Note that J 1 = 0 if, and only if, Δ s 2 ( i | k ) = 0

and Δ u ψ ( i 1 | k )

for i { 1 , , N p } . That is, the constant control input of the UAV makes it circle around the static target.

Due to the fact that only the first control input of U in (23) is used, the following contraction constraint is provided to ensure the stability of the system (which will be proven in Section 3.3):

C C 1 ( k ) = Δ

s 2 ( 1 | k ) δ · Δ

s 2 ( k ) 0 ,

where Δ s 2 ( k )

represents the 2-norm of s 2 ( k )

, δ ( 0 , 1 ) .

Therefore, based on Equations (11)–(13), (19), (22), and (24), the MPC optimization problem can be formulated as

P 1 : arg min U ( k ) J 1 ( k )

s . t .

s 2 ( i | k ) = f s s 2 , u ψ , i 1 | k ,

u ψ ( i 1 | k ) U s e t ,

Δ u ψ ( i 1 | k ) a s e t ,

g 1 ( i | k ) 0 ,                  

C C 1 ( k ) 0 ,                  

where i = 1 , 2 , , N p .

3.2. Switching-Based Optimization Control

Problem 2.

With the increase in N p and limited by the computing capability of the processors, it is time-consuming to solve the optimization problem of (25) with nonlinear hard constraints (25e) and (25f) online. Even worse, they may also lead to the problem of an infeasible solution within the predefined iterations. Then, the question arises of how to design an online MPC strategy for practical application?

To solve the problem, this paper considers adding the hard constraints into the cost function, so that these constraints need not be strictly satisfied.

Firstly, add the constraint (25e) into J r ; then, we have

J r , 1 ( i | k ) = J r ( i | k ) + β 1 · max { g 1 ( i | k ) , 0 }

,

where β 1 R + is a constant.

Remark 1.

In the context of discrete systems as addressed in this work, the discontinuous nature of the sampling points renders the exact occurrence at g 1 ( i | k ) = 0

highly improbable. Furthermore, it is essential to acknowledge that the cost function focuses on the overall optimization objective, thus rendering the non-differentiability of specific points inconsequential to the overall optimization.

Furthermore, considering the constraints of (12), (13), and the unknown motion of the target, it may be unable to make g 1 ( k + 1 ) 0

when g 1 ( k ) > 0

. Therefore, g 1 in (20) is redefined as follows to make β 1 · max { · }

in (26) function earlier:

g 2 : = u 3 2 + v 3 2 f 2 ( R M Δ R ) 2 H 2 ,

where Δ R > 0 . Then, (26) is rewritten as

J r , 1 ( i | k ) = J r ( i | k ) + β 1 · max { g 2 ( i | k ) , 0 }

,

After that, turn (24) into a soft constraint as well; then, the cost function can be represented as

J 1 , s o f t ( k ) = i = 1 N p J r , 1 ( i | k ) + β 2 · max { C C 1 ( k ) , 0 }

.

Compared with the soft constraints-based method that introduces slack variables like [26], the method that uses the max function is more efficient. When g 2 ( i | k ) 0

is satisfied, the nonlinear function does not participate in solving the gradient in each iteration when using the interior point method. However, the gradients of all the g 2 ( i | k )

still need to be calculated in each iteration for the former method, which is more time-consuming.

Therefore, the MPC optimization problem can be reformulated as

P 1 , s o f t : arg min U ( k ) J 1 , s o f t ( k )

s . t .

s 2 ( t | k ) = f s s 2 , u ψ , i 1 | k ,

u ψ ( i 1 | k ) U s e t ,          

Δ u ψ ( i 1 | k ) a s e t ,          

where i = 1 , 2 , , N p .

A warm start is also used in this work. Based on our previous work [7], the control input for the UAV can be obtained with the aid of LSM and (11), which is denoted by u ψ ( i | 0 ) , i = 0 , , N p 1

. Note that u ψ i

U s e t is required; then, the initial control sequence can be chosen as

U 0 = { u ψ ( 0 | 0 ) , u ψ ( 1 | 0 ) , , u ψ ( N p 1 | 0 ) }

.

Obviously, U 0 satisfies the inequality constraints of (30c) and (30d). This indicates that U 0 is the feasible solution of the optimization problem.

Furthermore, denote the optimal solution at time-step k by U ( k )

; then, the feasible solution at time-step k + 1 , denoted by U ( k + 1 ) , can be chosen as

u ψ ( i | k + 1 ) = u ψ ( i + 1 | k ) , i = 0 , , N p 2

u ψ ( N p 1 | k ) , i = N p 1

With increase in the target speed, the relative distance between the fixed-wing UAV and the target may exceed the maximum perceived distance limited by the constraints of (12) and (13). Although the target may still be recognized with the aid of a detection algorithm, the accuracy of detection will decline and the details of the target cannot be clearly distinguished. It is noted that investigating the details of the target is a basic need for UAV target tracking applications.
The items of β 1 · max { g 2 ( i | k ) , 0 }

( i = 1 , , N p )

in the cost function J r , 1 of (28) help to avoid the relative distance from exceeding R M . However, the optimization problem of (30) is still more concerned with the convergence of s 2 . Moreover, both the gradients about ( u 2 , v 2 ) and ( u 3 , v 3 ) need to be calculated online, which increases the workload of computation.

To solve the problem, a switching-based control method is proposed. When the relative distance keeps within the maximum perceived distance, the optimization problem (30) is considered to enable the UAV to fly around the target. However, if the condition is unsatisfied, the other optimization problem is designed to return the target back to the perception range quickly.

According to (16), the perception constraint is directly affected by ( u 3 , v 3 ) . However, the optimization problem P 1 , s o f t focuses on the convergence of ( u 2 , v 2 ) to s d . Therefore, in order to accelerate the convergence of g 1 ( k )

to 0 once the perception constraint is unsatisfied, a new cost function is defined as follows:

J g ( k ) = i = 1 N p Δ s 3 ( i | k )

Q s , g 2 + Δ u ψ ( i 1 | k )

Q u 2 = i = 1 N p l g ( i | k ) ,

where Q s , g = d i a g { q 1 , g , q 2 , g }

is positive definite, Q u R + and

s 3 = [ u 3 , v 3 ] , Δ s 3 ( i | k ) = s d s 3 ( i | k ) .

In addition, to ensure the convergence of Δ s 3 , the following contraction constraint is also given:

C C g ( t | k ) = Δ

s 3 ( 1 | k ) δ · Δ

s 3 ( k ) 0 ,

where Δ s 3 ( k )

represents the 2-norm of Δ s 3 ( k )

. Similar to (29), in order to avoid the nonlinear constraint of (35), the cost function of J g ( k )

in (33) is rewritten as

J g , s o f t ( k ) = i = 1 N p l g ( i | k ) + β g · max { C C g ( k ) , 0 }

,

where β g R + .

Remark 2.

The convergence of C C 1 in (24) does not theoretically guarantee the convergence of C C g in (35) around g 1 ( k ) = 0

. Only when u 2 2 and v 2 2 converge simultaneously can the convergence of (35) be ensured (refer to Section 3.3 for the proof), thereby ensuring the stability of the switching process.

To this end, a new contractive constraint is defined as follows:

C C 2 a = | Δ u 3 ( 1 | k ) | δ · | Δ

u 3 ( k ) 0 ,

C C 2 b = | Δ v 3 ( 1 | k ) | δ · | Δ

v 3 ( k ) 0 .

Referring to (36), the corresponding cost function can be written as

J 2 , s o f t ( k ) = t = 1 N p l g ( t | k ) + a 2 · max { C C 2 a ( k ) , 0 }

+ max { C C 2 b ( k ) , 0 }

.

Considering that (37) necessitates the simultaneous convergence of both | u 2 |

and | v 2 |

, whereas (35) only mandates the convergence of s 3 , it is evident that the solution requirements for the former are more stringent. By comprehensively considering the stability of the switching process and alleviating the solution constraints, we reformulate the control optimization problem based on Equations (30), (36), and (38) as

P s w i t c h : arg min U ( k ) J s w i t c h ( k )

s . t .

s 2 ( t | k ) = f s s 2 , u ψ , t 1 | k ,    

u ψ ( t 1 | k ) U s e t ,

Δ u ψ ( t 1 | k ) a s e t ,    

where t = 1 , 2 , , N p , and

J s w i t c h = J 1 , s o f t ( k ) , n 1 = 0 ,

J 2 , s o f t ( k ) , 0 < n 1 < n max ,

J g , s o f t ( k ) , n 1 = n max

Note that n 1 Z + functions as a counter that increases by one when g 1 ( k ) 0

and resets to 0 when g 1 ( k ) > 0

. Moreover, n max Z + represents the counting threshold. The constraint (35) is employed to relax the solution limit only after n 1 reaches n max , thereby mitigating the potential issue of an unstable switching process.

The update of n 1 is formulated as

n 1 = sat ( n 1 + 1 ) ,

g 1 ( k ) 0 ,

n 1 = 0 , g 1 ( k ) > 0 ,

where the saturation function s a t ( · ) is defined as

sat ( x ) = n max , x > n max , x , e l s e .

The initialization of n 1 is as follows:

n 1 = n max , g 1 ( 0 ) < 0 ,

n 1 = 0 , e l s e ,

The implementation of the proposed method is shown as Algorithm 1.

Algorithm 1:Switching-based optimization control for target tracking
Require: The image captured by camera
Ensure: ( u 1 , v 1 ) 0 , ( u 2 , v 2 ) 0
    1:
Let k = 0 , calculate g 1 ( 0 )

, and initialize n 1 based on (43).

    2:

while Discover the target do

    3:

   Detect the centroid coordinates ( u 1 , v 1 ) ;

    4:
   Calculate ( u 2 , v 2 ) of the reference state (7);
    5:

   if  k = 0  then

    6:
     Obtain initial control sequence U ( k ) based on (31).
    7:

   else

    8:
     Obtain initial control sequence U ( k ) based on (32).
    9:

   end if

    10:

   Solve the optimization problem (39) online to obtain U ( k )

.

    11:

   Choose the first element of U ( k )

to be the control input.

    12:

    k = k + 1 .

    13:
   Obtain the control input of the pan-tilt based on (9).
    14:
   Calculate g 1 ( k )

and update n 1 based on (41).

    15:

end while

[ad_2]

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Accept Read More