# GPU-Accelerated Eclipse-Aware Routing for SpaceWire-Based OBC in Low-Earth-Orbit Satellite Networks
## 2 Problem Description
### Energy Efficiency Problem in the LEO Network  
In LEO satellite networks, satellites recharge their batteries using solar energy. However, when entering an **eclipse** region, they can no longer receive solar energy, leading to a gradual depletion of battery reserves. These energy constraints significantly impact network stability and operational lifespan. If a specific satellite excessively consumes its battery power, it can degrade the overall network performance.  
Conventional routing algorithms primarily consider the shortest path or minimum latency; however, they do not account for the energy consumption of individual satellites. As a result, certain satellites may be repeatedly included in routing paths, leading to an imbalance in battery depletion. This imbalance can cause some satellites to drain their batteries prematurely, and in the worst-case scenario, it may result in network disconnection [23].  
To address this issue, this paper proposes the EAR approach, which distributes energy consumption more evenly across satellites. This method determines the optimal data transmission path by considering each satellite's eclipse duration, expected transmission load, and energy consumption rate.  
Algorithm 1 illustrates the computational flow of the EAR approach. This algorithm selects a routing path that ensures stable data transmission while minimizing energy consumption in LEO satellite networks. First, the algorithm initializes the energy consumption values for transmission, reception, and baseline operations. Then, it searches for K shortest paths available at the given time and calculates the energy consumption for satellites included in each path. To account for eclipse conditions, the algorithm determines whether each satellite is in eclipse and, if so, computes the eclipse duration. It then estimates the expected number of data transmissions during this period. Based on this estimation, the algorithm calculates the total energy consumption by summing the baseline operation energy and transmission/reception energy. Although the Depth of Discharge (DoD) is not explicitly computed, it is indirectly reflected in this energy model--satellites remaining in eclipse for extended periods with high communication load are considered at higher risk of battery depletion. For each path, the satellite with the highest estimated energy usage is identified, and the maximum value among all paths is used as a routing metric. The path with the lowest such value is selected to prevent overuse of energy-critical satellites, thus maintaining balanced energy consumption and avoiding early battery degradation. This approach is similar to previous studies that indirectly estimate DoD based solely on eclipse duration or reduce DoD risk by excluding or penalizing energy-critical satellites without direct DoD computation [9; 10].  
```
1 eclipseMatrix[time][nodes]
2 KShortestPaths[]
3 sampleTime
4 NoE, TxE, RxE
5 nTimeStep
6 minPath
7
8 Initialize Constants: NoE, TxE, RxE
9 Initialize Data Structures: expectedConsumedEnergy[]] <= 0;
10
11
12
13
14 For pathIndex = 0 \(\sim\) topPath
15 testingPath <= shortestPaths[pathIndex];
16
17 For satIndex = 0 \(\sim\) num_sats_in_path
18 testingSat <= testingPath[satIndex];
19
20
21 If eclipseMatrix[timeIndex, testingSat] == 1
22 Determine eclipseStartIndex and eclipseEndIndex;
23
24 eclipseTime = (eclipseEndIndex - eclipseStartIndex) * sampleTime;
25 expectedTxNum = round(eclipseTime * randi(10, 1, 1) * 0.01);
26
27
28 Compute Energy Consumption:
29 NominalE = eclipseTime * NoE;
30 CommunicationE = (expectedNum + 1) * (TxE + RxE)
31
32 ExpectedConsumedEnergy[pathIndex, satIndex] = NominalE +
33 CommunicationE;
34
35 End if
36 End for
37 End for
38
39 Compute Maximum Energy Consumtion per Path:
40 For pathIndex = 0 \(\sim\) topPath
41
42 maxEnergy[pathIndex] = max(ExpectedConsumedEnergy[pathIndex]);
43
44 End for
45
46
47
48 Select Optimal Path:
49
50
51 Return minPath;
```  
**Algorithm 1** **Eclipse Aware Routing--Pseudo-code representing the Eclipse Aware Routing method.**