Historical Context & Motivation
In single-variable calculus, you learned to find the high and low points of a curve by setting the derivative equal to zero. But what happens when a quantity depends on two or more variables at once? Think of a mountainous landscape: the elevation at any point depends on both how far north and how far east you are. Finding the tallest peak or the deepest valley on that surface requires a more powerful version of the "set the derivative to zero" idea. This need drove mathematicians over centuries to develop the tools of multivariable optimization.
Today, finding critical points of functions of two variables is central to fields ranging from engineering design to economics, wherever you need to optimize a quantity that depends on multiple inputs simultaneously. The central question this lesson addresses is: how do we systematically locate every candidate for a maximum, minimum, or saddle point on a surface?
Core Principles & Definitions
Before diving into calculations, you need to understand four key ideas that form the foundation of critical-point analysis for functions of two variables. A function f(x, y) assigns a single output value to every pair of inputs (x, y). You can visualize this as a surface hovering over the xy-plane, where the height at each point is f(x, y). The goal is to find the special points on that surface where the surface is perfectly "flat" — meaning it is neither tilting uphill nor downhill in any direction.
Partial Derivative with Respect to x
Partial Derivative with Respect to y
Critical Point
Saddle Point
Visual Explanation — The Geometry of Critical Points
The diagram below illustrates three types of critical points on surfaces of two variables. On the left, a local maximum looks like the top of a dome — the surface slopes downward in every direction from the peak. In the center, a saddle point curves upward along one axis and downward along the other. On the right, a local minimum is like the bottom of a bowl — the surface rises in every direction. At each of these points, the tangent plane is perfectly horizontal.
Notice that the condition fx = 0 and fy = 0 is the same at all three types of critical points. This is precisely why finding critical points is only the first step — you must later classify them (using a second derivative test) to determine which type each critical point is. In this lesson, however, our focus is on the finding step itself.
Mathematical Framework
The mathematical procedure for finding critical points of a function f(x, y) is a direct extension of the single-variable technique. In one variable, you set f′(x) = 0. In two variables, you set both partial derivatives equal to zero simultaneously and solve the resulting system of equations.
Let's look at how to compute partial derivatives. If f(x, y) = 3x² + 2xy − y², then to find fx you differentiate with respect to x while treating y as a constant. The term 3x² becomes 6x, the term 2xy becomes 2y (since y is treated as a constant coefficient), and the term −y² becomes 0 (it's a constant with respect to x). Combining these results gives fx = 6x + 2y.
Classifying Critical Points — A Preview
Once you have found the critical points, the natural next question is: which are maxima, which are minima, and which are saddle points? Although full classification is a separate topic, understanding the Second Derivative Test (Discriminant Test) in outline form will help you appreciate why finding the critical points is such a crucial first step.
| Condition at Critical Point | Discriminant D | Classification |
|---|---|---|
| D > 0 and fxx > 0 | D = fxx × fyy − (fxy)² | Local Minimum |
| D > 0 and fxx < 0 | Positive | Local Maximum |
| D < 0 | Negative | Saddle Point |
| D = 0 | Zero | Inconclusive — further analysis needed |
For the remainder of this lesson, we focus on Steps 1 and 2 — computing the partial derivatives and solving the system to locate the critical points. Mastering this process is essential before moving on to classification.
Worked Example
Let's walk through a complete example of finding the critical points of a function of two variables.
Strengths, Limitations & Common Pitfalls
Understanding the strengths and limitations of the critical-point method helps you apply it effectively and avoid common mistakes.
| Strengths | Limitations / Pitfalls |
|---|---|
| Works for any differentiable function of two variables — polynomials, exponentials, trigonometric functions, and more. | Only finds interior critical points. If the domain is restricted (e.g., a closed region), you must also check the boundary separately. |
| The process is algorithmic: compute two derivatives, set them to zero, solve the system. It is systematic and repeatable. | The resulting system of equations can be nonlinear and hard to solve, especially for functions with transcendental terms like sin or e. |
| Directly extends the one-variable technique you already know: set the derivative equal to zero. | Finding critical points tells you where potential extrema are, but not what type they are. You need the second derivative test for classification. |
| Provides all candidate points for local extrema in a single procedure, so you don't miss any. | Students often forget to solve the system simultaneously. Setting f_x = 0 alone gives a curve, not a point — you need both equations together. |
Connection to Advanced Theory
The critical-point technique for two variables generalizes directly to functions of three, four, or even hundreds of variables. In advanced courses and real-world applications, the same fundamental principle applies: set all partial derivatives equal to zero. The table below compares the two-variable case you've learned with the general n-variable case you'll encounter later.
| Feature | Two-Variable Case f(x, y) | General n-Variable Case f(x₁, x₂, …, xₙ) |
|---|---|---|
| Number of equations | 2 (fx = 0 and fy = 0) | n equations (∂f/∂xi = 0 for each variable) |
| Classification tool | Discriminant D = fxxfyy − (fxy)² | Hessian matrix (an n × n matrix of all second partial derivatives) |
| Visualization | 3D surface in xyz-space | Cannot be visualized directly; rely on algebra and linear algebra |
| Applications | Surface area, profit with two inputs, physics with two degrees of freedom | Machine learning (millions of variables), portfolio optimization, engineering design |
In machine learning, for example, neural networks have functions with millions of parameters, and training the network is essentially a massive critical-point search. The gradient (the vector of all partial derivatives) is computed, set toward zero, and the system is solved iteratively. The same principle you are learning right now — set every partial derivative to zero — scales up to power the technology behind image recognition, language translation, and much more.
Practice Problems
Test your understanding with these five problems, arranged from conceptual understanding through critical thinking. Work through each one on paper before checking the answer.
Lesson Summary
To find critical points of a function f(x, y), you compute both partial derivatives — fx (differentiate with respect to x, holding y constant) and fy (differentiate with respect to y, holding x constant) — then set both equal to zero and solve the resulting system of equations simultaneously. Each solution (a, b) is a critical point where the tangent plane is horizontal, making it a candidate for a local maximum, local minimum, or saddle point.
The key algebraic challenge varies with the function: if there are no cross-terms (like xy), the two equations decouple and you solve each independently. When cross-terms are present, you must use substitution or elimination to solve the coupled system. Once you've found all critical points, you can classify them using the second derivative test (discriminant D), which is the natural next step in multivariable optimization.