One Dimensional Wave Equation with Piecewise Initial Conditions

268 Views Asked by At

The problem I am trying to solve is:

$$ \begin{cases} u_{tt} - c^{2} u_{xx} = 0 \\ u(x, 0) = g(x) \\ u_{t}(x,0) = h(x) \end{cases} $$

where $h(x) = 0$ and $g(x) = \begin{cases} 0 \ : x < 0 \\ 1 \ : x \geq 0 \end{cases}$

Via direct application of D'Alambert's formula, I arrived at the following solution:

$$u(x, t) = \begin{cases} 0 \ : x - ct < 0\\ 1/2 \ : \ x - ct < 0 < x + ct \\ 1 \ : \ x - ct > 0 \end{cases}$$

where I plugged in $x - ct$ and $x + ct$ into $g$ and broke into cases depending on when it equalled $0$ or $1$.

My question is twofold. Firstly, I was hoping someone could confirm my answer. Secondly, to arrive at this answer I used the fact that $x - ct < x + ct$. Am I allowed to make this assumption; I noticed that the only time $c$ appears in the wave equation is as $c^2$. Can we make an assumption that $c > 0$ when solving the wave equation or is this not possible?

1

There are 1 best solutions below

0
On BEST ANSWER

Your solution is correct, except for (what I'll assume to be) a typo in the first line: $u=0$ when $x+ct < 0$

You can also break it down like this

$$ u(x,t) = \begin{cases} 0, && x < -ct \\ \frac12, && -ct < x < ct \\ 1, && x > ct \end{cases} $$