How do I numerically solve this type of differential equation? (Wave Equation) I'm trying to solve the wave equation numerically. I'm brand new to this and what I'm basically trying to accomplish is simulating a plucked string with fixed endpoints. How do I find the $h(x,t)$ values that satisfy the following equation?
$$\frac{\partial^2 h}{\partial x^2} = c^2 \frac{\partial^2 h}{\partial t^2}$$
 A: There are multiple ways, but I'll give you one. From writing out the Taylor expansions of $f(x+\Delta x)$ and $f(x-\Delta x)$ you can show that we can approximate the second derivative in $\mathbb{R}^2$ by $$\frac{h(x+\Delta x,t)-2h(x,t)+h(x-\Delta x,t)}{(\Delta x)^2}=h_{xx}(x,t)+O(\Delta x^2)$$ So, substituting in we get $$\frac{h(x+\Delta x,t)-2h(x,t)+h(x-\Delta x,t)}{(\Delta x)^2}=c^2\left[\frac{h(x,t+\Delta t)-2h(x,t)+h(x,t-\Delta t)}{(\Delta t)^2}\right] + O(\Delta x^2, \Delta t^2)$$
Now pick some $T>0$, $N,M\in\mathbb{N}$ and let $x_n=n\Delta x$, $n=0,1,2,...,N$ and $t_k=k\Delta t$, $k=0,1,2,...,M$ where $\Delta x=1/N$ and $\Delta t=T/M$ (You haven't given boundary conditions for the PDE, so I assumed that $0\leq x\leq1$). Then let $$h^k_n=h(x_n,t_k)=h(n\Delta x, k\Delta t),\quad0\leq k\leq M,\;0\leq n\leq N$$
So, using this notation and the equation above we can solve for the next step in time by:
$$h_n^{k+1}=2h_n^k-h_n^{k-1}+\frac{(\Delta t)^2}{c^2(\Delta x)^2}\left[h_{n+1}^k-2h_n^k+h_{n-1}^k\right]$$
Note here that we let $O(\Delta x^2, \Delta t^2)\rightarrow0$. Then from this we can build our finite difference grid. 
Based on Uranix's suggestion, it is definitely worth noting that to obtain convergence for this finite difference scheme we require that $\Delta t\leq c\Delta x$; which is called the CFL condition. (Note that if you look it up it will appear as $\Delta t\leq\frac{\Delta x}{c}$, but this is referring to the general wave equation $h_{tt}=c^2h_{xx}$ rather than $h_{xx}=c^2h_{tt}$ as you have). 
However,  we must note that this is a recurrence relation that depends on the last two times (time $k+1$ depends on time $k$ and $k-1$) and the two space positions on either side of $h_n^k$ ($h_{n-1}^k$ and $h_{n+1}^k$). So to build anything, we need to use the boundary and initial conditions to get started. 
