\[ \boxed { {\frac {{\rm d}^{2}}{{\rm d}{x}^{2}}}y \left ( x \right ) +ay \left ( x \right ) \left ( \left ( {\frac {\rm d}{{\rm d}x}}y \left ( x \right ) \right ) ^{2}+1 \right ) ^{2}=0} \]
Mathematica: cpu = 10.814373 (sec), leaf count = 262 \[ \left \{\left \{y(x)\to \text {InverseFunction}\left [-\frac {\sqrt {\frac {\text {$\#$1}^2 (-a)+2 c_1+1}{2 c_1+1}} \sqrt {2 \text {$\#$1}^2 a-4 c_1} E\left (\sin ^{-1}\left (\sqrt {\frac {a}{2 c_1+1}} \text {$\#$1}\right )|1+\frac {1}{2 c_1}\right )}{\sqrt {\frac {a}{2 c_1+1}} \sqrt {\text {$\#$1}^2 (-a)+2 c_1+1} \sqrt {2-\frac {\text {$\#$1}^2 a}{c_1}}}\& \right ]\left [c_2+x\right ]\right \},\left \{y(x)\to \text {InverseFunction}\left [\frac {\sqrt {\frac {\text {$\#$1}^2 (-a)+2 c_1+1}{2 c_1+1}} \sqrt {2 \text {$\#$1}^2 a-4 c_1} E\left (\sin ^{-1}\left (\sqrt {\frac {a}{2 c_1+1}} \text {$\#$1}\right )|1+\frac {1}{2 c_1}\right )}{\sqrt {\frac {a}{2 c_1+1}} \sqrt {\text {$\#$1}^2 (-a)+2 c_1+1} \sqrt {2-\frac {\text {$\#$1}^2 a}{c_1}}}\& \right ]\left [c_2+x\right ]\right \}\right \} \]
Maple: cpu = 0.187 (sec), leaf count = 94 \[ \left \{ \int ^{y \left ( x \right ) }\!{a \left ( {{\it \_a}}^{2}+2\,{ \it \_C1} \right ) {\frac {1}{\sqrt {-a \left ( {{\it \_a}}^{2}+2\,{\it \_C1} \right ) \left ( {{\it \_a}}^{2}a+2\,{\it \_C1}\,a-1 \right ) }}}} {d{\it \_a}}-x-{\it \_C2}=0,\int ^{y \left ( x \right ) }\!-{a \left ( {{ \it \_a}}^{2}+2\,{\it \_C1} \right ) {\frac {1}{\sqrt {-a \left ( {{\it \_a}}^{2}+2\,{\it \_C1} \right ) \left ( {{\it \_a}}^{2}a+2\,{\it \_C1} \,a-1 \right ) }}}}{d{\it \_a}}-x-{\it \_C2}=0 \right \} \]