|
1: Procedure: m(B, C, D, N) //selecting interface |
for an application requirement app |
2: B ⟵ set bandwidth requirement |
3: C ⟵ set cost requirement |
4: D ⟵ set delay requirement |
5: N ⟵ set network utilization requirement |
6: SET sk,n = 1 such that sknε S(m×t) //Interface ⟵ select a random network ID for initialization |
7: SWITCH app’s access preferences (B, C, D, Nn) |
8: CASE B: |
9: IF bkn >= ba such that bk,nε B(m×t) //if the current network interface meets application bandwidth requirements then, |
10: RETURN B |
11: ELSE B(m×t) >= ba such that B(m×t) = B = Blte = Bwave = Bwifi //compare it with |
//the bandwidths available to other access networks |
12: RETURN B //network interface with highest bandwidth support |
13: BREAK; |
14: CASE C: |
15: C(m)= ∑ C(e) //sum of costs of all links “e” |
ckε C(m) |
16: For all C(m), ckε C(m) do //FOR get the list of networks to iterate and sort in the increasing cost order |
17: RETURN (min(∑ck)) //return the network interface with least cost. k, m |
18: BREAK; |
19: CASE D: |
20: IF dkn <= da such that dk,nε D(m×t) where ∑dtotal,k = dproc + dqueu + dtrans + dprop |
//if the current network interface meets the delay requirements then, return void |
21: ELSE D(m×t) <= dasuch that D(m×t) = dtotal = dltetotal = dwavetotal = dwifitotal |
//compare it with the delays of other access networks |
22: RETURN ∀ dtotale D |
min(∑dtotal) |
total, m //return the network interface with least delay |
23: BREAK; |
24: CASE default: |
25: For all ck = 0 to n, //where n is the nth cost amount subject to vector of unit cost, that is, C(m), cke C(m) |
//FOR get the list of network interfaces to iterate and sort in an increasing cost order |
26: IF Nn >=Nasuch that bk,ne B(m×t) and dk,ne D(m×t), where Nn = B dtotal,n |
//if the current network interface meets bandwidth and delay requirements then, |
27: RETURN Nn |
28: ELSE Nn < Na such that Nn = Ninclte = Nincwave = Nincwifi and Ninclte = Blte dltetotal, Nincwave = Bwave dwavetotal, Nincwifi = Bwifi dwifitotal |
//compare it with the bandwidth and delay for other available access networks, and |
29: RETURN (max(∑Ninc)) //the one with highest bandwidth and least delay |
Nince N |
30: BREAK; |
31: F sk,n = 0 //no network interface is assigned then, |
32: RETURN false; |
33: ELSE RETURN true; |
|