The Wave Equation — Part 2
Introduction
This marks the second and last (probably) post on the wave equation. In the previous post, we looked at how we can mathematically model a wave. This will come useful when we actually derive the wave equation. Hand in hand, we can use these two mathematical objects to solve problems relating waves. If you haven’t already, it’s recommended you read my original post to get the mathematical intuition of what we are about to do
Just a disclaimer, this post will involve quite a bit of calculus. However, I have the necessary information you need to know to actually derive the equation. Using the equation to solve problems is another ballgame entirely.
The Derivative
The derivative is one of the first things you’ll learn in an introduction to calculus course. Congrats, by the end of this article you’ll know a bit of calculus. You won’t be guaranteed a 100 on your next text but you’ll at least have the big picture of what a derivative does.
Let’s say we were walking down a road and we wanted to plot a displacement-time graph for our journey, we’re masochists for maths at the end of the day.
A displacement-time graph plots time on the x axis, or well in this case the t axis while we plot the distance travelled on the y axis or the s axis. The reason we refer to displacement as s is because we’re talking about our spatial position, our position with respect to a certain point. We can make our displacement less ambiguous by either representing it with an x, horizontal displacement, or y, vertical displacement.
Now, what if we wanted to know our velocity during our travel?
Well, velocity is pretty much the rate of change of displacement. Essentially, velocity tells us how our displacement varies with time. In other words,
This is pretty much the gradient of our graph. Notice, how the gradient is easy to calculate for this specific function. This is because it is a straight line, hence we can simply use the equation
to calculate the gradient.
However, what if our distance-time graph looked something like this:
Notice how the gradient is not the same at every point?
One way we can find the gradient is by essentially taking two points on the graph that are very close to each other and calculating the slope using the equation of the gradient listed above
In essence, we’re calculating:
Where δy and δx are really small increments of y and x respectively (Remember that the two points have to be really close for us to get a nice straight line)
However, this gets kind of tedious.
Hence, we have a special tool called the derivative. The derivative of a function basically gives us another function called the gradient function. If we were to plug in a value in the gradient function, it would give us the slope of a function at that particular value.
For example, if our function was originally f(x), then the derivative of f(x) would be represented by f’(x) (Read as f prime of x). f’(2) would essentially give us the slope of f(x) at x=2.
Another way to represent a derivative is like so:
Or
The variable at the bottom, in this case x essentially represents with respect to what quantity of our function is the change occurring. Hence, this tells us how f(x) changes as x changes.
Now, I mentioned that velocity is the rate of change of displacement, hence we can represent velocity as the derivative of displacement:
t represents time.
For now, to make things simple, I will be using x for displacement
Let’s take our displacement-time graph as the following:
If I were to plot the derivative of my displacement-time graph, I would be plotting my velocity-time graph. Essentially, I am calculating the slope at every x value and plotting that as my y value at that specific x point in the new graph.
There are a lot of formulas to calculate the derivatives of different functions, however I will not be going into that.
Hence, just take for granted that plotting the derivative of the above graph yields:
The graph below represents the displacement (blue) and velocity (red) plotted against time. Notice how when the slope of the blue graph is 0, the y coordinate of the red graph is also 0? That’s how a derivative works
Another simple relation is that acceleration is the rate of change of velocity. Hence, we can model acceleration as the following derivative:
Notice that to get acceleration, we initially take the derivative of displacement (which yields velocity), and we then take the derivative of that derivative (the derivative of velocity yields acceleration)? Hence, we can also represent acceleration as:
This is called a second derivative. Essentially, a second derivative is just a derivative of a derivative.
Derivation of the wave equation (Intro)
The wave equation many of you have been introduced to likely looks something like this:
This equation relates the speed of a wave with the product of its frequency and wavelength. For example, if you had a hypothetical wave with frequency 2 Hz and wavelength 8m, its wavespeed would be 16 ms^-1.
However, the actual wave equation looks a lot different. In fact, this is the wave equation:
Partial derivatives (Mathematical interlude)
Hold on, it looks like we’re taking the derivative of something. But… why do we not use the letter “d”, why does it look weird? Essentially, we’re taking what is known as a “partial derivative”.
Most functions you’ll be introduced to are called single variable functions. What this means is that if you have some function f(x), the function will only have variables in terms of x, or constants. For example, f(x) = x²+5x+6.
However, it might seem apparent to you that these functions are limited in their use. In our real world, functions are multi-variable. In essence, they depend on multiple variables which can constantly change. In our previous post, we showed that modelling a wave depends on x and t.
Hence, a partial derivative with respect to a certain variable will basically treat the other variable as a constant.
Let’s suppose we have some function f(x, y) = x²y + xy².
The partial derivative of f(x, y) with respect to x would be represented as
This is equal to
Which is equal to 2xy + y². If you know any of the formulas to calculate the derivative of a one variable function, this would seem intuitive to you as for a partial derivative, all we’re doing is assuming the other variable is a constant.
The wave equation (Derivation)
For the purposes of making things simple, we’re going to assume our wave is only travelling in one direction.
In the last article, we established that we can model our wave function as a sinusoidal function of x and t. Let us assume we once again have our transverse wave like so
Recall from last article that the quantity on the y axis is u(x, t). This essentially gives us the displacement of the oscillation at some position x and some time t. The reason I introduced partial derivatives is because our wavefunction is multivariable. It depends on an x and t. For the purposes of making this simpler, let’s zoom in on this wave so that we’re only looking at half a period.
We can now take two points on the wave at some coordinate x and some coordinate x+δx.
Ideally, δx would be infinitesimally small. Now, if this wave was say a wave caused by a rope. There would be a tension force acting on both A and B. Let the tension at A be T_1 acting at some angle θ and let the tension at B be T_2 acting at some angle φ.
We can now break up our two tensions into their components using basic trigonometry to give
Now given that it is a transverse wave. There is only an oscillation vertically and no oscillation horizontally. Hence, we know that there is no horizontal force which allows us to say that
This is because the resultant force in the horizontal direction should be 0.
Therefore
Now, using Newton’s second law of motion
We can try and find the resultant force in our y direction. To rewrite this, we must bring in a new constant, the density of the rope. As our wave is in one dimension, we realise that the density of this rope is given by ρ=mass/length. Notice that in this case the length we’re focusing at is actually just δx? Therefore, the mass of this wave is ρδx. Now, we essentially have a function for our wave that plots some kind of displacement. Hence, we can basically find the acceleration by taking the second partial derivative of our function with respect to time (Recall that the second time derivative of displacement is acceleration)
Dividing each term by k gives us
Recalling that
We can conveniently just rewrite this as
Which can be simplified to
Remember that the tangent of any angle is the ratio between the opposite side and the adjacent side of a triangle.
In essence we’re getting
This look awfully close to the slope right? Hence, the tangent of each of these angles essentially gives us the slope at that particular point or the derivative.
Remember, as this is a multivariable function, we can rewrite all of this as a partial derivative to get
Now isolating the acceleration by dividing both sides by ρδx/k gives us
In order to make the next step less subtle, we can rewrite the above expression as
We established that δx would ideally be infinitesimally small. Hence, as the limit or δx approaches 0 (via first principles), we get
Now, with the definition v²=k/ρ, we get our wave equation:
Note that this is dimensionally accurate. k is measured in newtons while ρ is measured in kgm^-1. Hence, with the definition N=kgms^-1, we get the units of k/ρ as m²s^-2 which is the units of the velocity v squared.
I would also like to note that there are various different ways the wave equation can be derived. This is just one way. This derivation is not my derivation either and was inspired by the following youtuber .
With that, this marks the end of the wave-equation series. I hope you enjoyed!