<s>[INST] $\int_0^\infty \frac{\sin^n x}{x^m}dx$ could be expressed via $\pi$ or $\log$ I want to show some results first (they were computed by MMA)

$$
\int_0^\infty \frac{\sin^5 x}{x^3} dx =\frac{5}{32}{\color{Red}\pi} \quad
\int_0^\infty \frac{\sin^5 x}{x^5} dx =\frac{115}{384} {\color{Red}\pi} \\
\int_0^\infty \frac{\sin^5 x}{x^2} dx =\frac{5}{16}\,{\color{Red}\log}\, \frac{27}{5} \quad
\int_0^\infty \frac{\sin^5 x}{x^4} dx =-\frac{5}{96}(27\,{\color{Red }\log } \,3-25\,{\color{Red}\log }\,5) \\
$$

and

$$
\int_0^\infty \frac{\sin^6 x}{x^4} dx =\frac{1}{8} {\color{Red}\pi} \quad
\int_0^\infty \frac{\sin^6 x}{x^6} dx =\frac{11}{40} {\color{Red}\pi} \\
\int_0^\infty \frac{\sin^6 x}{x^3} dx =\frac{3}{16}\,{\color{Red}\log}\, \frac{256}{27} \quad
\int_0^\infty \frac{\sin^6 x}{x^5} dx ={\color{Red}\log}\, \frac{3^\frac{27}{16}}{4} \\
$$

As we can see, in the integral $\displaystyle\int_0^\infty \frac{\sin^nx}{x^m}dx$ 
, if $n-m$ is even, the integral is expressed via $\pi$, and if $n-m$ is odd, the integral is expressed via $\log$. Amazing for me, it seems always true such as
$$\int_0^\infty \frac{\sin^8 x}{x^2} dx =\frac{5\pi}{32}$$ and
$$\int_0^\infty \frac{\sin^8 x}{x^3} dx =\frac{9}{8}\log\frac{4}{3}$$

Do we have a general method to compute $\displaystyle\int_0^\infty \frac{\sin^nx}{x^m}dx$ which implies these laws?

My attempt
This post tells us how to compute $\displaystyle\int_0^\infty \frac{\sin^n x}{x^n}dx \tag{*}$
We can compute some other  $\displaystyle\int_0^\infty \frac{\sin^nx}{x^m}dx$ via $(*)$, such as via the formulas
$$\displaystyle\int_{0}^{\infty}\dfrac{\sin^3 x}{x}\,dx = \dfrac{3}{4}\int_{0}^{\infty}\dfrac{\sin x}{x}\,dx - \dfrac{1}{4}\int_{0}^{\infty}\dfrac{\sin 3x}{x}\,dx$$
and
$$\int_0^\infty \frac{\sin^2 (2x)}{x^2}dx=\int_0^\infty \frac{4\sin^2 x-4\sin^4 x}{x^2}$$
But it's complicated to compute the general cases. Could you please  share some ideas of a possible method to show the law mentioned above?
 [/INST] A somewhat recursive form of the integral can be derived as follows:
$$\int_0^\infty\frac{\sin^n(x)}{x^m}dx = \int_0^\infty\sin^n(x)\frac{1}{x^m}dx =$$
integrating per partes and assuming $n > m-1$ leads to
$$=\frac{n}{m-1}\int_0^\infty\frac{\sin^{n-1}(x)}{x^{m-1}}\cos(x)dx=\frac{n}{m-1}\int_0^\infty\frac{\sin^{n-2}(x)}{x^{m-2}}\frac{\sin(2x)}{2x}dx.$$
EDIT:
As mentioned also in one of the comments to OP, in the reference book Gradshteyn and Ryzhik (3.821.12),
this is further expanded to:
$$\int_0^\infty\frac{\sin^n(x)}{x^m}dx=\frac{n(n-1)}{(m-1)(m-2)}\int_0^\infty\frac{\sin^{n-2}(x)}{x^{m-2}}dx-\frac{n^2}{(m-1)(m-2)}\int_0^\infty\frac{\sin^n(x)}{x^{m-2}}dx,$$
but I am not sure how to obtain this.
Still, the answer by @SimplyBeautiful gives a better intuition why there is sometimes "$\pi$" in the expression and why "$\ln x$" in the rest.
</s>