TITLE: Classify functions into convex, concave, non-convex, non-concave?
QUESTION [0 upvotes]: Hi how do you classify these functions into convex, concave, non-concave or non-convex? 
Can someone explain the method/theorems used etc.
1.) $f(x_1,x_2)=1+5x_1 +2x_2 +9x_1^2+x_2^2-6x_1x_2$
2.) $f(x_1,x_2,x_3)=ln(x_1^2+x_2^2+1)+x_3^4$
Thanks

REPLY [1 votes]: Way 1:

try to put it in the form $x^T Q x + \alpha x_1 + \beta x_2 + \gamma$, if $Q$ is positive definite then it's convex, if negative definite then convave.
the only term you need to check is the first one, given the two variables are separated you only really need to check $\log(x^2)$ (non convex)

Way 2:
compute the hessian (easy in both cases) and check if it's positive definite (convex), negative definite (concave) or neither
{"set_name": "stack_exchange", "score": 0, "question_id": 1943898}