Higher Order Derivatives--Cobb Douglas
We have the following general form for the Cobb-Douglas Production Function
The first order condition is
The derivative we have obtained is just another function. We can take additional derivatives with respect to this function.
Matlab symbolic toolbox gives us the same answer:
f(L, K0, alpha) = K0^(alpha)*L^(beta);
frsDeri = diff(f, L)
frsDeri(L, K0, alpha) = 
secDeri = diff(diff(f, L),L)
secDeri(L, K0, alpha) = 
You can specify an additional parameter for the matlab diff function, if we want to take multiple derivatives:
f(L, K0, alpha) = K0^(alpha)*L^(beta);
fifthDeri = diff(f, L, 5)
tenthDeri(L, K0, alpha) = 
Curvature and Second Derivative, Concave Function
Let's graph out the second derivative when
. The production function is concave (concave down). For a function that is twice continuously differentiable, the function is concave if and only if its second derivative is non-positive (never accelerating). % Note that we have 1 symbolic variable now, the others are numbers
f(L) = K0^(alpha)*L^(beta);
% note fDiff1L >= 0 always
fDiff1L = diff(f, L)
fDiff1L(L) =

% note fDiff2L <= 0 always
fDiff2L = diff(f, L, 2)
fDiff2L(L) =

% fplot plots a function with one symbolic variable
title({'Concave f(x), with K=1, beta=0.5 (decreasing return to scale for L)' 'First and Second Derivatives'})
ylabel({'First derivative is slope=f increase or decrease' '2nd deri is curvature=f increase faster or slower'})
xlabel('Current level of Labor')
legend(['f(x)'], ['First Derivative'], ['Second Derivative'], 'Location','SE');
Curvature and Second Derivative, Convex Function
Let's graph out the second derivative when
. The production function is convex (concave up). For a function that is twice continuously differentiable, the function is convex if and only if its second derivative is non-negative (never decelerating). % Note that we have 1 symbolic variable now, the others are numbers
f(L) = K0^(alpha)*L^(beta);
fDiff1L = diff(f, L)
fDiff1L(L) =

fDiff2L = diff(f, L, 2)
fDiff2L(L) =

% fplot plots a function with one symbolic variable
title({'Convex f(x), with K=1, beta=1.2 (increasing return to scale for L)' 'First and Second Derivatives'})
ylabel({'First derivative is slope=f increase or decrease' '2nd deri is curvature=f increase faster or slower'})
xlabel('Current level of Labor')
legend(['f(x)'], ['First Derivative'], ['Second Derivative'], 'Location','NW');