# ✅ Checkpoint: curvature and convexity

By Better Wise



## Quiz

1. For a twice differentiable scalar function f: R^n -> R, what is the Hessian H(x)?
   - The n x n matrix of second partial derivatives, H_ij = d2f / dx_i dx_j
   - The Jacobian of f itself, which is a 1 x n row vector
   - The n x 1 vector of first partial derivatives
   - The matrix of third partial derivatives, used only for degenerate points
2. At a critical point x* (so grad f(x*) = 0), the Hessian has eigenvalues 3 and -1. What is x*?
   - Inconclusive, because the eigenvalues have different magnitudes
   - A saddle point
   - A strict local maximum
   - A strict local minimum
3. In two dimensions, a critical point has det H > 0 and H_11 < 0. What does the determinant shortcut conclude?
   - A saddle point
   - A local minimum
   - The test is inconclusive
   - A local maximum
4. For f(x, y) = x^2 + y^4, the Hessian at the origin is diag(2, 0). What can you conclude from the second-order test alone?
   - The origin is a strict local minimum
   - The origin is a saddle point
   - Nothing: the test is inconclusive because of the zero eigenvalue
   - The origin is a strict local maximum
5. Which statements about the Hessian and its eigenvalues are correct? Select all that apply.
   - The second directional derivative along a unit vector v is v^T H v.
   - The Hessian is the Jacobian of the gradient field.
   - A large condition number lambda_max / lambda_min means the curvature is nearly isotropic.
   - The trace of H equals the sum of its eigenvalues.
   - The eigenvalues of H(x) classify x as a minimum or maximum even when grad f(x) is nonzero.
6. Which statements about Taylor models and convexity are correct? Select all that apply.
   - The quadratic term in the Taylor model is p^T H p, with no factor of one half.
   - The second-order Taylor model is f(x) + grad f(x)^T p + (1/2) p^T H(x) p.
   - H(x) positive semidefinite at a single point is enough to prove f is convex.
   - For a convex differentiable function, every critical point is a global minimum.
   - A twice differentiable f is convex on a convex domain exactly when H(x) is positive semidefinite at every point of that domain.
7. At a critical point, a Hessian with both positive and negative eigenvalues indicates a ____.
8. For f(x, y) = x^2 + xy + y^2, the Hessian is [[2, 1], [1, 2]]. Its eigenvalues are 1 and 3, both positive everywhere, so f is strictly ____.
9. Derive the Hessian of f(x, y) = x^2 y + y^2 + x by hand, then evaluate it at (1, 1) and classify the local behavior of the second-order Taylor model there. Explain what the eigenvalues tell you about the model.
10. Explain why convexity upgrades a local minimum to a global minimum, and give one example from the lesson where a local minimum is not global because convexity fails.


---

## Contents

Part of [🧮 Mathematics for Machine Learning 2: Calculus and Optimization for Training Models](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training.md)

- **📐 First-order derivatives: gradients, Jacobians and the chain rule**
  - [📐 From partial derivatives to the gradient vector](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/partial-derivatives-to-gradient-vector.md)
  - [🧮 Jacobians of vector-valued functions](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/jacobian-vector-valued-functions.md) (sign-in required)
  - [🔗 Chain rule for composed functions](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/chain-rule-composed-functions.md)
  - [✅ Checkpoint: first-order derivatives](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/checkpoint-first-order-derivatives.md)
- **📉 Second-order behavior and convexity**
  - [🌀 Hessians and second-order behavior](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/hessians-second-order-behavior.md)
  - [📈 Taylor expansions, convexity and local minima](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/taylor-expansions-convexity-local-minima.md)
  - [✅ Checkpoint: curvature and convexity](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/checkpoint-curvature-and-convexity.md) — this lesson
- **⛰️ Constrained optimization and gradient descent**
  - [⚖️ Lagrange multipliers for constrained problems](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/lagrange-multipliers-constrained-problems.md)
  - [🔽 Gradient descent and learning rate behavior](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/gradient-descent-learning-rate-behavior.md) (premium content)
  - [✅ Checkpoint: constrained optimization and descent](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/checkpoint-constrained-optimization-descent.md) (premium content)
- [Course cheatsheet](https://everwise.study/courses/mathematics-for-machine-learning-2-calculus-and-optimization-for-training/cheatsheet.md) (premium content)
