Optimization of relative entropy - MathOverflow most recent 30 from http://mathoverflow.net 2013-05-24T03:44:37Z http://mathoverflow.net/feeds/question/43555 http://www.creativecommons.org/licenses/by-nc/2.5/rdf http://mathoverflow.net/questions/43555/optimization-of-relative-entropy Optimization of relative entropy skypemesm 2010-10-25T17:50:08Z 2010-11-13T17:06:53Z <p><em>Wondering if my following question is an application of information theory:</em></p> <p>Lets say we have a factory and ship boxes of stuff outside. If a competitor stands outside my factory, observes the stream of boxes coming out of a factory and note their sizes, he can get valuable information about my manufacturing process. So in order to hoodwink him, I manually expand the boxes to sizes different than the original ones. In order to make sure that I am doing a good job at masking the original size distribution from the resultant distribution, I must make sure that I maximize relative entropy between output distribution q and input distribution p, given that I cannot just create a uniform output distribution. Is this premise correct? Do you find any flaw in the question?</p> <p>The constraint, of course, is that we must use minimum amount of box material. In other words, sum of box sizes for a unit period of time must not exceed a threshold B.<br> i.e. $\frac{\sum_{j=1}^{i}{BS_i}}{T} \le B$</p> <p>Other constraints are: </p> <p>1] Both p and q must be probability distributions i.e. sum up to 1<br> 2] $BS_i \le MS$, where MS is the maximum size of a box. </p> <p>--</p> <p>If we take $BS_i$ as the size of the $i^{th}$ box, then we have an optimization function applying Lagrange multiplier $\lambda$:</p> <p>$\Lambda(BS_i,\lambda,p,q) = D(q||p) + \lambda (\frac{\sum_{j=1}^{i}{BS_i}}{T} - B)$ $= \sum_{S=1}^{n}{q(S) \log \frac{q(S)}{p(S)}} + \lambda (\frac{\sum_{j=1}^{i}{BS_i}}{T} - B)$</p> <p>$= \sum_{S=1}^{n}{q(S) \log q(S)} -\sum_{S=1}^{n}{q(S) \log p(S)} + \lambda (\frac{\sum_{j=1}^{i}{BS_i}}{T} - B)$</p> <p><strong>To proceed:</strong> Lets say we at the $i^{th}$ iteration. We know the actual box sizes that we already sent out for 1...i-1 iterations, and the actual size of the present box. i.e. $BS_0..BS_i$ are known, and hence p(BS) can be calculated and hence is a known value. We know the output box sizes till the $i-1^{th}$ iteration. </p> <p>So, we have,</p> <p>$\Lambda(BS_i,\lambda,q) = \sum_{S=1}^{n}{q(S) \log q(S)} -\sum_{S=1}^{n}{k*q(S) } + \lambda (\frac{\sum_{j=1}^{i}{BS_i}}{T} - B)$</p> <p>How do we now solve the optimization function, in order to get the output box size for this $i^{th} iteration?</p> <p>We have,$\frac{\partial\Lambda}{\partial BS_i} = 0$,$\frac{\partial\Lambda}{\partial q(S)} = 0$, and$\frac{\partial\Lambda}{\partial \lambda} = 0$</p> <p>The pertial differentiation wrt$\lambda$results in a trivial solution. Since q(S) is dependent on$BS_i$, we will get a factor of$\frac{\partial q(S)}{\partial BS_i}$in the other two equations.</p> <p>How do I proceed from here? What I am thinking wrong?</p> http://mathoverflow.net/questions/43555/optimization-of-relative-entropy/43573#43573 Answer by S. Sra for Optimization of relative entropy S. Sra 2010-10-25T20:23:09Z 2010-10-25T20:23:09Z <p>Two observations:</p> <ol> <li><p>Are you sure that you have to <em>maximize</em> and not <em>minimize</em>? Relative entropy is a convex function, and usually maximizing convex functions is not a very nice thing --- the solution will be on the boundary of your feasible set.</p></li> <li><p>In your formulation above, you have missed out the constraint that$q$should be a distribution. Without that constraint, the expression that you have written will reach its supremum by letting$q(S) \to \infty$for any index$S$.</p></li> </ol> http://mathoverflow.net/questions/43555/optimization-of-relative-entropy/45937#45937 Answer by Rod Carvalho for Optimization of relative entropy Rod Carvalho 2010-11-13T16:56:23Z 2010-11-13T17:06:53Z <p>Let us imagine that your factory manufactures two products, one of which is <em>small</em>, and the other is <em>large</em>. These products are shipped out in boxes. Suppose that your boxes come in two sizes, <em>small</em> and <em>large</em>. Suppose further that you can ship a small product in a large box, but that you cannot ship a large product in a small box.</p> <p>Instead of products / boxes of various sizes, a more information-theoretic way of looking at things would be to think of the factory as a <em>binary source</em>, and to view the box-enlargement process as a <em>binary channel</em>. Let$X$and$Y$be discrete random variables with alphabets$\mathcal{X}$and$\mathcal{Y}$, respectively, where$\mathcal{X} = \mathcal{Y} = \{0,1\}$. If the output of the production line is a small product, then$X = 0$, otherwise$X = 1$. If a small box is shipped out, then$Y = 0$, otherwise$Y = 1$. Hence, the random variable$X$gives us the size of the product, while the random variable$Y$gives us the size of the box. We can view$X$and$Y$as the input and output of a binary channel, respectively. </p> <p>To deceive your competitors, every time a small product is ready to be shipped you flip a coin and, depending on the outcome, you choose to ship the small product in a large box or not. If you do so, then$X = 0$and$Y = 1$. The "channel" has introduced an error. The channel is defined by the transition probabilities</p> <p>$\{ \mathbb{P}[Y = 0 \mid X = 0], \mathbb{P}[Y = 1 \mid X = 0], \mathbb{P}[Y = 0 \mid X = 1], \mathbb{P}[Y = 1 \mid X = 1] \}$.</p> <p>A competitor observes the sizes of the boxes being shipped out and tries to infer what the actual sizes of the products inside the boxes are. In other words, your competitor would like to infer what the probability mass function (p.m.f.) of$X$is, knowing only the p.m.f. of$Y$. To keep your competitor maximally confused, you would like to maximize the conditional entropy$H (X \mid Y)$, which is the uncertainty about$X$given$Y$. Recall that the <a href="http://en.wikipedia.org/wiki/Mutual_information" rel="nofollow">mutual information</a> is </p> <p>$I (X;Y) = H(X) - H(X \mid Y)$</p> <p>and it gives us the reduction in the uncertainty of$X$due to knowledge of$Y$. We would like to minimize the mutual information, which is equivalent to maximizing the conditional entropy$H(X \mid Y)$, as$H(X)$is fixed (depends on the p.m.f of$X$, which is assumed to be fixed).</p> <p>The mutual information can be written as$I(X;Y) = D( p(x,y) \| p(x) p(y) )$, which is the <a href="http://en.wikipedia.org/wiki/Kullback%E2%80%93Leibler_divergence" rel="nofollow">Kullback-Leibler</a> distance between the joint p.m.f. and the product of the marginal p.m.f.'s. Check [1] for details. Therefore, you have a <strong>relative entropy minimization problem</strong>. </p> <p>Usually, we are given the channel, and we choose the p.m.f. of$X$that maximizes the mutual information$I(X;Y)$. In this problem, we are given the p.m.f. of$X\$, and we choose the channel that minimizes the mutual information. It's a sort of "dual" of finding the capacity of a given channel.</p> <p>References:</p> <p>[1] Thomas M. Cover and Joy A. Thomas, <em>Elements of Information Theory</em>, John Wiley &amp; Sons 2006.</p>