Skip to main content
. 2023 Jan 8;23(2):723. doi: 10.3390/s23020723
Algorithm 2 Joint Optimization Algorithm for Maximizing Energy Efficiency
  • 1:

    Initialize variables τI0, QU0, PI0, and Dloc0. Set the minimum error value ϵ>0. Let the number of iterations r=0, update rate ξ=1, and update factor ε=0.1.

  • 2:

    Given QUr conditions, use the continuous convex optimization approximation algorithm to solve problem (P2), obtain optimal solutions τI*, PI*, Dloc*, and let τIr+1=ξ(τI*τIr)+τIr, PIr+1=ξ(PI*PIr)+PIr, Dlocr+1=ξ(DI*DIr)+DIr.

  • 3:

    Given τIr+1, PIr+1, and Dlocr+1, Algorithm 1 is used to solve problem (P3), obtain the optimized relay UAV trajectory QU*, and let QUr+1=ξ(QI*QIr)+QIr.

  • 4:

    Update the number of iterations r=r+1, ξ=ξ/1+r1×ε.

  • 5:

    Calculate the increment of the target value Δ. If Δ<ϵ, then the algorithm converges and ends. Otherwise, continue with steps 2–4.

  • 6:

    Output the optimized solution τI*, QU*, PI*, Dloc*, and the maximum secret energy efficiency.