I'm looking for any canonical method on how to solve a nasty differential equation Now, I do know how to guess and get a solution (as apparently there is a theorem that states guessing is a valid method).
However, I am curious if anyone knows of an algotithm for solving the equations of the form:
$$ay'' + b\lfloor x \rfloor y' + c\lfloor x \rfloor^2 y = 0$$
where $y = f(x)$ for some $f$ and where $a$, $b$, and $c$ are nonzero constants.
Now I know that technically this has no nontrivial solutions because of sharp corners, nondifferentiability, etc. I believe that the term weak solution or solutions to the corresponding integral equations likely captures what Im asking for. It seems like whenever I bring up something like this people give different names and this isnt really a question that needs an argument over terminology.
 A: Hint On any interval $I_n = (n, n+1)$, we have a homogeneous equation with constant coefficients. The solution is a linear combination of two complex exponentials.
Once this part is solved, see which conditions are needed on the constants to satisfy the equation at point $x = n$ in the sense of the distributions.
Edit
One way to see the initial equation $\left(E\right)$ is to write down the
first order system
\begin{equation}{\left[\begin{array}{c}y\\
z
\end{array}\right]'} = \left[\begin{array}{cc}0&1\\
{-\frac{c}{a}} {\left\lfloor x\right\rfloor }^{2}&{-\frac{b}{a}} \left\lfloor x\right\rfloor 
\end{array}\right] \left[\begin{array}{c}y\\
z
\end{array}\right] := A \left(x\right) \left[\begin{array}{c}y\\
z
\end{array}\right]\end{equation}
where the first component of $Y = \left[\begin{array}{c}y\\
z
\end{array}\right]$ is  the
solution of $\left(E\right)$. Here $A (x)$ is a piecewise constant,
locally bounded matrix. One cannot multiply such a matrix by any
distribution, but if we restrict ourselves to locally integrable
distributions $Y \in  {L}_{\text{loc}}^{1}$, then $A \left(x\right) Y$ has a sense
as a locally integrable function and we can ask that $\left(1\right)$ be
satisfied in the sense of the distributions, which means that
for all ${\varphi} , {\psi} \in  {\mathcal{C}}_{0}^{\infty }$,
\begin{equation}{-\int_{}^{}\left({{\varphi}'} y+{{\psi}'} z\right) d x} = \int_{}^{}\left({\varphi} z-\frac{c}{a} {\left\lfloor x\right\rfloor }^{2} {\psi} y-\frac{b}{a} \left\lfloor x\right\rfloor  {\psi} z\right) d x\end{equation}
Skipping a few details it is easy to prove that $y$ is a
solution in the classical sense of
$a {y''}+n b {y'}+{n}^{2} c y = 0$ in the open
interval ${I}_{n} = \left(n , n+1\right)$, because in such intervals,
${y'} , {z'} \in  {L}_{\text{loc}}^{1} \Rightarrow  y , z \in  {\mathcal{C}}^{0} \Rightarrow  {y'} , {z'} \in  {\mathcal{C}}^{0}$ etc.
We denote by ${y}_{n}$ this
solution, which is a smooth function on
$\overline{{I}_{n}} = \left[n , n+1\right]$
To find the boundary conditions, we compute
$$\renewcommand{\arraystretch}{2}  \begin{array}{rcll}\displaystyle -\int_{{I}_{n}}^{}\left({{\varphi}'} y+{{\psi}'} z\right) d x&=&{\varphi} \left(n\right) {y}_{n} \left(n\right)&{-{\varphi}} \left(n+1\right) {y}_{n} \left(n+1\right)+{\psi} \left(n\right) {z}_{n} \left(n\right)-{\psi} \left(n+1\right) {z}_{n} \left(n+1\right)\\
&&&\displaystyle +\int_{{I}_{n}}^{}\left({\varphi} {{y_n}'}+{\psi} {{z_n}'}\right) d x\\
&=&{\varphi} \left(n\right) {y}_{n} \left(n\right)&{-{\varphi}} \left(n+1\right) {y}_{n} \left(n+1\right)+{\psi} \left(n\right) {z}_{n} \left(n\right)-{\psi} \left(n+1\right) {z}_{n} \left(n+1\right)\\
&&&\displaystyle +\int_{I_n}^{}\left({\varphi} z_n-\frac{c}{a} {\left\lfloor x\right\rfloor }^{2} {\psi} {y}_{n}-\frac{b}{a} \left\lfloor x\right\rfloor  {\psi} {z}_{n}\right) d x
\end{array}$$
Summing on $n$ gives
$$0 = \sum _{n \in  \mathbb{Z}} \left({\varphi} \left(n\right) \left({y}_{n} \left(n\right)-{y}_{n-1} \left(n\right)\right)+{\psi} \left(n\right) \left({z}_{n} \left(n\right)-{z}_{n-1} \left(n\right)\right)\right)$$
We see that the condition is simply the continuity of $y$
and ${y'}$ at the integer points $x = n$.
Now I think you have all the tools to reach a complete solution of this problem.
A: If I understand properly your request, you are looking for an algorithm to compute the
solution to the ode
$$
ay'' + b\left\lfloor x \right\rfloor y' + c\left\lfloor x \right\rfloor ^{\,2} y = 0
$$
If so,  consider that such an equation
corresponds to that governing a series RLC circuit

$$
L\,q'' + R\,q' + {1 \over C}q = 0
$$
where $q(t)$ represents the electric charge on the capacitor, and 
$i(t) ={{dq(t)}/{dt}}$ is the current flowing in the circuit.
So, passing from $x$ to $t$ just to keep congruent with the physical model,
we are dealing with a circuit which has a constant inductance, while its resistance and capacitance 
are varying with time
$$
\left\{ \matrix{
  L\, = const. = a \hfill \cr 
  R = b\left\lfloor t \right\rfloor  \hfill \cr 
  C = 1/\left( {c\left\lfloor t \right\rfloor ^{\,2} } \right) \hfill \cr}  \right.
$$
with changes occurring "instantaneously", at discrete values of time $t=n \;|\,n \in \mathbb N_0$, while they remain constant during the following interval.
The behaviour of the RLC circuit
when the parameters are fixed is well studied and known,
and mathematically established also for negative values of $R$ and/or $L$ and/or$C$,
and it is not the case to repeat the fundamentals here.
But it is worthy to note that we can fix $L$ to be in any case positive; this physically means that
the "inertia" of the inductor will assure that $q''(t)$ be limited in absolute value,  so that $q(t)$ and $q'(t)$ remain continuous at the change of $R$ and $C$,
(while $q''(t)$ will change abruptely to keep the voltage balance). 
That is essentially the base of the algorithm to follow:
 - the initial values $q(0),q'(0)$ will determine the solution of the ode $q_0(t)$ for $0 \le t <1$
(with $R = b\left\lfloor 0 \right\rfloor=0$ and $1/C = c\left\lfloor 0 \right\rfloor^2=0$) ;
 -  $q_0(t \to 1),q'_0(t \to 1)$ will provide the initial values for the second piece $q_1(t)\; |\,1 \le t <2$
(solution of ode with $R$ and $1/C$ corresponding to $\left\lfloor t \right\rfloor=1$) ;
 .. and so on
thereby obtaining the solution piece-wise in time.
