# Blog

## Don’t be a Maths Criminal!

The following is a “proof” that 1 = 2:

Let a and b be any numbers but a must equal b. For example 3 = 3 is a true maths sentence but let’s just keep things in terms of a and b. Given this as a starting point, we can do the following:

Step 1: a = b

Step 2: Multiply the left side by a and the right side by b, which is valid since a = b. This gives a2 = ab

Step 3: Add a2 to both sides: a2 + a2 = a2 + ab

Step 4: Add terms on left side: 2 a2 = a2 + ab

Step 5: Subtract 2ab from both sides: 2 a2 – 2ab = a2 + ab – 2ab

Step 6: Add the like terms on the right side together: 2 a2 – 2ab = a2ab

Step 7: Factor out the 2 on the left side: 2(a2ab) = a2ab

Step 8: Noting that (a2ab)/ (a2ab) = 1, divide both sides by a2ab: 2 = 1

Is this true? Has all our maths training been one big pile of fertiliser?

As much as my jokester half would like to say “yes it has”, there is something wrong with the above “proof”. All the steps are perfectly valid except for the last one. If a = b, then a2ab = 0. So the last step is effectively dividing both sides of the equation by 0.

Dividing by 0 is against maths law because allowing it would make maths inconsistent and all sorts of false equations can result. See what happens if you try to divide any number by 0, even 0 itself, by 0. (Do this in secret as I will not be responsible for getting you out of maths jail.)

Borrowing from an American commercial about drugs:

This is your mind: 2 = 2

This is your mind after dividing by 0: 2 = 1.

## Arithmetic Sequences

This post is about quickly adding a sequential set of numbers from an arithmetic sequence. An arithmetic sequence is a list of numbers that have the same difference between each two adjacent numbers.

For example: 2, 4, 6, 8, 10, … is an arithmetic sequence with a difference of 2 between each two numbers. What if you needed to add the first 20 of these numbers or the next 20 numbers starting with any number in the sequence? Even if you don’t need to do this, the following is very interesting and surprising.

Let’s start with this arithmetic sequence: 7, 14, 21, …, 63, 70. You can see that the difference between the numbers is 7. If you write this sequence down, add the first and last number: 7 + 70 = 77. Now add the second number and the next to the last number: 14 + 63 = 77. What?! Will I get the same number if I keep doing this? It turns out, that you will:

There are 5 pairs of 77’s so 5 × 77 = 385 and this is the same answer you would get if you added all 10 numbers manually.

It turns out that this trick will work no matter what the difference between each number, how many numbers that are to be added, or where you start adding in the sequence. The only condition is that you are using an arithmetic sequence and that the numbers added are sequential, that is you can’t skip numbers.

So a generic sequence addition looks like this:

${a}_{1}\hspace{0.33em}{+}\hspace{0.33em}{a}_{2}\hspace{0.33em}{+}\hspace{0.33em}{a}_{3}\hspace{0.33em}{+}\hspace{0.33em}\cdots\hspace{0.33em}{+}\hspace{0.33em}{a}_{{n}{-}{1}}\hspace{0.33em}{+}\hspace{0.33em}{a}_{n}$

The subscripts just keep track of the order of the terms. The last term, an, means that there are n numbers to be added. In our example, n was 10 and an was 70.

So as in our example, we added the first and last term, then multiplied that by half the numbers to be added, that is n/2. The formula for this trick using the generic sequence is:

${\mathrm{Sum}}\hspace{0.33em}{=}\hspace{0.33em}\frac{n}{2}\hspace{0.33em}\times\hspace{0.33em}{(}{a}_{1}\hspace{0.33em}{+}\hspace{0.33em}{a}_{n}{)}$

This works even if n is odd. What I find fascinating about this formula is that it doesn’t include the difference between each number. It doesn’t matter what the difference between each number is. This formula just needs to know the first and last number and how many numbers are to be added. Isn’t math strange and wonderful!

## Happy Birthday!

For today’s post, I thought I’d return to statistics. Remember the Monty Hall problem I talked about last year? If not, do a search on “Monty” on the Blog page. That was an example of statistics defying common sense. Today’s post is another one of those.

This post is about the probability of any two people in a group of people in a room having the same birthday. But let’s simplify this scenario with an equivalent one. Suppose we have a random number generator that generates a number between 1 and 365, including 1 and 365 – kind of like a 365 faced die. Let’s say we “roll” this die twice. What is the probability that the two numbers generated are the same, the successful event?

As is often the case in statistics, it is easier to look at the probability of the unsuccessful events. You can then subtract that from 1 to get the probability of the successful event since

Probability of Success + Probability of Failure = 1 or

Probability of Success = 1 – Probability of Failure

since one or the other must happen. Remember that a certainty in probability is “1”, absolutely no chance is “0” and other probabilities are between those two numbers. For example, the probability of flipping a heads is 0.5. Please see my posts on probability for a review if needed.

So if we roll this 365-faced die twice, the first roll sets the number and the chance of the second roll matching that number is 1/365 and the chance of not matching that number is 364/365. This probability is

${1}\hspace{0.33em}{-}\hspace{0.33em}\frac{364}{365}\hspace{0.33em}{=}\hspace{0.33em}{0}{.}{00274}$

Very small! I wouldn’t bet on that happening. This is equivalent to the probability that two random people have the same birthday. Please bear with me here, but an equivalent expression that takes into account that we are rolling the die twice (or have two people in the room) is:

${1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{\frac{{2}\times{1}}{2}}{=}\hspace{0.33em}{1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{1}\hspace{0.33em}{=}\hspace{0.33em}{0}{.}{00274}$

That expression in the exponent, (2×1)/2, is how to calculate the number of pairs that have a chance of being a success. Since we are just rolling the die twice (or there are just two people in a room), we only have 1 pair. If we roll the die 3 times, there are (3×2)/2 or 3 pairs of numbers to compare. Note that this exponent is generated by multiplying the number of rolls by one less, then dividing by 2. So for three rolls (3 people in a room), the chance of two numbers being the same are

${1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{\frac{{3}\times{2}}{2}}{=}\hspace{0.33em}{1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{3}\hspace{0.33em}{=}\hspace{0.33em}{0}{.}{00}{82}$

Well that appeared to have increased the odds a bit. Let’s roll the die 10 times or have 10 people in a room. There are (10×9)/2 0r 45 pairs that have a chance of being the same. So the probability in this case is

${1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{\frac{{10}\times{9}}{2}}{=}\hspace{0.33em}{1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{45}\hspace{0.33em}{=}\hspace{0.33em}{0}{.}{1161}$

That means that in a group of 10 people, you have slightly better than an 11% chance that any two people have the same birthday. That really increased the chances with just a few more people! You can keep doing this for any number of rolls (people) using the formula

${1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{\frac{{n}{(}{n}{-}{1}{)}}{2}}$

where n is the number of rolls or number of people in a room. If you let n = 23, you will find that the chance of any two people having the same birthday is

${1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{\frac{23(22)}{2}}\hspace{0.33em}{=}\hspace{0.33em}{1}\hspace{0.33em}{-}\hspace{0.33em}{\left({\frac{364}{365}}\right)}^{{253}\hspace{0.33em}}\hspace{0.33em}{=}\hspace{0.33em}{0}{.}{5005}$

You have better than a 50% chance that in a room of 23 people, two of them will have the same birthday! Mathematically, this is so because you have 253 pairs to compare, or 253 opportunities of a success. What a surprise!

## Euler’s Initial

In my last post, the irrational number e was used. Let’s define and explain e a bit more in this post.

If you deposit $1 in the bank which pays 100% interest once each year (I need to find this bank!), then at the end of 1 year, you will have the original$1 plus 100% of that which is another $1, for a total of$2. Now bear with me, but an equivalent expression that will give me this same answer is

${\left({{1}\hspace{0.33em}{+}\hspace{0.33em}\frac{1}{1}}\right)}^{1}\hspace{0.33em}{=}\hspace{0.33em}{(}{2}{)}^{1}\hspace{0.33em}{=}\hspace{0.33em}{2}$

What happens if this generous bank computes part of the interest during the year and that interest is added to your original $1 to be included in subsequent interest calculations? When banks do this, this is called compounding interest. That is the interest made compounds, or is added to, the original investment to get even more interest. Now suppose the bank computes the interest twice per year. In 6 months, the bank will compute your interest but since only half the year has gone by, only half the interest, or 50%, is used. So in 6 months you have$1.50. At the end of the year, 50% interest is again computed but on $1.50 now. This gives a total of$2.25 which is better than the $2 you would get if the bank didn’t compound the interest semi-annually. Now the fractional equivalent of 50% is 1/2, so again bear with me, but an algebraic equivalent expression that computes the amount you will have at the end of 1 year when the bank compounds semi-annually is ${\left({{1}\hspace{0.33em}{+}\hspace{0.33em}\frac{1}{2}}\right)}^{2}\hspace{0.33em}{=}\hspace{0.33em}{(}{1}{.}{5}{)}^{2}\hspace{0.33em}{=}\hspace{0.33em}{2}{.}{25}$ Suppose the bank compounds interest four times a year (quarterly)? Again, the interest used each quarter will only be 1/4 of the annual 100% interest but the interest will compound each quarter. At the end of the first quarter, you will have$1.25. This is now the amount to be used at the end of the second quarter, and so on. The algebraic equivalent expression to compute what you have after the entire year is

${\left({{1}\hspace{0.33em}{+}\hspace{0.33em}\frac{1}{4}}\right)}^{4}\hspace{0.33em}{=}\hspace{0.33em}{(}{1}{.}{25}{)}^{4}\hspace{0.33em}{=}\hspace{0.33em}{2}{.}{44}$

This is better still! But do you notice the pattern in the algebraic expressions? The denominator of the fraction in the brackets and the exponent (power) are the same as the number of times interest is compounded during the year. So in general, if interest is compounded n times per year, the amount you will have at the end of the year is

${\left({{1}\hspace{0.33em}{+}\hspace{0.33em}\frac{1}{n}}\right)}^{n}$

You may have also noticed that the larger n is, the more money you have. Well if you’re not greedy enough, let’s find a bank that compounds daily. If your dollar is compounded daily, at the end of 1 year you will have

${\left({{1}\hspace{0.33em}{+}\hspace{0.33em}\frac{1}{365}}\right)}^{365}\hspace{0.33em}{=}\hspace{0.33em}{2}{.}{71}$

That’s great but you may have thought that would be a larger amount. The problem is that though the power over the bracket stuff is increasing which has the effect of increasing the amount, the fraction part in the brackets is getting smaller, making the stuff in the brackets closer to 1. Raising 1 to a power is just 1. So there are two competing forces here, one that increases the value of the expression and one that decreases it.

Now we can compound more frequently than daily. We can compound half-daily, etc. What happens to the expression as n increases to infinity, ∞?

Well maths does have a process for that, it’s called limits. Let me just show that and then explain it:

$\mathop{\lim}\limits_{{n}\rightarrow\infty}{\left({{1}\hspace{0.33em}{+}\hspace{0.33em}\frac{1}{n}}\right)}^{n}$

This is read: “What is the limit of this expression as n goes to infinity?”. Now you can get an approximate answer to this by putting larger and larger numbers in for n on your calculator. It turns out, that there is no exact answer that can be written in decimal numbers because the answer to the above is an irrational number like 𝜋. This was proven to be the case in 1737 by Leonhard Euler. Because of his work with this number, it is given the symbol e in his honour.

It turns out that to 50 decimal places e = 2.71828182845904523536028747135266249775724709369995…

So you see that the most you can make with your dollar is \$2.72.

This number was first calculated by Jacob Bernoulli in 1683 to solve the very problem about interest we just went through. But Euler did a lot more work with it.

e is a very important number in calculus, probability, finance, and the interesting world of complex numbers.

## Inverse Operations

I said a little about operations that are inverses to each other when I talked about square roots. Operations (or functions on numbers – I may use operations and functions interchangeably) are inverses of each other if those operations, when performed sequentially on a number, result in the original number.

For example, consider the operations of adding, then subtracting 4 to/from a number. Let’s use 5:

5 + 4 = 9, 9 – 4 = 5, the original number. More directly,

5 + 4 – 4 = 5 + 0 = 5

So no surprise, addition and subtraction are inverse operations. It doesn’t matter what the starting number is or the number you are adding or subtracting. In general, if you start with a number x, + y and – y are inverse operations:

x + yy = x

The order of these operations does not matter – I can first subtract 4 then add 4. Multiplication and division are also inverse operations. For example,

5 × 2 = 10, 10 ÷ 2 = 5 or 5 × 2 ÷ 2 = 5 × 1 = 5

Other less familiar inverse operations are squaring a number and taking a number’s square root. For example, I can square 4 then take it square root or take its square root the square the result and I will get 4 back in either direction:

$\begin{array}{l} {\sqrt{{4}^{2}}\hspace{0.33em}{=}\hspace{0.33em}\sqrt{16}\hspace{0.33em}{=}\hspace{0.33em}{4}}\\ {{\left({\sqrt{4}}\right)}^{2}\hspace{0.33em}{=}\hspace{0.33em}{2}^{2}\hspace{0.33em}{=}\hspace{0.33em}{4}} \end{array}$

In general,

$\begin{array}{l} {\sqrt{{x}^{2}}\hspace{0.33em}{=}\hspace{0.33em}{x}}\\ {{\left({\sqrt{x}}\right)}^{2}\hspace{0.33em}{=}\hspace{0.33em}{x}} \end{array}$

There are other ones like this as well: cube and cube roots, raise to the fourth power and fourth roots, etc.

Another less well known one, and one that confuses many of my students, is exponential and logarithm operations.

When x is the base and a number, say 2, is in the exponent, as in x², this is a power operation. However, when x is the exponent, and a number called e is in the base, this is called an exponential operation, .

I won’t spend much time on e, but it is an irrational number like 𝜋 and there are several reasons why it is the ‘base of choice’. So if the operation is to take a number and make it the power of e, you will generate a number. Many calculators have an ‘.’ key where you can do this. So for example, e² = 7.389 … . What inverse operation can I perform on this number to get the ‘2’ back? This operation is called the log operation.

Now logs can use any base but again, the base e is most commonly used in math. The notation for taking the log of a number is logₑx which is often shortened to ln x. The shorthand ‘ln’ stands for ‘natural log’ as e is a natural base to use in math (topic for another post). If you have an ‘ ‘ key on your calculator, you probably also have an ‘logₑx‘ or ‘ln x‘ key as well.

So what does ‘ln x‘ mean? This operation is asking the mathematical question: “What number do I need to raise e to, so I get x?”. Can you see how this is the opposite of ‘eˣ ‘ where I actually raise e to the x power? So, ln() is asking the maths question: “What power do I need to raise e to, so that I get ?”. Isn’t it obvious that x is the number I have to raise e to, to get ? So and ln x are inverse operations. If you take the number we generated before, 7.389 … , and hit the ln x key on your calculator, you will get the original ‘2’ back.

There are many other inverse functions. In trigonometry, the sin x key in your calculator will give the sine of the angle x. Sometimes 𝜃 is used instead of x. The inverse sine, sometimes called the arcsine, is the inverse of this. The notation you may see on your calculator for this operation is ‘ASIN x‘ or ‘SIN ̅¹x‘. SIN ̅¹x is asking the maths question: ” What angle has x as its sine?”. So SIN ̅¹[SIN(x)] is x.

There are inverse functions associated with the other trig functions as well. You will usually see inverse function keys as the same key on a calculator, you just need to hit another key first to activate the inverse definition for the key.

## How do you Rate?

This post will be about the relationship between distance, speed (or rate) and time, as well as the manipulation of units.

I think most of you are comfortable solving this problem:

If you are travelling at 60 km/hr, how far will you have gone after 2 hours? So if you travel 60 km every hour, after 2 hours you will have travelled 60 × 2 = 120 km. The 60 km/hr is a rate (or speed as normal people would call it) and the 2 hours is the time. The result of multiplying these two things gives a distance. So in equation form, the relationship between these three things is d = rt, where d is distance, r is the rate or speed, and t is time. Now this equation is in the form that allows solving for distance. But we could just as well use this equation to solve for an unknown rate or speed. If the problem was: you travel 120 km at a constant speed for 2 hours. How fast were you travelling? So the unknown thing here is rate. If I take the above equation and divide both sides by t, I get r = d/t. So for this problem, 120km/2hr = 60 km/hr. I can similarly solve for an unknown time.

Now notice how the units work out. in the original problem, I am multiplying a rate times a time. That is, the “hr” cancel to leave just “km” just as if they were variables:

$\frac{\mathrm{km}}{\rlap{/}{\mathrm{h}}\rlap{/}{\mathrm{r}}}\hspace{0.33em}\times\hspace{0.33em}\rlap{/}{\mathrm{h}}\rlap{/}{\mathrm{r}}\hspace{0.33em}{=}\hspace{0.33em}{\mathrm{km}}$

In the second problem we are dividing a distance, km, by a time, hr. That is, km/hr and that is the unit of the answer, a rate. Now let’s do a problem where time is the unknown.

The speed of light is 299,792 km/sec. The average distance from the sun to the earth is 149,597,870 km. I say ‘average’ because the earth’s orbit around the sun is not perfectly circular. So how long does it take for a ray of light to travel from the sun to the earth? Or a more interesting (and morbid) way to ask this is, how long would it take before we knew that the sun exploded?

Going back to our rate equation and solving for t gives t = d/r. So

$\frac{149,597,870\mathrm{km}}{299,792\mathrm{km}/\sec}\hspace{0.33em}\hspace{0.33em}{=}\hspace{0.33em}{499}\sec$

Again, looking at the units, and remembering that when dividing by a fraction, you get an equivalent multiplication problem by multiplying the numerator times the reciprocal of the denominator gives

$\frac{\mathrm{km}}{\mathrm{km}/\sec}\hspace{0.33em}\hspace{0.33em}{=}\hspace{0.33em}\rlap{/}{\mathrm{k}}\rlap{/}{\mathrm{m}}\hspace{0.33em}\times\hspace{0.33em}\frac{\sec}{\rlap{/}{\mathrm{k}}\rlap{/}{\mathrm{m}}}\hspace{0.33em}{=}\hspace{0.33em}\sec$

So ‘sec’ is the appropriate unit for the answer. Let’s convert the answer to minutes. There are 60 sec/min so

$\frac{{499}\hspace{0.33em}\sec}{{60}\hspace{0.33em}\sec{/}\min}\hspace{0.33em}{=}\hspace{0.33em}{499}\hspace{0.33em}\rlap{/}{s}\rlap{/}{e}\rlap{/}{c}\hspace{0.33em}\times\hspace{0.33em}\frac{\min}{60\rlap{/}{s}\rlap{/}{e}\rlap{/}{c}}\hspace{0.33em}{=}\hspace{0.33em}{8}{.}{32}\hspace{0.33em}\min$

So at any moment, you have a little more than 8 minutes to live. What a happy thought!

## Easy as 𝜋

I realise that my last few posts are a bit more advanced than my other posts. So let’s take it down a few notches. We will still be talking about angles however.

In my posts on trigonometry, I used angles measured in degrees. But that is a rather arbitrary measure. The origin of measuring angles based on 360° for a full circle is obscure, but one theory has it that it is based on ancient calendars that had 360 days in a year. In science and engineering, a different measure of angles is used, radians.

The number 𝜋 crops up a lot, especially when talking about circles. This is because 𝜋 is the ratio of a circle’s circumference (perimeter) to its diameter:

$\mathit{\pi}\hspace{0.33em}{=}\hspace{0.33em}\frac{C}{d}$

where C is circumference and d is diameter. This holds true no matter if the circle is as small as “o” or as large as the orbit of earth around the sun. The symbol “𝜋” is a Greek letter with the name “pi”, and that is the symbol used to represent this ratio. In fact, it is the only way to write down this number exactly if we all agree what 𝜋 represents. This is because 𝜋 is an irrational number which means you cannot ever write it down exactly with numbers. Approximately, 𝜋 is 3.14159265359… where the decimal part goes on forever without ever a repeating pattern. Irrational or not, 𝜋 is a natural number to associate with circles.

Now if you replace the diameter d with twice the radius, that is 2r, the equation becomes

$\mathit{\pi}\hspace{0.33em}{=}\hspace{0.33em}\frac{C}{2r}\hspace{0.33em}\hspace{0.33em}\Longrightarrow\hspace{0.33em}\hspace{0.33em}{2}\mathit{\pi}\hspace{0.33em}{=}\hspace{0.33em}\frac{C}{r}$

which is again true for any size circle. Now notice that the 2𝜋 on the left side is unitless. What do I mean by that? The right side of the equation is a circumference measured say, in meters, divided by a radius, again measured in meters. If you remember my post on units, you’ll remember that units can be cancelled in a fraction just like variables. So in this case, we have meters divided by meters which cancel each other and we are left with no units. So a full circle is associated with the unitless number 2𝜋. What about a half circle? A half circle will have half the circumference. Half of 2𝜋 is 𝜋. What about a quarter circle? A quarter of 2𝜋 is 𝜋/2. As these numbers are all unitless, they were seen as a natural way to define angles.

So a half circle (also called a semi-circle), can be seen as an arc formed by the familiar angle 180°. The quarter circle is an arc formed by the angle 90°. But instead of degrees, we can call these angles 𝜋 and 𝜋/2 since these are the length of the arc formed by the angle divided by the radius. The term used to distinguish this measure of angles from degrees is radians.

This can be generalised for any angle. Please look at the below diagram:

So an angle in radians is the arclength formed by the angle divided by the radius. By the way, radians are abbreviated as rad and this is what you will probably see on your calculator when you use the radians mode.

So there are 2𝜋 radians in a full circle, 𝜋 radians in a semi-circle, and 𝜋/2 for a quarter circle. We can use the fact that 180° = 𝜋 radians to convert between the two measurements. To change degrees to radians, multiply by 𝜋/180. To change radians to degrees, multiply by 180/𝜋.

For example, 30° is 30 × 𝜋/180 = 𝜋/6 rad. It is customary to keep 𝜋 as 𝜋 when working with radians.

One advantage of using radians becomes immediately apparent when rearranging the equation in the figure above. The arclength formed by an angle measured in radians is simply r𝜃.

So now that you know what radians are, my future posts will use this measure almost exclusively.

## A Springy Thingy, Part 2

So last time, I presented the equation that describes the position of a mass on a spring:

The equation is

${x}\hspace{0.33em}{=}\hspace{0.33em}{A}\hspace{0.33em}\sin\left({\frac{180t}{\mathit{\pi}}\sqrt{\frac{k}{m}}}\right)$

where x is the position of the mass at a given time t in seconds, k is the spring constant, and m is the mass in kg. This was developed from the equation that describes the forces on the spring (gravity and the spring), and through calculus, out pops the equation above. This equation is the sine of stuff in brackets multiplied by a number A.

Even though the stuff in the brackets looks rather ominous, we are still just taking the sine of it and the sine only goes from -1 to 1. So the maximum extent of the mass is from –A to A. Now let’s look at the stuff in the brackets.

The 180 and 𝜋 are just there to change the rest of the expression so that you can press the sine button on your calculator in the “degrees” mode. Normally, when engineers model something like this, they use radians and not degrees. I have not explained what radians are yet so I’ve included an adjustment (the 180 and the 𝜋) so that you can continue to use degrees. I think I’ll explain radians in my next post.

The rest of the numbers, t, k, and m are the real meat of the model. For simplicity, I have started time at 0 seconds when the mass is at its rest position and is moving upwards in the postive direction. So you would expect the position of the mass to change with time and that is what the t in the expression does. The k and the m determine how fast or how slowly the mass oscillates. Let’s actually use some numbers instead of letters here for a specific mass and spring.

Now let’s assume the spring has a spring constant of 1 kg/s² (I’ll discuss these units in my next post), and the mass connected to it is 1 kg. That means the stuff in the square root sign (called a radical) is just 1 and the square root of 1 is 1. And let’s further assume that I start the spring moving by stretching the spring 5 cm from its rest position. So now, the position equation above simplifies to

${x}\hspace{0.33em}{=}\hspace{0.33em}{5}\sin\left({\frac{180t}{\mathit{\pi}}}\right)$

Starting at time as 0, you can choose various values of t, compute the stuff in the brackets, use the “SIN” button on your calculator which is in the “degrees” mode, and then multiply by 5. So for example, at t = 1 sec, 180/𝜋 is 57.2958. Taking the sine of that gives 0.8415 and then multiplying that by 5 gives 4.2073 cm. So at 1 sec, the mass is 4.2073 cm above its resting position. You can plot this point and many others to graph this, or you can be lazy like me and use a graphing calculator. The graph of the position of the mass versus time for this scenario is

So no surprise, a sine wave. Now remember when I first talked about sine waves, I talked about the wavelength. Here I have indicated the wavelength as 6.28 sec. When dealing with time, the wavelength is called the period and usually represented with the symbol T. The period is the length of time it takes for one full cycle of motion. So it takes the mass 6.28 seconds to make one complete bounce. It turns out that you do not have to graph the curve to find this:

${T}\hspace{0.33em}{=}\hspace{0.33em}\frac{{2}\mathit{\pi}}{\sqrt{\frac{k}{m}}}$

Since our k and m are each 1, T in this case is just 2𝜋. Funny how 𝜋 keeps cropping up. Again, I’ll explain that in my next post on radians.

Associated with the period is something called frequency. The period is how long it takes for one complete cycle to occur, whereas the frequency is how many complete cycles occur in 1 second. Frequency is the reciprocal of the period and vice versa. That is f = 1/T. So for our mass, the frequency is 1/6.28 or 0.16 cycles per second. The term “cycles per second” is given a special unit called hertz which is abbreviated as hz. You may have heard this term before.

As you change the values of k and m, the values of T and f will change as well. If the spring gets stiffer (a higher k), you would expect the frequency to increase, that is it will bounce faster. You would expect a heavier mass to slow down the frequency and it does. I will leave it as an exercise for the student to check this using a graphing calculator or Excel.

A good simulation on the web that shows the effect of changing mass an spring constant is at https://www.physicsclassroom.com/Physics-Interactives/Waves-and-Sound/Mass-on-a-Spring/Mass-on-a-Spring-Interactive. This sets up the graph a bit differently than I do here, but the frequency changes are easy to see. Also, you can add damping to this which I did not include in this post to keep it simple, but you can play with that as well on this site.

## A Springy Thingy, Part 1

From my last three posts, I think we are ready to model the motion of a mass on a spring:

So, just like I did with the tennis ball, I will show you equations that describe this motion.

Now again, to develop these equations requires calculus, so I will just provide the final result. But before I do, just how does one begin modelling a physical process like this?

What is usually done, is to write down known equations that describe the forces acting on the mass. If you think about it, there are two: a force due to gravity and a force from the spring. There are other forces as well like resistance from the air, but as before, we will assume these to be zero to simplify the development.

Let’s first set up the picture. We have a weight on a spring. The weight has mass m. Now weight is different than mass, but on earth, the units are the same. So on earth, a 1 kg weight has a mass of 1 kg. But on the moon, the mass is still 1 kg but its weight is 0.165 kg because gravity is weaker there. We have a spring with a spring constant of k which is a measure of how stiff the spring is. The higher the value of k, the stiffer the spring.

To start the mass moving, we have stretched it A centimeters down from its resting position, then let go. We set up a one dimensional coordinate system where the rest position of the mass is 0 and up is positive.

The force due to gravity is –mg where m is the mass and g is the acceleration due to gravity. From my post on the tennis ball, remember that g is 9.8 m/s². It’s negative because the force is acting in the down direction. This comes from Isaac Newton’s second law that says that force is equal to mass times acceleration. That is, F = ma. The force due to the spring comes from something called Hooke’s Law: F = kx where k is the spring constant and x is the amount that the spring is stretched (negative) or compressed (positive) from the resting position.

So the force equation for this setup is:

F = ma = kxmg

This is the equation engineers start with before they do calculus on it. So now in this post, this is the part where a miracle happens, and I’ll give you the final result.

So the equation that shows where the mass is at a certain time is below where t is time in seconds. It is assumed that time starts (that is t = 0) when the mass is travelling upwards and is at the 0 position:

$%Translator MathMagic Personal Edition Mac v9.41, LaTeX converter, 2019.1.28 09:06 {x}\hspace{0.33em}{=}\hspace{0.33em}{A}\hspace{0.33em}\sin\left({\frac{180t}{\mathit{\pi}}\sqrt{\frac{k}{m}}}\right)$

In my next post, I’ll dissect this a bit and put some actual numbers in it and plot the results.

## Graphs of Trig Equations, Part 3

I know it’s taking a while before I use maths to model a mass on a spring, but that will only make sense by fully describing the graphs of sine equations. Hopefully, this development is interesting in its own right.

Now if you were to plot the daylight length at a certain latitude against days, and if you plotted for a full year, you would see a shape that looks amazingly like the sine graph I showed you in my last post. Except at the equator, the length of a day gets longer in the summer and shorter in the winter. Without actual taking a year to collect the data, I’ve plotted the daylight length in Melbourne Australia against days using the equation

${L}\hspace{0.33em}{=}\hspace{0.33em}{2}{.}{63}\sin\left({\frac{360t}{365}}\right)\hspace{0.33em}{+}\hspace{0.33em}{12}{.}{165}$

where L is the length of daylight in hours and t is the number of days after 22 September of any year. Why I chose 22 September is an interesting topic which I may eventually discuss, but it has to do with what are called equinoxes. The plot is below and is almost exactly the plot created if I actually measured the day length each day and plotted these for a year:

Now the shape of this curve is a sine wave but you can see several differences from the standard sine wave explored in my last post:

1. The amplitude is 2.63 instead of 1
2. The wavelength is 365 days instead of 360 degrees
3. The wave is centered at 12.165 instead of the x-axis
4. We are evaluating the sine of time instead of degrees.

Let me explain these differences.

1. Amplitude – The value of sin(x) , regardless of what form x is in, only has values from -1 to +1. So if I multiply the sine by any number, say 2.63, so that I now have y = 2.63 sin(x), then this results in values from 2.63 × (-1) = -2.63 to 2.63 × (+1) = 2.63. This make the amplitude of this new equation 2.63, that is, the number I multiply the sine by. So in general, the amplitude of y = sin(x) is A.
2. Wavelength – Notice that the wavelength 365 is the denominator in
$\sin\left({\frac{360t}{365}}\right)$

The 360 in the numerator is the wavelength of the standard sine wave. The common symbol to represent wavelength is the Greek letter lambda, 𝝀, so in general, when you are taking the sine of something that looks like

$\sin\left({\frac{360t}{\mathit{\lambda}}}\right)$

the denominator, 𝝀, is the wavelength.

Now for those of you who have had exposure to this before, you may have expected to see 2𝜋t in the numerator instead of 360t. This would be the case if we were taking the sine of numbers expressed as radians. But this series of posts is doing everything with calculators in the degree mode. I will explain radians later in a different post.

3. Wave center – Notice that the center of the sine wave is at 12.165 which is the number added to the sine in the daylight length equation. The effect on a graph of adding a number to an equation is to raise or lower it – it does not change shape. So if you can graph and know the shape of y = something, then y = something + 10 will be the same shape, just shifted up 10 units. So adding 12.165 to the sine, doesn’t change its shape, it just changes where it is on the graph.

4. Time – The big change here is that we are no longer finding the sine of an angle. It may appear that we are now taking the sine of numbers in seconds, hours, or days – whatever the units of t are. However, the 360 in the numerator serves the purpose of making the number we are taking the sine of, unitless. That is, 360t/365 does not have any units – it is just a pure number.

Mathematicians/scientists long ago discovered that many periodic physical processes, have motions that follow a sine wave. In fact, when equations were formed that represented the forces on objects that were experiencing periodic motion, the sine of numbers involving time appeared when solving these equations.

And so it is with the length of the day throughout the year. The earth is rotating around the sun and this motion repeats, that is, is periodic. It is no surprise then that the graph of the day length is a sine wave.

I think we are now ready to model a mass on a spring. Let’s do that in my next post.