In mathematics, concave function and convex function play an important role. Both the functions are related to each other. A concave function is the negative of a convex function. A function $f(x)$ is concave over a convex set if the function: $f(x)$ is a convex function over the set. Then, the result obtained for convex functions can be modified into result for concave functions by multiplication by -1 and vice versa. A concave function is also called as concave downwards, convex upwards, concave down, upper convex or convex cap.
The negative of a convex function is a concave function. Also sum of the concave functions is a concave function.

A real-valued function, $f$, for any $x$ and $y$ is said to be concave if it satisfied following conditions:
A function is concave if:

f($\lambda$x + (1 - $\lambda$)y) $\geq$ $\lambda$ f(x) + (1 - $\lambda$) f(y) ; For $\lambda$ $\in$ [0, 1]

A function is strictly concave if:

f($\lambda$x + (1 - $\lambda$)y) > $\lambda$ f(x) + (1 - $\lambda$) f(y) ; For x $\neq$ y and $\lambda$ $\in$ (0, 1).

A function is concave function if the straight line segment joining any two points on the function's graph:
Concave Function Definition
A function $g$ : $R$ $^n$ -> R is logarithmically concave if $g(x)$ > 0 for all $x$ $\in$ dom $f$ and log g is concave. Same function is said to be logarithmically convex if log $g$ is convex. If we are given with log convex function we can easily define log concave function, for example: if $g$ is log-convex then $\frac{1}{g}$ is log-concave.It is easy to allow g to take on the value zero, in which case we take log $g(x)$ = - $\infty$. In this case f is log-concave if the extended value function log $g$ is concave. While dealing with log-concave functions we should keep in mind that a non-negative concave function is log-concave. We can also called this function as quasi concave function, since the logarithm is monotone increasing.
The value a log-concave function at the average of two points is at least the geometric mean of the values at the two points.
Let us consider $g$ be a function of two variables $y$ and $z$ defined on the convex set $A$. Then $g$  is concave on the $A$, we have
         $g$ ((1 - $t$)$y$ + $tz$) $\geq$ (1 - $t$) $g (y)$ + $t g (z)$
for all $y$ $\in$ $A$, all $z$ $\in$ $A$, and all $t$ $\in$ (0, 1).

If function g satisfies the definition for concavity with a strict inequality (> rather than $\geq$). Then g is a strictly concave function for all y $\neq$ $z$.

A function of many variables, $g$($x_1, x_2, ...,x_n$) is a concave function iff the Hessian matrix, $H(x)$, is negative semi-definite.

$H(x)$ = $\begin{bmatrix}
\frac{\partial^2g }{\partial x_i\partial x_j}
\end{bmatrix}$ $\leq$ 0 ; for all x $\neq$ 0

The Hessian matrix, in case of a function of two independent variables $x_1$ and $x_2$ is as:

$H(x)$ = $\begin{bmatrix}
 \frac{\partial^2g }{\partial x_1^2}& \frac{\partial^2g }{\partial x_1 \partial x_2} \\
 \frac{\partial^2g }{\partial x_2\partial x_1}& \frac{\partial^2g }{\partial x_2^2}
\end{bmatrix}$
The principle of concave functions applies when a function is of many variables. Concave function of two variables is shown below:

Concave Function

There are various theorems based on the concave function. Let us discuss about one of them:
Suppose g$_1$, g$_2$, ....., g$_n$ are concave functions. Then g = $\sum_{i=1}^n$ $\lambda_i$g$_i$ is also a concave function ; for any $\lambda_1$, $\lambda_2$, ...., $\lambda_n$ and each $\lambda_j$  > 0. In addition, if atleast one g$_j$ is strictly concave and $\lambda_j$  > 0, then $g$ is strictly concave.

Proof: Let us consider $x, y$ $\in$ $X$ and t $\in$ (0, 1).

If each g$_i$ is concave, we have

$g_i$ $(tx + (1 - t)y)$ $\geq$ t g$_i$(x) + (1 - t)g$_i$(y)  (By the definition of concave function)

Therefore,

$g(tx + (1 - t)y)$ = $\sum_{i=1}^n$$\lambda_i$ g$_i$ (tx + (1 - t)y) > $\sum_{i=1}^n$$\lambda_i$(tg$_i$(x) + (1 - t)g$_i$(y))

= t $\sum_{i=1}^n$$\lambda_i$ g$_i$(x) + (1 - t)$\sum_{i=1}^n$$\lambda_i$g$_i$(y)

= t g(x) + (1 - t)g(y)

Hence g is concave. If some g$_i$ is strictly concave and $\lambda_i$ > 0, then the inequality is strict. 
A real valued function g(x) defined over a convex set S in R$^n$ is called quasi-concave if:

$g(x) \geq f(y)$

Then for all $x$, $y$ $\in$ $S$ and $t$ $\in$ [0, 1]

$g$ ($\lambda$x + (1 - $\lambda$)y) $\geq$ $g(y)$

A function that is concave over some domain is also quasiconcave over that domain similarly a strictly quasiconcave utility function is equivalent to a strictly convex set.
A linear utility functions predicts risk indifference, a concave utility function predicts risk-aversion and risk-proneness. For example, in risk conditions concave-down and concave-up utility functions act differently. Like in gambling, winning and losing have equal probability. In the concave down case the forager might lose more utility than it might win, so forager with a concave-down utility function would prefer not to gamble. In the concave-up case the forager might win more than it might loss, so it prefers to take the gamble.

On the other hand, when the utility funtion is not linear, we must know the shape of the utility function to predict preference in risk situations. For many applications, concave functions are more justifiable than convex utility functions.
Below are some examples based on concave function:

Example 1:
Suppose the function f of a single variable is concave on [c, d] and the function g of two variables is defined by $f(x, y)$ = $f(x)$ on [$c, d$] $x$ [$e, f$]. Show that $f$ concave?

Solution:
We can apply the definition of concavity since the domain of g is a convex set.

The function $g$ is depend upon two variables, so its graph will look like horizontal tunnel.

Now $g$((1 - $\lambda$)$(x, y)$ + $\lambda$)($x', y'$)) = $g$($\lambda$ $x'$ + (1 -$\lambda$)$x$, $\lambda$ $y$' + (1 - $\lambda$)y)

= $f$($\lambda$ $x$' + (1 - $\lambda$)$x$)

$\geq$ $\lambda$ $f(x')$ + (1 - $\lambda$)$f(x)$

= $\lambda$ $g(x', y')$ + (1 - $\lambda$)$g(x, y)$

Which satisfied the concave definition.

Hence $g$ is concave.

Example 2:
Suppose that $g_i$ is a concave function and $b_i$ > 0 (where i = 1, 2, 3,...., n), then prove that its linear combination is also a conave function.

Solution:
Since g$_1$, g$_2$, ...., g$_n$ are cocave functions and b$_1$ > 0, b$_2$ > 0,......, b$_n$ > 0

Now we have to prove that b$_1$g$_1$ + b$_2$g$_2$ + .....+ b$_n$g$_n$ is concave.

Let $G$ = b$_1$g$_1$ + b$_2$g$_2$ + .....+ b$_n$g$_n$

$G(tx + (1 - t)y)$ = $\sum$ $b_i$g$_i$$(tx + (1 - t)y)$

$\geq$ $\sum$ $b_i$ $((tg(x) + (1 - t)g(y))$

= $t$ $\sum$ $b_i$ g(x) + (1 - t)$\sum$ $b_i$g(y)

= $t G(x) + (1 - t) G(y)$

So linear combination of the concave function is concave.

Example 3:
Show that the following function is not a concave: $F(x)$ = $e^{2x}$

Solution:
Since $F(x)$ = $e^{2x}$
Find the second derivative of the function

$\frac{dF}{dx}$ = 2$e^{2x}$

$\frac{d^2F}{dx^2}$ = 4$e^{2x}$

$H(x)$ = $\frac{d^2F}{dx^2}$ = 4$e^{2x}$ > 0, for all real values of $x$.

Hence $F(x)$ is not a concave function.