Q = magic(5); x = sdpvar(5,1); solvesdp([-1 <= x <= 1],x'*Q*x)