Skip to main content
. 2025 Dec 11;25(24):7538. doi: 10.3390/s25247538
Algorithm 2 Pair Utility Optimization
  • Input: 

    TLE set (Two-Line Element data), ID (observer ID), location (observer coordinates)

  • Output: 

    sat_id of the best upcoming pass based on the local utility heuristic U(i,p) defined in Equation (12)

  •   1:

    passes ← UpcomingSatellitePasses(TLEs, location)

  •   2:

    if passes is empty then return No passes available

  •   3:

    end if

  •   4:

    if size(passes) = 1 then return passes[0].sat_id

  •   5:

    end if

  •   6:

    max_utility_found ← −∞

  •   7:

    best_pass ← NULL

  •   8:

    neighbors ← GetNeighbors(ID)

  •   9:

    for all pass in passes do

  • 10:

        prob_rx ← CalculateRxProb(ID, pass)

  • 11:

        utility_for_pass ← prob_rx

  • 12:

        for all neighbor in neighbors do

  • 13:

            prob_neighbor_rx ← CalculateRxProb(neighbor, pass)

  • 14:

            utility_for_pass ← utility_for_pass × (1 − prob_neighbor_rx)

  • 15:

        end for

  • 16:

        if utility_for_pass > max_utility_found then

  • 17:

            max_utility_found ← utility_for_pass

  • 18:

            best_pass ← pass

  • 19:

        end if

  • 20:

    end for

  • 21:

    return best_pass.sat_id