Find the area of the region in the first quadrant enclosed by the X axis, the line $y = x$ and the circle $x^2 + y^2 = 32$
$x^2 + y^2 = 32$ is a circle with center at $O \left(0,0\right)$ and radius $\sqrt{32}$ units.
The line $y = x$ and the circle intersect at the the point $A \left(4,4\right)$.
Required area is the shaded region OAB.
From the figure, $\text{Area OAB} = \text{Area OAC} + \text{Area ABC}$ $\;\;\; \cdots \; (1)$
Let $\text{Area OAC} = \left|I_1\right|$. Here
$\begin{aligned}
I_1 & = \int \limits_{0}^{4} y \; dx \hspace{2em} \left[\text{where } y = x\right] \\\\
& = \int \limits_{0}^{4} x \; dx = \left[\dfrac{x^2}{2}\right]_{0}^{4} = \dfrac{16}{2} = 8
\end{aligned}$
$\therefore$ $\text{Area OAC} = 8$ sq units $\;\;\; \cdots \; (2)$
Let $\text{Area ABC} = \left|I_2\right|$. Here
$\begin{aligned}
I_2 & = \int \limits_{4}^{\sqrt{32}} y \; dx \hspace{2em} \left[\text{where } y = \sqrt{32 - x^2}\right] \\\\
& = \int \limits_{4}^{\sqrt{32}} \sqrt{32 - x^2} \; dx \\\\
& = \int \limits_{4}^{\sqrt{32}} \sqrt{\left(4 \sqrt{2}\right)^2 - \left(x\right)^2} \; dx \\\\
& \hspace{2em} \left[\text{Note: }\int \limits_{p}^{q} \sqrt{a^2 - x^2} \; dx = \left[\dfrac{x}{2} \sqrt{a^2 - x^2} + \dfrac{a^2}{2} \sin^{-1} \left(\dfrac{x}{a}\right)\right]_{a}^{b}\right] \\\\
& = \left[\dfrac{x}{2} \sqrt{32 - x^2} + \dfrac{32}{2} \sin^{-1} \left(\dfrac{x}{4 \sqrt{2}}\right)\right]_{4}^{\sqrt{32}} \\\\
& = \dfrac{\sqrt{32}}{2} \times \sqrt{32 - 32} + 16 \sin^{-1} \left(\dfrac{\sqrt{32}}{4 \sqrt{2}}\right) - \dfrac{4}{2} \sqrt{32 - 16} - 16 \sin^{-1} \left(\dfrac{4}{4 \sqrt{2}}\right) \\\\
& = 0 + 16 \sin^{-1} \left(1\right) - 2 \times 4 - 16 \sin^{-1} \left(\dfrac{1}{\sqrt{2}}\right) \\\\
& = 16 - \dfrac{\pi}{2} - 8 - 16 \times \dfrac{\pi}{4} = 4 \pi - 8
\end{aligned}$
$\therefore$ $\text{Area OAB} = 4 \pi - 8$ sq units $\;\;\; \cdots \; (3)$
$\therefore$ $\;$ In view of equations $(2)$ and $(3)$, equation $(1)$ becomes
$\text{Area OAB } = 8 + 4 \pi - 8 = 4 \pi$ sq units