Oct-19-2020, 11:45 AM
I want to find the global minima of a two-variables function, say V(x,y,T), where (x,y) are the independent variables and `T' is the parameter. My target is to find the global minimum/ minima (minima of the function which has two variables is determined by https://en.wikipedia.org/wiki/Second_par...ative_test) of the function V(x,y,T) for a fixed value of the parameter T. I want to use the package 'scipy.optimization.brute'. At first, please confirm whether I am right or wrong.
I am pasting a sample example from (https://scipy-lectures.org/intro/scipy/a...mple2.html)
This example is for single-variable-function. I have no idea how to put the input for the two-variables case.
I am pasting a sample example from (https://scipy-lectures.org/intro/scipy/a...mple2.html)
[python] from scipy import optimize # Global optimization grid = (-10, 10, 0.1) xmin_global = optimize.brute(f, (grid, )) print("Global minima found %s" % xmin_global)[/python]
This example is for single-variable-function. I have no idea how to put the input for the two-variables case.