diff --git a/website/src/pages/understand/pitch.mdx b/website/src/pages/understand/pitch.mdx new file mode 100644 index 00000000..ef4294dd --- /dev/null +++ b/website/src/pages/understand/pitch.mdx @@ -0,0 +1,74 @@ +--- +title: Understanding Pitch +layout: ../../layouts/MainLayout.astro +--- + +import { MiniRepl } from '../../docs/MiniRepl'; +import { PitchSlider } from '../../components/PitchSlider'; + +# Understanding Pitch + +Let's learn how pitch works! But first, let's experience pitch in its rawest form: + + + +- Drag the slider to hear a pitch +- Move the slider to change the pitch +- Observe how the number on the right changes + +The number on the right is the **frequency** of the pitch you're hearing. +The higher the frequency, the higher the pitch and vice versa. +A pitch occurs whenever something is vibrating / oscillating at a frequency, in this case it's your speaker. +The unit **Hz** describes how many times that oscillation happens per second. +Our eyes are too slow to actually see the oscillation on the speaker, but we can [see it in slow motion](https://www.youtube.com/watch?v=CDMBWw7OuJQ&t=5s). + +## Pitch Perception + +Maybe you have already noticed that the pitch slider is "lopsided". To make that more obvious, let's automate the slider! +Below are 2 buttons for automation, try them out: + + + +There are 2 different colored lines: + +- blue: the frequency value +- yellow: the pitch value or how you perceive the frequency + +Depending on the type of sweep, the lines behave differently: + +- Frequency Sweep: frequency is linear , pitch is logarithmic +- Pitch Sweep: frequency is exponential , pitch is linear + +Don't be scared of these mathematical terms: + +- "logarithmic" is just a fancy way of saying "it starts fast and slows down" +- "exponential" is just a fancy way of saying "it starts slow and gets faster" + +## A Pitch Slider + +Most of the time, we might want to control pitch in a way that matches our perception. +Now that we know that frequency in Hz does not match our perception, +let's make the slider exponential (and yellow): + + + +- Do you see how the slider is now linked to the yellow line? +- Try out the buttons again and compare it to the frequency slider above + +## A unit for Pitch + +Let's try to find a linear unit for pitch, as frequency won't cut it. +To approach that unit of pitch, let's look at how frequency behaves when it is doubled: + + + +- Can you hear how these pitches seem related to each other? + + + + +## Definition + +From [wikipedia](): "Pitch is a perceptual property of sounds that allows their ordering on a frequency-related scale,[1] or more commonly, pitch is the quality that makes it possible to judge sounds as "higher" and "lower" in the sense associated with musical melodies." + +The oscillation is just a pattern of movement that repeats over and over again.