Research Article

Enabling Device-to-Device (D2D) Communication for the Next Generation WLAN

Algorithm 2

Generating maximum independent sets
Input: , ,
Output:
1:
2: when is not empty do
3:   ,
4:   Select a D2D pair in as the initial node
5:   Add into , and remove it from
6:   for to ) do
7:     for to len() do
8:        ifthen
9:          
10:          Break
11:        end if
12:     end for
13:     ifthen
14:      Add D2D pair into and remove it from
15:        Update
16:     end if
17:   end for
18: end when
19: Sort ()
20:Return