2.3 Derivatives of functions defined implicitly
One parameter
The equilibrium value of a variable x in some economic models is the solution of an equation of the formTypically, we make assumptions about the form of the function f—for example, we might assume that it is increasing in x and decreasing in p—but do not assume that it takes a specific form. Thus typically we cannot solve explicitly for x as a function of p (i.e. we cannot write x = g(p) for some function g).
We say that the equation
Before trying to determine how a solution for x depends on p, we should ask whether, for each value of p, the equation has a solution. Certainly not all such equations have solutions. The equation x^{2} + 1 = 0, for example, has no (real) solution. Even a single linear equation may have no solution in the relevant range. If, for example, the value of x is restricted to be nonnegative number (perhaps it is the quantity of a good), then for p > 0 the equation x + p = 0 has no solution.
If a single equation in a single variable has a solution, we may be able to use the Intermediate Value Theorem to show that it does. Assume that the function f is continuous, the possible values of x lie between x_{1} and x_{2}, and for some value of p we have f(x_{1}, p) < 0 and f(x_{2}, p) > 0, or alternatively f(x_{1}, p) > 0 and f(x_{2}, p) < 0. Then the Intermediate Value Theorem tells us that there exists a value of x between x_{1} and x_{2} for which f(x, p) = 0. (Note that even if these conditions are not satisfied, the equation may have a solution.)
If we cannot appeal to the Intermediate Value Theorem (because, for example, f is not continuous, or does not satisfy the appropriate conditions), we may be able to argue that a solution exists by appealing to the particular features of our equation.
Putting aside the question of whether the equation has a solution, consider the question of how a solution, if one exists, depends on the parameter p. Even if we cannot explicitly solve for x, we can find how a solution, if it exists, depends on p—we can find the derivative of x with respect to p, if it exists—by differentiating the equation that defines it. The principle to use is simple: if you want to find a derivative, differentiate!
Differentiating both sides of the equation f(x(p), p) = 0, using the chain rule, we get
This calculation tells you, for example, that if f is an increasing function of both its arguments (f'_{1}(x, p) > 0 and f'_{2}(x, p) > 0 for all (x, p)), then x is a decreasing function of p.
Application: slopes of level curves
The equation f(x, y) = c of the level curve of the function f for the value c defines y implicitly as a function of x: we can writeg'(x) = − 


= − 

. 
 Proposition (Implicit function theorem)

Let f be a continuously differentiable function of two variables defined on an open set S. If f'_{2}(x_{0}, y_{0}) ≠ 0 then there exists a continuously
differentiable function g of a single variable defined on an open interval I containing x_{0} such that f(x, g(x)) = f(x_{0}, y_{0}) for all x ∈ I, and
g'(x_{0}), the slope of the level curve of f for the value f(x_{0}, y_{0}) at the point (x_{0}, y_{0}), is
− f'_{1}(x_{0}, y_{0}) f'_{2}(x_{0}, y_{0}) .
We deduce that the equation of the tangent to the level curve at (x_{0}, y_{0}) is
y − y_{0} = − 

·(x − x_{0}). 
f'_{1}(x_{0}, y_{0})(x − x_{0}) + f'_{2}(x_{0}, y_{0})(y − y_{0}) = 0, 
(f'_{1}(x_{0}, y_{0}), f'_{2}(x_{0}, y_{0})) 

= 0. 
The vector (f'_{1}(x_{0}, y_{0}), f'_{2}(x_{0}, y_{0})) is called the gradient vector and is denoted ∇f(x_{0}, y_{0}).
Let (x, y) ≠ (x_{0}, y_{0}) be a point on the tangent at (x_{0}, y_{0}). Then the vector

One can compute the second derivative of the level curve as well as the first derivative, by differentiating once again.
Many parameters
Suppose that the equilibrium value of the variable x is the solution of an equation of the formRecording the dependence of x on p explicitly in the notation, we have
x'_{i}(p) = − 

. 
 Example

Consider the competitive firm studied previously that uses a single input to produce a single output with the differentiable production function f, facing the price w for the input and the price p for output. Denote by z(w, p) its profitmaximizing input for any pair (w, p). We
know that z(w, p) satisfies the firstorder condition
pf'(z(w, p)) − w = 0 for all (w, p).How does z depend on w and p?
Differentiating with respect to w the equation that z(w, p) satisfies we get
pf"(z(w, p))z'_{w}(w, p) − 1 = 0.Thus if f"(z(w, p)) ≠ 0 thenz'_{w}(w, p) = 1 pf"(z(w, p)) . A similar calculation yields
z'_{p}(w, p) = − f'(z(w, p)) pf"(z(w, p)) ,