\[\begin{equation} \begin{aligned} \int \int_R &= \frac{\partial P}{\partial y} dy dx \int^b_a (\int^{f_2 (x)}_{f_1 (x)} \frac{\partial P}{\partial y} dy ) dx \\ &= \int^b_a [P(x, f_2 (x)) - P(x, f_2 (x))] dx \\ &= \int^b_a P(x, f_2 (x))dx - \int^b_a P(x, f_2 (x))] dx \\ &= - \int^a_b P(x, f_2 (x))dx - \int^b_a P(x, f_2 (x)) dx \\ &= \oint_C P(x,y) dx \end{aligned} \end{equation} \]
Hence,
\[\int \int_R \frac{\partial P}{\partial y} dxdy = - \oint_C P(x,y) dy \]
From the bottom diagram,\[\begin{equation} \begin{aligned} \int \int_R &= \frac{\partial Q}{\partial x} dx dy \int^d_c (\int^{g_2 (y)}_{g_1 (y)} \frac{\partial Q}{\partial x} dx ) dy \\ &= \int^b_a [Q(x, g_2 (x)) - Q(x, g_2 (x))] dy \\ &= \int^d_c Q(x, g_2 (x))dy - \int^d_c Q(x, g_2 (x))] dy \\ &= - \int^d_c Q(x, g_2 (x))dy + \int^c_d Q(x, g_2 (x)) dy \\ &= \oint_C Q(x,y) dy \end{aligned} \end{equation} \]
Hence,
\[\int \int_R \frac{\partial Q}{\partial x} dxdy = \oint_C Q(x,y) dy \]
Adding the two integrals gives
\[\int \int_R \frac{\partial Q}{\partial x}- \frac{\partial P}{\partial y} dxdy = \oint_C P(x,y)dx +Q(x,y) dy \]