0

I am looking the example on the page:

http://cvxopt.org/examples/book/maxent.html

The problem statement is:

# minimize     p'*log p
# subject to  -0.1 <= a'*p <= 0.1
#              0.5 <= (a**2)'*p <= 0.6
#             -0.3 <= (3*a**3 - 2*a)'*p <= -0.2
#              0.3 <= sum_{k:ak < 0} pk <= 0.4
#              sum(p) = 1

but the last line

#              sum(p) = 1

is never implemented it seems ?

Zanam
  • 4,607
  • 13
  • 67
  • 143

1 Answers1

2

It is implemented in the line

A, b = matrix(1.0, (1,n)), matrix(1.0)
qua
  • 972
  • 1
  • 8
  • 22