Green function of non self adjoint differential equation. How to find Green function of the ODE $$y’’-\frac{1}{x}y’=1, y(0)=0,y(1)=0$$ As given ODE is not Self Adjoint . Should I change it into self adjoint? Corresponding self adjoint equation is $$\frac{1}{x}y’’-\frac{1}{x^2}y’=\frac{1}{x}$$  Now boundary conditions will be same ? Or there is other way to find Green function  for this problem? Thank you.
 A: The complication that can arise is: if $Ly=0$ has nontrivial solutions, then  $Ly=f$ has either no solutions or nonunique solutions (Fredholm alternative). In the latter case, there will be no solutions unless $f$ is perpendicular to all solutions of $L^\dagger y=0$. In your case, the homogenous equation $Ly=(\partial_{xx}-x^{-1}\partial_x)y=0$ with the stated boundary conditions has only the trivial solution $y=0$, so we may proceed directly without worrying about $L^\dagger$. Let
$$\tag{1}
G''(x,x')-\frac{G'(x,x')}{x}=\delta(x-x')
$$
where $G'=\partial_x G$. For $x\neq x'$, the solution is that of the homogenous equation
$$\tag{2}
G_\pm=A_\pm x^2+B_\pm
$$
where $G_+$ is the solution for $x>x'$ and $G_-$ is the solution for $x<x'$. The constants $A$ and $B$ are, generically, functions of $x'$. Applying the boundary conditions we find
$$\tag{3}
G_+(x,x')=A_+(x')(x^2-1)\\
G_-(x,x')=A_-(x')x^2
$$
Integrating (1) wrt $x$ over a vanishing region around $x=x'$ we find the derivative discontinuity
$$\tag{4}
G_+'(x',x')-G'_-(x',x')=1\\
2x'A_+(x')-2x'A_-(x')=1
$$
$G$ must be continuous at $x=x'$ else there would be terms more singular than $\delta$ on taking the second derivative in (1). The continuity yields
$$\tag{5}
G_+(x',x')=G_-(x',x') \\
A_+(x')({x'}^2-1)=A_-(x'){x'}^2
$$
Equations (4) and (5) are algebraic equations for the unknowns $A_\pm$. Upon solving them, we find
$$\tag{6}
G(x,x')=H(x-x')\frac{x'(x^2-1)}{2}+H(x'-x)\frac{x^2(x'-1/x')}{2}
$$
where $H(x)$ is the Heaviside step function. As a check, we can integrate (6) to find $\int\limits_0^1 dx' \ G(x,x')=\frac{x^2}{2}\ln(x)$, which is the solution to your first inhomogeneous equation.
