I am trying to find the gradient
$$\nabla \mbox{trace}(Axx^TB)$$
where both $A$ and $B$ are $n \times n$ matrices, and $x$ is an $n$-length column vector
I'm not exactly sure how to approach this problem in order to lead me to the solution. I know that $xx^T$ forms an $n \times n$ matrix with squares along the diagonal, but how do both other matrices multiply with that to achieve the trace?