I am trying to optimize an an objective function which looks like the following
minimize sqrt((0.5*cos(theta1)+0.5*cos(theta2)-0.3)^2 + (0.5*sin(theta1)+0.5*sin(theta2)-0.3)^2)
There are constraints on theta1 and theta2.
Theta1 and Theta2 have a piecewise linear approximation.
How do I take into account the norm while feeding it to the gurobi optimizer?
I am aware of setPWLObj method but I am unsure how to take the square of the individual terms and then take its square root (or the L2 norm).