Separation of VariablesUsing the technique of separation of variables, let u(r,t) = v(r)w(t). Substituting into the wave equation,
In[13]:=Clear[v,w]
waveSeparable := D[v[r] w[t],{t,2}] == Div[c^2 Grad[v[r] w[t]]]
waveSeparable
Out[15]=Notice that we can factor w[t] out of the right hand side and separate the functions of r from the functions of t.2 2
c w[t] v'[r] + c r w[t] v''[r]
v[r] w''[t] == --------------------------------
r
In[16]:=waveSeparable2 = Simplify[waveSeparable]
Out[16]=2
c w[t] (v'[r] + r v''[r])
v[r] w''[t] == --------------------------
r
In[17]:=waveSeparable3 = waveSeparable2[[1]]/(v[r] c^2 w[t]) ==
waveSeparable2[[2]]/(v[r] c^2 w[t])
Out[17]=Since one side of the equation is a function of t and the other is a function of r, both must be a constant. Let's cheat and let that constant be -k^2. This will simplify the notation later.w''[t] v'[r] + r v''[r]
------- == ----------------
2 r v[r]
c w[t]
In[18]:=timeDiffEqn = waveSeparable3[[1]] == -k^2
Out[18]=w''[t] 2
------- == -k
2
c w[t]
In[19]:=timeDiffEqn2 =
timeDiffEqn[[1]]*(c^2 w[t]) == timeDiffEqn[[2]]*(c^2 w[t])
Out[19]=2 2
w''[t] == -(c k w[t])
In[20]:=radiusDiffEqn = waveSeparable3[[2]] == -k^2
Out[20]=v'[r] + r v''[r] 2
---------------- == -k
r v[r]
In[21]:=radiusDiffEqn2 =
radiusDiffEqn[[1]]*(r v[r]) == radiusDiffEqn[[2]]*(r v[r])
Out[21]=2
v'[r] + r v''[r] == -(k r v[r])