Solution of $\frac{d^2y}{dx^2} – \frac{H(x) y}{b} = H(-x)$

Does the equation

$$\frac{d^2y}{dx^2} – \frac{H(x)}{b} y = c H(x)$$

have a solution where $H(x)$ is the Heaviside step function and $b$ and $c$ are constant?

Update: What about the second step function be $H(-x)$:
$$\frac{d^2y}{dx^2} – \frac{H(x)}{b} y = c H(-x)$$

Solutions Collecting From Web of "Solution of $\frac{d^2y}{dx^2} – \frac{H(x) y}{b} = H(-x)$"

For $x<0$, $y”=0$, i.e. $$y=C_1x+C_0.$$

For $x\ge0$, $y”-\frac1by=1$.

Assuming $b>0$, the solution of the homogenous equation is
$$y=A\exp(\frac x{\sqrt b})+B\exp(-\frac x{\sqrt b}),$$
and a particular solution is
Hence the general solution,
$$y=A\exp(\frac x{\sqrt b})+B\exp(-\frac x{\sqrt b})-b.$$

You will ensure continuity of the function by equating the function and first derivative at $x=0$:
$$C_0=A+B-b\\C_1=\frac A{\sqrt b}-\frac B{\sqrt b}.$$

In particular, starting from the steady state, $A=B=\frac b2$, and
$$y=b\left(\cosh(\frac x{\sqrt b})-1\right)H(x).$$

I’m going to answer the updated question, which asks for the solution of the problem:

$$ \color{green}{y”(x) – \frac{H(x)}{b} y(x) = H(-x) \, c } \tag{1}$$

which can be rewritten equivalently as follows:

$$ \begin{array}{ll}
y_1” – \frac{1}{b} y_1 = 0 & \quad x > 0 \\ \tag{2}
y_2” = c & \quad x < 0

where I have denoted $y_1(x)$ as the solution for $x>0$ and $y_2(x)$ the solution for $x<0$. If we integrate both equations we will arrive at:

$$ \color{blue}{y_1(x) = A e^{r_1 x} + B e^{r_2 x}, \quad y_2(x) = \frac{c x^2}{2} + Dx +E} \tag{3}$$

where $r_i$ are the solutions of the characteristic equation $s^2 – 1/b = 0$ and $A, B, D$ and $E$ are constants of integration. To enforce continuity of both the function and its first derivative, we must provide:

$$y_1(0) = y_2(0), \quad y’_1(0) = y_2′(0), \tag{4}$$

which yields to:

A+B & = E \\
Ar_1 + B r_2 & = D, \tag{5}
\end{align} which gives us the solution, provided $r_1 \neq r_2$:

$$\color{blue}{A = \frac{D-r_2 E}{r_1 – r_2} , \quad B = \frac{D – r_1 E}{r_2 – r_1}} \tag{6}$$

The constants $D$ and $E$ remain unkown until any boundary conditions or initial conditions are specified.

Hope this helps!


I am not sure wether this answer is correct or not, but as far as the step function is only a sign, I brought it out of the integration.

Please note that, for finding the constants, you need the boundary values and compare the value of the function at the point $x=0$.

$$\begin{array}{l}\frac{{{d^2}y}}{{d{x^2}}} – \frac{{H(x)y}}{b} = H(x)\\\frac{{{d^2}y}}{{d{x^2}}} = \frac{{H(x)y}}{b} + H(x)\\\frac{{{d^2}y}}{{d{x^2}}} = \left( {\frac{y}{b} + 1} \right)H(x)\\\frac{{{d^2}y}}{{\left( {\frac{y}{b} + 1} \right)}} = H(x){d^2}x\\\int {\frac{b}{{y + b}}{d^2}y} = H(x)\int {{d^2}x} \\\int {\left\{ {bLn\left( {y + b} \right) + {c_1}} \right\}dy} = H(x)\int {x + {c_3}dx} \\b\left\{ {\left( {y + b} \right)Ln\left( {y + b} \right) – \left( {y + b} \right)} \right\} + {c_1}y + {c_2} = H(x)\left\{ {\frac{1}{2}{x^2} + {c_3}x + {c_4}} \right\}\end{array}$$