# How do I maximize a function instead of minimize?

Updated:

YALMIP always assumes minimization. Hence, to maximize, you simply negate your objective function. Note that this will lead to a non-convex objective function if the objective is convex.