Cone programming formulation to solve non-convex optimization problem in generalized discrepancy algorithm