I was reading Electromagnetism by David Tong. In Chapter 3 (Page 60), he deduced $$\mathbf{F} = ∇(\mathbf{B} \cdot \mathbf{m})\tag{3.28}$$ by Taylor expanding $\mathbf{B}$ around a certain point $\mathbf{r} = \mathbf{R}$. So I would think of this as the force of a current distribution with magnetic dipole $m$ would approximately experience in the space.
Then I got confused in the next section with this understanding. In the next chapter, Tong used this formula he derived to calculate the force between two dipoles. He first got, $$\mathbf{F} = \frac{\mu_0}{4\pi} \nabla \left[ \frac{3(\mathbf{m}_1 \cdot \hat{\mathbf{r}})(\mathbf{m}_2 \cdot \hat{\mathbf{r}}) - \mathbf{m}_1 \cdot \mathbf{m}_2}{r^3} \right]\tag{p.61}$$ and then $$\mathbf{F} = \frac{3\mu_0}{4\pi r^4} \left[ (\mathbf{m}_1 \cdot \hat{\mathbf{r}})\mathbf{m}_2 + (\mathbf{m}_2 \cdot \hat{\mathbf{r}})\mathbf{m}_1 + (\mathbf{m}_1 \cdot \mathbf{m}_2)\hat{\mathbf{r}} - 5(\mathbf{m}_1 \cdot \hat{\mathbf{r}})(\mathbf{m}_2 \cdot \hat{\mathbf{r}})\hat{\mathbf{r}} \right].\tag{3.31}$$ He still kept this $r$, saying that the dipole force drop off as $1/r^4$. But I don't understand how does this $r$ still mean anything here. It is not the distance between two dipoles. In Tong's own calculation, $$\mathbf{F} = \int_V d^3r \, \mathbf{J}(\mathbf{r}) \times \left[ (\mathbf{r} \cdot \nabla') \mathbf{B}(\mathbf{r}') \right] \Bigg|_{\mathbf{r}'=\mathbf{R}}.\tag{p.60}$$ He had this idea of evaluating at where $\mathbf{B}$ was expanded. But in the example, I cannot understand what does $r$ mean but a reference point you choose in space.