```markdown
> **Note:** This is still a work in progress. Some content may be updated before class, but most of it will remain the same. Please take a look and read through it!
```
# Compression and Rarefaction
Sound is produced by **mechanical vibrations** that create disturbances in a medium such as air. When a sound wave travels through air, air molecules **oscillate back and forth around their equilibrium positions**. As they move, they create changes in air pressure. These changes create alternating regions of **compression** (higher pressure) and **rarefaction** (lower pressure), and these pressure variations propagate through the air.
When the sound wave reaches our ears, these pressure variations make our **eardrum vibrate**. Our auditory system then converts these vibrations into signals that our brain perceives as sound. This makes us wonder: what happens if the air pressure changes only in one direction instead of repeatedly increasing and decreasing? Or what if the air pressure does not change at all?
If the air pressure stays completely constant, there is no sound wave, and for a continuous sound, we need the pressure to keep changing over time. In a periodic sound, the pressure repeatedly increases and decreases, creating an oscillation. The important thing here is not that air molecules have to travel from the speaker all the way to our ears. (They really don't!) Instead, the molecules **move back and forth around their equilibrium positions**, while the disturbance and its energy travel through the air. This is what eventually makes our eardrum vibrate.
# Frequency
Now we know that sound involves oscillation, but how do we describe how fast an oscillation occurs? The number of times a **periodic oscillation** repeats each second is its **frequency**, measured in **Hertz (Hz)**. One Hertz means one complete cycle per second, and one cycle means one complete oscillation.
If you have ever played in an orchestra, band, or other musical group, you may have heard a tuning reference based on **440 Hz**. In an orchestra, the oboe is commonly used to provide this reference when tuning to **A4**. A frequency of 440 Hz means that the sound pressure completes **440 cycles every second**. A sinusoidal sound-pressure variation at 440 Hz corresponds to the musical pitch conventionally called **A4**.
This gives us an important engineering question: if we want to build a device that produces a particular sound, how can we create an **oscillation at a particular frequency**? For example, to produce a pure A4 tone, we need a sinusoidal acoustic pressure variation at 440 Hz. Real musical sounds, however, can contain many additional harmonics while retaining a 440 Hz fundamental frequency. These harmonics contribute to the sound's **timbre**, which allows different instruments to sound different even when they play the same pitch. Similarly, in human speech, **formants**—prominent resonant frequency regions of the vocal tract—play an important role in distinguishing vowel sounds.

Spectrogram of American English Vowels
http://corpus.eduhk.hk/english_pronunciation/index.php/2-2-formants-of-vowels/
Creating a controlled electrical sine-wave oscillator brings us directly into electronics. We need a circuit capable of generating a periodic electrical signal with a predictable frequency and waveform. Natural sound sources can also produce signals with a dominant fundamental frequency, but their waveforms generally contain additional harmonics and are therefore not perfectly sinusoidal.
An electronic oscillator can generate an electrical signal that oscillates at a particular frequency, but this electrical signal is not sound yet. We can then use a speaker, which is an **electromechanical transducer**, to convert the electrical signal into mechanical movement. The movement of the speaker cone creates pressure variations in the air, and those pressure variations are what we hear as sound. So the basic process is:
**Electrical oscillation → speaker movement → air-pressure variation → sound**
This sounds simple enough, but now we have another question:
**How do we create an electrical oscillation in the first place?**
---
> [!Further Understanding]
# Physical Properties of Sound
When people think of "sound," they maybe picture a musical note or a sudden loud crash. But if you strip away human perception, sound is fundamentally just a mechanical pressure wave pushing its way through a physical medium. How those molecules bump into each other dictates every physical property we measure in the lab.
## 1. Compression, Frequency, and Wavelength
Think of sound propagation as a continuous game of push-and-pull. A vibrating source pushes air molecules into high-density pockets (**compressions**) and pulls back to leave low-density spaces (**rarefactions**).
The rate at which these pressure cycles repeat gives us our core temporal metrics:
- **Frequency ($f$):** Cycles per second, measured in Hertz ($\text{Hz}$).
- **Period ($T$):** The time it takes for a single cycle to complete:
$
T = \frac{1}{f}
$
Because the disturbance travels through a medium at a finite velocity ($v$), frequency directly dictates the physical spatial footprint of the wave—its **wavelength** ($\lambda$):
$
v = f\lambda
$
This simple relationship explains a lot about real-world wave behavior:
- **Low frequencies (long $\lambda$):** A $100\text{ Hz}$ tone stretches over $3.4\text{ meters}$ in air. It easily bends around walls and obstacles through diffraction.
- **High frequencies (short $\lambda$):** A $10\text{ kHz}$ tone spans just a few centimeters. It behaves more like a beam of light, reflecting cleanly off hard surfaces and casting sharp acoustic shadows.
## 2. Amplitude, Velocity, and Phase
What separates a quiet whisper from a jet engine comes down to pressure displacement and medium dynamics:
- **Amplitude & Intensity:** Amplitude is the peak change in pressure relative to normal atmospheric pressure. The actual energy carried by the wave—its **acoustic intensity** ($I$)—scales with the square of the amplitude:
$
I \propto A^2
$
- **Speed of Sound ($v$):** Sound cannot travel through a vacuum. Its velocity depends on how rigid ($K$, bulk modulus) and dense ($\rho$) the medium is:
$
v = \sqrt{\frac{K}{\rho}}
$
This is why sound travels at around $343\text{ m/s}$ in air, $1,480\text{ m/s}$ in water, and nearly $6,000\text{ m/s}$ in steel.
- **Phase ($\phi$):** When two waves interact, their relative phase determines the outcome. If two identical waves line up in phase ($0^\circ$), their pressure peaks combine constructively. If they arrive $180^\circ$ out of phase, they can cancel each other completely—the physical principle behind active noise-canceling headphones.
We don't study wave mechanics just to pass exams. Room acousticians rely on wavelength relationships to size bass traps and diffusers; medical engineers use short ultrasonic wavelengths to resolve fine tissue details; and oceanographers track speed-of-sound shifts across temperature layers to run sonar.
Next time you set up a microphone or transducer in the lab, don't just look at the oscilloscope trace as abstract numbers. You may ask yourself what the physical medium is actually doing to that pressure wave right now.
---
# Audio Oscillators as Sound Generator
As our first project, we will build two different types of oscillators: a **phase-shift oscillator** and a **reverse-avalanche oscillator**. The two circuits work in very different ways. The phase-shift oscillator uses **amplification and positive feedback** to produce an approximately sinusoidal waveform, while the reverse-avalanche oscillator uses **transistor avalanche breakdown and capacitor charging and discharging** to produce a nonlinear relaxation waveform. Although the circuits work differently, they both help us answer the same fundamental question of **how a DC power supply can produce a repeating AC waveform**.
## Materials for Phase-Shift Oscillator
- 1 x NPN transistor (**2N3904** or similar)
- 4 × 1 kΩ resistors (or 4 x 3.6 kΩ)
- 3 × 360 nF capacitors (or 3 x 100 nF)
- 1 × 1 uF capacitor
- 1 × 10 uF capacitor
- 1 x 1 kΩ potentiometer
- 1 × 470 Ω resistor
- Wires
- Breadboard
- Power supply (9 V battery or suitable 9 V supply)
- LED
- Appropriate LED current-limiting resistor
- Small amplifier
A **phase-shift oscillator** is an oscillator that uses an amplifier and a frequency-selective feedback network to generate an approximately **sinusoidal output**. The basic idea of feedback is pretty simple. The system produces an output signal, we take some of that output, and we send it back to the input. However, when we first learn about the phase-shift oscillator, we might find something confusing because there is no AC input. The circuit is connected to a 9 V battery, and a battery provides **DC (direct current)**. So, we might wonder, **if there is no AC input, how does the feedback loop start working?** And an even bigger question is **can a DC power supply create an AC signal?** At first, this might not make much sense to us. The key is **small disturbances in the circuit**.
---
> [!Further Understanding]
# Pure-Tone and Complex-Tone Perception
So far, we have treated sound mainly as a physical signal: pressure changes, frequency, amplitude, and waveforms. Now we can connect these physical properties to **what we actually hear**. Although a sound wave exists physically as pressure variations in the air, **pitch, loudness, and timbre are perceptual experiences produced by the auditory system**. To understand this connection, it helps to begin with the simplest possible signal: a pure tone, typically represented as a sine wave.
## 1. Pure-Tone Perception
A **pure tone** contains only one sinusoidal frequency:
$x(t)=Asin(2πft+ϕ)$
Pure tones are uncommon in everyday life, but they are extremely useful in acoustics because they let us study how the auditory system responds to one frequency at a time. It is important to distinguish the physical signal from the perception it produces:
- **Frequency ($f$)** is the physical rate of oscillation, measured in hertz.
- **Pitch** is the perceived sensation associated with frequency.
- **Sound pressure amplitude** describes the magnitude of the pressure variation.
- **Loudness** is the resulting perceptual sensation and does not increase linearly with physical level.
The ear does not simply pass this signal directly to the brain. The **cochlea** performs an important first stage of frequency analysis.

## 2. How the Cochlea Separates Frequencies
The **basilar membrane** inside the cochlea is organized so that different locations respond most strongly to different frequencies.
- High frequencies produce their strongest response toward the **base** of the cochlea.
- Low frequencies produce their strongest response toward the **apex**.
This spatial organization is called **tonotopic organization**. At the same time, for lower frequencies, auditory nerve fibers can preserve some information about the waveform's timing through **phase locking**. This is the tendency of auditory nerve fibers to fire action potentials at a consistent point, or "phase," within each cycle of a sound wave. The auditory system therefore receives both **spatial information** about where different frequencies excite the cochlea and **temporal information** about the timing of the waveform. We can think of the basic process as:
$Sound Wave→Cochlear Analysis→Neural Representation→Perception$
## 3. Hearing Is Frequency-Dependent
Human hearing is not equally sensitive to every frequency. We are generally most sensitive in the mid-frequency region, particularly around **2–5 kHz**, while very low and very high frequencies require greater sound pressure levels to be detected. This is described by the **absolute threshold of hearing** and **equal-loudness contours**.

The auditory system also behaves approximately like a bank of overlapping frequency-selective filters. These are often described using **auditory filters** or **equivalent rectangular bandwidths (ERBs)**. This filtering is important because nearby frequencies can interact perceptually, producing effects such as **masking**, in which a sufficiently strong sound reduces the detectability or perceived level of another sound, particularly when their frequencies are close together.
## 4. Complex-Tone Perception
Real musical and environmental sounds are usually much more complicated than pure tones. A complex sound can contain many sinusoidal components:
$ x(t)=\sum_{n=1}^{N} A_n\sin\left(2\pi f_n t+\phi_n\right) $
Where:
- $x(t)$ = resulting sound waveform
- $N$ = number of sinusoidal components
- $A_n$ = amplitude of the $n$th component
- $f_n$ = frequency of the $n$th component
- $\phi_n$ = phase of the $n$th component
- $t$ = time
If those frequencies are related by integer multiples of a fundamental frequency $f_0$, we have a **harmonic complex tone**:
$ f_1=f_0,\quad f_2=2f_0,\quad f_3=3f_0,\quad \dots $
The relative amplitudes and phases of these components contribute to the sound's **timbre**. However, not every complex sound is harmonic. Bells, cymbals, and other vibrating objects can contain **inharmonic partials**, where the frequency components are not simple integer multiples of a fundamental frequency.
## 5. The Missing Fundamental
Here's where hearing becomes particularly interesting. Imagine a sound containing:
$ 600,\quad 800,\quad 1000,\quad 1200\text{ Hz} $
There is no physical $200\text{ Hz}$ component. However, the frequency components are separated by:
$ 800-600=1000-800=1200-1000=200\text{ Hz} $
The auditory system can detect this regular harmonic structure and perceive a pitch corresponding to **200 Hz**. This is called the **missing fundamental** phenomenon or **virtual pitch**. The important lesson is that perceived pitch does not always require physical energy at the perceived fundamental frequency. The auditory system can infer pitch from the **relationship between frequency components**.
## 6. Timbre
Pitch tells us roughly _which note_ we hear, but timbre helps us identify _what produced it_. For example, a piano and violin can both play A4 at 440 Hz and at the same overall level, yet they sound completely different. Timbre depends strongly on:
- **Spectral structure** — the relative strengths of harmonics and other frequency components.
- **Temporal structure** — how the sound changes during its attack, decay, sustain, and release.
This is why the attack of an instrument can be so important. Two sounds can have similar steady-state spectra but still sound very different because their **transients** develop differently.
## 7. How We Separate Sounds
In a real environment, several sound sources may reach our ears simultaneously. The auditory system must determine which components belong together. Two important grouping cues are:
- **Harmonicity:** frequency components with a common harmonic relationship tend to be perceived as belonging to the same sound source.
- **Common fate:** components that begin, end, or change together tend to be grouped together.
This is part of **auditory scene analysis**—the process by which the brain organizes a mixture of sounds into meaningful auditory objects.
---
# Where Does the Noise Come From?
Back to the project. Another question we might have is **“Is noise DC or AC?”**
Noise is a random, time-varying electrical signal and is generally treated as an **AC signal**. When analyzed in the frequency domain, it can contain energy over a range of frequencies. However, there is an important distinction here. It is not correct to say that **“anything that makes sound is AC.”** AC and DC describe the behavior of an **electrical quantity**, such as voltage or current. Sound is a mechanical pressure wave, while electricity (voltage and current) is not sound. A microphone, for example, converts mechanical pressure variations into a corresponding electrical signal. That electrical signal can then be analyzed as an AC waveform. Therefore, an **audio signal** is an electrical representation of sound that is usually time-varying and can contain an **AC component**. It can also have a **DC offset**, meaning that the signal's average value is shifted away from zero.
When we connect a 9 V battery to the circuit, the battery provides **DC power**. Importantly, real electronic circuits are never perfectly quiet. Transistors, resistors, and other components naturally produce tiny random electrical fluctuations. These fluctuations are what we call **electronic noise**. There can also be other small disturbances, such as transients when the circuit is powered on. Noise is not limited to a single frequency; when viewed in the frequency domain, it can contain energy across a wide range of frequencies. This is actually very useful for our oscillator. We don't need to provide an external AC signal because tiny disturbances are already present inside the circuit. The oscillator can take these disturbances and reinforce the frequency components that satisfy the conditions for oscillation. To understand how this works, we need to look at the three important parts of our circuit: **Transistor, resistor, and capacitor.**
>[!Further Understanding]
# Noise and Its Spectral Colors
When people hear the word **“noise,”** they maybe picture annoying TV static. But in signal processing, noise is simply a signal whose energy is distributed across different frequencies, and the way that energy is shaped gives us a whole palette of “colors.” Think of **white noise** as the baseline. Its **power spectral density (PSD)** is flat, meaning it has equal power per unit bandwidth across the frequency range. This produces the familiar, uniform hiss of untuned radio static.
If you want to tame the emphasis on higher frequencies, you can shape white noise so that its power decreases by about **3 dB per octave**, giving it a $1/f$ spectral characteristic. This is **pink noise**. Because pink noise contains approximately equal energy per octave, it is often perceived as more balanced than white noise and is commonly associated with sounds such as steady rainfall. Reduce the power even more rapidly—by about **6 dB per octave**, corresponding to a $1/f^2$ spectrum—and you get **brown noise** (or Brownian noise). Brown noise can be generated by integrating white noise, which produces a strong emphasis on low frequencies and gives it a deep, rumbling character reminiscent of distant thunder.
Push the spectral slope in the opposite direction by emphasizing higher frequencies, and the result becomes increasingly bright. **Blue noise** has a PSD that increases by approximately **3 dB per octave**, proportional to $f$. It can be produced by appropriately differentiating a white-noise signal or by using spectral shaping designed to produce this frequency dependence. Taking this trend further gives **violet noise**, whose PSD increases by approximately **6 dB per octave**, proportional to $f^2$, resulting in an even stronger emphasis on high frequencies.
We don't study these different noise “colors” merely as academic trivia; each spectral shape has useful applications in engineering and signal processing. **Pink noise** is commonly used in audio testing and room-acoustic measurements because of its approximately equal energy per octave. **Blue noise** and related noise-shaped signals can be useful in digital signal processing and dithering applications, where spectral shaping can help move unwanted quantization noise toward less noticeable frequency ranges. **Brown noise** is closely related to integrated random processes and is useful in modeling and analyzing low-frequency-dominated signals.
Ultimately, comparing these noise spectra is about understanding how signal power is distributed noise across frequency and selecting the spectral shape that best fits a particular application. Next time you're setting up a test signal in the lab, pay close attention to which spectral shape you're actually feeding into your system.
---
# Transistor as an Amplifier
We may have heard before that modern computers are full of transistors, calculators contain transistors, and transistors can be used as switches, and all of these are correct. Transistors are one of the fundamental building blocks of modern electronics, and if we play guitar, we may have heard about a **transistor amplifier**. That is correct too. So, it turns out that a transistor can be used for several different purposes. In our phase-shift oscillator, we will use the transistor as an **amplifier**.
An amplifier takes a small electrical signal and produces a larger electrical signal. This is exactly what we need because the tiny disturbances in the circuit are extremely small. We need to amplify them, but amplification alone is not enough. If we simply amplified a random signal, we would not necessarily get one clean frequency. We want one particular frequency to grow, and this is where the resistors and capacitors come in.
# Resistor and Capacitor
A **resistor** opposes the flow of current. The larger the resistance, the more the resistor limits the current for a given voltage. A **capacitor** is a little different. A capacitor stores energy in an electric field, and its current depends on how quickly its voltage changes. This means that a capacitor behaves differently depending on the frequency of the signal. When we combine resistors and capacitors, we can create an **RC network**. An RC network can change both the **amplitude and phase** of a signal, and these changes depend on the frequency. This is exactly what we need for our oscillator.
# Amplifying Noise at Specific Frequencies
So now we have the basic idea. We have an amplifier, which is our transistor. We have resistors and capacitors, which form our RC feedback network. We also have small disturbances, including noise, which contain energy over a range of frequencies. When we power the circuit with DC, tiny electrical fluctuations are already present, and those fluctuations enter the transistor amplifier. The amplifier makes them larger, and part of the output signal travels through the three RC sections and is fed back to the transistor input. All sounds good, but you may wonder **if the noise contains many different frequencies, won't the circuit amplify all of them?**
This is where things get interesting. The RC network does not treat every frequency in the same way. Different frequencies experience different amounts of **attenuation and phase shift** as they pass through the RC network. The amplifier also has its own frequency-dependent behavior. At one particular frequency, the total loop can satisfy the conditions needed for oscillation, and that frequency is reinforced each time the signal travels around the loop. Other frequencies do not satisfy those conditions as well, so they do not continue growing in the same way.
# Is This Resonance?
At first, we might think this must be some kind of resonance, which is the frequency at which a system naturally responds most strongly when it is driven. After all, we have a particular frequency that seems to be favored by the circuit, but this is where we need to be careful with terminology. An RC circuit does not have a **resonant frequency** in the same sense as an LC (inductor-capacitor) circuit does. Instead, an RC network has a frequency-dependent amplitude and phase response. For a simple high-pass RC network, we often encounter the **characteristic frequency**:
$
f_c = \frac{1}{2\pi RC}
$
For example, let's say we have:
**R = 1 kΩ** and **C = 360 nF** (or R = 3.6 kΩ and C = 100 nF)
Then:
$
f_c =
\frac{1}{2\pi(1000)(360\times10^{-9})}
$
which gives us approximately:
$
f_c \approx 442\text{ Hz}
$
That's very close to 440 Hz, which is the musical pitch A4. At first, this seems almost perfect. We might think **if this RC circuit gives us about 440 Hz, does that mean it passes 440 Hz and blocks everything else?** Not exactly. The equation gives us a **characteristic frequency** of the RC network. Depending on the particular RC topology, this may be a cutoff or corner frequency. It does not mean that the RC circuit resonates at 442 Hz, nor does it mean that every other frequency is completely blocked. So then we have another question **if one RC circuit can give us a particular frequency response, why do we need three RC circuits?** The answer is **phase**.
# Phase
Phase is one of those concepts that we might find both fun and confusing when we first start working with audio signals. It is also extremely important. From a big-picture perspective, phase tells us **where a periodic signal is within its cycle**. Think about a sine wave. If we write:
$
\sin(0)
$
the result is 0.
If we write:
$
\sin\left(\frac{\pi}{2}\right)
$
the result is 1.
The argument of the sine function can be thought of as an angle. One complete cycle is:
$
360^\circ = 2\pi\text{ radians}
$
So phase can be thought of as describing the position of a periodic signal within that cycle. This becomes extremely important when we start feeding a signal back into a circuit. Depending on the phase, the feedback signal can either **reinforce** the original signal or **oppose** it, and this brings us back to our transistor amplifier.
# Back to the Transistor Amplifier
There are many different types of amplifier circuits, and they don't all behave in exactly the same way. The transistor amplifier in our circuit is a **common-emitter amplifier**. One important property of a common-emitter amplifier is that it produces approximately **180° of phase inversion** over the relevant frequency range. In simple terms, when the input signal goes up, the output signal goes down, and when the input goes down, the output goes up. So if we put a sine wave into the amplifier, the output is an inverted version of the input.
This is actually a problem for our feedback loop. Imagine that we take the output and immediately feed it back into the input. Because the amplifier has inverted the signal by 180°, the feedback would tend to oppose the original signal. That would be **negative feedback**, and we don't want negative feedback. We want the feedback to reinforce the signal, so we need another 180° of phase shift somewhere else. This is where our three RC sections become important.
# 3 RC Sections to Invert the Signal
Each RC section can change the **phase** of the signal. The resistor limits the flow of current, while the capacitor stores and releases electrical energy. Together, they control how quickly the capacitor voltage changes, causing a frequency-dependent phase relationship between the input and output. With the appropriate design, the **complete three-section RC feedback network** provides approximately **180° of phase shift at the desired oscillation frequency**. The transistor amplifier provides another approximately **180°**. So around the entire feedback loop we get:
$
180^\circ + 180^\circ = 360^\circ
$
360° is the same phase as 0°, and this means that when the signal travels around the entire loop and comes back to the transistor input, it is **in phase with the original signal**. Instead of cancelling the original signal, the feedback reinforces it. This is why the three RC sections are important. One thing we might initially assume is that each RC section simply provides exactly 60° of phase shift. That is a useful way to visualize the total:
$
60^\circ+60^\circ+60^\circ=180^\circ
$
However, the real circuit is more complicated. The phase shift of each section depends on the circuit configuration, and the sections load one another. What matters for the oscillator is that, at the desired frequency, the **total phase shift of the complete RC feedback network is approximately 180°**.
There is another important thing happening too. The RC network doesn't just shift the phase. It also **attenuates the signal**. In other words, some of the signal is lost as it travels through the feedback network. Therefore, the transistor amplifier needs to provide enough gain to compensate for this loss. This gives us the two important conditions for oscillation. **The total phase shift around the loop must be approximately 0° (or 360°), and the loop gain must be sufficient to sustain the oscillation.** This is the basic idea behind the **Barkhausen criterion**. In simple terms, the conditions for sustained oscillation can be written as:
$
|A\beta| \approx 1
$
and
$
\angle(A\beta) = 0^\circ \quad \text{(or } 360^\circ\text{)}
$
where:
- $A$ is the amplifier gain.
- $\beta$ is the feedback factor.
- $A\beta$ is the **loop gain**.
In other words, the feedback signal must return with approximately the **same amplitude** and the **correct phase** to sustain the oscillation. In a real oscillator, the conditions for startup and steady-state operation are a little more subtle. The loop gain generally needs to be slightly greater than unity for oscillation to grow from a small disturbance. As the amplitude increases, nonlinearities in the circuit reduce the effective gain until the oscillation settles into a steady state.
---
>[! Further Understanding: Trigonometry, Vectors, and Phase]
Trigonometry provides the mathematical foundation for understanding **vectors, sinusoidal signals, and phase** in electronics.
The key connection is:
$
\boxed{
\text{Triangle}
\rightarrow
\text{Components}
\rightarrow
\text{Angles}
\rightarrow
\text{Phase}
\rightarrow
\text{Phasors}
}
$
## 1. Trigonometry and Components
For a right triangle:
$
\sin(\theta)=\frac{\text{opposite}}{\text{hypotenuse}}
$
$
\cos(\theta)=\frac{\text{adjacent}}{\text{hypotenuse}}
$
$
\tan(\theta)=\frac{\text{opposite}}{\text{adjacent}}
$
For a vector $V$:
$
V_x=V\cos(\theta)
$
$
V_y=V\sin(\theta)
$
Its magnitude is:
$
\boxed{V=\sqrt{V_x^2+V_y^2}}
$
and its angle is:
$
\boxed{\theta=\operatorname{atan2}(V_y,V_x)}
$
So a vector can be described either by:
$
(V,\theta)
\quad\Longleftrightarrow\quad
(V_x,V_y)
$
## 2. Phase as an Angle
A sinusoidal signal can be written as:
$
x(t)=A\sin(2\pi ft+\phi)
$
where:
- $A$ = amplitude
- $f$ = frequency
- $\phi$ = phase angle
One complete cycle corresponds to:
$
360^\circ=2\pi\text{ rad}
$
Therefore:
$
90^\circ=\frac{\pi}{2}\text{ rad}
$
Phase describes the waveform's position within its cycle **relative to a reference**.
## 3. Phase and Time Shift
A time shift can be expressed as a phase angle:
$
\boxed{
\phi=2\pi\frac{\Delta t}{T}
}
$
or:
$
\boxed{
\phi=360^\circ\frac{\Delta t}{T}
}
$
For example:
$
\Delta t=\frac{T}{4}
\quad\Rightarrow\quad
\phi=90^\circ
$
Thus:
$
\boxed{
\frac{1}{4}\text{ cycle}=90^\circ=\frac{\pi}{2}\text{ rad}
}
$
A `+` phase represents a **lead**, while a `−` phase represents a **lag**:
$
A\sin(\omega t+\phi)
\rightarrow \text{lead}
$
$
A\sin(\omega t-\phi)
\rightarrow \text{lag}
$
## 4. Why It Matters in AC Circuits
Voltage and current can have the same frequency but different phase angles. This is important for:
- Resistors
- Capacitors
- Inductors
- Filters
- Resonance
- Impedance
- Frequency response
A **phasor** represents a sinusoidal quantity using its magnitude and phase:
$
\boxed{\mathbf{V}=V\angle\phi}
$
The magnitude tells us **how large** the signal is, while the phase tells us **where it is relative to the reference**.
---
# So How Does the Oscillator Start?
Now we can finally return to the question that confused us in the beginning. **There is no AC input. So how does the oscillator start?** The answer is that the circuit does not start from a perfectly zero signal. There are always tiny electrical disturbances in a real circuit. Some of them come from electronic noise. There can also be tiny disturbances when the circuit is powered on. These disturbances provide the initial perturbation that allows the feedback process to begin.
The feedback loop treats different frequency components differently. If a frequency component satisfies the required phase relationship and has sufficient loop gain, that component is reinforced every time it goes around the loop. The signal gets larger, and then it gets larger again, and again. Eventually, the oscillation becomes large enough that the amplifier is no longer operating in a perfectly linear region. The nonlinear behavior of the transistor limits the amplitude and prevents the signal from growing indefinitely. Therefore, the oscillator does not need an external AC input.
- The **DC power supply provides the energy**.
- The **electronic noise and other small disturbances provide the initial perturbation**.
- The **transistor provides amplification**.
- The **RC network provides frequency-selective phase shift and attenuation**.
- The **positive-feedback loop reinforces the oscillation** at the frequency that satisfies the oscillation conditions.
That is how a circuit powered by a DC battery can produce an AC oscillating signal and eventually, through a speaker, turn that electrical oscillation into something we hear as sound.
# Build the Circuit on a Breadboard as Shown in the Schematic
![[Phase Shift Oscillator LTSpice.png]]
[LTSpice Files](https://drive.google.com/file/d/1jF-_3ltToh97f6dv_kWib3shsTsQNtcZ/view?usp=sharing)
Is the LED flashing? If it is flashing, how many times do we see it? At a sufficiently high oscillation frequency, the LED switches faster than our visual system can resolve as individual flashes, so it may appear continuously illuminated or simply appear to change brightness. If our oscillator is working at around 440 Hz, the LED is switching far too quickly for us to see individual flashes. So, do we hear 440 Hz? Actually, we may not. Then what frequency do we hear? Are we hearing a lower frequency than 440 Hz, or a higher one? If we don't hear 440 Hz, what is causing the difference? To answer this, we need to look more carefully at the **phase shift of the RC feedback network** and, more importantly, at the behavior of the **complete feedback loop**.
# Calculating the Phase Shift in the RC Network
We initially chose **1 kΩ** resistors and **360 nF** capacitors (or 3.6 kΩ and 100 nF) because their characteristic frequency is close to 440 Hz:
$
f_c = \frac{1}{2\pi RC}
$
Substituting:
**R = 1000 Ω** and **C = 360 nF = 360 × 10⁻⁹ F** (or R = 3.6 kΩ and C = 100 nF = 100 × 10⁻⁹ F)
we get:
$
f_c =
\frac{1}{2\pi(1000)(360\times10^{-9})}
$
$
f_c\approx442\text{ Hz}
$
So 1 kΩ and 360 nF (or 3.6 kΩ and 100 nF) gives us a characteristic frequency of approximately 442 Hz. However, we have not yet considered the phase behavior of the oscillator. For a simple RC circuit, the phase angle depends on frequency, but we need to be careful here. The phase of an **individual RC impedance** is not the same thing as the phase shift of the **three-section feedback network**. Let's first use a simple RC circuit to understand where phase angles come from.
# Total Impedance of an RC Circuit
We may have heard the term **impedance** before, especially when working with passive speakers and amplifiers. We may also have heard about impedance matching and how an incorrect impedance can cause problems for an amplifier or audio system. So, what is impedance? Impedance is the opposition that a circuit presents to an **AC signal**. It is similar to resistance, but impedance also accounts for the effects of capacitance and inductance. We use **Z** to represent impedance instead of **R**, which represents resistance. For a resistor and capacitor connected in series, the total impedance is:
$
Z=R+\frac{1}{j\omega C}
$
where:
$
\omega=2\pi f
$
and **j** is the imaginary unit:
$
j^2=-1
$
Since:
$
\frac{1}{j}=-j
$
we can write:
$
Z=R-\frac{j}{\omega C}
$
A complex number can be written in the form:
$
Z=a+jb
$
For our RC circuit:
$
a=R
$
and
$
b=-\frac{1}{\omega C}
$
Therefore, the phase angle of the impedance is:
$
\theta=\tan^{-1}\left(\frac{b}{a}\right)
$
or:
$
\boxed{
\theta=-\tan^{-1}\left(\frac{1}{\omega RC}\right)
}
$
Let's use:
**R = 1 kΩ**
**C = 360 nF**
and:
**f = 440 Hz**
First:
$
\omega=2\pi f
$
$
\omega=2\pi(440)
$
$
\omega\approx2764.6\text{ rad/s}
$
Then:
$
\frac{1}{\omega RC}
=
\frac{1}
{(2764.6)(1000)(360\times10^{-9})}
$
$
\frac{1}{\omega RC}\approx1.004
$
Therefore:
$
\theta=-\tan^{-1}(1.004)
$
$
\theta\approx-45.1^\circ
$
So the impedance of this **simple series RC combination** has a phase angle of approximately **−45° at 440 Hz**. This calculation is **not yet an oscillator calculation**. We are using it only to develop our intuition for complex impedance and phase. It is useful for understanding how phase works, but we should not confuse this with the phase shift of one section of our three-section oscillator. The feedback network has to be analyzed as a complete network.
> [!Further Understanding]
# Complex Numbers and AC Circuits
AC circuits require us to describe not only **magnitude**, but also **phase**. Complex numbers provide a convenient way to represent both.
## 1. The Imaginary Unit
The imaginary unit is defined as:
$
j=\sqrt{-1}
$
Therefore:
$
j^2=-1
$
In electrical engineering, $j$ is used instead of $i$ because $i$ commonly represents current. A complex number can be written as:
$
z=a+jb
$
or in magnitude-angle form:
$
z=|z|\angle\theta
$
where:
$
|z|=\sqrt{a^2+b^2}
$
and:
$
\theta=\tan^{-1}\left(\frac{b}{a}\right)
$
This gives us a mathematical way to represent **magnitude and phase together**.
## 2. Complex Impedance
In AC circuits, resistance alone cannot describe capacitors and inductors because they introduce phase shifts. We therefore use **impedance**:
$
Z=\frac{V}{I}
$
Impedance can be written as:
$
Z=R+jX
$
where $R$ is resistance and $X$ is reactance.
For the basic components:
$
Z_R=R
$
$
Z_L=j\omega L
$
$
Z_C=\frac{1}{j\omega C}=-\frac{j}{\omega C}
$
The sign of the imaginary component indicates the phase relationship between voltage and current:
- **Resistor:** voltage and current are in phase.
- **Inductor:** current lags voltage.
- **Capacitor:** current leads voltage.
## 3. Why It Matters
Complex impedance lets us extend Ohm's law to AC circuits:
$
\boxed{V=IZ}
$
Instead of handling magnitude and phase separately, we can represent both with a single complex quantity.
$
\boxed{
\text{Complex Numbers}
\rightarrow
\text{Magnitude + Phase}
\rightarrow
\text{Impedance}
\rightarrow
\text{AC Circuit Analysis}
}
$
The key idea is simple: **$j$ provides the mathematical representation of the phase-related component of an AC quantity.**
---
# A Tempting but Incorrect Shortcut
At this point, we might be tempted to say **there are three RC sections, and we need 180° total phase shift. Therefore, each section should provide 60°.** That gives us:
$
60^\circ+60^\circ+60^\circ=180^\circ
$
If we then use the simple series-RC impedance equation and ask **at what frequency does the impedance have a phase angle of −60°?** we start with:
$
60^\circ
=
\tan^{-1}\left(\frac{1}{\omega RC}\right)
$
Taking the tangent:
$
\tan(60^\circ)
=
\frac{1}{\omega RC}
$
Since:
$
\tan(60^\circ)=\sqrt3
$
we get:
$
\sqrt3=\frac{1}{\omega RC}
$
Therefore:
$
\omega=\frac{1}{\sqrt3RC}
$
Using:
**R = 1000 Ω**
and
**C = 360 × 10⁻⁹ F**
we get:
$
\omega=
\frac{1}
{\sqrt3(1000)(360\times10^{-9})}
$
$
\omega\approx1603.8\text{ rad/s}
$
Since:
$
\omega=2\pi f
$
we get:
$
f=\frac{1603.8}{2\pi}
$
$
f\approx255.2\text{ Hz}
$
So our simple calculation tells us that a **series RC impedance** has a phase angle of approximately −60° at 255 Hz. At first, 255 Hz looks like exactly what we need:
$
255\text{ Hz}
\rightarrow
-60^\circ\times3
\rightarrow
-180^\circ
$
But there is a problem.
# Why 255 Hz Is Not the Oscillator Frequency
The 255 Hz calculation treats each RC section as though it were an **independent series RC impedance**. Our actual feedback network is not like that. The three RC sections are connected together, so they **load one another**. Because of this interaction, the phase shift and attenuation of the complete network are different from simply taking the phase angle of one RC impedance and multiplying it by three. Therefore, **255 Hz is not the actual oscillation frequency**. It is a useful simplified calculation that shows us how phase angle can be calculated, but it does not describe the complete feedback network. Therefore, **the phase of an impedance is not necessarily the same thing as the phase shift of a circuit's transfer function.** For an oscillator, what we really care about is the phase of the feedback signal relative to the original signal. In other words, we want to analyze:
$
\boxed{
\beta(j\omega)
=
\frac{V_{\text{feedback}}}{V_{\text{output}}}
}
$
where $\beta$ represents the feedback network.
The phase we need is:
$
\boxed{
\angle\beta(j\omega)
}
$
not simply:
$
\angle Z_{RC}
$
This distinction is extremely important.
# The Complete Three-Section RC Network
To recap, the transistor amplifier provides approximately **180° of phase inversion**. Therefore, for positive feedback, the RC network needs to provide another approximately **180° of phase shift**. For the conventional three-section RC phase-shift oscillator with equal R and C values, assuming the standard idealized topology and negligible loading by the amplifier input, circuit analysis gives the commonly used result:
$
\boxed{
f_0=
\frac{1}{2\pi RC\sqrt6}
}
$
The $\sqrt6$ factor comes from analyzing the **complete three-section feedback network**, including the interaction between the RC sections. This is different from the simple RC characteristic frequency:
$
f_c=\frac{1}{2\pi RC}
$
Let's calculate the oscillation frequency for our values.
**R = 1000 Ω**
**C = 360 nF = 360 × 10⁻⁹ F**
Therefore:
$
f_0=
\frac{1}
{2\pi(1000)(360\times10^{-9})\sqrt6}
$
Since:
$
\sqrt6\approx2.449
$
we get:
$
f_0\approx180.5\text{ Hz}
$
So, under this particular three-section model, the expected oscillation frequency is approximately **180 Hz**, and this is why our original calculation of approximately 442 Hz does **not** mean that the oscillator will automatically produce 442 Hz. The 442 Hz value is the characteristic frequency of the individual RC network. The oscillator frequency comes from the **complete feedback network**. There is also an important qualification here. The formula
$
f_0=\frac{1}{2\pi RC\sqrt6}
$
is an idealized result for a particular three-section RC phase-shift topology. The actual frequency of a physical oscillator can shift because of component tolerances, transistor behavior, loading between stages, amplifier input and output impedances, parasitic capacitance, and other nonideal effects. Therefore, 180 Hz should be treated as a **theoretical prediction for our model**, not as a guaranteed frequency for the physical circuit.
# Three Different Frequencies
Now we have three different numbers:
**442 Hz**: The characteristic frequency of a single RC network:
$
f_c=\frac{1}{2\pi RC}
$
**255 Hz**: The frequency at which our simple series RC impedance has a phase angle of approximately −60°. This is useful for understanding the simplified **60° + 60° + 60° = 180°** idea, but it does not account for the loading between the three sections.
**180 Hz**: For the standard three-section RC phase-shift oscillator with equal R and C values, the approximate oscillation frequency obtained by analyzing the complete RC network, under the idealized assumptions described above, is:
$
f_0=\frac{1}{2\pi RC\sqrt6}
$
Threrefore, **the frequency of an oscillator is determined by the behavior of the entire feedback loop, not simply by the characteristic frequency or phase angle of one RC component.**
# So What Frequency Do We Actually Hear?
For our 1 kΩ and 360 nF (or 3.6 kΩ and 100 nF) components, the simplified three-section model predicts an oscillation frequency of approximately **180 Hz**. However, the actual circuit may produce a different frequency because real circuits are not ideal. The actual frequency depends on the **exact circuit topology**, the transistor amplifier, the loading between the RC sections, component tolerances, and the input and output impedances of the amplifier. Therefore, we should not assume that the circuit will produce exactly 180 Hz without measuring the output. The best way to determine the actual frequency is to **measure the oscillator output** using an oscilloscope, frequency counter, or suitable audio-frequency measurement tool. If we measure a frequency close to 180 Hz, that would be consistent with the simplified model. If we measure something significantly different, we should investigate the actual schematic, component values, loading, and transistor operating point.
> [!Further Understanding]
# Basic Transistor Operation
A transistor is a semiconductor device that allows a small electrical signal to control a larger current. In an **NPN transistor**, the three terminals are the **base (B)**, **collector (C)**, and **emitter (E)**.
## 1. The Three Terminals
The terminals have different roles:
- **Base:** controls the transistor's operation.
- **Collector:** receives the main current flowing through the transistor.
- **Emitter:** provides the main current path out of the transistor.
For an NPN transistor operating in its active region, conventional current flows approximately:
$
C\rightarrow E
$
while a much smaller base current flows into the base:
$
I_E=I_C+I_B
$
The collector current is controlled by the base-emitter voltage or, in the common simplified current model, by the base current:
$
I_C\approx\beta I_B
$
where $\beta$ is the transistor's current gain.
## 2. Base-Emitter Junction
An NPN transistor can be thought of as containing two semiconductor junctions. For normal active operation, the **base-emitter junction is forward biased**. For a silicon transistor, this typically requires approximately:
$
V_{BE}\approx0.7\,\text{V}
$
Once the base-emitter junction is sufficiently forward biased, the transistor allows substantial collector-emitter current to flow. This is why a transistor is often described as a **controlled current device**: a relatively small base current can control a much larger collector current.
## 3. Transistor as a Switch
The simplest way to understand an NPN transistor is as an electronic switch. With little or no base drive:
$
I_B\approx0
\quad\Rightarrow\quad
I_C\approx0
$
The transistor is approximately **OFF**.
With sufficient base drive, the transistor conducts strongly and can be driven into **saturation**, where it behaves approximately like a closed switch. Thus:
$
\boxed{
\text{Base drive}
\rightarrow
\text{Collector current}
\rightarrow
\text{Controlled switching}
}
$
## 4. Transistor as an Amplifier
A transistor can also operate in its **active region**, where changes in the base signal produce corresponding changes in collector current. If the collector current flows through a resistor, those current changes produce voltage changes:
$
V=IR
$
A small change at the base can therefore produce a larger voltage change at the collector. This is the basic principle behind a **transistor amplifier**:
$
\boxed{
\text{Small input}
\rightarrow
\text{Base control}
\rightarrow
\text{Collector-current change}
\rightarrow
\text{Larger output voltage change}
}
$
The important distinction is that the transistor does not create energy. The additional output power comes from the **DC power supply**, while the input signal controls how that available power is delivered to the load.
---
# Reverse-Avalanche Oscillator
The next oscillator we want to make is a **reverse-avalanche oscillator**, which is different from the phase-shift oscillator. Instead of using an amplifier and a frequency-selective feedback network, it takes advantage of **reverse-avalanche breakdown in a transistor** to create a relaxation oscillator. A relaxation oscillator does not normally produce a sine wave. Depending on the circuit configuration and component values, the resulting waveform can be a pulse, sawtooth-like waveform, or another non-sinusoidal waveform. This makes it particularly interesting from a **synthesizer perspective**, because the non-sinusoidal waveform can contain multiple frequency components that contribute to its timbre.
- A phase-shift oscillator can give us an approximately sinusoidal waveform with relatively little harmonic content.
- A reverse-avalanche oscillator can produce a waveform with much more complex harmonic content.
That means we can approach sound synthesis in two different ways. With **additive synthesis**, we can build a complex sound by adding simpler sine waves:
$
x(t)
=
A_1\sin(\omega_1t+\phi_1)
+
A_2\sin(\omega_2t+\phi_2)
+\cdots
$
With **subtractive synthesis**, we can start with a waveform that already contains many harmonics and then use filters to remove or attenuate selected frequency components. These two oscillators therefore give us two useful starting points for exploring sound synthesis: a relatively simple waveform and a more harmonically complex waveform.
>[!Further Understnading]
# Waveforms and Signals: Shapes, Harmonics, and Spectra
When people think of **signals**, they might picture simple musical notes or squiggly lines on an oscilloscope screen. But in **signal processing and sound synthesis**, a **waveform** is simply a time-varying quantity whose shape determines its spectral content. How energy is distributed across the **fundamental frequency and its harmonics** determines the harmonic properties we measure in the lab.
## 1. Basic Periodic Waveforms & Harmonic Spectra
Think of the **sine wave** as the baseline. It is a pure sinusoidal oscillation consisting of a single fundamental frequency $f_0$ with no harmonic overtones—the basic building block of more complex waves. Modifying a periodic wave's shape introduces harmonics at integer multiples of the fundamental frequency ($n \cdot f_0$):
- **Square Wave:** A symmetrical wave alternating between two fixed amplitude levels. It contains only **odd harmonics** ($3f_0, 5f_0, 7f_0$) with amplitudes decreasing approximately as $1/n$.
- **Triangle Wave:** A smooth, linear ramp up and down. Like the square wave, it contains only **odd harmonics**, but their amplitudes decay much faster, approximately as $1/n^2$, giving it a softer sound.
- **Sawtooth Wave:** A linear ramp followed by a sharp drop. It contains **all integer harmonics** (both even and odd: $2f_0, 3f_0, 4f_0,\dots$) with amplitudes decreasing approximately as $1/n$, producing a rich, bright spectrum.
- **Pulse Wave:** A generalized rectangular wave with a variable duty cycle:
$
D=\frac{\tau}{T}
$
where $\tau$ is the pulse width and $T$ is the total period. Adjusting $D$ changes the waveform shape and can cause certain harmonics to have zero amplitude.
Because a periodic signal's shape determines its spectrum, a repeating waveform $x(t)$ can be represented using a Fourier series:
$
x(t)=a_0+\sum_{n=1}^{\infty}
\left(
a_n\cos(n\omega_0t)+b_n\sin(n\omega_0t)
\right)
$
- **Pure Tone (Sine):** Contains a single frequency component at $f_0$.
- **Harmonic Waveforms (Square/Saw/Triangle):** Contain discrete spectral components at integer multiples of $f_0$.
## 2. Aperiodic Signals, Impulses, and Complex Waves
What separates **simple periodic waves** from many real-world signals is their periodicity and component composition:
- **Impulse ($\delta(t)$) & Impulse Train:** An ideal impulse (Dirac delta function) occurs instantaneously with theoretically infinite amplitude and zero width. Its Fourier transform has equal magnitude across all frequencies, producing a flat spectrum. Repeating impulses periodically forms an **impulse train** (Dirac comb), whose spectrum consists of equally spaced discrete frequency components.
- **Aperiodic Signals:** Signals that do not repeat over a finite period $T$, such as transient strikes, speech consonants, or random noise. Their frequency content is generally represented as a continuous spectrum using the Fourier transform.
- **Complex Waves:** Real-world signals—from vocal sounds to musical instruments—are composite signals formed by superimposing multiple sinusoidal components, transients, and noise.
We don't study these waveforms merely as geometric exercises; each shape serves a specific engineering purpose:
- **System Testing & Characterization:** Impulse signals reveal a system's time-domain impulse response $h(t)$, while square waves can test amplifier transient performance, slew rate, and ringing.
- **Subtractive Audio Synthesis:** Sawtooth and square waves provide harmonic-rich raw material that can be filtered to create different timbres.
- **Digital Timing & Modulation:** Pulse waves with adjustable duty cycles form the foundation of **Pulse-Width Modulation (PWM)** for power electronics, motor control, and other applications.
---
# Reverse-Avalanche Breakdown: From Emitter to Collector
![[Reverse Avalanche Oscillator.png]]
When we use an NPN transistor as an amplifier in a typical circuit, the collector is normally connected toward the positive supply, while the emitter is connected toward the lower-potential side of the circuit (GND). In the forward-active region, the collector-emitter current is controlled by the base-emitter voltage and, in the simplified current model, by the base current. An important detail, however, is that saying **“current flows from collector to emitter”** describes normal transistor operation; it does not mean that the transistor can never conduct in other directions under different conditions.
A transistor contains semiconductor junctions, and under a sufficiently high reverse voltage, one of these junctions can enter **avalanche breakdown**. In a reverse-avalanche oscillator, we intentionally apply a reverse voltage large enough to cause avalanche breakdown. For example, in an NPN transistor, the **collector-base junction** can be strongly reverse-biased until it enters avalanche breakdown. This is an operating condition outside the normal intended operating region of many ordinary transistors, so the behavior may not be specified or guaranteed by the manufacturer.
> **Caution:** Reverse-avalanche operation intentionally drives the transistor outside its normal operating region. Do not assume that an ordinary transistor is safe to avalanche simply because another experiment has used the same part number. The allowable voltage, avalanche current, pulse duration, power dissipation, and repetitive electrical stress all matter. Use appropriate current limiting and consult the transistor's specifications whenever relevant data are available.
The basic circuit can contain components such as:
- 1 x NPN transistor (**2N3904** or **2N2222**)
- 1 x 4.7 uF Capacitor
- 1 x 50 kΩ Potentiometer
- LED
- Appropriate LED current-limiting resistor (460 Ω)
- Small amplifier or audio amplifier
- Wires
- Breadboard
- Suitable power supply (2 × 9 V batteries in series to create 18 V)
The important difference from a phase-shift oscillator is that the reverse-avalanche oscillator does not need a conventional amplifier-feedback network to sustain oscillation. Instead, it uses the **breakdown behavior of the transistor and the charging/discharging behavior of a capacitor**. This makes it a type of **relaxation oscillator**.
## How the Oscillation Happens
Suppose a capacitor is connected to a supply through a resistor, while the transistor provides a breakdown path for the capacitor. Initially, the capacitor voltage is low. The transistor is below its avalanche breakdown voltage, so only a very small leakage current flows through the transistor. Meanwhile, current through the resistor gradually charges the capacitor. As the capacitor voltage increases, it eventually reaches a voltage high enough to cause avalanche breakdown. The transistor then conducts much more strongly, providing a relatively low-impedance discharge path for the capacitor. The capacitor rapidly discharges through the transistor. Once its voltage falls sufficiently, the avalanche condition disappears and the transistor stops conducting strongly. The capacitor then begins charging again. This process repeats:
$
\boxed{
\text{charge}
\rightarrow
\text{avalanche}
\rightarrow
\text{discharge}
\rightarrow
\text{charge}
\rightarrow\cdots
}
$
This repeating process produces a periodic waveform.
# Potentiometer as a Current-Limiting and Frequency-Control Element
One problem is that the capacitor can charge and discharge very quickly. Without enough resistance, the resulting oscillation frequency can be much higher than the audible range. Human hearing is approximately:
$
20\text{ Hz}\sim20\text{ kHz}
$
although the exact useful range depends on the listener, age, sound level, and other factors. We can place a resistor between the power supply and capacitor to limit the charging current. The resistance also affects how quickly the capacitor charges and therefore affects the oscillation frequency. If we use a **potentiometer as a variable resistor**, we can change this resistance while the circuit is operating. This allows us to change the charging time and therefore adjust the oscillator frequency. Increasing the resistance generally makes the capacitor charge more slowly:
$
R\uparrow
\quad\Rightarrow\quad
\text{charging time}\uparrow
\quad\Rightarrow\quad
f\downarrow
$
while decreasing the resistance makes the capacitor charge more quickly:
$
R\downarrow
\quad\Rightarrow\quad
\text{charging time}\downarrow
\quad\Rightarrow\quad
f\uparrow
$
A simplified view of the timing is related to the **RC time constant**:
$
\boxed{\tau=RC}
$
However, the actual frequency of a reverse-avalanche oscillator cannot generally be calculated from $RC$ alone, unlike the simplified characteristic-frequency calculation used for the phase-shift oscillator. The avalanche voltage, capacitor charging and discharge behavior, transistor characteristics, supply voltage, leakage currents, and overall circuit configuration can all affect the oscillation frequency.
## LED as an Indicator
An LED can be used as an indicator of the oscillation. However, the LED must have an appropriate **series current-limiting resistor**. The LED should not simply be connected directly across a transistor breakdown/discharge path because the discharge current can be large enough to damage the LED.
# Protecting the Components
There is an important potential problem with this circuit: the transistor and other components can be damaged if the current is not properly limited. For example, suppose we use a $100\,\text{k}\Omega$ potentiometer as a variable resistor. Depending on how it is connected, the resistance could approach $0\,\Omega$ at one end of its adjustment range. If the potentiometer is effectively $0\,\Omega$, the capacitor or transistor can experience a very large current. This can damage the transistor, LED, potentiometer, or power supply. A common way to prevent this is to place a **fixed resistor in series with the potentiometer**.
For example:
$
R_{\text{total}}
=
R_{\text{fixed}}
+
R_{\text{pot}}
$
If we use a $1\,\text{k}\Omega$ fixed resistor and a $100\,\text{k}\Omega$ potentiometer:
$
1\,\text{k}\Omega
\le
R_{\text{total}}
\le
101\,\text{k}\Omega
$
The important benefit is that the resistance can never fall below $1\,\text{k}\Omega$. However, the fixed resistor must be chosen based on the actual supply voltage, transistor, capacitor, LED, and desired operating current. It should not simply be assumed that $1\,\text{k}\Omega$ is always safe. There is also a trade-off. If the minimum resistance is too high, the capacitor may charge too slowly, limiting the maximum oscillator frequency. If the minimum resistance is too low, the current during avalanche/discharge can become excessive and damage components. Therefore, the resistance range should be selected based on both **frequency requirements and component-current limits**.
# Instability of the Transistor
Another interesting characteristic of this experiment is that the avalanche behavior of an ordinary transistor can vary significantly. For example, the breakdown voltage and leakage behavior can depend on:
- transistor type
- individual device variation
- temperature
- supply voltage
- previous electrical stress
- circuit layout
- measurement conditions
Temperature can change semiconductor characteristics, and different transistors of the same part number can also behave somewhat differently. This is particularly important because reverse-avalanche operation is generally **not the normal operating mode** for an ordinary transistor. Many manufacturers do not specify or guarantee the transistor's long-term behavior when deliberately operated in avalanche breakdown. Therefore, it is difficult to design a reverse-avalanche oscillator with the same predictable frequency accuracy as a carefully designed oscillator using components whose relevant parameters are specified. For an experimental sound-making circuit, however, this unpredictability can actually be interesting. Instead of expecting a perfectly calculated frequency, we can treat the circuit as an experiment and investigate how different transistors, capacitors, resistors, and supply voltages affect the resulting sound and waveform.
The goal is therefore not necessarily to build a perfectly stable frequency reference, but to explore how **avalanche breakdown, RC charging, and semiconductor behavior can be combined to create an oscillator**.
# Summary of Conceptual Comparison
The two oscillators solve the same problem in fundamentally different ways. The phase-shift oscillator uses **continuous amplification and positive feedback**: a small disturbance is amplified and selectively reinforced. The reverse-avalanche oscillator uses **threshold behavior**: a capacitor slowly stores energy until a transistor suddenly enters avalanche breakdown and releases that stored energy. In other words, one oscillator is based primarily on **feedback**, while the other is based primarily on **charging, threshold, and discharge**.