This is the first part of a proof that $J_n(x)N_{n+1}(x)-J_{n+1}(x)N_n(x)=-\dfrac{2}{\pi x}$:
Write Bessel's equation $$x^2y^{\prime\prime}+xy^{\prime} + (x^2 - p^2)y=0\tag{1}$$ with $y=J_p$ and again with $y=J_{-p}$; multiply the $J_p$ equation by $J_{−p}$ and the $J_{−p}$ equation by $J_p$ and subtract to get $$\frac{\mathrm{d}}{\mathrm{d}x}\left[x\left(J_pJ_{-p}^{\prime}-J_{-p}J_{p}^{\prime}\right)\right]=0\tag{2}$$
So I wrote $(1)$ with $y=J_p$: $$x^2J_p^{\prime\prime}+xJ_p^{\prime} + (x^2 - p^2)J_p=0\tag{3}$$ and again with $y=J_{-p}$: $$x^2J_{-p}^{\prime\prime}+xJ_{-p}^{\prime} + (x^2 - p^2)J_{-p}=0\tag{4}$$
Multiplying $(3)$ by $J_{-p}$:
$$x^2J_p^{\prime\prime}J_{-p}+xJ_p^{\prime}J_{-p} + (x^2 - p^2)J_pJ_{-p}=0\tag{5}$$
Multiplying $(4)$ by $J_{p}$:
$$x^2J_{-p}^{\prime\prime}J_{p}+xJ_{-p}^{\prime}J_{p} + (x^2 - p^2)J_{-p}J_{p}=0\tag{6}$$
Subtracting $(6)$ from $(5)$ gives:
$$x^2\left[J_p^{\prime\prime}J_{-p}-J_pJ_{-p}^{\prime\prime}\right]+x\left[J_p^{\prime}J_{-p}-J_pJ_{-p}^{\prime}\right]=0\tag{7}$$ Rewriting the second term of $(7)$ and cancelling the $x$'s as $x\ne 0$ gives $$x\left[J_p^{\prime\prime}J_{-p}-J_pJ_{-p}^{\prime\prime}\right]+\left[J_pJ_{-p}\right]^{\prime}=0\tag{8}$$ but I'm not sure if this is helping.
Could anyone please give me some hints or advice on how I can obtain equation $(2)$? $$\bbox[#AFA]{\frac{\mathrm{d}}{\mathrm{d}x}\left[x\left(J_pJ_{-p}^{\prime}-J_{-p}J_{p}^{\prime}\right)\right]=0}\tag{2}$$
Many thanks.
EDIT:
In response to the answer given by @okrzysik
\begin{equation} x[(J_{p}'' J_{-p} + J_{p}' J_{-p}') - (J_{p} J_{-p}'' + J_{p}' J_{-p}')] + [J_{p}' J_{-p} - J_{p} J_{-p}'] = 0. \end{equation}
\begin{equation} \implies x[(J_{p}'J_{-p})' - (J_{-p}'J_{p})'] + [J_{p}' J_{-p} - J_{p} J_{-p}'] = 0. \end{equation}
I'm still unsure how to show that this is equal to $$\bbox[#AFF]{\frac{\mathrm{d}}{\mathrm{d}x}\left[x\left(J_pJ_{-p}^{\prime}-J_{-p}J_{p}^{\prime}\right)\right]=0}\tag{2}$$
Could anyone please assist me on these final steps?
Thanks again.
Note that the $[J_p J_{-p}]'$ term in your equation (8) is not correct, writing out equation (8) correctly gives
\begin{equation} x[J_{p}'' J_{-p} - J_{p} J_{-p}''] + [J_{p}' J_{-p} - J_{p} J_{-p}'] = 0. \end{equation}
Now consider adding and subtracting $x J_{p}' J_{-p}'$ on the LHS side of this equation:
\begin{equation} x[(J_{p}'' J_{-p} + J_{p}' J_{-p}') - (J_{p} J_{-p}'' + J_{p}' J_{-p}')] + [J_{p}' J_{-p} - J_{p} J_{-p}'] = 0. \end{equation}
Now we can recognise the grouped terms in the first bracket as derivatives. The equation can thus be written as
\begin{equation} x[(J_{p}' J_{-p})' - (J_{p}J_{-p}')'] + [J_{p}' J_{-p} - J_{p} J_{-p}'] = 0, \end{equation}
So we can also write
\begin{equation} x[J_{p}' J_{-p} - J_{p}J_{-p}']' + [J_{p}' J_{-p} - J_{p} J_{-p}'] = 0. \end{equation}
You should now notice that these two terms do indeed come from differentiating a single term with the product rule, namely $x[J_{p}' J_{-p} - J_{p}J_{-p}']$ and hence
\begin{equation} \frac{d}{dx}[x(J_{p}' J_{-p} - J_{p}J_{-p}')] = 0 \end{equation}
as required.