Saturday, July 24, 2021

Wave Equation 1: UNIZOR.COM - Physics4Teens - Waves - Waves in Medium

Notes to a video lecture on http://www.unizor.com

Wave Equation 1

In order to understand the propagation of oscillation in a medium, in the last lecture we discussed the oscillation of two molecules inside a thin rod.



We left our problem with a system of two differential equations describing the displacements x1(t) and x2(t) of these two molecules of mass m each, connected by weightless springs of elasticity k, as functions of time t:
m·x"1(t) + 2k·x1(t) − k·x2(t) = 0
m·x"2(t) − k·x1(t) + 2k·x2(t) = 0
or, using the familiar concept of angular speed ω²=k/m,
x"1(t) + 2ω²·x1(t) − ω²·x2(t) = 0
x"2(t) − ω²·x1(t) + 2ω²·x2(t) = 0

We then suggested a vector form of this system of equations that resembles the equation of harmonic oscillations.
Consider a vector X(t) of displacements
X(t) =
x1(t)
x2(t)

and a matrix Ω of coefficients
Ω =
2ω²−ω²
−ω²2ω²

Now our system of two differential equations can be represented as one equation with vector argument X(t):
X"(t) + Ω·X(t) = 0
where X"(t) signifies a vector of second derivatives of each component of a vector X(t) and 0 signifies a null-vector.
An operation · (dot) in this equation signifies a multiplication of a matrix Ω by a vector X(t).

Compare it with an equation for harmonic oscillations we discussed in the very first lecture on Waves
x"(t) + (k/m)·x(t) = 0
where later on we assigned ω²=k/m.
Similarity of equations is obvious. Can solution be similar as well?

Multiplication of a vector by a matrix represents a linear transformation of a vector space. This transformation can make a vector longer or shorter, it can turn it to any direction, including an opposite one.

Here is a matrix that stretches any vector by a factor of 5:
50
05

Indeed, multiplication of this matrix by a vector
p
q
results in
5·p+0·q
0·p+5·q
=
5·p
5·q

that is, an original vector stretched in length by a factor of 5.

Here is a matrix that turns any vector by 90°:
0−1
10

Indeed, multiplication of this matrix by a vector
p
q
results in
0·p−1·q
1·p+0·q
=
−q
p

that is, an original vector turned counterclockwise by 90°.

There is a big difference between the two examples above.
It's much easier to solve differential equations like our
X"(t) + Ω·X(t) = 0
if matrix Ω is of "stretching" type.
Indeed, if Ω·X(t)=λ·X(t), where λ is constant, our vector equation
X"(t) + λ·X(t) = 0
can be reduced to two independent scalar equations
x1"(t) + λ·x1(t) = 0
x2"(t) + λ·x2(t) = 0
and we know how to solve them.

Unfortunately, the matrix we are dealing with in our problem of two oscillating molecules is not of a "stretching" type.
For example, a unit vector along the X-axis will be turned and unevenly stretched by multiplication by our matrix:
2ω²−ω²
−ω²2ω²
·
1
0
=
2ω²
−ω²


But not everything is lost.
Apparently, there are some vectors that are just stretched by this matrix. The plan now is
(a) to find all vectors that are just stretched by our matrix and
(b) try to find partial solutions to our differential equations among only these vectors.

So, we are looking for vectors
V =
v1
v2

such that
2ω²−ω²
−ω²2ω²
·
v1
v2
= λ ·
v1
v2

or
2ω²−ω²
−ω²2ω²
·
v1
v2
=
λ·v1
λ·v2

or
2ω²−ω²
−ω²2ω²
·
v1
v2
=
λ0
0λ
·
v1
v2

or
(2ω²−λ)−ω²
−ω²(2ω²−λ)
·
v1
v2
=
0
0


We cannot be satisfied with a trivial solution of null-vector v1=v1=0 to this system of equations.
To have non-trivial solutions, that is to find non-zero vectors that are stretched by our matrix, the determinant of this matrix must be equal to zero.
So, let's find λ that brings the determinant of this matrix to zero and then non-zero vectors that are stretched by this matrix.

It means, we have to solve an equation for λ:
det
(2ω²−λ)−ω²
−ω²(2ω²−λ)
= 0

or
(2ω²−λ)² − (−ω²)² = 0
or
(2ω²−λ)² = (ω²)²
or
2ω²−λ = ±ω²
from which we have two solutions:
λ1 = ω² and λ2 = 3ω²

These values are called eigenvalues of matrix Ω.

Potentially, there might be some vectors that our matrix Ω stretches by a factor λ1=ω² without any rotation and there might be some other vectors stretched by Ω by a factor of λ2=3ω².

Let's try to find these vectors because, since they are just stretched (that is, multiplied by a constant) by matrix Ω, we might easily find solutions to our system of differential equations by separating it into two independent equations, one for x1(t) and another for x2(t).

Firstly, let's find such a vector (or vectors) that matrix Ω stretches by λ1=ω².
2ω²−ω²
−ω²2ω²
·
v1
v2
= ω² ·
v1
v2

It means that the result of multiplication of a matrix by a vector equals to multiplication of a factor by this vector.
Therefore,
2ω²·v1−ω²·v2
−ω²·v1+2ω²·v2
=
ω²·v1
ω²·v2


The above represents two separate scalar equations: 2ω²·v1−ω²·v2 = ω²·v1 and
−ω²·v1+2ω²·v2 = ω²·v2
Both equations produce
v1 = v2
which means that any vector with X-coordinate equaled to Y-coordinate is just stretched by matrix Ω.
Such a vector is called eigenvector.

In this case any vector function of time argument that looks like this
x(t)
x(t)

is an eigenvector that transformation described by matrix Ω stretches by a factor of λ1=ω².

Indeed,
2ω²−ω²
−ω²2ω²
·
x(t)
x(t)
=
=
2ω²·x(t)−ω²·x(t)
−ω²·x(t)+2ω²·x(t)
=
=
ω²·x(t)
ω²·x(t)
= ω² ·
x(t)
x(t)


Secondly, let's find such a vector (or vectors) that matrix Ω stretches by λ2=3ω².
2ω²−ω²
−ω²2ω²
·
v1
v2
= 3ω² ·
v1
v2

It means that the result of multiplication of a matrix by a vector equals to multiplication of a factor by this vector.
Therefore,
2ω²·v1−ω²·v2
−ω²·v1+2ω²·v2
=
3ω²·v1
3ω²·v2


The above represents two separate scalar equations: 2ω²·v1−ω²·v2 = 3ω²·v1 and
−ω²·v1+2ω²·v2 = 3ω²·v2
Both equations produce
v1 = −v2
which means that any vector with X-coordinate equaled by absolute value but opposite in sign to Y-coordinate is just stretched by matrix Ω.
All such vectors are also eigenvectors.

In this case any vector function of time argument that looks like this
y(t)
−y(t)

is an eigenvector that transformation described by matrix Ω stretches by a factor of λ2=3ω².

Indeed,
2ω²−ω²
−ω²2ω²
·
y(t)
−y(t)
=
=
2ω²·y(t)+ω²·y(t)
−ω²·y(t)−2ω²·y(t)
=
=
3ω²·y(t)
−3ω²·y(t)
= 3ω² ·
y(t)
−y(t)


Summarizing the above, we have two sets of eigenvectors:
one that is stretched by matrix Ω by a factor of ω² and looks like
{P} =
x(t)
x(t)

where x(t) is any function of time t,
and another that is stretched by matrix Ω by a factor of 3ω² and looks like
{Q} =
y(t)
−y(t)

where y(t) is any function of time t.

All of the above analysis leads us to an opinion that we might attempt to look for solutions to a vector form of our differential equation
X"(t) + Ω·X(t) = 0
only among those vectors X(t) that belong to either set {P} of eigenvectors of matrix Ω with eigenvalue ω² or set {Q} of eigenvectors of matrix Ω with eigenvalue 3ω².

Assume, X(t){P},
that is X(t) =
x(t)
x(t)

where x(t) is some unknown function of time t.

Then Ω·X(t) = ω²·X(t) and our equation looks like
X"(t) + ω²·X(t) = 0 or
x"(t)
x"(t)
+ ω²·
x(t)
x(t)
=
0
0

which is equivalent to one regular differential equation
x"(t) + ω²·x(t) = 0
which is an equation of harmonic oscillations with a general solution
x(t) = D·cos(ωt+φ)
where amplitude D and phase shift φ depend on initial conditions.

Assume, X(t){Q},
that is X(t) =
y(t)
−y(t)

where y(t) is some unknown function of time t.

Then Ω·X(t) = 3ω²·X(t) and our equation looks like
X"(t) + 3ω²·X(t) = 0 or
y"(t)
−y"(t)
+ 3ω²·
y(t)
−y(t)
=
0
0

which is equivalent to one regular differential equation
y"(t) + 3ω²·y(t) = 0
which is an equation of harmonic oscillations with a general solution
y(t) = E·cos(√3ωt+ψ)
where amplitude E and phase shift ψ depend on initial conditions.

Now we have two different sets of solutions for our system of two degrees of freedom:
X(t) =
D·cos(ωt+φ)
D·cos(ωt+φ)

and
Y(t) =
E·cos(√3ωt+ψ)
−E·cos(√3ωt+ψ)

where D, E, φ and ψ can be any constants and ω²=k/m is a known characteristic of the system..

From the linearity of the differential equations involved follows that any linear combination of solutions from these two sets is also a solutions.

Therefore, a more general expression of solutions is
α·X(t) + β·Y(t)
or (dropping multipliers D and E since they, as well as multipliers α and β, are any numbers)
α·cos(ωt+φ)+β·cos(√3ωt+ψ)
α·cos(ωt+φ)−β·cos(√3ωt+ψ)


As we see, the motion of our two objects between springs is a superposition of two oscillations with different angular speeds, amplitudes and phase shifts.

Easy check shows that for any α, β, φ and ψ the above vector represents a solution to our vector differential equation
X"(t) + Ω·X(t) = 0

It remains to be proven that this expression encompasses all solutions and, therefore, can be considered as a general solution to differential equations that describe our system of two objects connected with springs, but this proof is a part of a more advanced course of differential equations and is outside of the scope of this course.

Another important part of the analysis is to find all unknown constants (α, β, φ and ψ) based on some initial conditions (displacements and velocities) of oscillating objects. It requires tedious but straight forward calculations and solving algebraic systems of equations, so we leave it anybody with inquisitive mind to do himself.

Monday, July 19, 2021

Waves in Medium: UNIZOR.COM - Physics4Teens - Waves - Waves in Medium

Notes to a video lecture on http://www.unizor.com

Waves in Medium

This lecture is about a different type of waves.
These waves are still mechanical oscillations in a sense that they are movements of objects with some periodicity, but the objects are not exactly the same as we studied in a previous chapter "Mechanical Oscillations".
The objects we discuss in this lecture are molecules of some substance, like air or water, or steel.

The word medium we use in a sense of "a substance regarded as the means of transmission of a force or effect", as defined in Merriam-Webster dictionary. Examples are air, water, wood, glass etc.
Basically, any substance can be a medium and transmit an oscillation from its source to some destination. The only thing that cannot be a medium in this sense is an absolute vacuum void of any force fields.

As an example of oscillation of a medium, consider a ringing bell after we strike it with a hammer.
For quite some time molecules inside this bell are oscillating, forcing to oscillate air around a bell as well, so we hear the sound.

Let's create a simplified model of this process.
First of all, we will research only a one-dimensional case.
As an example, consider a propagation of oscillation inside a thin metal rod after we strike one of its ends with a hammer.

Further consider that each molecule of a metal this thin rod is made of is connected by spring-like inter-molecular links with its left and right neighbors along a rod. If one molecule is oscillates, it will squeeze one link that attaches it to one neighboring molecule and stretches the other link, thus engaging its neighbors in oscillation.
In our one-dimensional case this model looks like this

where letter m indicates a molecule with its mass, while letter k indicates an elasticity of a weightless spring-like connection between molecules.

The above model of propagation of oscillation, while not perfect, allows to better understand the mechanism of waves in medium.

Finally, we simplify the problem even further by limiting the length of a rod to only two molecules, thus making the following model.



In this model two identical molecules, #1 (left on the picture) and #2 (right), of mass m each are linked by identical weightless springs of length L and elasticity k among themselves and to the edges of a thin rod.
Assume that initially the left end of the rod is at the origin of X-axis, the molecule #1 is at distance L from it along the X-axis, the molecule #2 is at distance L from the first further along the X-axis and the right end of a rod is by L further down. This assumption means that initially all springs are in neutral position.
Also assume that the molecule #1 (left on the picture above) has an initial speed v, modeling a strike of a hammer on the bell.

Let x1(t) be a displacement of the molecule #1 (left on the picture above) from its initial position at moment in time t and x2(t) be a displacement of the molecule #2 (right on the picture) from its initial neutral position at time t.
Assume, the initial displacement of molecules at time t=0 is:
x1(0)=0
x2(0)=0
Their initial velocity is:
x'1(0)=v
x'2(0)=0

There are two forces acting on the molecule #1 (left on the picture above) from two springs on both sides of it, which are:
F1L(t) by the left spring attached to the left edge and
F12(t) by the middle spring attached to the molecule #2.
There are two forces acting on the molecule #2 (right) from two springs on both sides of it, which are:
F2R(t) by the right spring attached to the right edge and
F21(t) by the middle spring attached to the molecule #1.

The direction (sign) of these forces depends on the displacement of molecules, we will take it into account when constructing the equations based on the Hooke's Law.
Also, forces F12(t) by the middle spring on the first molecule and F21(t) by the middle spring on the second molecule are opposite in direction and equal by absolute value since they depend only on the length of the middle spring.

The resulting force acting on the molecule #1 is
F1(t) = F1L(t) + F12(t)
The resulting force acting on the molecule #2 is
F2(t) = F2R(t) + F21(t)

If the displacements of molecules #1 (left on the picture above) and #2 (right) at any moment of time t are, correspondingly, x1(t) and x2(t), the forces F1L(t) of the left spring and F2R(t) of the right spring, acting on molecules #1 and #2 correspondingly, according to the Hooke's Law, are
F1L(t) = −k·x1(t)
F2R(t) = −k·x2(t)

The forces of the middle spring acting on molecules #1 and #2 depend on the difference in displacements of these molecules from their neutral position.

Let
Δ(t) = x1(t) − x2(t)

If Δ(t) is positive, the middle spring is squeezed and its left end (towards molecule #1) pushes molecule #1 to the left (in negative direction), which makes F12(t) negative, while its right end pushes to the right (in positive direction) molecule #2, which makes F21(t) positive.

If Δ(t) is negative, the middle spring is stretched and its left end (towards molecule #1) pulls molecule #1 to the right (in positive direction), which makes F12(t) positive, while its right end pulls to the left (in negative direction) molecule #2, making F21(t) negative.

Therefore,
F12(t) = −k·Δ(t)
F21(t) = k·Δ(t)

Now we can express the resulting force acting on the molecule #1 is
F1(t) = −k·x1(t) − k·Δ(t) =
= −k·
[x1(t) + x1(t) − x2(t)]
And the resulting force acting on the molecule #2 is
F2(t) = −k·x2(t) + k·Δ(t) =
= −k·
[x2(t) − x1(t) + x2(t)]

Taking into account the Second Newton's Law, F1(t)=m·x"1(t) and F2(t)=m·x"2(t), we obtain the following system of two linear homogeneous differential equations of second order
m·x"1(t) = −2k·x1(t) + k·x2(t)
m·x"2(t) = k·x1(t) − 2k·x2(t)
Bringing all members to the left part of equations, we get m·x"1(t) + 2k·x1(t) − k·x2(t) = 0
m·x"2(t) − k·x1(t) + 2k·x2(t) = 0
or, using the familiar concept of angular speed ω²=k/m,
x"1(t) + 2ω²·x1(t) − ω²·x2(t) = 0
x"2(t) − ω²·x1(t) + 2ω²·x2(t) = 0

Let's approach this system of equations in a more "mathematical" way, using vectors and matrices (you can refer to "Math 4 Teens" course on UNIZOR.COM, which explains the concepts of a vector and a matrix and operations with them).

Consider a vector X(t) of displacements
x1(t)
x2(t)
and a matrix Ω of coefficients
2ω²−ω²
−ω²2ω²

Now our system of two differential equations can be represented as one equation with vector argument
X"(t) + Ω·X(t) = 0
where X"(t) signifies a vector of second derivatives of each component of a vector X(t) and 0 signifies a null-vector.
An operation · (dot) in this equation signifies a multiplication of a matrix Ω by a vector X(t).

Compare it with an equation for a periodic movement we discussed in the very first lecture on Waves
x"(t) + (k/m)·x(t) = 0
where later on we assigned ω²=k/m.
We will try to solve a vector equation the same way we solved this similar equation in a one-dimensional case.
This is a subject of the next lecture.

Saturday, July 3, 2021

Forced Oscillation 2 - Resonance: UNIZOR.COM - Physics4Teens - Waves - M...

Notes to a video lecture on http://www.unizor.com

Forced Oscillation 2 -
Resonance


This lecture continues analysis of forced oscillations for a specific case, when the angular frequency of external periodic force equals to an inherent natural frequency of an object on a spring without any external forces.

Let us remind the introductory material from the previous lecture.

Oscillation is forced, when some periodic force is applied to an object that can potentially oscillate.

A subject of our analysis will be an object on a spring with no other forces acting on it except one external force that we assume is periodical.

As we know, in the absence of external force the differential equation describing the displacement x(t) from a neutral position of an object of mass m on a spring of elasticity k follows from the Hooke's Law and the Newton's Second Law
m·x"(t) = −k·x(t)
or
m·x"(t) + k·x(t) = 0
with a general solution
x(t) = A·cos(ω0·t) + B·sin(ω0·t)
where
A and B are any constants;
ω0 = √k/m is an inherent natural angular frequency of oscillation of this particular object on this particular spring.

The equation above is homogeneous because, together with any its solution x(t), the function C·x(t) will be a solution as well.

Consider a model of forced oscillation of an object on a spring with a periodic external force F(t)=F0·cos(ω·t).

Previous lecture was dedicated to a case of angular frequency of an external force ω to be different from the inherent natural frequency of an object on a spring ω0.
In this lecture we consider a case of angular frequency ω of the periodic external function F(t)=F0·cos(ω·t) to be equal to the inherent natural angular frequency ω0=√k/m of oscillations without external forces:
ω = ω0 = √k/m
So, from now on we will use only symbol ω for both inherent natural angular frequency of a spring with an object without external forces and for an angular frequency of an external force.

If external force F(t), described above, is present, the differential equation that describes the oscillation of an object looks like
m·x"(t) = −k·x(t) + F(t)
or, assuming the external force is a periodic function F(t)=F0·cos(ω·t),
m·x"(t)+ k·x(t) = F0·cos(ω·t)
where ω=√k/m

The function on the right of this equation makes this equation non-homogeneous.
Our task is to analyze the movement of an object on a spring in the presence of a periodic external function, as described by the above differential equations and some initial conditions.

Notice that if some non-homogeneous linear differential equation has two partial solutions x1(t) and x2(t), their difference is a partial solution to a corresponding homogeneous linear differential equation.
Indeed, if
m·x1"(t)+ k·x1(t) = F0·cos(ω·t)
and
m·x2"(t)+ k·x2(t) = F0·cos(ω·t)
then for x3(t)=x1(t)−x2(t)
m·x3"(t)+ k·x3(t) = 0

From the above observation follows that, in order to find a general solution to a non-homogeneous linear differential equation, it is sufficient to find its one partial solution and add to it a general solution of a corresponding homogeneous equation.

In our case we already know the general solution to a corresponding homogeneous equation
m·x"(t)+ k·x(t) = 0
So, all we need is to find a single partial solution to
m·x"(t)+ k·x(t) = F0·cos(ω·t)
where ω=√k/m
and add to it the general solution to the above homogeneous equation.

In the previous lecture, where we considered an angular frequency of external force ω to be different from the inherent natural frequency of oscillation of an object on a spring ω0, we were looking for a partial solution in a form xp(t)=C·cos(ω·t) and found such a coefficient C that the equation is satisfied:
C = F0 / [m·(ω0²−ω²)]
But, if ω=ω0=√k/m, we cannot use this method (since denominator becomes zero) and have to invent something new.

The usual recommendation in a case like this is to still use trigonometric functions, but with some simple function as a multiplier.
Let's try the following function:
xp(t) = Q·t·sin(ω·t)

Let's find second derivative of xp(t), substitute xp(t) and x"p(t) into our differential equation and find suitable values for a constant Q. That would deliver a partial solution to our non-homogeneous differential equation.

x'p(t) =
= Q·sin(ω·t) + Q·t·ω·cos(ω·t)


x"p(t) = Q·ω·cos(ω·t)+
+Q·ω·cos(ω·t)−Q·t·ω²·sin(ω·t)


Our original equation
m·x"(t)+ k·x(t) = F0·cos(ω·t)
can be written as
x"(t) + (k/m)·x(t) =
= (F0/m)·cos(ω·t)

or
x"(t)+ω²·x(t) = (F0/m)·cos(ω·t)

Substitute the partial solution expression into the left part of the differential equation above:
Q·ω·cos(ω·t)+Q·ω·cos(ω·t)−
−Q·t·ω²·sin(ω·t)+Q·t·ω²·sin(ω·t)


Canceling positive and negative terms that are equal by absolute value, got the following equation with the proposed solution
2Q·ω·cos(ω·t) =
= (F0/m)·cos(ω·t)

from which
Q = F0/(2m·ω)
The partial solution to our non-homogeneous differential equation is
xp(t) = F0·t·sin(ω·t)/(2m·ω)

Now we can express the general solution to a differential equation that describes the forced oscillation by a periodic external function as
x(t) = F0·t·sin(ω·t)/(2m·ω) +
+ A·cos(ω·t) + B·sin(ω·t)

where
A and B are any constants determined by initial conditions x(0) and x'(0);
ω = √k/m is an inherent natural angular frequency of oscillation of this particular object on this particular spring;
F0·cos(ω·t) is an external periodic force acting on an object with the same angular frequency as an inherent natural angular frequency of oscillation of this particular object on this particular spring.

It's beneficial to represent A·cos(ω·t)+B·sin(ω·t) through a single trigonometric function as follows.
Let
D = √A²+B²
Angle φ is defined by
cos(φ) = A/D
sin(φ) = B/D
(on a Cartesian coordinate plane this angle is the one from the X-axis to a vector with coordinates {A,B})
Then
A·cos(ω·t)+B·sin(ω·t) =
= D·
[cos(φ)·cos(ω·t) +
+ sin(φ)·sin(ω·t)
] =
= D·cos(ω·t−φ)


Now the general solution to our differential equation that describes forced oscillation looks like
x(t)=F0·t·sin(ω·t)/(2m·ω) +
+ D·cos(ω·t−φ)

where
F0 is an amplitude of a periodic external force;
m - mass of an object on a spring;
k - elasticity of a spring;
ω=√k/m is an inherent natural angular frequency of oscillation of this particular object on this particular spring and the angular frequency of external periodic force;
t is time;
D and φ parameters are determined by initial conditions for x(0) and x'(0).

The main component of the function describing the movement of an object, when a periodic external force acts synchronously with the inherent natural oscillation of an object on a spring, is F0·t·sin(ω·t)/(2m·ω).
This function represents oscillation with gradually, proportionally to time t, increasing to infinity amplitude.
Added to this function is a regular sinusoidal oscillation with the same angular frequency but, potentially, a phase shift φ.
The periodic external force, acting synchronously (that is, with the same angular frequency) with inherent natural oscillation of an object on a spring, causes proportional to time increasing of an amplitude of oscillations to (theoretically) infinity. This is called the resonance.

Let's represent it graphically for some specific case of initial conditions and parameters.

Initial conditions:
x(0) = 0
x'(0) = 0
From these initial conditions follows
0 = D·cos(φ)
0 = D·ω·sin(φ)
We know that ω≠0.
Also, sin(φ) and cos(φ) cannot be simultaneously equal to 0.
Therefore, D=0, and our oscillation in this case is described by a function
x(t) = F0·t·sin(ω·t)/(2m·ω)

Parameters:
m=1
k=4
ω=√k/m=2
F0=12

With the above initial conditions and parameters the oscillation of the object is described by function
x(t)=12·t·sin(2t)/(2·1·2) = 3·t·sin(2t)

The graph of this function looks like this