I would like to optimize function with SLSQP solver. The function contains 5 parameters, and I would like to add a constraint that x[0] > x[3]
. The following code makes x[0]=x[3]
. Can you help me to modify it to "x[0] > x[3]
"
cons = {'type':'eq', 'fun': lambda x: x[0] - x[3]}
res = minimize(model_calib, xo, bounds=[(100,8000),(0,650),(0,1),(5,550),(0,3)], method='SLSQP',constraints = cons)
Best regards,