title: Multiple variables in SciPy's optimize.minimize
body: <p>According to the <a href="http://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.minimize.html" rel="noreferrer">SciPy documentation</a> it is possible to minimize functions with multiple variables, yet it doesn't tell how to optimize on such functions.</p>
  
  <pre><code>from scipy.optimize import minimize
  from math import *
  
  def f(c):
    return sqrt((sin(pi/2) + sin(0) + sin(c) - 2)**2 + (cos(pi/2) + cos(0) + cos(c) - 1)**2)
  
  print minimize(f, 3.14/2 + 3.14/7)
  </code></pre>
  
  <p>The above code does try to minimize the function <code>f</code>, but for my task I need to minimize with respect to three variables.</p>
  
  <p>Simply introducing a second argument and adjusting minimize accordingly yields an error (<code>TypeError: f() takes exactly 2 arguments (1 given)</code>).</p>
  
  <p><strong>How does <code>minimize</code> work when minimizing with multiple variables.</strong></p>