Here are some computations that may be useful. Here below, $\big[ \,f\,\big]_a^b$ denotes $f(b)-f(a)$, and $n^{(k)}:=n(n-1)\dots(n-k+1)$.

**1. (An integration by parts)** *Let $w$ be a solution of the third order linear ODE on the interval $[a,b]$:
$$(x^4-34x^3+x^2)w''' + 3(2x^3-51x^2+x)w''+(7x^2-112x+1)w'+(x-5)w=0,$$
and put $$M(n):=\int_a^b x^nw(x)dx$$ for any integer $n\ge0$.
Then, for any $n\ge 2$, 
$$n^3M(n)- (34n^3-51n^2+27n-5)M(n-1) + (n-1)^3M(n-2)= \Big[a(x)(x^n)''  + b(x)(x^n)' + c(x)x^n  \Big]_a^b,$$
where 
$$ a:=pw  \qquad   b:=  qw- (pw)'  \qquad c:=   (pw )''   -  (qw)'+ rw   ,$$
and* $$p(x):=x^3-34x^2+x\qquad q(x):=3x^2-51x\qquad r(x):=x+10-x^{-1}.$$

**Proof**. We express the above polynomials of $n$ in the base  $n^{(k)}$,   then we absorb the latter terms as coefficients of   derivatives of $x^n$, and finally we integrate by parts. 

The RHS writes:$$\int_a^b\Big\{n^3x^nw -(34n^3-51n^2+27n-5)x^{n-1}w   +(n-1)^3x^{n-2}w\Big\}dx=$$
$$\int_a^b\Big\{(n^ {(3)}-3n^ {(2)}+2n)x^nw -(34n^{(3)}+51n ^{(2)}+10n-5)x^{n-1}w   +(n^{(3)}-n+1)x^{n-2}w\Big\}dx=$$
$$\int_a^b\Big\{(x^n)'''pw+(x^n)''qw+(x^n)'rw+x^n(5x^{-1} -x^{-2} )w\}dx=$$
$$ \int_a^bx^n \Big\{-(pw)'''+(qw)''-(rw)'+ (5x^{-1} -x^{-2} )w\}dx
+\Big[ (x^n)''pw- (x^n)'(pw)'+ x^n(pw)'' +(x^n)'qw-x^n(qw)'   +rw \Big]_a^b=$$
$$ -\int_a^bx^{n-1} \Big\{(x^4-34x^3+x^2)w''' + 3(2x^3-51x^2+x)w''+(7x^2-112x+1)w'+(x-5)w\Big\}dx+$$
$$+\Big[ (x^n)''pw- (x^n)'(pw)'+ x^n(pw)'' +(x^n)'qw-x^n(qw)'   +rw \Big]_a^b=$$
$$=B(b)-B(a).\qquad\square$$

**2.(consequence)** *Let $w$ a   solution of the above linear equation on $(0,c)\setminus\{c_0\}$, with $\int_0^c wdx=1$, and and assume it verifies the following linear boundary conditions, expressed in terms of the above coefficients $a,b,c$:* 

i)   $a(x)=o(1)$, $b(x)=o(1)$ $c(x)=O(1)$, as $x\to0$;

ii)   $a(x)$, $b(x)$, $c(x)$, are continuous at $x=c_0$ ,

iii) $a(x)=o(1)$, $b(x)=o(1)$ $c(x)=o(1)$, as $x\to c$.

*Then the corresponding $M(n)$ are the Apéry sequence.*

Indeed, computing the integral on $[0,c]$ for $M(n)$ as limit of integrals on $[\epsilon, c_0-\epsilon]\cup[c_0+\epsilon, c-\epsilon]$ as $\epsilon\to0$, and applying the above integration by parts formula, one gets that $M(n)$ satisfy the Apéry recurrence, with $M(0)=1$ (note that $M(1)=5M(0)$ follows from the recurrence as  well).

**3. (Positive solutions of the third order ODE).** *Assume $u$ solves the second order linear ODE 
$$(x^3-34x^2+x)u''+(2x^2-51x+1)u'+\frac{1}{4}(x-10)u=0.$$
Then $w:=u^2$ solves*
$$(x^4-34x^3+x^2)w''' + 3(2x^3-51x^2+x)w''+(7x^2-112x+1)w'+(x-5)w=0.$$

**Proof**. Put $$P:=x^4-34x^3+x^2\qquad Q:=\frac{x^2}{2}-5x,$$
so the equation for $u$ (multiplied by $2x$) writes:
$$2Pu''+P'u'+Qu=0,$$
and we have
$$0=(2Pu''+P'u'+Qu)'u+ 3(2Pu''+P'u'+Qu)u'=$$
$$=(2Pu'''+2P'u''+P'u''+P''u'+Qu'+Q'u)u+3(2Pu''+P'u'+Qu)u'=$$
$$=P(2u'''u+6u''u')+3P'(u''u+u'^2)+(P''+4Q)u'u+Q'u^2=$$
$$=Pw''' +\frac{3}{2}P'w''+\Big(\frac{P''}{2}+2Q\Big)w'+Q'w,$$
which is the above third order equation for $w$.