I am very familiar with calculating gradients for single and multi-variable functions, as a vector containing partial derivatives.
However, when I want to calculate the gradient of a vector product, given some undefined vector, I do not understand the intuition. Say I want to calculate the gradient of $f(x) = x^Tx + c$ for some constant $c\in\mathbb{R}$
In my textbook, I have a simple table which evaluates this to $2x$. The constant of cause evaluates to zero, for any derivative by itself, but how does $x^Tx$ evaluate to $2x$?
What I am trying to understand is how intuitively to engage finding partial derivatives of a vector, without knowing its values.
I might think of $x^T$ as a vector containing multiple inputs: $[x_1,...,x_n] \in\mathbb{R}^n$ and similar for $x$ (but as a column vector), but how would I go about finding the gradient of such an expression?
Hint Expanding in components, we find that $$x^\top x = x_1^2 + \cdots + x_n^2 .$$