Maximize \(\prod_{t=1}^{T}{(1+p_th_t)}^{c_tw_t}\) subject to: C1: \(\sum_{t=1}^{T}c_tp_t\le P_{\rm{Max}}\) Here \(w_t>0\) and \(h_t>0\) are given constants and they are positive. \(T\) is an integer multiple of \(N\). asked 21 Feb '15, 00:34 dip 
Come back over to http://ask.cvxr.com/question/3756/howtowriteitincvxacceptableequivalentform/ where geo_mean awaits you. answered 21 Feb '15, 07:54 Mark L Stone @Mark L Stone, Thanks. Please note that the method mcg showed there is true only for binary z_t. In this setting, z_t are no more binary. Also note that z_t are variables not constant.
(23 Feb '15, 05:31)
dip
Of course what jfpuget wrote above is true, you "must" have other constraints you haven't told us about. As for z_t not being constant, I believe if you go back to constant w_t and binary variable c_t as you have in the CVX Forum thread, then you can use mcg's approach, if you include the w_t in the geo_mean argument, i.e., geo_mean(w.*q) where w is a vector of w_t. Note that the w_t cancel out in the extra constraints mcg adds to make the geo_mean work.
(23 Feb '15, 08:57)
Mark L Stone
@Mark L Stone: What do you mean by " w_t cancel out in the extra constraints mcg adds to make the geo_mean work."?
(23 Feb '15, 22:00)
dip
I was referring to the old mcg post which was linked to in the comments and incorporated extra constraints to make it work. Subsequently, mcg posted an answer in your thread which essentially incorporated the extra constraints into a modified objective. Either way should work.
(23 Feb '15, 22:24)
Mark L Stone
@Mark L Stone: Thanks a lot. Your method works fine. However, I do not know why I get error when I run mcg's method.
(24 Feb '15, 00:09)
dip

You can get rid of the ct variables altogether, thanks to the trick mcg gave in the cvx blog @Mark_Stone pointed to. Indeed, (1 + pt.ht)^(ct.wt) = (1 + pt.ct.ht) ^ wt Check for ct = 0 and for ct = 1 to see why. Then all yor constraints involve the products ct.pt Given pt is continuous, pt can range over all the values ct.pt can take. answered 23 Feb '15, 11:02 jfpuget Please answer my questions. 1) Are the ht positive? 2) Are there additional constraints besides the one we see here? I am asking because if ht >0 and there are no other constraint than the one with Pmax then your problem has an analytical solution IMHO. This solution is a derivative of geometric mean as @Mark L Stone suggested.
(24 Feb '15, 04:57)
jfpuget

\(z_t = c_t w_t\) is a linear constraint, and just does what you need.
There must be additional constraints to your problem. Indeed,
@dip You did not address the case where ht < 0