Algorithm 1 Predicting the probability of directly contacting a Wi-Fi Access Point (AP) within a time constraint |
Input: the starting region , the starting time interval t, the stop time interval . Output: Initialize: 1: OneStepTransition() { 2: if ( contains a Wi-Fi AP) then 3: ; 4: else 5: Getting the staying time intervals d and using (2); 6: ; 7: if then 8: for every possible next region do 9: Calculating using (1); 10: Calculating using (3); 11: ; 12: ; 13: Calling OneStepTransition() 14: end for 15: end if 16: end if } 17: return ; |