# Sine Waves and Music

### Pre-AP PreCalculus

Math and Music Short

## How do you think Beethoven was able to create his music compositions?

Was it just by chance that his music was pleasing to the ear? Why or why not?

## Introduction

For this activity, we will explore the key components of waves and sound using the iPad apps, WavePad, Auto Function Generator, and Desmos. You will be able to see and hear how changing these parameters alters the audio and the waveform.

1. Where do we observe waves in the real world?

2. What is sound?

3. So...if a tree falls in the forest, and no one is around to hear it....does it still make a sound?

## Day 1: Sine Waves

Sine waves are the building blocks of sound. In fact, ALL signals can be created by combining sine wave.

Sine Wave = Frequency

Cycle = One repetition of a wave's pattern
Frequency = The number of cycles per second (measured in Hz)
Period = The time duration of one cycle (the inverse of frequency, P = 1/f )
Wavelength = The length of one period of a wave
Amplitude = A measure of a wave's change over a single period ## Looking at the picture above:

1. The sine wave with the highest frequency is _________________ , and the sine wave with the lowest frequency is _________________ .

2. The sine wave with the longest period is _________________ , and the sine wave with the shortest period is _________________ .

3. The sine wave with the shortest wavelength is _________________ , and the sine wave with the longest wavelength is _________________ .

4. What relationship exist between frequency and wavelength?

## Using an iPad to Generate Waveforms

Open the Auto Function Generator app on your iPad. This app allows you to choose a waveform and change the amplitude and the fundamental frequency parameters.

Use your headphones, and take a couple of minutes to explore the different waveforms (sine, square, saw). Also, you can tweek the amplitude and fundamental frequency. To hear your waveform, press the play button.

What changes to the sound occur when you:
1. Change waveforms?
2. Raise/lower the amplitude?
3. Alter the frequency setting?

## Signal Analysis

Sine waves are the building blocks of sound. In this activity, we will take a closer look at sine waves and their properties. While exploring the Auto Function Generator app, you heard and saw different types of waveforms. Something you may not have been able to guess from seeing and hearing these different signals is that they can all be created by combining simple single frequency sine waves. Remember ALL sounds can be created by combining sine waves.

We will be using the Auto Function Generator app again. At the top of the page you can select your waveform and change your frequency setting in Hz.

Select the waveform for "Sine" (the farthest waveform to the left).

Set your frequency at 650 Hz.

1. Sketch a diagram of the wave.
2. What do you notice about the graph of the sine wave as you change the volume?___________________
3. What is another label that could accurately label the volume slider? _____________________
4. What happens to the graph as you change the frequency slide? __________________
5. Describe the sound that is created by the sine wave? _______________________

## Song Analysis

We are now going to look at how songs can be displayed by sine waves. Using the WavePad app, we will record various 20 second sound clips. Then you and your group will analyze the recordings and answer the following questions for each recording:

1. What type of song was played? _________________
2. Sketch a diagram of the wave produced by the song over the full twenty seconds.
3. Label the highest frequency, the lowest frequency, the largest amplitude, and the smallest amplitude.
4. What affected the frequency throughout the recording? _______________
5. What affected the amplitude? __________________

## Create your own wave from music

The next activity with demonstrate how ANY sound can be reduced to individual sine waves. Using the WavePad app, students will record a 20 second sound clip. This can be a clip of a song, someone talking, a movie, or an instrument. Each group will then be drawing their own waveform, taking note of how the wave looks and sounds.

1. What did you record for your sound? _________________
2. Sketch a diagram of the wave produced by your sound over the full twenty seconds.
3. Label the highest frequency, the lowest frequency, the largest amplitude, and the smallest amplitude.
4. What affected the frequency throughout your recording? _______________
5. What affected the amplitude? __________________

## Sine Waves on sheet music

In this activity, you will calculate the frequencies of two octaves of a chromatic musical scale in standard pitch. Then, you will experiment with different combinations of notes and related sine waves to observe why some combinations of musical notes sound harmonious and others have a dissonance. When you check out note combinations, you will listen to those combinations played on a keyboard to associate the sounds with sine waves. You will be using your Desmos app for graphing the functions.

## The Chromatic Scale — A Geometric Series

Musical pitches (notes) are determined by their frequency, which is measured in vibrations per second, or Hertz (Hz). The notes on a piano keyboard form a chromatic scale.

A chromatic scale divides the octave into its semitones. There are twelve semitones, or half steps, to an octave in the chromatic scale.

The white keys on a keyboard are A, B, C, D, E, F, and G. The black keys are named relative to their adjacent white keys. For example, the black key between the C and D keys is known as either C sharp (C#) or D flat (Db).

• The A note below middle C on a keyboard has a frequency of 220 Hz. Using this value, calculate the frequencies of the terms that generate a two-octave chromatic scale. Calculate each value using the original value of a = 220 and the formula ar^n, where r = 2^1/12 .Round each frequency to the nearest whole number. • In the table above, compare the frequencies of notes that are one octave apart. For instance, compare A in the lower octave (left column) with A in the higher octave (right column), compare A# in the lower octave with A# in the higher octave, and so forth. How do frequencies an octave apart appear to be related?

The sine wave related to a musical pitch has the following form, where A is the amplitude of the sound (or the volume, measured in decibels) and B is the frequency of the note (measured in Hz): f (x)= Asin(Bx)

• Based on the frequencies in the above table, write the sine functions to represent both the low and high octaves for the C notes. (The value of A represents the volume of the note, so any value can be used. For the remainder of this activity sheet, let A = 2.)
• Then, graph the sine function for each note on your graphing calculator, and change the viewing window to show two cycles of the curve. (To do this, set Xmin = 0, and set Xmax to twice the value of the period; the period is equal to 2π divided by the frequency.) Graph the sine waves for notes in both octaves in the same viewing window. Draw the graph, and record the scale, frequency and period below. • Based on your observations above, describe where the graphs meet. With use of your iPad and the Auto Function Generator app, play C notes that are an octave apart. Describe in your own words how the notes compare. A major chord (or triad) of any scale consists of the first, third, and fifth notes of the scale. Based on the A major scale identified above, identify the notes of the A major chord, the frequencies of those notes, the associated sine function with A = 2, and the period of the sine wave. • When all three of the above sine waves are graphed, they intersect at the point (0, 0).

1. What are the coordinates of the second point where all three sine waves intersect? (The first point of intersection should be the origin.) ( ______ , ______ )

2. From the origin to the next point of intersection, record the number of cycles for each of the sine waves. Music and math: The genius of Beethoven - Natalya St. Clair

## Why is this song stuck in my head?

For the final part of this activity, I will be giving your groups a piece of sheet music. You will graph it's notes in Desmos to determine why it is a song that gets stuck in our heads.
1. Using the sin function formula f(x) = 2sin(Bx), where B represents the frequency of the note, graph the first line of your sheet music.
2. Sketch or Screenshot your graph.
3. Does your song have consonance or dissonance?
4. Why do you think this is a catchy song? Or if it isn't, why not?