# Line integral problem / integrating a vector equation

For this problem, I'm just confused on how to start by coming up with an equation $f(x,y)$ such that $F = \nabla \cdot f$. Everything I've been trying seems to not work. How should I get started?
You're basically calculating the work exerted by a force field $$\mathbf f : \mathbb R^2 \to \mathbb R^2, \qquad \mathbf f(\mathbf x) = (-2x_2,x_2)$$ along the segment $S = \{\mathbf x \in \mathbb R^2\ |\ \mathbf x = (0,0)+t(1,2),\ t \in [0,1] \}$.
Therefore you may parametrize your segment with the function $$\mathbf r : [0,1] \to \mathbb R^2, \qquad \mathbf r(t) = (t,2t),$$ whose derivative is $\mathbf r'(t) = (1,2)$. Then your integral becomes $$\begin{split} \int_C \mathbf f(\mathbf x) \cdot d\mathbf r &= \int_0^1 \mathbf f(\mathbf r(t)) \cdot \mathbf r'(t)\ dt \\ &= \int_0^1 (-2(2t),(2t)) \cdot (1,2)\ dt \\ &= \int_0^1 (-4t + 4t )\ dt = \int_0^1 0\ dt = 0. \end{split}$$