I am trying to solve this simple simultaneous equations using scipy's fsolve function:
x + 2 = 10 & x^2 = 64.
I am expecting 8 as the solution. However I'm getting an error saying "minpack.error: Result from function call is not a proper array of floats."
I am pretty new to python scientific library. Can someone please explain how to solve this error? Thanks!
from scipy.optimize import fsolve
def equations(p):
x = p
return (x-8, x**2 - 64)
x = fsolve(equations, 1)
print(x)