Why is there a difference between the internal and external calculation of the same summation formula in CVX?

I’m not sure what your question is. But the following answers my guess as to what your question is.

See my paragraph 1., starting from the 2nd sentence of the paragraph at The problem shows that it has been resolved, but there is a constraint that is not satisfied .