Jordan algebraic approach to symmetric optimization