## Application of Stokes' theorem

Evaluate the following integrals

$I_1 = \oint \vec{r} (\vec{a} \cdot \vec{n}) dS$,
$I_2 = \oint (\vec{a} \cdot \vec{r})\vec{n} dS$,

where $\vec{a}$ is a constant vector, and $\vec{n}$ is an unit vector normal to the closed surface $S$.

I'm not sure whether the Stokes's theorem can be used in this case. For instance, if we write the integrals in the component notation

$I_1 = \oint x_i (a_j dS_j)$,
$I_2 = \oint (a_j x_j)dS_i$,

then the Stokes' theorem would suggest the supstitution $dS_i \to dV \partial_i$ where $S=\partial(V)$. This results in

$I_1 = \int (a_j \partial_j) x_i dV=\vec{a} V$,
$I_2 = \int \partial_i (a_j x_j)dV=\vec{a} V$.

Is this correct?