Algorithm 3.
Conditional Exponential Method
| Input: | |
| Candidate i-subgraphs Ci; Privacy budget ϵc; Threshold θ; The number of frequent i-subgraphs ni; | |
| Output: | |
| Frequent i-subgraphs Fi; | |
| 1: | ϵc1 ← βϵc, ϵc2 ← (1-β)ϵc; |
| 2: | for j from 1 to ni do |
| 3: | Ci’ ← ∅; |
| 4: | for each subgraph g in Ci do |
| 5: | ; |
| 6: | if nsg ≥ θ then |
| 7: | add g into Ci’; |
| 8: | end if |
| 9: | end for |
| 10: | if Ci’ is not empty then |
| 11: | gj ← select a subgraph from Ci’ such that ; |
| 12: | remove gj from Ci; |
| 13: | add gj into Fi; |
| 14: | end if |
| 15: | end for |
| 16: | return Fi; |