I need help to solve the following differential equation:
$$A^{'''}y + A^{''}(-1 - y\cot{y}) - \frac{2A^{'}}{y} + \frac{2A}{y^{2}}(3+y\cot{y}) = 0$$
where $A$ is a function of $y$ and $A'$ represents the derivative of $A$ with respect to $y$.
What I have tried:
Using DSolve in Mathematica (It does not work but simply returns the original input)
Using Sympy package in Python (Also does not work but returns an error also)
I can see nothing wrong with my code (see attached pictures) and I have no idea how to solve such an equation by hand. Any advice would be greatly appreciated.


See code below:
from sympy.interactive import printing
printing.init_printing(use_latex=True)
from sympy import *
import sympy as sp
y = sp.Symbol('y')
a =sp.Function('a')(y)
diffeq = Eq(a.diff(y,y,y)*y + a.diff(y,y)*(-1-y*sp.cot(y)) - 2*a/y + (2*a/y**2)*(3+y*sp.cot(y)),0)
display(diffeq)
dsolve(diffeq,a)
There is no general easy approach for higher order equations with non-constant coefficients. However taking a close look at the coefficients one observes that they have descending power in $y$ and therefore it is a good idea to try monomials as solutions. Indeed, setting $A=y^n$ gives $$ (n+1)(n-2)y^{n-2}(-y\cot(y)+n-3)=0 $$ which gives to fundamental solutions namely $A_1=y^2$ and $A_2=\tfrac{1}{y}$.
To find the third solution we can reduce the order of the differential equation using Abel's theorem $W=c\cdot e^{\int 1/y+\cot(y) dy}$ where $W$ denotes the Wronskian comprised of the two known solutions and a placeholder $A_3$ for the missing one. This leads to an order reduction namely $$ 3y^2A''_3(y)-6A_3(y) = c\cdot y^3\sin(y) $$ I hope this answers your question.
Additional note: I do not have access to Mathematica but Maple was able to compute the solutions without a problem so maybe you did have an Input error after all?