Skip to content
Advertisement

Scipy Optimise (minimize) not giving correct results

I am trying to do a simple minimisation as below using SciPy optimise, but the expected results are NOT matching the optimiser output:

JavaScript

I would expect the final results to be close to “x_expected”… but that is not the case.. any ideas ?

Advertisement

Answer

SLSQP solver failed to find the optimal value for your problem.

JavaScript

Therefore, inequality constraint does not hold.

JavaScript
JavaScript

Initial guess [0, 0, 0, 0] can help find the optimal value for your problem.

JavaScript
User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement