1%{ @file cache_prob_erec.m
2 % @brief Computes cache hit probabilities
using recursive method
4 % @author LINE Development Team
8 % @brief Computes cache hit probabilities recursively
11 % This function computes cache hit probability distribution
using a
12 % recursive method based on normalizing constants.
16 % prob = cache_prob_erec(gamma, m)
21 % <tr><th>Name<th>Description
22 % <tr><td>gamma<td>Item popularity probabilities
23 % <tr><td>m<td>Cache capacity vector
28 % <tr><th>Name<th>Description
29 % <tr><td>prob<td>Cache hit probability distribution
32function prob = cache_prob_erec(gamma,m)
34E = cache_erec(gamma, m);
37 Ei = cache_erec(gamma(setdiff(1:n,i),:),oner(m,j));
38 prob(i,1+j) = m(j) * gamma(i,j) * Ei / E;
40 prob(i,1) = abs(1 - sum(prob(i,2:end)));