In your homework, you are asked to derive an expression for the gradient of the area of a triangle with respect to one of its vertices. In particular, if the triangle has vertices \(a,b,c \in \mathbb{R}^3\), then the gradient of its area \(A\) with respect to the vertex \(a\) can be expressed as

\[

\nabla_a A = \tfrac{1}{2} N \times (b-c).

\]

This formula can be obtained via a simple geometric argument, has a clear geometric meaning, and generally leads to a an efficient and error-free implementation.

In contrast, here’s the expression produced by taking partial derivatives via *Mathematica* (even after calling `FullSimplify[]`):

Longer expressions like these will of course produce the same values. But without further simplification (by hand) it will be less efficient, and could potentially exhibit poorer numerical behavior due to the use of a longer sequence of floating-point operations. Moreover, they are far less easy to understand/interpret, especially if this calculation is just one small piece of a much larger equation (as it often is).

In general, taking gradients the “geometric way” often provides greater simplicity and deeper insight than just grinding everything out in components. Your current assignment will give you some opportunity to see how this all works.

*Update:* As mentioned by Peter in the comments, here’s the expression for the gradient of angle via partial derivatives (as computed by Mathematica). Hopefully by the time you’re done with your homework, you’ll realize there’s a better way!