A complete, source-preserving edition organized around the movement of signals, energy, and information through electronic systems.
Parts
09
Chapters
73
Interactive models
34
Part I · 6 chaptersCh 01–06
01
Electronic Systems and Electrical Foundations
Part I · Electronic Systems and Electrical Foundations
01
The Sense–Compute–Communicate Paradigm
0 sections2 min read
A general electronic system does three things. It senses the physical world — sound, light, pressure, temperature, motion. It computes on what it senses — amplifies, filters, mixes, digitizes, stores, processes. And it communicates or actuates the result — drives a speaker, lights a display, transmits over a wire or through the air. This sense–compute–communicate arc is the spine of EE1101, and every concept in this book sits somewhere on it.
The course opens not with a definition but with a problem. A mobile phone contains a 3.8 V battery that supplies a microprocessor, a display controller, and a camera. Each of these draws a current that changes with time: call them \(I_1(t)\), \(I_2(t)\), \(I_3(t)\). If we could measure those three currents, the instantaneous power drawn from the battery would be
The course's promise is that by its end a student can take such a current profile and compute how much energy was consumed — that is, the time integral of \(P(t)\). The expression \(P = V\,I\) here is used in its everyday sense of "voltage times current gives power"; the quantities \(V\), \(I\), and \(P\) are formally defined and measured in Chapters 6 and 7. What makes this tractable, the instructors claim, is that very elementary ideas — essentially just Kirchhoff's current and voltage laws — get a reasonable distance in understanding real gadgets.
Two threads run through this opening. First, a real phone does exactly this kind of accounting internally through a power-management unit (PMU), an IC that continuously monitors current and lets the operating system shut down blocks that are not needed. Second, because the quantities of interest are time-varying, a plain voltmeter is the wrong instrument; an oscilloscope is needed to see how voltage and current evolve in time. These two threads — power accounting and time-varying measurement — recur throughout the book.
Part I · Electronic Systems and Electrical Foundations
02
Teardown as a Learning Method
0 sections1 min read
The first laboratory operation of the course is a teardown: opening a mobile phone screw by screw, keeping the critical components in a box, unplugging the screen first so it separates cleanly, and identifying the headphone jack, charging port, camera module, and the motherboard that holds a couple of integrated chips. The point is not to learn repair. The point is to make the abstract physical hierarchy of an electronic system visible: a central computational core, a large energy store, and a constellation of sensors and actuators around them.
A natural question follows: how small can a phone get? Summing the areas of the small components shows they occupy less than half the phone's footprint. The screen is not the limiting factor — older Nokia phones and modern smartwatches use far smaller screens; the screen size is a user-experience constraint, not a hardware one. The actual limiting factor is the battery, which spans nearly the full length of the phone and occupies roughly 60–70% of its floor plan. The reason is energetic: a modern phone is used for watching video, taking photos, and recording, not just low-energy calling, so a large energy store is unavoidable.
This single observation — that energy storage sets the size of a modern portable system — motivates the entire first part of the book.
Part I · Electronic Systems and Electrical Foundations
03
The Battery and the Charger
4 sections3 min readInteractive model
3.1 What a battery stores
Interactive lab
Unit converter
Adjust the model. Battery units: 1 mAh = 3.6 C; 1 Wh = 3600 J.
Interactive lab
Charger rate
Adjust the model. Power is voltage × current; time follows from energy ÷ power.
A battery stores electrical energy in chemical form and can be recharged when depleted. Its nameplate ratings answer two distinct questions:
How much charge can it deliver? Answered in milliampere-hours (mAh). A battery rated \(C\) mAh can supply \(C\) milliamperes for one hour.
How much energy can it deliver? Answered in watt-hours (Wh), the product of voltage and charge capacity: \(\text{Wh} = \text{V} \times \text{Ah}\). This follows directly from \(W = V\,Q\) (the work done in moving charge \(Q\) through a potential difference \(V\), derived in Chapter 6): if \(V\) is held fixed at the nominal voltage and \(Q\) is the charge delivered, then \(W = V\,Q\).
A few unit conversions worth keeping in mind: one hour is \(3600\,\text{s}\), so \(1\,\text{Wh} = 1\,\text{V} \times 1\,\text{A} \times 3600\,\text{s} = 3600\,\text{J}\), and \(1\,\text{mAh} = 10^{-3}\,\text{A} \times 3600\,\text{s} = 3.6\,\text{C}\).
The iPhone 5S battery is rated 1510 mAh, 3.8 V, and 5.73 Wh. A smaller battery is rated 3.7 V, 800 mAh, 3 Wh. Smaller batteries generally have lower specifications on all three axes.
A subtlety worth internalizing early: the measured voltage of a real battery is rarely exactly its rated voltage. A 3.7 V battery may measure 3.62 V on a multimeter because of wear, state of charge, and meter error. The rating is a nominal value; the measurement is what you have right now.
3.2 Battery life
If a battery of capacity \(C\) mAh supplies a total current \(I_{\text{tot}}\) mA, its life in hours is, to first order,
With three ICs drawing 10, 20, and 40 mA (70 mA total) from a 1510 mAh battery, the life is \(1510/70 \approx 20\) hours. The endurance rating of a phone is the same idea expressed against a defined daily usage pattern (e.g. one hour each of calls, browsing, and video per day); the iPhone 5S endurance rating is 54 hours, meaning it needs recharging about once every two days under that pattern.
3.3 The charger experiment
A loose but instructive experiment motivates the charger. The same phone is charged from four sources — wall charger, laptop USB, car power USB, and a car infotainment USB port — and the time taken for each 1% increment of charge is measured. To control for the unknown true battery state, the clock is started only when the displayed percentage ticks to base+1 and stopped at base+2.
The wall charger and laptop USB each took about 20 s per 1%. The car power USB took 40 s. The infotainment port failed entirely: the voltage read roughly 3.6 V, the same as the other sources, yet the phone did not charge. The lesson is decisive: a charger's usefulness depends on its current rating, not just its voltage. The infotainment port could not supply enough current, even though its voltage was correct.
3.4 Batteries versus chargers, dimensionally
The dimensional contrast is the key takeaway:
A battery is specified in units of stored charge/energy (mAh, Wh). It is a reservoir.
A charger is specified in units of rate (A, W). It is a pump.
Dimensionally, \(\text{mAh}/\text{time} \to \text{A}\) and \(\text{Wh}/\text{time} \to \text{W}\). This is why modern chargers boast high current (3 A, 25 W): rate of energy delivery is what matters. USB port ratings vary by generation (USB 1.0 up to 500 mA, USB 3.0 about 900 mA), and "up to 500 mA" does not guarantee that current is delivered — the infotainment port is the cautionary example.
Advanced battery considerations
Battery capacity is not a fixed number. The rated mAh is a measurement under specific conditions: a defined discharge current (often C/5, meaning a current that would deplete the cell in five hours), a defined temperature (typically 25°C), and a defined endpoint voltage (typically 3.0 V for a Li-ion cell). Real-world discharging at higher rates, lower temperatures, or different cutoffs reduces the deliverable capacity. Peukert's law captures the rate dependence: at higher discharge currents, the effective capacity C_eff follows roughly C_eff = I · t with the time t falling faster than linearly with I.
The internal resistance of a Li-ion cell is on the order of 50–100 mΩ when new, rising to 200–400 mΩ by end-of-life. This resistance has two practical consequences: (1) some of the cell's energy is dissipated as heat inside the cell itself, reducing the energy available to the load; (2) the terminal voltage sags under high discharge currents, so the device may shut off prematurely even when the cell still holds substantial charge. This is why a phone may report 20% battery and then suddenly drop to 5% under load — the terminal voltage fell below the protection circuit's cutoff before the cell was truly empty.
State of charge (SOC) is not directly measurable; it must be inferred from terminal voltage, current integration (coulomb counting), or impedance spectroscopy. Modern battery management ICs combine all three: a voltage lookup table gives a rough SOC, an integrating current sensor refines it over time, and a periodic impedance measurement (a small AC pulse at 1 kHz) corrects for drift. The result is the percentage estimate shown on the phone's screen — accurate to roughly 2% when calibrated, but visibly imprecise at the extremes (0% and 100% are tricky because the voltage curve flattens).
Charging a lithium-ion cell is a two-stage process. A constant-current (CC) phase drives charge into the cell at a rate of 0.5C to 1C until the terminal voltage reaches 4.2 V per cell. Then a constant-voltage (CV) phase holds the voltage at 4.2 V while the current tapers down to roughly 0.05C. The CC phase restores about 70% of the capacity in the first half of the charging time; the CV phase fills the remaining 30% in the second half. This is why a phone's “time to 80%” estimate is much shorter than the “time to 100%” estimate, and why the last 20% of charging feels slow.
Part I · Electronic Systems and Electrical Foundations
04
Back-of-the-Envelope Engineering
0 sections1 min read
Engineers routinely estimate the order of magnitude of an answer before computing it precisely. This practice, called back-of-the-envelope calculation, has three defining features:
It rests on a sound scientific principle.
It uses known approximations (not guesses).
Its approximations are removable: the experiment can be made rigorous by removing them one by one.
Two illustrations make this concrete. First, \(e \approx 2.71\) can be obtained from a Taylor series expansion to two decimals without full precision. Second, the area of a circular well of diameter \(D\) is \(\pi D^2/4\); with \(\pi \approx 3\) this collapses to a "75% rule" — a simple multiplier on \(D^2\) that is accurate enough for digging a well.
The point of order-of-magnitude reasoning is to sanity-check simulators. A simulator can give a wrong answer if its settings are wrong; an engineer who has a rough estimate of the expected magnitude is the only defense. Enrico Fermi's estimation of the atomic-bomb yield from how far bits of paper were blown is the canonical example. Rigor in measurement complements estimation: control variables (turn off apps, use airplane mode), measure current at the same point, and repeat the experiment many times to average out noise.
Part I · Electronic Systems and Electrical Foundations
05
The Resistor and Joule Heating
0 sections1 min readInteractive model
Why does a phone heat up during a long call? The answer begins with a kettle.
Interactive lab
Resistive heating ledger
Adjust the model. Electrical power V²/R becomes heat; area determines power density.
A kettle's heating element is a resistor. Measured with a multimeter, its plug shows roughly \(52.7\,\Omega\) across its terminals, and the mains delivers about \(230\,\text{V}\) (AC). Using
the heater dissipates \(P \approx 230^2/52.7 \approx 1000\,\text{W}\), matching the kettle's nameplate 1000 W / 230 V / 50 Hz. This formula combines \(P = V\,I\) with Ohm's law \(V = I\,R\) to eliminate \(I\); it will be derived formally from \(V = IR\) once Ohm's law is introduced in Chapter 8.
Passing current through a resistor always dissipates electrical power as heat. The two equivalent forms are
\[P \;=\; I^2 R \;=\; \frac{V^2}{R} \;=\; V I.\](5.2)
In a kettle the heat is harnessed usefully to boil water over a large surface area. In a phone the same dissipation is concentrated into a tiny silicon area, which is why thermal management — heat spreading, throttling, clock gating — is a critical design problem. The principle is identical; the power density (\(P_{\text{density}} = P_{\text{total}}/\text{Area}\)) is what differs.
Power, heat, and thermal design
The kettle and the phone illustrate a fundamental design tradeoff: the same electrical dissipation P = V²/R can be useful heat (kettle boiling water) or destructive heat (phone thermal shutdown). The power density — watts per unit area — is what determines the outcome. A kettle's heating element is a long, thin wire wound into a flat coil; the surface area is large, so each square centimeter dissipates only a few watts, and the water absorbs it efficiently. A phone's silicon die is a few square millimeters; the same power density concentrates into an area a million times smaller, and the temperature rises by hundreds of degrees without active cooling.
Thermal management is therefore a central design problem. The four-tier strategy is: (1) reduce the power dissipated (clock gating, power gating, low-leakage transistors); (2) spread the heat (heat spreaders, thermal interface materials, copper or graphite sheets); (3) move the heat away (fans, heat pipes, vapor chambers); (4) accept the limit (thermal throttling — reducing the clock speed when temperature exceeds a threshold). Phones use all four; high-end phones combine a graphite spreader, a copper vapor chamber, and aggressive thermal throttling.
Joule heating is also the mechanism behind fuses and circuit breakers. A fuse is a calibrated resistor designed to melt at a specific current: when the current exceeds the rating, the I²R heating melts the element and breaks the circuit. PTC (positive temperature coefficient) thermistors do the same job resettably: their resistance increases sharply with temperature, so a fault current self-heats the element and limits the current to a safe value until the fault clears. Both are passive, fail-safe thermal protections derived from the same P = I²R law that heats a kettle.
Part I · Electronic Systems and Electrical Foundations
06
From Experiments to Theory: Charge, Drift, and Power
5 sections4 min readInteractive model
The first week's experiments — battery, charger, kettle — are now placed on a formal footing.
Interactive lab
Electron drift
Adjust the model. Drift velocity is much smaller than the electrical signal speed.
6.1 The elementary charge and the electric field
The elementary charge is \(e = 1.6\times 10^{-19}\,\text{C}\). A charge \(Q\) placed in an electric field \(\mathcal{E}\) experiences a force
In a conductor, free electrons (electrons available for conduction, as opposed to bound electrons) are in constant chaotic motion at high speed due to thermal energy. Without any applied field, this motion is symmetric: equal numbers of electrons cross any cross-section in each direction, so the net charge flow averages to zero — no macroscopic current. When a voltage source is connected across the conductor, it produces an internal electric field\(\mathcal{E}\) pointing from the higher-potential end to the lower-potential end. The field exerts a force \(F = -e\mathcal{E}\) on each free electron (the minus sign because the electron charge is negative), superimposing a slow, directed drift velocity\(v_d\) on top of the rapid random thermal motion. The "sweet box and flies" analogy captures this exactly: the box (drift) drifts slowly in one direction while the flies (thermal motion) buzz chaotically inside it. The drift is opposite to the field direction because the electron charge is negative, so electrons drift from the lower-potential end toward the higher-potential end inside the conductor.
To connect this microscopic picture to the macroscopic current \(I\), count the electrons that cross a cross-sectional area \(A\) of the conductor in a small time \(\Delta t\). In that interval, the volume of conductor that "empties" across the cross-section is \(A \cdot v_d \cdot \Delta t\). If \(n\) is the number of free electrons per unit volume, the number of free electrons in that volume is \(n A v_d \Delta t\), and each carries charge \(e\) (in magnitude). The total charge crossing is therefore \(e n A v_d \Delta t\). Dividing by \(\Delta t\) gives the current:
This is the microscopic origin of macroscopic current: a slow, field-driven drift of a vast number of mobile charges.
A useful order-of-magnitude comparison. For copper, the free-electron density is about \(n \approx 8 \times 10^{28}\,\text{m}^{-3}\), and a typical wire carrying \(1\,\text{A}\) in a \(1\,\text{mm}^2\) cross-section gives a drift velocity of roughly
or about \(0.07\,\text{mm/s}\). This is extraordinarily slow — many orders of magnitude below the random thermal speeds of the electrons, which are of order \(10^5\,\text{m/s}\) at room temperature. The lesson is that macroscopic current is a statistical effect: a tiny bias superimposed on rapid random motion of an enormous number of charge carriers. The signal travels fast (close to the speed of light), but the individual charge carriers barely move.
Current is the rate of flow of charge, \(I = dq/dt\).
6.3 Units: ampere, coulomb, and the meaning of mAh
The ampere is a coulomb per second: \(1\,\text{A} = 1\,\text{C/s}\). Therefore a milliampere-hour is a unit of charge:
The 1510 mAh battery therefore holds about \(5400\,\text{C}\), which is roughly \(3\times 10^{22}\) elementary charges. This is the sense in which a battery is a reservoir of charge.
6.4 Power as the rate of energy delivery
Power is the time derivative of work:
\[P \;=\; \frac{dW}{dt} \;=\; \frac{d(QV)}{dt} \;=\; V\frac{dQ}{dt} \;=\; V I.\](6.6)
So \(1\,\text{W} = 1\,\text{V}\cdot\text{A}\). This single derivation explains why chargers (concerned with rate) are rated in watts while batteries (concerned with stored amount) are rated in mAh and Wh.
6.5 The DC source
A DC (direct current) source provides a voltage that is a fixed number as a function of time — a 5 V battery plotted against time is a flat horizontal line. The kettle experiment validates \(P = V^2/R \approx 1000\,\text{W}\) for a constant 230 V (treating the AC mains via its RMS value, which we justify later).
Part II · 11 chaptersCh 07–17
02
Circuit Variables and Network Analysis
Part II · Circuit Variables and Network Analysis
07
Voltage, Current, and Ground
3 sections2 min read
Voltage and current are abstract — they cannot be seen directly. The course builds intuition for them through a gravitational analogy.
7.1 The gravitational analogy
Lifting a mass \(m\) in a uniform gravitational field \(g\) from height \(h_1\) to \(h_2\) requires mechanical work
The potential difference (voltage) between two points is the work required per unit charge to move a charge between them. The unit is the volt, \(1\,\text{V} = 1\,\text{J/C}\).
7.2 Electrical ground
Just as the surface of the earth is a convenient zero of gravitational potential, an electrical ground is a designated reference node whose potential is defined to be zero (\(V = 0\,\text{V}\)). Once a ground is chosen, every other node's voltage is measured relative to it, so the energy to bring a charge from ground to a node at potential \(V_2\) is simply \(\Delta E = Q V_2\).
7.3 Current
Current is the rate of flow of charge, first as \(I = Q/T\) and then precisely as
The unit is the ampere, \(1\,\text{A} = 1\,\text{C/s}\). For a sustained current to flow, charge must travel in a closed loop — a complete circuit is required for a battery's stored energy to be released continuously. (Charge is conserved at every node regardless of topology; the closed-loop requirement is for current, not for charge itself.)
The direction of current requires a convention. By historical choice, current is defined as the direction positive charges would move if positive charges were the carriers — this is called conventional current. In a metal, the actual mobile carriers are electrons, which drift opposite to the electric field. Therefore the conventional current points opposite to the electron drift. All circuit-analysis conventions in this book — arrow on a current source, sign of KCL/KVL terms, sign of \(P = VI\) — follow this conventional-current definition.
Part II · Circuit Variables and Network Analysis
08
Ohm's Law and Material Classification
1 sections2 min readInteractive model
A battery stores electrochemical potential energy, but that energy is available only when charges are allowed to flow. Resistance is the material property that resists current flow. Materials are classified as:
Interactive lab
Circuit diagram
Adjust the model. A labelled source, resistor, return wire, and ground form one unambiguous loop.
Good conductors (metals, gold, copper): low resistance.
Bad conductors / insulators (glass, dry wood, rubber): high resistance.
Semiconductors: in between, engineerable.
Ohm's law states that the voltage–current relationship across a resistor is linear:
A component that obeys \(V = I\,R\) over its operating range is called ohmic (or linear); many real components (filament lamps, diodes, transistors) are non-ohmic because their I–V characteristic is nonlinear. The linear "resistor" used in circuit analysis is the ideal, ohmic component.
The resistance of a physical piece of material depends on its geometry and its resistivity \(\rho\):
where \(L\) is the length and \(A\) the cross-sectional area. A longer or thinner conductor has more resistance; a thicker or shorter one has less.
Why does a low-resistance copper wire get hot when shorted across a battery while a hand holding the wire does not? The power dissipated is \(P = I^2 R\). A low resistance draws a very large current, and the current is squared, so the product \(I^2 R\) can be enormous — large enough to heat the wire. The hand, a high resistance, draws almost no current, so it dissipates almost no power.
8.1 Series and parallel connection of batteries
Two batteries in series add their voltages (1.5 V + 1.5 V = 3 V) and the current through the load doubles (for a fixed load resistance). Two batteries in parallel keep the same voltage (1.5 V) but can supply more current. Two batteries in series with opposing polarity cancel: the potential difference is zero and no current flows through any load.
Why ohmic materials behave linearly
Ohm's law V = IR is empirical — it works for many materials over a range of conditions — but it is not a universal law of physics. The microscopic reason a material obeys Ohm's law is that the drift velocity v_d of charge carriers is proportional to the applied electric field, with the proportionality constant being the carrier mobility μ = v_d / E. This holds when the carriers' collisions with the lattice are frequent enough that the random thermal motion dominates the drift motion — the drift is a small perturbation added to a Maxwell–Boltzmann distribution of thermal velocities.
At very high fields (>10⁶ V/m in semiconductors), the carriers gain enough energy between collisions to ionize lattice atoms, creating new electron–hole pairs. This is avalanche breakdown, and the current rises far faster than Ohm's law predicts. The same mechanism explains why a diode's reverse breakdown is sharp: at high enough reverse bias, the carriers multiply and the diode conducts. Below this threshold, the diode is non-ohmic (the current is exponentially related to the voltage, not linearly), which is exactly why diodes are useful for signal processing.
Temperature dependence is also worth noting. For metallic conductors, resistance increases with temperature because the lattice vibrates more, scattering electrons more frequently. For semiconductors, resistance decreases with temperature because more carriers are thermally excited across the band gap. This is why a thermistor (a semiconductor resistor) can measure temperature — its resistance is a sensitive function of temperature and the relationship is well-calibrated. The resistance of a copper wire at room temperature increases by about 0.4% per °C; the resistance of a semiconductor thermistor can change by 4% per °C, ten times more sensitive.
Part II · Circuit Variables and Network Analysis
09
Ideal Sources and Their Combinations
4 sections3 min readInteractive model
9.1 The ideal voltage source
Interactive lab
I–V characteristics
Adjust the model. The resistor line, ideal voltage source, and ideal current source share one labelled I–V plot.
An ideal voltage source maintains a fixed potential difference \(V\) across its terminals regardless of the current flowing through it. It can deliver any current, positive or negative, while holding the voltage constant.
9.2 The ideal current source
An ideal current source is the dual: it maintains a fixed current \(I\) flowing through it in the direction of its arrow, regardless of the voltage across it. The voltage across a current source is decided by the rest of the network — it is whatever the network equation demands. For the common special case of a purely resistive load, Ohm's law gives \(V = I\,R\), and the power dissipated in the resistor is \(I^2 R\). For reactive or general loads, the voltage is set by the network equation and is not simply \(I\,R\).
9.3 Combining sources
There are four distinct ways to connect two sources (series or parallel, each with two polarities):
Two voltage sources in series, aiding: voltages add.
Two voltage sources in series, opposing: voltages subtract (cancelling to zero if equal).
Two current sources in parallel, aiding: currents add to \(2I\).
Two current sources in parallel, opposing: net output is zero; current circulates internally between the sources.
Two current sources in series: behave as a single source of value \(I\), but only when their imposed currents are compatible (equal and in the same direction). Two equal ideal current sources in series with aligned arrows pass the same current \(I\), equivalent to a single source of value \(I\). Two unequal ideal current sources in series demand contradictory branch currents through the same wire and are incompatible — no physically realizable circuit can satisfy both simultaneously. Similarly, two ideal voltage sources with different values in parallel demand contradictory voltages across the same pair of nodes and are incompatible; an ideal voltage source has zero internal impedance and refuses to deviate from its prescribed voltage, so two such sources fighting over the same nodes have no consistent solution. Real sources with finite internal impedance can be connected this way, with the resulting voltage settled by their internal resistances — but ideal sources cannot.
9.4 Why some combinations are forbidden
The forbidden cases follow from the definitions of the ideal sources. An ideal voltage source fixes the voltage across its terminals to a specific value, no matter what current is drawn. Placing two such sources of different voltages in parallel says the same pair of nodes must simultaneously be at two different potentials, which is a logical contradiction — no consistent circuit exists. By contrast, two equal ideal voltage sources in parallel are redundant (both dictate the same voltage) and are perfectly well-defined: any current can be shared between them in any proportion.
Symmetrically, an ideal current source fixes the current through itself to a specific value, no matter what voltage appears across it. Two unequal ideal current sources in series would have to push different currents through the same single wire, which is impossible; two equal ones are again redundant and well-defined. The general rule: two sources of the same type connected in a configuration that forces them to dictate the same quantity (voltage across the same pair of nodes, or current through the same branch) are compatible only when their dictated values agree.
Part II · Circuit Variables and Network Analysis
10
I–V Characteristics
0 sections1 min readInteractive model
Plotting current against voltage (or voltage against current) gives a visual signature of a component called its I–V characteristic.
Interactive lab
I–V characteristics
Adjust the model. The resistor line, ideal voltage source, and ideal current source share one labelled I–V plot.
Resistor: \(V = IR\) is a straight line through the origin. Flipping the applied voltage reverses the current, moving the plot into the third quadrant while keeping the same magnitude \(V/R\). If we plot \(V\) versus \(I\), the slope of the line is \(R\).
Voltage source: a vertical line at \(V\) — the voltage stays the same no matter what current is drawn.
Current source: a horizontal line at \(I\) — the current stays the same no matter what voltage appears across it.
The resistor's line passes through the origin; the sources' lines do not. This distinction becomes important when we define linearity in Part IV.
Part II · Circuit Variables and Network Analysis
11
Kirchhoff's Laws
3 sections2 min readInteractive model
11.1 KCL — conservation of charge
Interactive lab
KCL at a node
Adjust the model. Arrow directions and values make the current sum visible.
Interactive lab
KVL around a loop
Adjust the model. Labelled voltage rises and drops sum to zero.
Kirchhoff's Current Law (KCL): the sum of all currents entering a node equals the sum of all currents leaving it:
with signs chosen consistently. KCL is the statement of charge conservation at a node, under the assumption that the node's charge (and hence its potential) stays constant — it does not accumulate.
11.2 KVL — conservation of energy
Kirchhoff's Voltage Law (KVL): the sum of all voltage rises and drops around any closed loop is zero:
KVL is the statement of energy conservation: moving a charge around any closed path returns to the same point, so the net potential difference — and hence the net work per unit charge — is zero.
These two laws are the conceptual backbone of the entire book. Almost every circuit analysis method that follows is a systematic way of writing KCL and KVL equations.
11.3 Where KCL and KVL apply
The ordinary, lumped-circuit form of KCL and KVL used throughout this book is valid under three assumptions that are satisfied by the great majority of circuits encountered in first-year electronics:
Lumped elements. Each component (resistor, capacitor, inductor, source) is modeled as occupying a single point in space, with all its effect captured by one or two terminal voltages/currents. This requires that the physical size of every component be much smaller than the wavelength of the highest frequency present in the circuit. When this fails (long cables, gigahertz signals), the circuit must be treated as a distributed transmission line.
Quasi-static fields. The electric and magnetic fields inside the circuit change slowly enough that the electromagnetic wave-propagation delay across any loop can be neglected. At 1 MHz the wavelength in free space is 300 m, so any compact circuit is well within this regime; at 1 GHz the wavelength is 30 cm and a wire of that length begins to act as an antenna.
No significant radiation or external coupling. The circuit exchanges negligible energy with its surroundings as electromagnetic radiation and is not appreciably perturbed by external fields.
When these assumptions hold — and they do for every circuit studied in this book — KCL is the statement of charge conservation at each node and KVL is the statement of energy conservation around each loop, both of which are exact. Chapter 65 returns to the limit when these assumptions break down.
Conservation laws as circuit axioms
Kirchhoff's current law (KCL) and voltage law (KVL) are not derived from more fundamental physics — they are the fundamental physics. KCL is a statement of charge conservation: charge cannot accumulate at a node, so the rate at which charge flows in must equal the rate at which it flows out. In differential form, Σᵢ iᵢ(t) = 0 at every node, where the sum is taken with a sign convention (current flowing in is positive, current flowing out is negative).
KVL is a statement of energy conservation: the work done in moving a charge around a closed loop must sum to zero, because the charge returns to its starting point with the same energy. In differential form, Σⱼ vⱼ(t) = 0 around every loop. The two laws together turn any linear circuit into a system of linear equations that can be solved for the unknown voltages and currents.
It is tempting to think of KCL and KVL as approximations that fail at high frequencies (where the lumped-element assumption breaks down) or at the quantum scale (where the electron wavefunction extends across the circuit). But for any circuit whose dimensions are much smaller than the wavelength of the highest frequency of interest, the two laws are exact. The exceptions are transmission lines, waveguides, and any circuit where the propagation delay across the components is significant compared to the signal period.
SPICE, the canonical circuit simulator, takes a netlist of elements and applies KCL at every node and KVL around every loop. The algorithm is essentially Gaussian elimination on a system of linear equations whose size is proportional to the number of nodes. A circuit with 1000 nodes yields a 1000×1000 matrix; modern SPICE handles millions of nodes by exploiting the sparsity of the matrix (most nodes connect to only a few neighbors). The same algorithm underlies modern circuit analysis and design tools.
Part II · Circuit Variables and Network Analysis
12
Nodal and Mesh Analysis
5 sections4 min readInteractive model
A circuit with more than two elements cannot be solved by Ohm's law alone. Two systematic methods exist, and they give the same answers.
Interactive lab
Network reduction
Adjust the model. Step through equivalent-resistance transformations.
12.1 Nodal analysis (KCL-based)
Identify the nodes (points where two or more components meet).
Choose one node as the reference node (ground, \(V=0\)).
Label each remaining node with an unknown voltage \(V_1, V_2, \dots\).
Express every branch current in terms of node voltages using Ohm's law, \(I_k = (V_a - V_b)/R_k\).
Write one KCL equation per non-reference node.
Solve the linear system.
Branch-current directions are chosen arbitrarily; the method works regardless. A two-element join (e.g. a voltage source to a resistor) need not be treated as an explicit node — the source current is simply \(I_V = -I_1\).
12.2 Mesh analysis (KVL-based)
Identify the meshes (closed loops, each enclosing no other loop — "minimal loops").
Name a loop current for each mesh, conventionally clockwise.
Write one KVL equation per mesh in terms of the loop currents and Ohm's law.
For a resistor shared by two meshes (say \(R_2\) between meshes \(A\) and \(B\)), the current through it is the difference of the two loop currents, \((I_A - I_B)\), so its voltage drop is \((I_A - I_B) R_2\).
Solve the linear system.
12.3 A worked example
Consider a circuit with \(V = 3\,\text{V}\), \(R_1 = 1.5\,\text{k}\Omega\), and \(R_2 = R_3 = 3\,\text{k}\Omega\) arranged so that \(R_2\) and \(R_3\) are in parallel and the combination is in series with \(R_1\).
The parallel combination of \(R_2\) and \(R_3\) is \(1.5\,\text{k}\Omega\), so the total resistance seen by the source is \(1.5 + 1.5 = 3\,\text{k}\Omega\). The source current is \(I_1 = 3\,\text{V}/3\,\text{k}\Omega = 1\,\text{mA}\). The voltage across the parallel pair is \(V_2 = 1\,\text{mA} \times 1.5\,\text{k}\Omega = 1.5\,\text{V}\), and each \(3\,\text{k}\Omega\) branch carries \(0.5\,\text{mA}\).
Check with KVL around the outer loop:\(+3 - 1.5 - 1.5 = 0\,\text{V}\). ✔ Check with KCL at the node:\(1\,\text{mA}\) in, \(0.5 + 0.5 = 1\,\text{mA}\) out. ✔
A computed negative current means the actual current flows opposite to the assumed direction — not an error, just a sign convention to interpret.
12.4 Units and scale
Units are not optional. Voltage is in volts (V), current in amperes (A), with prefixes \(\text{k} = 10^3\), \(\text{m} = 10^{-3}\), \(\mu = 10^{-6}\), \(\text{n} = 10^{-9}\), \(\text{p} = 10^{-12}\). A quantity without units carries no meaning.
12.5 Scope of nodal versus mesh analysis
Nodal analysis is broadly applicable: it works for any circuit — planar or non-planar, simple or arbitrarily complex — provided the lumped-circuit assumptions of Chapter 11 hold. The procedure (one KCL equation per non-reference node) always produces a solvable linear system.
Mesh-current analysis is more restricted. It applies cleanly only to planar circuits — those that can be drawn on a flat surface without any wires crossing. For a planar circuit, every mesh is unambiguously the interior of a minimal loop, and one KVL equation per mesh yields a well-posed system. For a non-planar circuit (a circuit whose schematic necessarily has wires crossing with no node at the crossing), the notion of "mesh" breaks down: there exist closed loops that cannot be written as the sum of mesh currents. Non-planar networks can always be analyzed by brute force — write KVL for an independent set of loops, where "independent" means each new loop carries at least one branch not yet seen — but the choice of those loops is no longer automatic. This is why the universal fallback throughout the book is nodal analysis, with mesh analysis reserved for planar topologies where its bookkeeping advantage is real. For circuits with millions of components (as inside an IC), the same equations are solved by computer in either form.
Part II · Circuit Variables and Network Analysis
13
Measurement of a Resistive Circuit
3 sections1 min readInteractive model
The simple circuit of the previous section is built on a breadboard and measured with a multimeter.
Interactive lab
Multimeter
Adjust the model. The ammeter splices in series; the voltmeter connects across.
13.1 Breadboard internals
A breadboard's rows are internally connected: components inserted across adjacent lines become short-circuited or placed in parallel. A short circuit behaves as a wire — the points are electrically the same node.
13.2 How to measure current versus voltage
Current must be measured by opening the circuit and inserting the ammeter in series, so that the same current flows through the meter.
Voltage is measured across a component in parallel.
13.3 Measurement versus calculation
Measured values were 3.127 V supply, 1.06 mA input current, 0.508 mA through each \(3\,\text{k}\Omega\) branch, and 1.563 V across the parallel pair — against calculated 3 V, 1 mA, 0.5 mA, 1.5 V. The small deviations come from three sources:
Resistor tolerance (the last color band indicates the permitted deviation, typically 1–5%).
A slightly higher battery voltage (3.127 V vs 3 V).
The meter's limited accuracy (about 2%).
Direct resistance measurements (\(1.494\,\text{k}\Omega\) and two \(\sim 2.99\, \text{k}\Omega\) in parallel) confirm the equivalent-resistance analysis.
Part II · Circuit Variables and Network Analysis
14
Series and Parallel Equivalent Resistance
3 sections1 min readInteractive model
A network of resistors can often be replaced by a single equivalent resistance\(R_{\text{eq}}\) that draws the same current from the same source.
Interactive lab
Network reduction
Adjust the model. Step through equivalent-resistance transformations.
14.1 Parallel resistors
Two resistors in parallel share the same voltage; by KCL the currents add. Using Ohm's law,
The current in one branch uses the other resistor in the numerator. A larger resistor in parallel carries a smaller current.
Part II · Circuit Variables and Network Analysis
15
The Capacitor
4 sections2 min readInteractive model
15.1 Physical structure
Interactive lab
Capacitor model
Adjust the model. Q = CV and I = C dV/dt with a labelled plate diagram.
A capacitor is built from two parallel conductive plates separated by a gap (air or an insulating dielectric). When a voltage source is connected, it deposits \(+Q\) on one plate and \(-Q\) on the other, creating a uniform electric field between them.
15.2 The constitutive relation
The stored charge is proportional to the applied voltage:
where \(C\) is the capacitance, measured in farads (F) — a very large unit, so practical capacitors are in microfarads (\(\mu\)F), nanofarads (nF), or picofarads (pF). \(C\) depends on the plate area, the separation, and the dielectric material, but not on the applied voltage.
Differentiating \(Q = CV\) gives the capacitor's current–voltage relation:
This is fundamentally different from a resistor: the current depends on the rate of change of voltage, not on the voltage itself. Integrating from an initial time \(t_0\) with initial voltage \(V(t_0)\) gives the inverse form
The initial condition \(V(t_0)\) is required because the integral alone does not uniquely determine the voltage — a capacitor has memory of its prior state.
derived by integrating power \(P = V I = V\,C\,dV/dt\):
\[E \;=\; \int V\,C\,dV \;=\; \tfrac{1}{2} C V^2.\](15.5)
This energy can be recovered, much like energy from a battery.
15.4 Series and parallel capacitors
Parallel: same voltage across each, charges add, so \(C_{\text{eq}} = C_1 + C_2 + \dots + C_N\).
Series: same current through each, voltages add, so \(1/C_{\text{eq}} = 1/C_1 + \dots + 1/C_N\).
This is exactly swapped relative to resistors — a useful mnemonic is that capacitors combine opposite to resistors.
Capacitor physics and equivalent circuits
A real capacitor is more than an ideal C. The metallic plates have finite resistance; the dielectric has finite resistance (called leakage, modeled as a parallel resistor); the leads have finite inductance; the dielectric absorbs some energy when voltage is applied (dielectric absorption, modeled as a series of RC sub-circuits). A first-order non-ideal model is a series R-L-C; a more accurate model adds a parallel leakage resistor and one or more “absorption” RC sub-circuits. For most applications the simple C is sufficient, but precision circuits (integrators, sample-and-hold, ADC front ends) suffer from leakage and absorption in ways that matter.
The energy stored in a capacitor's electric field is E = ½CV². This is recoverable: discharging the capacitor through a resistor returns most of the energy to the circuit as heat in the resistor, with the other half dissipated in the capacitor's own internal resistance. The exactly-half split between stored and dissipated energy is independent of the resistance (the same physics that gave the 50% loss in the energy-ledger widget), and is the fundamental reason charging a capacitor through any resistor is at best 50% efficient.
Capacitors are characterized by their dielectric. Common types include ceramic (small, cheap, lossy, non-linear with voltage), film (stable, low loss, larger), electrolytic (very high capacitance, polarized, leaky), and supercapacitors (extremely high capacitance, low voltage, very leaky). Each type has a different maximum voltage, temperature range, frequency behavior, and aging characteristic. Choosing the right capacitor for an application is a real engineering decision: a switching power supply needs low-ESR ceramics, an audio coupling needs film, a power-supply bypass needs ceramics for HF and electrolytics for LF, and an energy-harvesting circuit needs supercapacitors for storage.
Part II · Circuit Variables and Network Analysis
16
The Inductor
4 sections2 min readInteractive model
16.1 Physical structure
Interactive lab
Inductor model
Adjust the model. V = L di/dt with a labelled coil and current ramp.
An inductor is a coil of wire wound on a former (a magnetic core or air). When current passes through it, it generates a magnetic field — an electromagnet. The study of inductors is why electricity and magnetism are taught together.
16.2 The constitutive relation
A time-varying current produces a time-varying magnetic field, which induces a voltage proportional to \(di/dt\). Under the passive sign convention (current entering the positive-labelled terminal), the inductor's terminal voltage is
The constant \(L\) is the inductance, measured in henries (H); practical values are in \(\mu\)H, mH, nH. \(L\) depends on geometry (number of turns, coil dimensions) and the core material — an iron nail inside the coil increases the inductance.
The minus sign that appears in some textbooks, \(V = -L\,di/dt\), belongs to Faraday's law of induction in the form \(e = -d\Phi/dt\): it is the back-EMF statement, which says the induced EMF opposes the change in flux that produced it (Lenz's law). The equation without the minus sign is the terminal I–V relation under the passive sign convention; the two are reconciled by keeping track of the reference polarity assigned to the voltage. The book uses the passive sign convention throughout.
A constant current through an inductor produces no voltage (since \(di/dt = 0\)). Therefore, in DC steady state, an ideal inductor connected across a voltage source behaves as a short circuit — the source will try to supply unbounded current. The danger is the steady-state condition, not the instant of switch closure: at \(t = 0^+\) the current is still zero and rises linearly at \(di/dt = V/L\), which is finite. This is the dual of the capacitor, which under constant voltage draws zero current (an open circuit).
16.4 Series and parallel inductors
Inductors combine like resistors provided no magnetic coupling exists between them: series inductances add (\(L_{\text{eq}} = L_1 + L_2 + \dots\)), and parallel inductors follow the reciprocal rule (\(1/L_{\text{eq}} = 1/L_1 + \dots\)). When two coils are physically close, their magnetic fields link and the simple addition fails; the phenomenon is mutual inductance, demonstrated in Chapter 17.
Inductor physics and energy storage
An inductor stores energy in its magnetic field. The energy is E = ½LI², analogous to the kinetic energy ½mv² of a moving mass. The same physics that makes it impossible to instantaneously change a mass's velocity (Newton's first law) makes it impossible to instantaneously change an inductor's current (Faraday's law): V = L di/dt, so a sudden change in current would require an infinite voltage.
Like capacitors, real inductors are not just L. The wire has resistance (modeled as a series resistor); the core has losses (modeled as a parallel resistor); the magnetic field can couple to nearby circuits (modeled as mutual inductance). At high frequencies, the parasitic capacitance between turns becomes significant and the inductor self-resonates. For most applications the simple L is sufficient, but precision filters and power inductors need careful modeling of these parasitics.
One subtle but important point: the energy stored in an inductor's magnetic field is recoverable. Disconnecting a current-carrying inductor produces a huge voltage spike (the V = L di/dt trying to maintain the current), which is why switches in inductive circuits need snubber diodes or other protection. The flyback topology in switch-mode power supplies exploits this spike deliberately: the inductor's energy is dumped through a diode into a capacitor at a different voltage, transforming energy without dissipating it in resistors. The same trick is used in ignition coils, camera flashes, and defibrillators.
Part II · Circuit Variables and Network Analysis
17
Measuring Capacitance and Inductance
0 sections1 min read
A handheld LCR meter on a breadboard confirms the formulas of the previous two chapters.
Two capacitors measured individually at 97 nF and 100.8 nF combine in parallel to 198.5 nF (essentially the sum) and in series to 49.3 nF (about half, as expected for two nearly-equal values).
Two inductors measured at 97.1 \(\mu\)H and 98 \(\mu\)H gave a surprise: in series the meter first read 232 \(\mu\)H instead of the expected \(\sim\)195 \(\mu\)H. The reason is mutual inductance — the magnetic field of one coil couples into the other when they are physically close, adding extra energy storage. After separating the coils, the series sum worked correctly, and the parallel combination gave 49.3 \(\mu\)H via \(L_1 L_2/(L_1+L_2)\).
The copper wire used to wind coils carries a thin layer of insulation (enamel), so adjacent turns do not short together — only the connection ends are stripped.
A historical note: this experiment-first style mirrors Faraday's own experience, where seeing the effect preceded forming the theory. Sometimes experiment runs ahead of theory, and that is healthy.
Part III · 5 chaptersCh 18–22
03
Energy Storage, Signals and Sinusoids
Part III · Energy Storage, Signals and Sinusoids
18
Sensing: Microphone, Motor, and Generator
3 sections3 min readInteractive model
18.1 The three operations of a phone call
Interactive lab
Microphone cross-section
Adjust the model. A diaphragm changes capacitance and produces an output voltage.
Interactive lab
Faraday rotation
Adjust the model. Flux and induced voltage vary as the coil rotates.
A phone call involves three electrical operations: dialing, talking, and hearing. Each is realized electrically.
Dialing: pressing a number button closes a switch. A conductive pad on the underside of the key bridges a flower-shaped contact pattern on the PCB, completing a circuit the phone detects. The flower shape is not decorative: it guarantees a clean contact even when the press is slightly off-center or moving.
Talking: the microphone converts sound waves into an electrical signal. The two most common constructions are different. A dynamic (moving-coil) microphone has a diaphragm mechanically attached to a coil sitting in a permanent magnetic field; when the diaphragm moves, the coil moves, and the changing flux through it induces a voltage by Faraday's law. A condenser (capacitor) microphone instead uses the diaphragm as one plate of a capacitor; sound pressure changes the plate spacing and hence the capacitance, which converts the acoustic signal into a varying voltage when the capacitor is held at a bias charge. Both produce a time-varying (AC-like) voltage, not the fixed DC voltages of earlier chapters. A multimeter fluctuating around 89 mV is the wrong instrument; an oscilloscope is needed.
Hearing: the speaker is the microphone in reverse. Sending current through a coil in a constant magnetic field produces a magnetic force \(F = BIL\) on the coil, which moves and drags an attached diaphragm to recreate the sound wave. The eardrum is just another diaphragm.
18.2 The microphone as a transducer
An electrical transducer is a device that senses a physical signal from the real world (voice, touch, pressure) and translates it into an electrical signal. The microphone is one such transducer.
When a condenser microphone is connected to a breadboard and viewed on an oscilloscope, a few features appear:
Speaking softly yields a small amplitude riding on a DC offset of about 1.75 V.
Speaking loudly drives the peak toward 3.7 V: more air-molecule motion moves the diaphragm more, producing a larger electrical signal. Amplitude corresponds to energy.
A bass (low-pitch) voice shows fewer oscillations in a fixed time window; a high-pitch voice shows more. Pitch corresponds to frequency.
The 1.75 V DC offset is not useful for analysis, so the signal is written as \(V(t) = 1.75\,\text{V} + V_0(t)\). Subtracting the DC reveals a \(V_0(t)\) that can take negative values — and those negative values carry information.
18.3 The motor and the generator
Where does the AC sinusoid in power lines come from? A table fan rated DC 12 V / 0.18 A is a motor: applying 12 V DC drives a current \(I\) through a coil in a fixed magnetic field \(B\). The force on each side of the coil is \(F = BIL\); the two equal-and-opposite forces form a couple and a torque, causing the coil to rotate. A motor converts electrical input into rotation.
Reversing the process: rotate the fan by hand with no supply connected, and feed the terminals into an oscilloscope. A voltage jump followed by decaying oscillations appears — an AC signal, not DC. The fan is now a generator. The magnetic flux through the rotating coil is
The maximum voltage is the amplitude \(V_p = BA\omega\), so \(v(t) = V_p \sin(\omega t)\). Energy is never created — Bobby's manual work was converted into electrical energy with large losses. The same principle, scaled up, underlies hydroelectric generation.
Part III · Energy Storage, Signals and Sinusoids
19
The Sinusoid
3 sections2 min readInteractive model
The sinusoid is the canonical time-varying signal of electrical engineering. It arises naturally from a coil rotating at fixed angular speed in a magnetic field, from simple harmonic motion, and from waves on a string.
Interactive lab
Waveform explorer
Adjust the model. Amplitude, frequency, and phase control a labelled sinusoid.
\(V_p\): peak voltage (amplitude), the maximum value the waveform reaches.
\(\omega\): angular frequency, related to the time period by \(\omega = 2\pi/T\).
\(\phi\): phase, the time delay/advance relative to a reference sine of zero phase.
The time period\(T\) is the interval over which the wave has unique values before repeating. The frequency is \(f_0 = 1/T\), measured in hertz (Hz). The sine is periodic: \(v(t) = v(t + kT)\) for integer \(k\).
19.2 Sinusoid across a resistor: instantaneous and average power
Applying an AC source \(v(t) = V_p \sin(\omega t)\) across a resistor \(R\) gives an in-phase current \(i(t) = (V_p/R)\sin(\omega t)\). The instantaneous power is
The energy delivered in one cycle is the time integral of \(P(t)\). Using the identity \(\sin^2(\omega t) = \tfrac{1}{2}(1 - \cos(2\omega t))\), the \(\cos(2\omega t)\) term integrates to zero over a full period (its positive and negative areas cancel), leaving
RMS is the equivalent DC value: a sinusoidal source of \(V_{\text{rms}}\) delivers the same average power to a resistor as a DC source of the same voltage. This is why the 230 V home supply can be treated as a DC-like 230 V for power calculations, even though the actual waveform swings between \(+230\sqrt{2}\,\text{V}\) and \(-230\sqrt{2}\,\text{V}\) at 50 Hz (period 20 ms).
Part III · Energy Storage, Signals and Sinusoids
20
Energy and Power of Time-Varying Signals
0 sections1 min read
The phone power-management problem of Chapter 1 returns, now with the language of time-varying signals. A phone held to the ear during a call turns off its display — a smart power-management feature. To decide when to do this, the phone must know how much current each component draws.
Model the phone as a battery feeding three loads: microprocessor (\(I_1(t)\)), display (\(I_2(t)\)), and antenna (\(I_3(t)\)). Each is a time-varying waveform, rising during a call and falling to a small background current otherwise (the OS stays active even when no call is made). The instantaneous power of each component is
Because \(V_{DD}\) is constant, the energy is simply \(V_{DD}\) times the area under the total current curve. This is exactly how the PMU estimates energy continuously. The display-off feature saves the energy corresponding to the display-current peak over the call duration.
RMS, average, and effective values
The wall outlet delivers 230 V (in Europe) or 120 V (in North America) AC mains. The peak voltage is 230 V or 120 V, but the average voltage over a cycle is zero. So a naive question — “how much voltage is the wall delivering?” — has no single answer. The convention is to specify the root-mean-square (RMS) value: the DC voltage that would deliver the same average power to a resistor.
For a sinusoid v(t) = V_p sin(ωt), the RMS value is V_p / √2. The 230 V mains is RMS, so the peak is 230 × √2 ≈ 325 V. A multimeter reading 230 V on the AC scale is reporting the RMS value; reading 325 V would require a true RMS meter on the peak mode. Most inexpensive multimeters assume the signal is sinusoidal and apply the √2 correction internally; if the signal is not sinusoidal (a chopped PWM, a square wave, a distorted sine), the meter reads incorrectly.
Average power dissipation over a full cycle is P = V_rms² / R for a resistive load. The same formula also holds for a DC voltage of magnitude V_rms. This is why the RMS voltage is the “effective” voltage for power calculations — and why the iPhone charger rated 5 V at 1 A delivers 5 W, and the wall outlet at 230 V at 0.5 A delivers 115 W. Both are RMS values.
Part III · Energy Storage, Signals and Sinusoids
21
Phase, Harmonics, and Standing Waves
5 sections2 min readInteractive model
21.1 Phase completes the description of a sine
Interactive lab
Phase explorer
Adjust the model. Two labelled traces show their phase offset.
Interactive lab
Harmonic explorer
Adjust the model. A nonlinear transform adds a DC term and a second harmonic.
Amplitude and frequency alone are insufficient to characterize a sinusoid: two sines of identical shape, frequency, and amplitude can be shifted in time. That delay or advance is the phase\(\phi\) in \(v(t) = V_p\sin(\omega t + \phi)\). A negative phase is lagging, a positive phase is leading, relative to a reference defined as zero phase.
21.2 Where harmonics come from
Power-electronic loads draw a current that looks like a distorted sine wave. Any nonlinearity in a system produces harmonics — components at integer multiples of the fundamental frequency.
A violin string clamped at both ends demonstrates the geometric origin of harmonics. Only discrete standing-wave modes are allowed:
Fundamental mode: \(\lambda = 2L\), frequency \(f_0\).
Higher modes: \(\lambda = 2L/n\), frequency \(n f_0\), for integer \(n = 2, 3, \dots\).
Fractional frequencies like \(1.5 f_0\) or \(2.3 f_0\) do not occur — a string responds to a 512 Hz tuning fork but not to 440 Hz because only the allowed modes are excited.
A linear system (resistor, inductor, capacitor) keeps a sinusoid a sinusoid. A nonlinear system does not. The canonical example: a system \(y = x^2\) fed \(\sin(\omega t)\) outputs
a sinusoid at twice the frequency (plus a DC term). This is exactly the mechanism behind the distorted load current: nonlinearity in the load converts the fundamental into its second harmonic.
21.4 Traveling waves and wavelength
Sound propagates as air molecules executing simple harmonic motion with distance-dependent phase. A traveling wave is a function of both space and time,
where \(k = 2\pi/\lambda\) is the wavenumber and \(\lambda\) is the wavelength. The propagation velocity is \(v = \lambda f = \lambda/T\), set by the medium (light at \(3\times 10^8\) m/s in free space, slower in glass).
21.5 Notation: peak versus peak-to-peak
The peak value should be written \(V_p\); the peak-to-peak voltage is \(V_{pp} = 2 V_p\), the full swing from the most negative to the most positive value. The two are easy to confuse and should be kept distinct.
Part III · Energy Storage, Signals and Sinusoids
22
Electricity Consumption and Billing
3 sections1 min read
The phone's milliamp-hours scale up to the household electricity bill. The meter on a home reads in units, where
which is dimensionally energy (joules), not instantaneous power.
22.1 Why energy, not power, is billed
A 1 kW air conditioner used for only five minutes a day should not cost more than a 40 W bulb left on 24/7. A billing scheme based on power alone would unfairly penalize the AC owner; time must be included. Energy = power × time, so billing is based on energy.
22.2 A back-of-the-envelope household estimate
Using RMS voltage to treat the 230 V AC supply as a DC-equivalent 230 V, a typical appliance inventory and duty cycle gives:
Appliance
Power
Hours/day
Duty cycle
Energy/day
AC
1 kW
6 h
0.9
5.4 kWh
Fridge
0.25 kW
24 h
0.25
1.5 kWh
Tube lights
40 W each
several
—
a few kWh
Fans
80 W each
several
—
a few kWh
The sum is about 9.8 kWh/day, corroborating a bill that implies roughly 8 kWh/day. The duty cycle — the fraction of time an appliance actually runs (the fridge compressor cycles on and off) — is essential to the estimate.
22.3 Slab billing and time-of-day pricing
Electricity billing is nonlinear: per-unit slab rates increase with consumption, and some regions use time-of-day pricing (peak hours cost more) to disincentivize simultaneous large draws. When tracking consumption, track units (which scale linearly with usage), not the bill amount (which is slab-dependent).
Part IV · 10 chaptersCh 23–32
04
Linear Networks and Circuit Problem Solving
Part IV · Linear Networks and Circuit Problem Solving
23
Equivalent Resistance as a Black-Box Concept
0 sections1 min read
A multimeter in ohmmeter mode measures resistance by applying a DC voltage \(V_{DC}\) to the unknown network, reading the resulting current \(I_{DC}\), and computing
For a single resistor, one measurement suffices because the I–V characteristic is a straight line through the origin whose slope is \(R\). The method extends to any purely resistive network because such a network is linear: the single \(V_{DC}/I_{DC}\) measurement yields the correct equivalent resistance regardless of internal complexity. For two series resistors, KVL gives \(V_{DC} = (R_1 + R_2) I_{DC}\), so \(R_{\text{eq}} = R_1 + R_2\). For two parallel resistors, KCL plus KVL gives \(1/R_{\text{eq}} = 1/R_1 + 1/R_2\).
Important limitation: capacitors break this method. Because \(I_C = C\,dV_C/dt\), under a constant DC voltage the capacitor current is zero and the capacitor looks like an open circuit — the meter reads infinite resistance. The ohmmeter method applies only to purely resistive networks.
A passive element is one that only dissipates power; its I–V characteristic occupies only the first and third quadrants (where \(V \cdot I > 0\)). A resistor is the canonical passive element.
A final terminology distinction: a mesh is a closed loop that encloses no other loop (a "minimal" loop); a loop is any closed path, which may traverse several meshes. When solving multi-mesh networks, choose independent loops that each carry at least one independent current variable — a loop that merely recombines existing branches gives no new equation.
Part IV · Linear Networks and Circuit Problem Solving
24
Bounds, Redrawing, and Topology
3 sections2 min read
Network reduction is iterative: identify a recognizable sub-structure (series pair or parallel pair), replace it with its equivalent, move one level up, and repeat until the two terminals of interest are reached.
24.1 Example
For a network with \(R_2 \parallel R_3\) in series with \(R_1\):
A circuit's identity depends only on the connection positions of the components between nodes, not on how it is drawn. A three-node triangle redrawn as a "T" is the same circuit if the node connections are preserved. This is how students are commonly tricked: the same network is drawn in an unfamiliar shape and looks harder than it is.
On a schematic, two visual features carry distinct meanings:
A wire crossover (one wire hopping over another with no dot) means no electrical connection.
A node connection dot (a solid dot where three or more wires meet) means a direct electrical connection — all such points are the same node.
24.3 Bounding the answer before computing
Before doing the full reduction, bound the answer:
A parallel equivalent must be smaller than each branch resistance.
A series equivalent must be larger than each element.
Terminal series resistors set a floor; terminal parallel branches set a ceiling.
For the worked network, the portion feeding the 30 Ω branch is in parallel with 30 Ω (so it must be less than 30) and in series with 5 Ω, giving bounds of \(5 \le R_{\text{eq}} \le 35\,\Omega\). The computed 25 Ω sits comfortably inside.
Part IV · Linear Networks and Circuit Problem Solving
25
The Resistive Ladder and Self-Similarity
1 sections1 min readInteractive model
A resistive ladder is a repeating structure of series and shunt resistors. For a two-stage ladder with series \(R_1\) and shunt \(R_2\):
Interactive lab
Network reduction
Adjust the model. Step through equivalent-resistance transformations.
For uniform resistors \(R_1 = R_2 = R\), this gives \(5R/3\).
25.1 The infinite ladder
Standard back-to-front reduction fails for an infinite ladder because there is no last stage to start from. The trick is self-similarity: removing the first stage leaves a structure identical to the original, so the infinite tail beyond the first stage can be replaced by a single resistor \(R\)equal to the total input resistance. Writing the node equation:
the golden ratio. Physical bounding confirms this: shorting the tail gives \(R_{\min} = R_1\); open-circuiting the tail gives \(R_{\max} = R_1 + R_2\), so \(R_1 \le R \le R_1 + R_2\). Practical engineering uses of ladder analysis include concrete reinforcement quality testing via terminal electrical measurements.
Part IV · Linear Networks and Circuit Problem Solving
26
The Wheatstone Bridge
3 sections2 min readInteractive model
A Wheatstone bridge is a diamond of four resistors \(R_1\)–\(R_4\) with a diagonal bridge element between the two interior nodes, and the driving source across the other two corners. The goal is the equivalent resistance seen between the source terminals.
Interactive lab
Network reduction
Adjust the model. Step through equivalent-resistance transformations.
26.1 The all-equal (balanced) case
For all four resistors equal to \(R\), simple series/parallel reduction gives \(R_{\text{eq}} = R/2\). The same result follows rigorously from KCL plus a symmetry argument: at the input, \(I\) splits as \(I_1 = I_2 = I/2\) into the two branches, and the return currents are \(I_4 = I_5 = I/2\). Because the voltage drops across the first two resistors are equal, the two interior nodes are equipotential, so the bridge current \(I_3 = 0\). An equipotential pair of nodes can be collapsed into one (or the zero-current bridge resistor can be removed) without changing the circuit.
26.2 The balance condition
Generalizing to \(R_1\)–\(R_4\), the bridge current is zero if and only if
This is the Wheatstone balance condition. In practice, one places an ammeter in the bridge branch and tunes \(R_4\) until the meter reads zero; the unknown resistance (in place of, say, \(R_3\)) is then computed from the ratio. This is a precision measurement technique: null measurements are sensitive because a zero reading is easy to verify accurately.
26.3 When balance fails
When symmetry or balance fails (e.g. swapping two resistor values), the guaranteed fallback is brute force: write KCL at the nodes, write KVL around the loops, add Ohm's law for each branch, and solve the linear system in \(I_1, I_2, I_3, \dots\). Then \(R_{\text{eq}} = V/(I_1 + I_2)\). This is the universal method that always works, even when clever shortcuts do not.
Part IV · Linear Networks and Circuit Problem Solving
27
The Resistive Cube
3 sections1 min readInteractive model
The classic problem: twelve equal resistors \(R\) form the edges of a cube; find the equivalent resistance between two diagonally opposite corners (call them node 1 and node 7).
Interactive lab
Network reduction
Adjust the model. Step through equivalent-resistance transformations.
27.1 Why simple methods fail
Series/parallel reduction does not work because the network is not a simple series-parallel chain. Brute-force KVL is intractable by hand because it requires about twelve loop-current variables. Symmetry is the way in.
27.2 Symmetry forces equal splitting
At node 1, the incoming current \(I\) has no reason to prefer any of the three identical outgoing edges, so it splits equally:
The voltage drops across those first three resistors are equal (\((I/3)\cdot R\)), so the three nodes adjacent to node 1 (call them 2, 4, 5) are equipotential. By the same argument at node 7, the three nodes adjacent to it (3, 6, 8) are also equipotential.
27.3 Reduction to three parallel blocks
With the eight nodes collapsed into three equipotential groups — {1}, {2,4,5}, {3,6,8}, {7} — the cube reduces to three stages:
Three resistors in parallel from {1} to {2,4,5}: \(R/3\).
Six resistors in parallel from {2,4,5} to {3,6,8}: \(R/6\).
Three resistors in parallel from {3,6,8} to {7}: \(R/3\).
The labeling \(R_{12}, R_{14}, \dots\) is only for counting edges and is valid only under the equipotential, equal-resistor conditions of this problem.
Part IV · Linear Networks and Circuit Problem Solving
28
Linearity, Homogeneity, and Additivity
3 sections1 min readInteractive model
The mixer experiments hinted at "straight-line" behavior. We now formalize what that means.
Interactive lab
Harmonic explorer
Adjust the model. A nonlinear transform adds a DC term and a second harmonic.
28.1 The network-as-a-block abstraction
Abstract a network as a block \(N\) with input \(X\) and output \(Y = f(X)\). The network is linear if and only if two properties hold:
Homogeneity: scaling the input by \(a\) scales the output by the same \(a\), \(f(aX) = a\,f(X)\).
Additivity: the output of a sum equals the sum of the outputs, \(f(X_1 + X_2) = f(X_1) + f(X_2)\).
So a squaring system is nonlinear and will generate harmonics from a sinusoid.
28.3 Why linearity forces passage through the origin
Consider a characteristic \(y = x + 2\) (a line that does not pass through the origin). Homogeneity fails: \(f(ax) = ax + 2 \neq a(x+2) = a\,f(x)\) (the constant \(2\) does not scale). So a network whose characteristic does not pass through the origin is not linear. Such "shifted-line" networks are called affine. Linearity requires the origin to be on the characteristic.
Part IV · Linear Networks and Circuit Problem Solving
29
The Superposition Principle
1 sections2 min readInteractive model
Combining homogeneity and additivity yields the superposition principle: for a linear network,
Interactive lab
Superposition
Adjust the model. Source 1 + source 2 = the summed response.
In words: the response to a weighted sum of inputs is the weighted sum of the responses to each input applied separately. A network is linear if and only if it obeys superposition.
29.1 Using superposition to solve circuits
Consider the two-source resistive mixer: a node \(X\) is fed by two branches, one containing source \(V_1\) in series with \(R_1\), the other containing source \(V_2\) in series with \(R_2\), and both branches return to a common ground through a shared resistor \(R\) between \(X\) and ground. (This is the topology of Chapters 33–34.) Because the network is purely resistive and linear, the output \(V_X\) decomposes as
where \(v_{x1}\) is the output with only \(V_1\) active (and \(V_2\) de-energized, that is, replaced by a short circuit), and \(v_{x2}\) is the output with only \(V_2\) active (and \(V_1\) de-energized). Each sub-problem is a single-source resistive network and is solved by KCL and Ohm's law.
Sub-problem 1 (\(V_1\) active, \(V_2\) shorted). The two source-resistor branches are now both connected from \(V_1\) (or 0 V, for the shorted branch) into node \(X\), and node \(X\) is connected to ground through \(R\). Apply KCL at \(X\): the current into \(X\) from \(V_1\) through \(R_1\), plus the current into \(X\) from the shorted \(V_2\) branch through \(R_2\), equals the current out through \(R\) to ground:
The technique scales: for a 64-channel mixer, the expression simply keeps adding terms \(V_k/R_k\) over the sum of conductances.
Part IV · Linear Networks and Circuit Problem Solving
30
Linear and Nonlinear Elements
1 sections1 min readInteractive model
A network built only of resistors is linear because every resistor's I–V characteristic (\(V = IR\)) passes through the origin. Independent sources cannot be inside such a network: their characteristics (a vertical line for a voltage source, a horizontal line for a current source) do not pass through the origin. Sources must be pulled out and treated as inputs to the linear network.
Interactive lab
I–V characteristics
Adjust the model. The resistor line, ideal voltage source, and ideal current source share one labelled I–V plot.
Under the passive sign convention established in Chapter 37, \(P = V I > 0\) means the element absorbs power (current enters the positive-labelled terminal and both \(V\) and \(I\) are positive). For a source supplying power to a load, the current actually leaves the positive terminal, so its \(V\) and \(I\) have opposite signs in the source's reference frame, giving \(P < 0\) — the source delivers power. The same battery being recharged has \(P > 0\) (it absorbs energy from the charger). The sign therefore distinguishes delivering from absorbing, not positive from negative.
30.1 Inductors and capacitors are linear
The inductor relation \(V = L\,di/dt\) is linear because differentiation is a linear operator: \(L\,d(a i_1 + b i_2)/dt = a\,L\,di_1/dt + b\,L\,di_2/dt\). The capacitor relation \(i = C\,dv/dt\) is linear for the same reason, and the integral form is also linear. Therefore any network of resistors, inductors, and capacitors — with sources pulled out as inputs — is a linear network on which superposition can be applied. Any internal voltage or current can be expressed as a linear combination of the inputs.
Part IV · Linear Networks and Circuit Problem Solving
31
Voltage and Current Dividers
3 sections1 min readInteractive model
Two specific network results recur so often they are worth naming.
Interactive lab
Network reduction
Adjust the model. Step through equivalent-resistance transformations.
31.1 Voltage divider
For two series resistors \(R_1, R_2\) across a source \(V_1\) with no other element drawing current from the divider node (an unloaded divider), the voltage across \(R_2\) is
generalizing to any number of series resistors: the voltage across \(R_k\) is \(R_k / (\sum_i R_i) \cdot V_{\text{in}}\). The formula assumes no load is attached to the divider node; if a load is connected, it draws additional current and the divider ratio no longer holds.
31.2 Current divider
For two parallel resistors \(R_1, R_2\) fed by a current source \(I\) (no other branches drawing current from the top node), the current through \(R_1\) is
with the other resistor in the numerator. A larger resistor in parallel carries a smaller current. The formula assumes the parallel pair is fed by an ideal current source and that no other path diverts current.
31.3 Network-simplification properties
Two idealizations give useful simplification rules:
A resistor placed directly across an ideal voltage source does not affect the rest of the network: both see the same fixed voltage \(V\), so the network current is unchanged (only the source current differs).
A resistor placed directly across an ideal current source does not affect the rest of the network: the same current \(I\) flows in and out of the network regardless.
These follow directly from the ideal source definitions (constant voltage or constant current regardless of load).
Part IV · Linear Networks and Circuit Problem Solving
32
Source Deactivation Rules
2 sections2 min readInteractive model
Superposition requires turning sources "off" one at a time. The rules are:
Interactive lab
Superposition
Adjust the model. Source 1 + source 2 = the summed response.
To de-energize a voltage source, replace it with a short circuit (an ideal wire, \(V = 0\)).
To de-energize a current source, replace it with an open circuit (a break, \(I = 0\)).
32.1 Worked superposition example
Consider the following linear resistive network: a 2 V voltage source in series with a 2 kΩ resistor, and a 1 mA current source in parallel with a 4 kΩ resistor, with the two sub-circuits joined in a single loop (the 2 kΩ resistor in series with the parallel combination of the 1 mA current source and the 4 kΩ resistor). Find the current through the 4 kΩ resistor.
Case 1 — voltage source only (current source opened). With the current source opened, the 2 kΩ and 4 kΩ resistors are in series across the 2 V source, so \(i_{x1} = 2\,\text{V} / (2\,\text{k}\Omega + 4\,\text{k}\Omega) = 1/3\,\text{mA}\) flows through the 4 kΩ resistor.
Case 2 — current source only (voltage source shorted). With the voltage source shorted, the 1 mA current source drives the parallel combination of 2 kΩ and 4 kΩ. By current division, the fraction through the 4 kΩ branch is \(2/(2+4) = 1/3\), so \(i_{x2} = (1/3)\cdot 1\,\text{mA} = 1/3\, \text{mA}\).
Total.\(i_x = i_{x1} + i_{x2} = 2/3\,\text{mA}\).
32.2 A caution about symmetry intuition
In a square network of eight 6 Ω resistors with three 12 V sources (\(V_1, V_2, V_3\)), the three sources look symmetric but produce unequal contributions. For \(V_1\) alone, \(I_{A1} = 1/2\) A. For \(V_2\) alone, \(I_{A2} = 0\) because a resistor-only loop with no return path carries no current. For \(V_3\) alone (the mirror of \(V_1\)), \(I_{A3} = 1/2\) A. The total is \(I_A = 1\) A. The lesson: do not trust visual symmetry — return to basics and solve each case explicitly.
Part V · 11 chaptersCh 33–43
05
Amplifiers, Transients and Filters
Part V · Amplifiers, Transients and Filters
33
The Analog Audio Mixer
2 sections2 min readInteractive model
At a concert, every musician plays at full volume, yet the audience hears a balanced mix. The sound engineer uses an audio mixer: a system that takes in all microphone inputs and lets the engineer adjust each channel's volume via knobs to produce a good mix. Mixers are characterized by their channel count (16, 32, 64 channels).
Interactive lab
Waveform explorer
Adjust the model. Amplitude, frequency, and phase control a labelled sinusoid.
33.1 KCL as a natural adder
Kirchhoff's Current Law gives an immediate way to add signals in a circuit: currents entering a node sum automatically. If each microphone output is modeled as a voltage source driving a current through a resistor into a common node, KCL forces \(I = I_1 + I_2\), and the node voltage is \(V_X = I \cdot R\).
A potentiometer is a variable resistor; turning its screw changes \(R\) and so scales the current in that arm, independently controlling that channel's amplitude.
33.2 What happens when frequencies differ
Adding two equal-frequency sinusoids preserves the amplitude shape. Adding two different frequencies (say 1 kHz and 10 kHz) produces a product/AM-type waveform via the identity
\[\sin a + \sin b \;=\; 2\sin\!\Bigl(\frac{a+b}{2}\Bigr)\cos\!\Bigl(\frac{a-b}{2}\Bigr),\](33.1)
giving a 1 kHz envelope carrying 10 kHz oscillations — a first glimpse of amplitude modulation, studied in Part VIII. The identity itself follows directly from the angle-addition formulas:
so $\sin a + \sin b = \sin(\tfrac{a+b}{2}+\tfrac{a-b}{2}) + \sin(\tfrac{a+b}{2}
\tfrac{a-b}{2})\(. Using the identity \)\sin(x+y) + \sin(x-y) = 2\sin x \cos y$
with \(x = \tfrac{a+b}{2}\), \(y = \tfrac{a-b}{2}\) produces the boxed form above. Adding a DC offset to a sinusoid shifts the sine vertically, illustrating superposition of a DC level with an AC signal.
Part V · Amplifiers, Transients and Filters
34
The Resistive Mixer as a Weighted Summer
3 sections3 min readInteractive model
The experimental mixer is now derived theoretically. Consider two source branches feeding a common node \(X\): source \(V_1\) in series with \(R_1\), and source \(V_2\) in series with \(R_2\), both returning to ground through a shared resistor \(R\) between \(X\) and ground. (The topology is identical to the one used in Chapter 29's superposition example.) Apply KCL at node \(X\) — the sum of currents leaving \(X\) through each branch must equal zero:
Interactive lab
Superposition
Adjust the model. Source 1 + source 2 = the summed response.
The circuit is a weighted resistive summer. With lab values \(R = 1\,\text{k}\Omega\), \(R_1 = R_2 = 400\,\Omega\), \(V_1 = 1\,\text{V}\), \(V_2 = 2\,\text{V}\), the formula gives \(V_X \approx 1.25\,\text{V}\), matching measurement.
34.1 Subtraction, design, and Fourier synthesis
Subtraction is achieved by sign-inverting one source (\(V_2 \to -V_2\)) without changing the circuit.
Design problem: given desired coefficients \(\beta_1, \beta_2\), solve a \(2\times 2\) linear system in \(x_1 = R/R_1\), \(x_2 = R/R_2\), with \(R\) as a free variable fixed to match available component values.
Fourier synthesis: extending to five sources with coefficients \(1/(n\pi)\) and frequencies 10, 20, 30, 40, 50 kHz synthesizes a sawtooth waveform. The resistive mixer is implementing a Fourier series in the analog domain — a first taste of analog computing.
34.2 Passive circuits cannot amplify
Because all elements are passive, each \(\alpha_k < 1\). The mixer can only attenuate each input; amplification requires an active device. This motivates the amplifier of the next chapter. A real audio mixer also sends a separate feedback monitor mix to each performer so they can hear mainly their own voice/instrument; the mixer is kept analog because digital buffering adds complexity.
34.3 Linearity confirmed experimentally
Fixing \(R_2\) (replacing the potentiometer with 390 Ω) makes the two legs contribute equally. Tabulating \(V_X\) versus \((V_1, V_2)\):
\((1, 0)\) V → \(V_X \approx 0.416\) V
\((2, 1)\) V → \(V_X \approx 1.25\) V
\((1, 1)\) V → \(V_X \approx 0.836\) V
\((1, -1)\) V → \(V_X \approx 0\) V
The output scales linearly with the sum of inputs: the circuit is a linear adder. When \(V_2 = 0\), the zero source is replaced by a short circuit (an ideal wire with zero resistance and zero potential drop).
Part V · Amplifiers, Transients and Filters
35
The Non-Inverting Amplifier
3 sections2 min readInteractive model
A mixer's output is in millivolts and milliwatts — far too feeble to drive a stage speaker rated around 1 kW, which needs amperes of current at hundreds of volts. An amplifier sits between the mixer and the speaker.
Interactive lab
Op-amp explorer
Adjust the model. Gain, rails, and clipping are exposed as explicit values.
where \(A\) is the amplification factor (gain), set by two tunable resistors on the board. Amplification changes only the amplitude; the frequency \(\omega_0\) is unchanged.
35.2 Input isolation
The amplifier input behaves as an open circuit (infinite input resistance), so it does not load the mixer node. Why zero input current? In the ideal amplifier model, the input terminals sense a voltage but draw no current to do so — the input resistance is taken to be infinite so that attaching the amplifier to any node does not disturb the voltage there. This is what makes the mixer output \(V_X\) independent of the amplifier:
This is the same weighted-summer expression as Chapter 34, taken in the limit where the shared resistor \(R\) from \(X\) to ground is taken to infinity (so the conductance \(g = 1/R\) vanishes). With a finite \(R\), the formula would include \(g\) in the denominator; the ideal infinite-input-resistance amplifier is the case where the mixer is not loaded by any downstream path. The formula recovered is consistent with Chapter 34 in that limiting case.
The amplifier then simply scales \(V_X\) by \(A\).
The idealization is essential but not physical. A real amplifier has a large but finite input resistance — typically \(\text{M}\Omega\) to \(\text{G}\Omega\) for a precision op-amp, several \(\text{k}\Omega\) for a general-purpose bipolar transistor stage. So a real amplifier draws a small current from the mixer node, slightly disturbing \(V_X\). The disturbance is negligible as long as the mixer output impedance is much smaller than the amplifier input resistance, which is exactly the condition the idealization captures in its limit. Distinguishing the ideal from the real is essential whenever a downstream stage is added to a resistive network.
35.3 The bandwidth limit
A purely resistive mixer expression would suggest it works at any frequency up to gigahertz. Real amplifiers have a bandwidth limit tied to capacitors (internal and parasitic), which makes the gain frequency-dependent. This motivates the RC analysis of the next chapters.
Part V · Amplifiers, Transients and Filters
36
The Inverting Amplifier and Clipping
3 sections1 min readInteractive model
36.1 Negative gain
Interactive lab
Op-amp explorer
Adjust the model. Gain, rails, and clipping are exposed as explicit values.
An inverting amplifier produces an output 180° out of phase with the input because its gain \(A\) is negative. The gain is set by two tunable resistors \(R_3, R_4\), giving an adjustable negative gain like \(-3\) or \(-4\).
36.2 Linear scaling then clipping
Feeding a 1 kHz sinusoid: doubling the input from 100 mV to 200 mV scales the output accordingly (about 600 mV), with the sinusoid intact and the phase at 180°. Beyond a point, however, the output stops scaling: at a 2 V input the output clips (saturates) near 4.2 V and is no longer a sine wave.
36.3 Clipping is a power/energy limit, not a gain limit
The saturation level is governed by the DC power supply (\(V^+\) and \(V^-\)). Lowering the supply makes clipping occur earlier; the amplification factor itself is unchanged away from the rails. The energy argument is decisive: for a passive voltage divider, \(E_{\text{out}} < E_{\text{in}}\). For an amplifier, almost all of the output energy is supplied by the DC supply \(E_{DC}\); the small input signal \(E_{\text{in}}\) contributes only the control that shapes the output, not the bulk of its energy. Energy accounting still requires that the sum of all energy inputs (DC supply plus the small input) covers the output plus any losses, so
In practice \(E_{DC} \gg E_{\text{in}}\) and essentially \(E_{\text{out}} \le E_{DC}\). Clipping is the DC supply being unable to provide enough energy — a power limit, not a loss of gain. This introduces the idea of power amplification: the amplifier converts DC power into AC (sinusoidal) power.
Part V · Amplifiers, Transients and Filters
37
Passive Sign Convention and Power Accounting
4 sections1 min readInteractive model
37.1 The convention
Interactive lab
I–V characteristics
Adjust the model. The resistor line, ideal voltage source, and ideal current source share one labelled I–V plot.
The passive sign convention: when current enters the positive terminal of a two-terminal element and both \(V\) and \(I\) are positive, the element absorbs power \(P = V I\). This is the standard convention for analyzing any two-terminal element.
37.2 Passive versus active elements
A passive element always absorbs power: its I–V characteristic occupies only the first and third quadrants, where \(V \cdot I > 0\) regardless of sign reversal. A resistor is the canonical passive element (1 Ω across 2 V absorbs 4 W as heat).
An active element (voltage or current source) can deliver power by operating in the second or fourth quadrant of the V–I plane. The 2 V source delivering current out of its positive terminal is delivering power.
A voltage source can also absorb power when charging: a current source forcing 2 A into a 2 V source makes the source absorb 4 W, exactly what a charger does to a battery.
37.3 Amplifiers as active
Viewed purely from the AC (sinusoidal) signal perspective, an amplifier converts DC power into sinusoidal power and so appears to operate in the second/fourth quadrants — it is classed as active. The apparent "creation" of energy is resolved by separating the DC (absorbing) part from the sinusoidal (producing) part.
37.4 Storage elements
Inductors and capacitors store energy (electromagnetic and electrostatic) rather than dissipating it like a resistor. This sets up the RC transient analysis of the next chapter.
Part V · Amplifiers, Transients and Filters
38
The RC Step Response — Experiment
0 sections1 min readInteractive model
Apply a square wave input across a series RC circuit with \(R \approx 1\, \text{k}\Omega\), \(C \approx 100\,\text{nF}\). The capacitor voltage \(V_C(t)\) exhibits charge–discharge dynamics that depend on the frequency.
Interactive lab
RC response
Adjust the model. The curve marks τ and prints R, C, and the response formula.
Low frequency (e.g. 100 Hz): the square-wave period is long enough that \(V_C(t)\) reaches the steady-state maximum \(V_M\) with negligible visible delay — the capacitor tracks the input.
High frequency (e.g. 5–10 kHz): the rapid switching prevents full charging or discharging. The output degrades into a reduced-amplitude, nearly triangular shape.
The step function\(u(t)\) — zero for \(t < 0\) and one for \(t \ge 0\) — is a cleaner mathematical input than a periodic pulse, because it isolates a single transition. The capacitor starts from an initial discharged state\(V_C(0^-) = 0\).
Part V · Amplifiers, Transients and Filters
39
The RC Step Response — Theory
4 sections3 min readInteractive model
39.1 The governing equation
Interactive lab
RC response
Adjust the model. The curve marks τ and prints R, C, and the response formula.
KVL is valid at every instant even with a capacitor. For a series RC with input \(V_{\text{in}}(t)\),
The integrating factor\(e^{\int p\,dt} = e^{t/RC}\) works because multiplying through by it collapses the left-hand side into a single total derivative. The key is the product rule: if \(V_C \cdot e^{t/RC}\) is differentiated,
The left-hand side is now a single derivative of a known product, which integrates trivially. (The homogeneous part of the equation, with \(V_{\text{in}}(t) = 0\), is separable in the strict sense — bring all \(V_C\) terms to one side, all \(t\) to the other, and integrate — which yields the same exponential factor \(e^{-t/RC}\). The driven equation with \(V_{\text{in}}(t) \neq 0\) is not separable; the integrating factor is the standard method because it handles the non-homogeneous input term on the right-hand side uniformly.) Integrating both sides and applying the initial condition \(V_C(0^-) = 0\) gives, for a unit step \(V_{\text{in}} = u(t)\),
Whether a frequency counts as "low" or "high" depends on \(RC\), not on the frequency number alone:
At 100 Hz the half-period is 5 ms, effectively infinite compared to \(RC = 100\, \mu\text{s}\), so the capacitor tracks the input.
At 10 kHz the half-period is 50 \(\mu\)s, comparable to \(RC\), so the capacitor only traverses part of the swing.
On time scales much shorter than \(RC\), the exponential looks linear: \(1 - e^{-t/RC} \approx t/RC\), which is why the output can resemble a straight or triangular line.
Key takeaway: the time constant determines the frequency analysis of any RC circuit. The same exponential \(e^{-t/RC}\) that controls the step response also controls the way the circuit responds to sinusoids — its amplitude scaling and phase shift at frequency \(\omega\) are set entirely by the dimensionless product \(\omega RC\), which compares the input's period to the RC time constant. A capacitor anywhere in an amplifier makes its gain frequency-dependent, and parasitic capacitance means even an "ideal" resistor fails to behave ideally at gigahertz frequencies. The next two chapters make this connection explicit: Chapter 40 derives the low-pass amplitude response \(A/\sqrt{1 + \omega^2 R^2 C^2}\) from the same ODE solved here, and Chapter 41 obtains the complementary high-pass response from the same circuit.
Part V · Amplifiers, Transients and Filters
40
The Low-Pass Filter
3 sections3 min readInteractive model
40.1 From step to sinusoid
Interactive lab
Filter explorer
Adjust the model. The selected response prints its cutoff and −3 dB point.
The RC step response showed that \(RC\) has dimensions of time, so \(1/RC\) is an angular frequency — the natural reference for classifying inputs as slow or fast. For \(R = 1\,\text{k}\Omega\), \(C = 100\,\text{nF}\), \(1/RC \approx 10\,\text{kHz}\).
Sweeping a sinusoid from 100 Hz to 100 kHz and measuring the capacitor voltage:
At 100 Hz the output tracks the input closely (equal amplitude, near-zero phase).
As frequency increases, output amplitude decreases and the output lags the input. "Delay" is replaced by phase, which is independent of the time period.
Phase changes rapidly in the region around \(1/RC\) and saturates near \(\pi/2\) at very high frequencies, while amplitude keeps falling. This is the low-pass filter response.
40.2 Deriving the steady-state response
With \(V_{\text{in}} = A\sin(\omega t)\), the ODE is
Integrating both sides requires evaluating the integral \(\int e^{at}\sin(bt)\,dt\) with \(a = 1/RC\) and \(b = \omega\). This integral is computed by two successive integrations by parts:
and using the identity \(\sin x + (a/b)\cos x = \sqrt{1 + (a/b)^2}\,\sin(x + \phi)\) with \(\tan\phi = a/b\) (equivalently, \(\phi = \tan^{-1}(b/a)\) after re-indexing), the result is
Substituting \(a = 1/RC\), \(b = \omega\), and dropping the decaying transient term (proportional to \(e^{t/RC}\), which vanishes as \(t \to \infty\)) gives the steady-state response:
Phase\(\phi = \tan^{-1}(\omega RC)\): - \(\omega RC \to 0\): \(\phi \to 0\). - \(\omega RC = 1\): \(\phi = 45°\). - \(\omega RC \to \infty\): \(\phi \to \pi/2\) (saturates; a single RC can never exceed \(\pi/2\)).
The cutoff condition \(\omega RC = 1\) gives \(A/\sqrt{2}\) and \(45°\), verified experimentally near 1.4 kHz.
Because the circuit suppresses high frequencies and passes low frequencies, it is a low-pass filter, enabling frequency-dependent equalization in audio mixing.
How low-pass filters shape signals
A first-order RC low-pass filter has a magnitude response |H(f)| = 1 / √(1 + (f/f_c)²) and a phase response φ(f) = -arctan(f/f_c). The cutoff frequency f_c = 1/(2πRC) is defined as the point where the magnitude response falls to 1/√2 ≈ 0.707 of its DC value, which corresponds to a power loss of 3 dB (half the power).
Signals well below f_c pass through unchanged; signals well above f_c are attenuated by a factor of f_c/f per decade (i.e. frequency-doubled gives 6 dB attenuation, frequency-decade gives 20 dB). This 6 dB/octave or 20 dB/decade slope is the signature of a first-order filter. A second-order filter (RLC, or two cascaded RC stages) gives 12 dB/octave or 40 dB/decade; this is why audio speakers use second-order and higher-order crossovers to prevent frequencies outside the driver's range from reaching it.
The phase response matters for time-domain signals. A step input to a low-pass filter does not appear instantly at the output — it rises exponentially with time constant τ = RC, lagging behind the input by a couple of time constants. This is why video signals are bandwidth-limited before transmission: a finite bandwidth means a finite rise time, and the rise time limits the sharpest edges the signal can carry. A 4 MHz video signal has a rise time of roughly 1/(2π · 4 MHz) ≈ 40 ns — fast enough for crisp text but not fast enough for a perfect step.
Part V · Amplifiers, Transients and Filters
41
The High-Pass Filter
2 sections1 min readInteractive model
41.1 The complementary output
Interactive lab
Filter explorer
Adjust the model. The selected response prints its cutoff and −3 dB point.
Taking the voltage across the resistor instead of the capacitor, KVL around the single loop gives
The two are complementary and sum to the input. They cross at \(V/2\) at \(t \approx 0.693\,RC\). The series current is \(I(t) = V_R/R\), a scaled copy of the resistor voltage.
Initially the discharged capacitor behaves as a short circuit (full input across \(R\), current \(V_{\text{in}}/R\)). At steady state it behaves as an open circuit, so \(V_R \to 0\).
At low \(\omega\), \(V_R\) is small (low frequencies blocked).
At high \(\omega\), \(V_R \approx a\sin(\omega t)\) (high frequencies passed).
The circuit passes high frequencies and cuts low frequencies — a high-pass filter, the complement of the low-pass. The standard high-pass topology places the capacitor in series and the resistor to ground.
Experimentally, high frequencies (10–100 kHz) pass nearly unattenuated with negligible phase shift; at the cutoff \(f_c = 1/(2\pi RC)\) (about 1.6 kHz here) the output drops to \(1/\sqrt{2}\) of the input (the "707 crossing"); at 100 Hz the signal is attenuated to near zero.
Part V · Amplifiers, Transients and Filters
42
The Band-Pass Filter
3 sections2 min readInteractive model
42.1 From mixer knobs to filters
Interactive lab
Filter explorer
Adjust the model. The selected response prints its cutoff and −3 dB point.
A sound mixer's high/mid/low EQ knobs correspond to high-pass, band-pass, and low-pass filters, each amplifying only a selected frequency range rather than the whole signal.
42.2 Design by cascading
A band-pass filter is built by cascading a high-pass and a low-pass stage — placing them in series, like an AND operation. The response is high only where both filters are high, so the individual responses multiply, not add. (Adding would give a high value wherever either filter is high.)
Critical design constraint: the high-pass cutoff \(\omega_L\) must be lower than the low-pass cutoff \(\omega_H\). Reversing them produces a "no pass filter" — the multiplied response is near zero everywhere.
With \(R_1 = 1\,\text{k}\Omega\), \(C_1 = 10\,\text{nF}\) the low-pass cutoff is \(f_c = 1/(2\pi R_1 C_1) \approx 15.9\,\text{kHz}\); with \(R_2 = 100\,\text{k}\Omega\), \(C_2 = 10\,\text{nF}\) the high-pass cutoff is \(f_c = 1/(2\pi R_2 C_2) \approx 159\,\text{Hz}\). The band-pass passes a middle band roughly from ~160 Hz to ~16 kHz.
42.3 The loading effect
Directly connecting a second stage to the first changes the first stage's behavior, because the second stage draws current through the first — this is the loading effect. The cascaded output is not simply the product \(V_1 \cdot V_2\) of the individual responses.
To minimize loading, choose \(R_2\) much larger than \(R_1\) (here \(100\,\text{k}\Omega\) vs \(1\,\text{k}\Omega\)) so the second stage draws little current from the first, and space \(\omega_L\) and \(\omega_H\) far apart so the two cutoffs can be designed independently. The experiment confirms the design: output rises from ~0 at 1 Hz through ~55 mV at 100 Hz, to a flat ~100 mV mid-range (2–3 kHz), then falls off again toward 500 kHz, with the two cutoffs at roughly 140–150 Hz and 14–16 kHz.
Part V · Amplifiers, Transients and Filters
43
First-Order Limitations and Higher-Order Filters
3 sections1 min readInteractive model
43.1 The ideal brick wall
Interactive lab
Filter explorer
Adjust the model. The selected response prints its cutoff and −3 dB point.
An ideal low-pass filter has gain 1 below the cutoff and gain 0 above it, with an abrupt transition. The practical first-order RC filter tapers off slowly — far from ideal.
43.2 Raising the order
Introducing a series inductor gives an RLC circuit governed by a second-order differential equation. The order of the filter equals the order of its differential equation. Adding more capacitors and inductors raises the order, making the roll-off faster and the passband flatter, approaching the ideal "brick wall" response. Tenth- to twentieth-order filters closely resemble the ideal.
43.3 Why move to the frequency domain
Time-domain first-order analysis gives intuition but does not scale to higher-order systems. Frequency-domain methods (Fourier and Laplace transforms, covered in later courses) convert differential equations into sets of linear equations solvable in matrix or computational form. The awareness of the first-order limitation is essential before applying these techniques in design.
Part VI · 8 chaptersCh 44–51
06
Analog-to-Digital Conversion
Part VI · Analog-to-Digital Conversion
44
Analog versus Digital Audio
4 sections3 min read
44.1 What an oscilloscope can and cannot do
An oscilloscope displays an audio signal in real time, voltage versus time, on a phosphor or LCD screen. The trace is transient: the moment the input is disconnected, the waveform vanishes. The 'scope is therefore a non-storage display device. It is the right tool for diagnosing whether a circuit is behaving correctly right now, but it cannot save a waveform for later analysis, cannot email it to a colleague, and cannot run an algorithm on it three months from today.
Digital audio software (Audacity, Reaper, Logic Pro, Pro Tools) and the file formats they consume (WAV, AIFF, FLAC, MP3) solve exactly this storage problem. A digital audio system captures a continuous waveform, quantizes it into a finite sequence of numbers, and stores those numbers on disk. The same numbers can later be replayed exactly, edited non-destructively, transmitted over a network, and analyzed by software. The cost of all this is twofold: the quantization is an irreversible projection of the continuous world into a discrete one, and the storage requires bits — a finite budget that scales with both the sample rate and the bit depth.
44.2 The two parameters of digital audio
Two parameters govern any digital audio representation:
Sample rate\(f_s\) (Hz): how often the continuous signal is measured. Periodic sampling at \(f_s\) produces \(f_s\) samples per second. The audible band of human hearing extends to roughly 20 kHz, so by the Nyquist–Shannon sampling theorem (Chapter 45) the sample rate must exceed 40 kHz to capture all audible content. The CD standard \(f_s = 44.1\,\text{kHz}\) was chosen to leave a small safety margin; DVD audio and Blu-ray audio use \(f_s = 96\,\text{kHz}\) or \(192\,\text{kHz}\) but the audible benefit is debated. Telephony uses \(f_s = 8\,\text{kHz}\) because the human voice has almost no content above 4 kHz.
Bit depth\(n\): how many bits represent each sample. An \(n\)-bit sample can take \(2^n\) distinct values. CDs use 16 bits per sample (\(2^{16} = 65{,}536\) levels); professional audio uses 24 bits (\(2^{24} \approx 16.8\,\text{million}\) levels). The bit depth determines the amplitude quantization — the smallest voltage difference the system can resolve.
44.3 File size and the bit-rate calculation
A stereo file with two channels, \(f_s\) samples per second, \(n\) bits per sample, and \(T\) seconds of duration contains
\[\text{size} = 2 \cdot f_s \cdot n \cdot T \quad \text{bits}.\](44.1)
For a 3-minute CD-quality track at 44.1 kHz, 16 bits, stereo:
This is the uncompressed PCM size; the WAV file adds a small header. The same calculation explains why a 30 MB MP3 file is "CD-quality" — the MP3 codec typically reaches compression ratios of 10-to-1 by dropping perceptually irrelevant information.
44.4 Software mixing mirrors hardware mixing
Multi-track recording and mixing in software mirror the hardware resistive mixer of Part V: each channel (vocal, guitar, drums) is an independent track that can be filtered, attenuated, and combined. The key conceptual difference is that the software operates on sequences of numbers rather than on continuous voltages in real time. The mathematics of the operation is identical — a weighted sum of input tracks — but the computational model is fundamentally different: the software mixer can take as long as it likes to render a session, while the hardware mixer must produce the output within microseconds to maintain the illusion of live sound.
This module builds the bridge from the continuous analog world of voltages and currents to the discrete digital world of bits and samples. The next chapter quantizes time itself (sampling), and the chapter after that quantizes amplitude (bit depth). Together they are the two halves of analog-to-digital conversion.
Part VI · Analog-to-Digital Conversion
45
Time Quantization (Sampling)
5 sections4 min readInteractive model
An analog signal contains an infinite number of time points and so cannot be stored directly in a digital computer. Time quantization (sampling) discretizes the time axis by measuring the signal amplitude at fixed intervals
Interactive lab
Sampling explorer
Adjust the model. Samples and the Nyquist limit are labelled on the signal.
The principle: faster-varying signals and richer harmonic spectra require higher sampling rates. A DC or slowly changing signal needs very few samples; a signal with subtle high-frequency harmonics needs many. High sampling rates yield large raw datasets (PCM/WAV), driving lossy compression formats like MP3, which discard imperceptible high harmonics at the cost of fidelity.
45.2 The Nyquist sampling theorem
How fast is fast enough? The Nyquist sampling theorem gives the answer. If a signal contains no frequency content above \(f_{\max}\) (it is band-limited to \(f_{\max}\)), then it can be reconstructed exactly from its samples provided the sampling rate satisfies
The lower bound \(f_s = 2f_{\max}\) is the Nyquist rate; sampling faster than this is oversampling and gives some safety margin, while sampling slower loses information permanently.
The intuition is geometric. A sinusoid at frequency \(f\) completes one full period in time \(T = 1/f\). To distinguish it from any other sinusoid after sampling, the sampling instants must "see" enough of the waveform to identify its period — fewer than two samples per period leaves the cycle ambiguous. Sampling at exactly two samples per period captures one peak and one trough, which is just enough in the ideal noiseless case. Anything slower and the samples can be matched by infinitely many different sinusoids.
45.3 Aliasing
Sampling below the Nyquist rate produces aliasing: high-frequency components of the original signal reappear at spurious lower frequencies in the sampled data. A sinusoid at \(f\) sampled at \(f_s < 2f\) is indistinguishable from a sinusoid at the aliased frequency
for the integer \(k\) that places the result in \([0, f_s/2]\). The high-frequency content has "folded" back into the lower band, and the fold cannot be undone — two different analog signals (one at \(f\), one at \(f - f_s\)) produce exactly the same sample values. This is why once aliasing has happened, the original information is lost; no amount of post-processing can recover it from the samples alone. Pictorially, frequencies beyond \(f_s/2\) wrap around and superimpose on frequencies inside the band — a phenomenon called frequency folding.
45.4 The anti-aliasing filter
The cure is to prevent aliasing in the first place. Before sampling, the signal is passed through a low-pass anti-aliasing filter with cutoff at or below \(f_s/2\). Any frequency content above the Nyquist limit is removed, so only band-limited information reaches the sampler and no folding occurs. A practical filter has a finite transition band, so engineers often set the sampling rate a little above \(2f_{\max}\) and design the filter's stopband to begin near \(f_s/2\). The same low-pass-filter transfer function studied in Chapter 40 is what is used here — the RC time constant of the filter, in conjunction with the chosen sampling rate, determines how aggressively high frequencies are attenuated.
45.5 Why 44.1 kHz for audio
Human hearing extends to roughly \(20\,\text{kHz}\) in young ears. The Nyquist rate for an audio signal band-limited to \(20\,\text{kHz}\) is therefore \(2 \times 20\,\text{kHz} = 40\,\text{kHz}\). The compact-disc standard of \(44.1\,\text{kHz}\) exceeds this bound by about \(2\,\text{kHz}\), leaving headroom for an analog anti-aliasing filter with a gentle roll-off. The slightly higher sampling rate of \(48\,\text{kHz}\) used in professional audio gives even more margin. The telephone standard of \(8\,\text{kHz}\) corresponds to a band-limit of about \(3.5\,\text{kHz}\) — enough for intelligible speech but not for music, which is why telephony sounds "muffled". Each sampling rate is a deliberate trade-off between data volume and the band of frequencies preserved.
Part VI · Analog-to-Digital Conversion
46
Amplitude Quantization
4 sections2 min readInteractive model
46.1 The continuous-to-discrete mapping
Interactive lab
Quantizer
Adjust the model. The staircase and quantization step are labelled.
Physical analog voltages span an infinite continuum of real numbers; a digital system can store only a finite set of discrete levels. Amplitude quantization maps the continuous range onto \(M\) discrete levels. If the input voltage spans a range \(V_{\text{range}}\) from \(V_{\text{min}}\) to \(V_{\text{max}}\), each sample \(V\) is mapped to the nearest of the \(M\) discrete output levels.
For a system spanning 0 to 2 V with \(M = 256\) levels, \(\Delta = 7.8125\,\text{mV}\); two input voltages that differ by less than 7.8125 mV are unresolvable — they map to the same output. The whole point of high-resolution audio (24-bit, \(M = 2^{24} = 16.8\,\text{million}\) levels) is to make this quantization step so small that the human ear cannot detect the rounding.
46.2 Quantization error
Truncating or rounding each sample to the nearest level introduces a small quantization error\(e = V_{\text{quantized}} - V_{\text{continuous}}\). The maximum magnitude of this error is \(\Delta/2\) for round-to-nearest quantization. The error is not random in time — it is a deterministic function of the input — but to a casual observer it resembles a small amount of added noise. For high-resolution audio, the signal-to-quantization-noise ratio (SQNR) is
where \(n\) is the bit depth. For 16-bit audio, SQNR ≈ 98 dB; for 24-bit, SQNR ≈ 146 dB. The 16-bit figure is the reason CDs sound "clean" to human ears — the quantization noise is far below the threshold of audibility.
46.3 The staircase transfer curve
Plotting quantized output against continuous input yields a characteristic staircase transfer curve: each input range of width \(\Delta\) maps to a constant discrete output. The step jumps occur at the midpoints of the intervals (for round-to-nearest), and the curve is flat across each step. This staircase is the visual signature of all uniform quantizers and is the foundation of the A/D converter. The inverse operation — D/A conversion — takes the integer code and produces a voltage equal to the center of the corresponding step, which is then low-pass filtered to reconstruct a continuous waveform.
46.4 Hardware realization
The discrete levels are then remapped into simple integer indices (0 to \(M-1\)) for compact storage. In hardware, ADCs (analog-to-digital converters) and DACs (digital-to-analog converters) in sound cards perform this conversion in real time. Successive-approximation ADCs (SAR-ADC) make one binary decision per clock cycle, \(n\) cycles for \(n\)-bit conversion — fast and accurate to 16–18 bits. Delta-sigma ADCs oversample at a much higher rate and use noise-shaping to push quantization noise out of the audio band, achieving 24-bit resolution at modest cost. Both convert the continuous input into a finite-alphabet integer code that the digital world can store, transmit, and process without further loss.
Part VI · Analog-to-Digital Conversion
47
The Sample-and-Hold Circuit
3 sections1 min readInteractive model
To quantize a continuously varying signal, the ADC needs a stable snapshot. The sample-and-hold circuit captures the instantaneous value of the input and holds it constant during the conversion.
Interactive lab
Sample-and-hold
Adjust the model. Track and hold phases are drawn as a labelled staircase.
47.1 The capacitor as a storage element
A capacitor is the natural choice: it retains its terminal voltage when isolated from current-drawing paths, unlike a resistor or inductor.
47.2 The ideal switch
An ideal switch is a three-terminal element: a control terminal commands it, and the signal path is either a short circuit (ON, \(R = 0\)) or an open circuit (OFF, \(R = \infty\)). In both states the ideal switch dissipates zero power: \(V = 0\) in ON (so \(P = V I = 0\)) and \(I = 0\) in OFF (so \(P = 0\)).
47.3 Practical constraint
A real switch has non-zero ON resistance \(R_{\text{on}}\). For the capacitor to charge to the instantaneous input voltage during the brief ON interval, the time constant must satisfy
When driven by periodic short pulses at the control terminal, the capacitor voltage tracks the input during turn-on and holds the value during turn-off, generating a staircase waveform that approximates the continuous input.
Part VI · Analog-to-Digital Conversion
48
The Flash ADC
3 sections1 min readInteractive model
The Flash ADC converts a continuous-level voltage into a discrete integer representation in a single parallel step, rather than searching sequentially.
Interactive lab
Flash ADC
Adjust the model. A resistor ladder feeds labelled parallel comparators.
48.1 Architecture
A resistor ladder — a series string of equal-valued resistors across a reference voltage \(V_{\text{max}}\) — divides the total voltage into uniform threshold steps \(\Delta, 2\Delta, 3\Delta, \dots\). Each tap feeds the reference input of a comparator: a high-gain differential amplifier that drives its output to one of the supply rails, saturating to \(+V_{dd}\) if its \(+\) input exceeds its \(-\) input and to \(-V_{dd}\) otherwise. A dedicated comparator IC (not a general-purpose operational amplifier) is normally used, because comparators are designed for fast saturation and digital-friendly output levels without the internal compensation that makes op-amps slow. All comparators evaluate the held input voltage against their thresholds simultaneously.
48.2 Thermometer code
If the input exceeds a given tap's reference, that comparator outputs high; otherwise low. The resulting pattern — a string of highs up to the input level followed by lows — is a thermometer code. Counting the number of high outputs yields the quantized integer index.
48.3 Why analog storage is unreliable
Real switches have finite OFF resistance \(R_{\text{off}}\), so a hold capacitor's charge leaks exponentially with time constant \(\tau = R_{\text{off}} C\). This is why long-term storage must be digital (binary), not analog.
Why flash ADCs are fast but expensive
A flash ADC uses one comparator per code level. A 4-bit flash ADC has 2⁴ = 16 comparators; an 8-bit flash ADC has 256; a 16-bit flash ADC has 65536. Each comparator compares the input voltage to a fraction of the reference voltage, and a priority encoder converts the one-hot comparator output to a binary code. The conversion happens in a single clock cycle — the comparator chain is fully parallel.
The cost is enormous. Doubling the resolution quadruples the number of comparators. A 16-bit flash ADC is impractical to build; even a 12-bit flash ADC has 4096 comparators and consumes significant power. The 8-bit flash ADC is the sweet spot for video (the TDA8703 and similar parts digitize analog video at hundreds of megasamples per second). For higher resolutions, successive-approximation ADCs (one comparator, N cycles) or delta-sigma ADCs (oversampling + noise shaping) are used instead.
Each comparator in a flash ADC must be precise. The reference voltage ladder has 4096 resistors for a 12-bit flash, and any mismatch in the resistor values creates a differential nonlinearity (DNL) — the input range producing some codes is wider or narrower than the ideal value. Mismatches as small as 0.1% of the reference translate to INL errors of 4 LSB in a 12-bit ADC. The reference ladder is therefore the most demanding analog component in the design.
Part VI · Analog-to-Digital Conversion
49
Charge Sharing Between Capacitors
2 sections1 min readInteractive model
When two capacitors initially at different voltages are connected by a switch, charge redistributes between them until they reach a common voltage. This is charge sharing.
Interactive lab
Charge sharing
Adjust the model. Both capacitors, final voltage, and energy loss are printed.
49.1 Derivation
Capacitor \(C_1\) is initially charged to \(V\); capacitor \(C_2\) is initially uncharged. When a switch connects them, the total charge is conserved (no active source is connected):
The initial energy is \(\tfrac{1}{2} C_1 V^2\). The final energy is \(\tfrac{1}{2}(C_1 + C_2) V_{\text{final}}^2\). For \(C_1 = C_2 = C\) the final energy is \(\tfrac{1}{4} C V^2\) — exactly half the initial. The missing half is dissipated as heat through the switch's parasitic ON resistance, and remarkably the loss is independent of the resistance value. (A smaller \(R\) dissipates a larger current over a shorter time; a larger \(R\) dissipates a smaller current over a longer time; the integral is the same.)
Part VI · Analog-to-Digital Conversion
50
Switched-Capacitor Circuits
4 sections4 min readInteractive model
50.1 From one capacitor to two at different voltages
Interactive lab
Switched capacitor
Adjust the model. Non-overlapping φ1 and φ2 phases show charge transfer.
Chapter 49 considered a single capacitor \(C_1\) pre-charged to \(V_1\) sharing charge with a second capacitor \(C_2\) that started at zero. The natural generalization is two capacitors initially charged to different non-zero voltages \(V_1\) and \(V_2\). A switched-capacitor circuit is the engineering realization of this idea: independent, non-overlapping clock phases \(\phi_1\) and \(\phi_2\) drive a small bank of CMOS switches that connect, isolate, and re-route capacitors along predefined paths. The non-overlap condition is critical — a period when both phases are simultaneously active would create a direct low-impedance path between the two capacitors and cause uncontrolled charge redistribution.
In phase \(\phi_1\), the two switches that connect the top plates of \(C_1\) and \(C_2\) to their respective voltage sources are closed and the inter-capacitor switch is open. The bottom plates are held at ground. After a few time constants, \(C_1\) sits at \(V_1\) and \(C_2\) sits at \(V_2\). In phase \(\phi_2\), the source switches open and the inter-capacitor switch closes; the two top plates are now tied together and the two bottom plates are still at ground. The capacitors share charge until they reach a common voltage \(V_{\text{final}}\).
50.2 Charge conservation gives the final voltage
By conservation of charge, the charge on the top-plate node before the connection equals the charge after:
The final voltage is a weighted average — a convex combination of the two initial voltages, with weights equal to the relative capacitance of the contributing capacitor. Because \(\alpha \in (0, 1)\), the result is strictly bounded between \(\min(V_1, V_2)\) and \(\max(V_1, V_2)\), regardless of the polarity of \(V_1 - V_2\). This is a charge-averaging operation: it cannot create a voltage outside the input range, but it can shift a voltage toward the other.
50.3 Why switched-capacitor circuits matter
Three practical reasons make switched-capacitor (SC) circuits ubiquitous in modern mixed-signal CMOS:
Capacitor ratios are far more accurate than resistor ratios in CMOS. Two capacitors on the same die track each other within 0.1% across process and temperature variation. Two resistors can differ by 20% or more. A circuit that depends on a ratio of two elements therefore prefers capacitors.
Time constants are tunable by clock frequency. A continuous-time RC low-pass filter has a fixed time constant \(\tau = RC\). The SC equivalent realizes the same transfer function with a time constant set by \(C_1/C_2\)and the clock frequency \(f_{\text{clk}}\). Doubling the clock halves the time constant; this programmability is impossible in a passive RC.
No continuous current flows. Each capacitor is charged through a switch from a voltage source and discharged through another switch. The current is pulsed, not continuous, so the circuit is naturally compatible with sampled-data and digital systems.
50.4 A worked example: voltage halving
Let \(C_1 = C_2\) so \(\alpha = 1/2\). Then \(V_{\text{final}} = (V_1 + V_2)/2\). If \(V_1 = 3\,\text{V}\) and \(V_2 = 1\,\text{V}\), the final voltage after phase \(\phi_2\) is \(V_{\text{final}} = 2\,\text{V}\). The total charge moved off the top plates during the redistribution is \(\Delta Q = C_1 (V_1 - V_{\text{final}}) = C_1 \cdot 1\,\text{V}\), and the energy stored in the combined capacitor is \(E_f = \tfrac{1}{2}(C_1 + C_2) V_{\text{final}}^2 = \tfrac{1}{2}(2C_1)(2\,\text{V})^2 = 4C_1\,\text{J}\) per farad. The energy initially stored was \(E_i = \tfrac{1}{2}C_1 V_1^2 + \tfrac{1}{2}C_2 V_2^2 = 4.5 C_1 + 0.5 C_1 = 5 C_1\,\text{J}\) per farad. The loss is \(E_i - E_f = C_1\), always a positive quantity — exactly half of the energy that the larger capacitor had above the average is dissipated as heat in the switch resistance, irrespective of the switch's on-resistance. This is the same unavoidable "charge-sharing loss" that Chapter 49 surfaced, here expressed in a more general setting.
Why switched-capacitor circuits are ubiquitous in CMOS
Switched-capacitor circuits are one of the most important analog building blocks in modern CMOS. Three reasons explain their dominance.
Capacitor ratios are precise. Two capacitors fabricated on the same die track each other within 0.1% across process, voltage, and temperature variation. Two resistors can differ by 20% or more. A circuit whose transfer function depends on a ratio of two elements therefore prefers capacitors.
Time constants are tunable. A continuous-time RC low-pass filter has a fixed time constant τ = RC. The SC equivalent realizes the same transfer function with a time constant τ_eff = (C1/C2) × T_clk, where T_clk is the clock period. Doubling the clock halves the time constant. This programmability is impossible in a passive RC.
No continuous current flows. Each capacitor is charged through a switch from a voltage source and discharged through another switch. The current is pulsed, not continuous. The circuit is naturally compatible with sampled-data and digital systems, and the average current draw can be made extremely small by operating at a low duty cycle.
The charge-redistribution SAR ADC is a switched-capacitor circuit in disguise. It uses a binary-weighted capacitor array to perform a binary search for the input voltage. Each cycle, one comparator decides one bit, and the capacitors are switched to refine the residue for the next bit. The same SC techniques that make filters work make this ADC work, and the same physical tradeoffs (capacitor matching, switch resistance, kT/C noise) limit both.
Part VI · Analog-to-Digital Conversion
51
The Capacitive Mixer
3 sections1 min readInteractive model
The resistive mixer of Part V combined signals by current addition. A capacitive mixer combines signals by charge sharing, which is advantageous in integrated circuits where precision capacitors are easier to fabricate than precision resistors.
Interactive lab
Switched capacitor
Adjust the model. Non-overlapping φ1 and φ2 phases show charge transfer.
51.1 N-channel capacitive mixer
Under two-phase switching:
Phase \(\phi_1\): input capacitors \(C_1, \dots, C_n\) are charged to \(V_1, \dots, V_n\); the load capacitor \(C\) is reset.
Phase \(\phi_2\): charge redistributes across all capacitors, yielding a weighted-sum output \(V_{\text{fin}}\).
51.2 Unity coefficient summation
To make the weighting coefficients sum to exactly 1 (\(\alpha_1 + \dots + \alpha_n = 1\)), the extra grounded load capacitor \(C\) must be zero (an open circuit), directly mimicking an open-circuit resistive divider.
51.3 Sample-and-hold requirement
Resistive mixers process continuous time-varying signals directly. Capacitive mixers require sample-and-hold operation: time-varying inputs must be sampled and held at discrete intervals, because charge transfer relies on static quasi-DC levels during each clock phase. This is the entry point into sampled-data analog signal processing.
Part VII · 6 chaptersCh 52–57
07
Digital Systems
Part VII · Digital Systems
52
The Laptop Teardown
3 sections2 min readInteractive model
Opening a Lenovo T420 traces how an analog signal is captured and stored as a digital file, by inspecting the laptop's internals.
Interactive lab
Memory pyramid
Adjust the model. Storage tiers are arranged by speed, size, and persistence.
52.1 Battery
A lithium-ion pack rated 4400 mAh, 48 Wh, 10.8 V DC — generous for its era but barely enough for a modern phone.
52.2 Heat from switching
Each charging/discharging capacitor dissipates a small amount of energy as heat (half the stored energy, per Chapter 49). A billion such events on a modern chip generate substantial heat, so active cooling (a 5 V fan) is fundamental.
52.3 The motherboard and memory hierarchy
The motherboard is the large board everything plugs into. It carries:
DRAM in DIMM (Dual Inline Memory Module) form: each DRAM cell is a capacitor storing a voltage — high (\(V_{DD}\)) is a logic 1, low is a logic 0. The charge leaks, so DRAM must be refreshed often enough. A bit is a single storage element holding either a logic 1 or a logic 0.
SRAM (static RAM): sits inside the processor, faster but less dense.
A hard disk (320 GB, 5400 RPM): stores data on concentric tracks read by a head sweeping a rotating platter. Mechanical motion makes it slow and fragile, which is why SSDs (solid-state drives, no moving parts, limited only by how fast a small capacitor can charge) are far faster.
An ADC near the audio jack (hard to spot) — the bridge from the analog microphone signal to digital data.
Memory is organized as a hierarchy by access time:
Level
Size
Access time
L1/L2 cache (on-chip)
~128 bytes
~30 ns
DRAM
4 GB
~100 ns
Hard disk
320 GB
~10 ms
The microprocessor must manage what sits where, moving data up the hierarchy as needed. Flip-chip packaging mounts a chip by flipping it over and connecting its ball array directly to the board.
Part VII · Digital Systems
53
The Binary Number System
2 sections1 min readInteractive model
How are discrete quantized numbers represented inside a computer?
Interactive lab
Binary explorer
Adjust the model. Positional weights and the current binary word are printed.
53.1 The weighing-balance puzzle
To weigh any integer mass from 0 to 15 using the minimum set of block weights, the optimal choice is the powers of two: \(1, 2, 4, 8\). Any integer \(0\) to \(15\) is a unique sum of a subset — this is the essence of binary representation.
A physical analogy: placing equal 1 kg weights at lever-arm positions \(X, 2X, 4X, 8X\) creates binary positional weighting through torque moments. Identical weights at geometrically spaced distances produce distinct, combinable contributions.
53.2 Positional base-2
The binary number system is the positional base-2 system. Each bit is a binary digit taking one of two values, 0 or 1. The value of an \(N\)-bit binary number is
where \(b_k \in \{0,1\}\). Electrical engineers index bit positions from zero because \(2^0\) corresponds to the least significant bit.
Part VII · Digital Systems
54
Decimal-to-Binary Conversion and ADC Resolution
4 sections1 min readInteractive model
54.1 Binary search
Interactive lab
Binary explorer
Adjust the model. Positional weights and the current binary word are printed.
Converting a decimal value to binary is a binary search: find the largest power of two that fits, subtract, and repeat — this mirrors the algorithm for determining an unknown weight with minimal weighings using the \(8, 4, 2, 1\) set.
54.2 Bit groupings
Computer architecture organizes bits into standard groups:
8 bits = 1 byte
16 bits = 1 word
32 bits = 1 dword (double word)
64 bits
54.3 The range of an \(n\)-bit integer
An \(n\)-bit binary integer ranges from \(0\) to \(2^n - 1\) (geometric series sum: \(1 + 2 + \dots + 2^{n-1} = 2^n - 1\)).
54.4 ADC quantization levels
ADC quantization levels are naturally chosen as powers of two (\(2^n\)) so that each level maps directly to an \(n\)-bit binary representation. An 8-bit ADC has \(2^8 = 256\) levels; a 16-bit ADC has \(2^{16} = 65536\) levels.
Part VII · Digital Systems
55
Calculating Digital Audio File Size
2 sections1 min readInteractive model
For an uncompressed PCM WAV file, the data payload size is
Interactive lab
File size calculator
Adjust the model. Duration × sample rate × bit depth becomes a byte count.
an exceptionally close match, with the tiny excess attributable to the standard 44-byte WAV header metadata.
This direct calculation applies only to uncompressed PCM. Lossy formats like MP3 apply encoding algorithms that alter the file size, so the formula does not apply.
55.2 The data path during playback
Binary sample data moves through the memory hierarchy during playback and editing: from hard drive storage, to DRAM, to cache, to the processor, and back. The hierarchy exists precisely because no single memory technology is simultaneously fast, large, and cheap.
Part VII · Digital Systems
56
Analog versus Digital Computing
3 sections1 min read
56.1 The analog compute chain
A pure analog resistive mixer computes the average of two inputs in real time:
Moving the mixing computation into the digital computer decouples the channels: each input can be digitized individually via switches, stored separately in memory, filtered, equalized, and manipulated independently before being mixed and replayed. This is a qualitative advantage over the continuous analog mixer, where all channels are processed simultaneously and cannot be independently edited after the fact.
56.3 Quantization error in the digital chain
A concrete example with \(V_1 = 471\,\text{mV}\), \(V_2 = 343\,\text{mV}\) on a 3-bit (8-level) ADC: digitizing the analog sum \((471+343)/2 = 407\,\text{mV}\) first, then quantizing, gives a slightly different result than quantizing \(V_1\) and \(V_2\) separately and then averaging the integers — because the quantization step boundaries fall at different places. Increasing the ADC resolution to 8-bit or 16-bit minimizes this discrepancy.
Part VII · Digital Systems
57
Digital Compute Blocks and Noise Immunity
2 sections1 min readInteractive model
57.1 The compute engine
Interactive lab
Noise immunity
Adjust the model. Logic thresholds make the noise margin explicit.
A digital system fetches numerical operands from memory into a compute engine containing distinct hardware blocks — adders, subtractors, multipliers. A high-level C operation like c = a + b; compiles to machine instructions (mov, add, sub, imul, idiv) that trigger these physical hardware blocks.
57.2 Noise immunity
Digital signals have far superior noise immunity over analog storage (e.g. magnetic cassette tape). A binary logic state is represented by a large voltage margin (e.g. 0 V for logic 0, 5 V for logic 1), so small millivolt-level noise fluctuations cannot easily corrupt the state. An analog signal of, say, 343 mV corrupted by 10 mV of noise becomes 353 mV — a real distortion. A digital 5 V corrupted by 10 mV is still unambiguously logic 1. This margin is the fundamental reason digital systems preserve data integrity across storage and transfer.
Part VIII · 8 chaptersCh 58–65
08
Wired and Wireless Communication
Part VIII · Wired and Wireless Communication
58
Wired Communication — The Experiment
3 sections2 min read
58.1 The experimental setup
Transmit binary serial data over a multi-meter telephone cable using square-wave voltage signals. The setup is a transmitter, a long cable, and a receiver. The transmitter is a function generator or a microcontroller GPIO pin that swings between 0 V and 3.3 V (or 5 V) at a controllable frequency. The cable is the physical medium — a twisted-pair telephone cable a few meters long, with the characteristic that any long wire has distributed resistance, capacitance, and inductance along its length. The receiver is an oscilloscope probing the far end of the cable, observing the waveform that arrives after the wire has done its work on the signal.
The square wave is the diagnostic signal of choice because it contains an infinite Fourier series of harmonics. A perfect 1 kHz square wave has significant spectral content at 1, 3, 5, 7, … kHz with amplitudes falling as \(1/n\). The received waveform therefore tells us, frequency by frequency, how the cable treats each component.
58.2 Observations
Low-frequency signals pass with minimal distortion. A 1 kHz square wave on a 5 m cable looks almost identical at the receiver end to the transmitter.
High-frequency signals (100 kHz to 1 MHz) suffer severe non-idealities: ringing (damped sinusoidal oscillations on the rising and falling edges), overshoot beyond the power rails, and waveform degradation. A 1 MHz square wave emerges at the receiver as a damped oscillation that bears little resemblance to the original.
These dynamics are not predicted by the first-order RC model studied so far. A single RC low-pass filter produces a smooth exponential rise and fall — it cannot oscillate. The cable's behavior is qualitatively different; it must be modeled with second-order dynamics at minimum.
58.3 The bandwidth constraint
The physical characteristics and length of the wire impose a maximum frequency (and therefore a maximum data rate) for readable communication. A digital signal can be transmitted without inter-symbol interference only if its spectrum fits inside the cable's passband. For a square wave of fundamental frequency \(f\), the significant harmonics extend to roughly \(5f\) to \(10f\) (5th to 10th harmonic). A cable that passes 10 MHz cleanly can transmit a 1 MHz square wave (highest data rate one might call out without distortion); a cable that passes only 100 kHz can transmit at most a 10 kHz square wave.
This is the bandwidth constraint of wired communication, and it is the physical reason that early Ethernet (10BASE-T) ran at 10 Mb/s over twisted-pair cable, while modern 10GBASE-T runs at 10 Gb/s but requires tight manufacturing tolerances, careful impedance matching, and short cable runs. The cable has not become faster; the engineering has learned to fit more bits into the same bandwidth by using more sophisticated modulation (PAM-16, error correction).
Part VIII · Wired and Wireless Communication
59
Inductive Ringing and the RLC Wire Model
3 sections3 min readInteractive model
59.1 Why RC is not enough
Interactive lab
RLC ringing
Adjust the model. Damping regime, R, L, C, and the resulting waveform are labelled.
A long wire cannot be modeled purely as a short circuit or as an RC low-pass filter. Coiling and distance introduce parasitic self-inductance, requiring an RLC equivalent model.
59.2 Energy interchange and ringing
With both inductive storage (\(\tfrac{1}{2} L i^2\), magnetic field) and capacitive storage (\(\tfrac{1}{2} C v^2\), electric field), energy can oscillate back and forth between the two fields. This exchange is the physical origin of the sinusoidal ringing observed on the oscilloscope.
59.3 The damped second-order equation
The RLC system yields a second-order differential equation whose generic response combines exponential decay (due to resistive energy dissipation) with sinusoidal oscillation (due to L–C energy exchange). For a series RLC driven by a step input, KVL gives
In the ideal lossless limit (\(R = 0\)), the oscillation is undamped and persists forever. In a real wire, resistance damps the oscillation, causing the observed decaying ringing.
The damping behavior falls into three regimes, distinguished by the discriminant\(R^2 - 4L/C\) (equivalently, by comparing \(R\) to \(2\sqrt{L/C}\)):
Underdamped (\(R < 2\sqrt{L/C}\)): the response is a damped sinusoid $\( V_C(t) \;=\; V_{\infty} + e^{-\alpha t}\bigl(A\cos\omega_d t + B\sin\omega_d t\bigr), \qquad \alpha = \frac{R}{2L}, \quad \omega_d = \sqrt{\tfrac{1}{LC} - \alpha^2}. \)\( The oscillation frequency \)\omega_d\( is slightly below the natural resonance \)\omega_0 = 1/\sqrt{LC}\(, and the envelope decays exponentially with time constant \)1/\alpha = 2L/R$. This is the regime that produces the visible ringing on the oscilloscope: each overshoot is smaller than the previous one by the same fractional factor.
Critically damped (\(R = 2\sqrt{L/C}\)): \(\omega_d = 0\) and the response becomes the fastest non-oscillatory return to the final value, $\( V_C(t) \;=\; V_{\infty} + (A + B t)\,e^{-\alpha t}. \)$ No ringing — the system reaches steady state in the minimum time without overshooting.
Overdamped (\(R > 2\sqrt{L/C}\)): the discriminant becomes positive, the frequency \(\omega_d\) becomes imaginary, and the response is a sum of two real exponentials, both decaying but at different rates: $\( V_C(t) \;=\; V_{\infty} + A\,e^{s_1 t} + B\,e^{s_2 t}, \qquad s_{1,2} = -\alpha \pm \sqrt{\alpha^2 - \tfrac{1}{LC}}. \)$ The system returns to steady state without oscillation but more slowly than in the critical case.
The ringing observed on the wire places it firmly in the underdamped regime — exactly the regime that makes RLC behavior qualitatively different from RC. Critically damped is the design target when speed and absence of overshoot are both required (galvanometers, control systems); underdamped is unavoidable in low-loss transmission lines and is the source of the signal-integrity problem called ringing.
Part VIII · Wired and Wireless Communication
60
Serial versus Parallel Communication
3 sections1 min readInteractive model
60.1 The trade-off
Interactive lab
Serial versus parallel
Adjust the model. Wire count, timing, and skew trade-offs are labelled.
Serial transmission sends bits one after another over a single conductor pair. It minimizes wire count but increases total time linearly with the number of messages.
Parallel transmission uses multiple dedicated line pairs operating concurrently, reducing latency at the cost of high physical complexity (wire volume, connector size, skew management).
60.2 Sampling at the right instant
To decode bits in the presence of ringing, the receiver must wait for oscillations to decay and then sample at the center of the bit period (\(T/2\)) relative to a \(V_{DD}/2\) threshold — the point most robust to timing jitter and residual ringing.
60.3 Shared-channel interference
Attempting to multiplex unstructured signals with different bit periods onto a single channel causes wave summation and garbled data — like several people shouting at once. This motivates the need for coordinated modulation and, when scaling interconnects, for wireless methods.
Part VIII · Wired and Wireless Communication
61
The Radio and the Antenna
4 sections1 min readInteractive model
Radio is the oldest (~100+ years) form of wireless signaling, credited to Marconi and Jagdish Chandra Bose.
Interactive lab
Antenna explorer
Adjust the model. λ = c/f and near/far-field regions are labelled.
61.1 Modulation as the core idea
Information is transmitted by modulating one of three parameters of a sinusoidal carrier\(c(t) = a\sin(2\pi f t + \theta)\) (the symbol \(m(t)\) is reserved for the message signal in Chapters 63 and elsewhere):
Amplitude → Amplitude Modulation (AM)
Frequency → Frequency Modulation (FM)
Phase → Phase Modulation (PM)
The 'M' in AM and FM stands for modulation.
61.2 Broadcast bands
AM: ~530–1600 kHz
FM: ~87–108 MHz
Shortwave: ~2.8–10 MHz
Tuning selects a specific carrier frequency to receive a particular station. Radio is one-way (broadcast) communication: a station transmits, many receivers listen.
61.3 Range and propagation
Reception range depends on transmitted power and propagation mode:
Shortwave signals reflect off ionospheric layers, reaching far beyond line of sight (e.g. Sri Lanka from Chennai). Wavelength is inversely related to frequency, so low-frequency AM has long wavelengths (~300 m) and 10 MHz shortwave has shorter wavelengths.
FM does not reflect off the ionosphere, so it is limited to roughly line-of-sight distances (10–20 km). Taller broadcast towers extend the horizon by trigonometry (the tangent to the Earth's surface from the tower top), which is why radio stations use huge towers.
61.4 The antenna as transducer
The antenna is the transducer that converts voltages/currents into electromagnetic waves on the transmitter side and back to electrical signals on the receiver side. Common shapes include the yagi (TV), horn, and parabolic dish (satellite TV), each shaped for a specific frequency and directivity.
Part VIII · Wired and Wireless Communication
62
Modulation: AM, FM, and PM
2 sections1 min readInteractive model
Wireless systems use transmitters and receivers to send information through free space as electromagnetic waves, with no physical connection.
Interactive lab
Modulation explorer
Adjust the model. Message, carrier, and modulated output are labelled.
62.1 The shared-medium problem
Free space is a shared transmission medium: simultaneous transmissions overlap and interfere. To resolve this, each user is assigned a distinct carrier frequency, and receivers select the desired signal using tuned band-pass filters.
62.2 The three modulation schemes
Information is encoded onto a sinusoidal carrier by modulating one (or a combination) of its three parameters:
Amplitude Modulation (AM): vary the amplitude \(a(t)\) with the message.
Frequency Modulation (FM): vary the frequency \(f(t)\) with the message, keeping amplitude constant.
Phase Modulation (PM): vary the phase \(\theta(t)\) with the message.
Part VIII · Wired and Wireless Communication
63
Amplitude Modulation and Demodulation
3 sections2 min readInteractive model
63.1 AM as multiplication
Interactive lab
Modulation explorer
Adjust the model. Message, carrier, and modulated output are labelled.
AM is the multiplication of a message signal \(M(t)\) by a high-frequency carrier \(\sin(2\pi f_c t)\):
This shifts the message to the carrier frequency band, enabling wireless transmission and frequency-division multiplexing.
63.2 On-off keying (OOK)
The simplest digital AM is on-off keying: transmit the sinusoidal carrier for a binary '1' and transmit nothing for a binary '0', over a bit duration \(T\).
63.3 Demodulation by mixing and low-pass filtering
At the receiver, the message is recovered by:
Mixing: multiply the incoming signal by a local copy of the carrier oscillator (same frequency and phase).
Low-pass filtering: pass the result through a low-pass filter that acts as a time-averaging integrator.
The algebra is the explicit application of a product-to-sum identity. The incoming AM signal is
and the local oscillator produces \(\sin(2\pi f_c t)\) at the receiver (assuming the receiver has recovered the carrier frequency and phase). Multiplying gives
This expression has two parts: a baseband term\(\tfrac{1}{2}M(t)\) centered at DC (low frequency, containing the original message), and a high-frequency term\(\tfrac{1}{2}M(t)\cos(2 \cdot 2\pi f_c t)\) at twice the carrier frequency \(2f_c\), modulated by the message. A low-pass filter with cutoff well below \(2f_c\) removes the second term (since \(M(t)\) varies slowly compared with \(\cos(4\pi f_c t)\), the entire second term sits at frequencies around \(2f_c\)) and passes the baseband term. The output is
recovering the original message up to a constant factor of \(1/2\). The factor is unimportant because downstream amplification can compensate it. The entire process relies directly on high-school trigonometry and selective frequency tuning.
Part VIII · Wired and Wireless Communication
64
Frequency Modulation and FSK
3 sections1 min readInteractive model
64.1 FM keeps amplitude constant
Interactive lab
Modulation explorer
Adjust the model. Message, carrier, and modulated output are labelled.
Unlike AM, FM encodes information only in the frequency, keeping the amplitude constant. In a binary digital system, logical 0 and logical 1 are encoded using two distinct frequencies \(F_1\) and \(F_2\), both chosen to be much larger than the bit rate.
64.2 Frequency Shift Keying (FSK)
The digital variant of FM is Frequency Shift Keying (FSK): assign \(F_1\) to binary 0 and \(F_2\) to binary 1. The baseband FSK signal is then modulated onto a high-frequency RF carrier for transmission.
64.3 The AM/FM trade-off
AM hardware is simple and cheap to build (basic filters and multipliers suffice for demodulation).
FM requires more complex demodulators but is more robust to amplitude noise and to signal fading, because the information is carried in the frequency (or phase) rather than the amplitude. As a result, FM delivers higher fidelity for voice and audio in noisy or fading channels, occupying a wider bandwidth in exchange.
Part VIII · Wired and Wireless Communication
65
Antenna Scaling and Near versus Far Field
3 sections3 min readInteractive model
65.1 Wavelength and propagation
Interactive lab
Antenna explorer
Adjust the model. λ = c/f and near/far-field regions are labelled.
Wavelength is \(\lambda = c/f\). Lower frequencies have longer wavelengths:
AM (~1 MHz): \(\lambda \approx 300\) m — diffracts around buildings and other obstacles; long wavelength is the dominant reason it propagates well.
FM (~100 MHz): \(\lambda \approx 3\) m.
Wi-Fi (~3 GHz): \(\lambda \approx 0.1\) m — does not diffract effectively around walls; degrades rapidly across room barriers.
Skin depth is the distance into a conducting material at which an electromagnetic wave's amplitude has fallen by a factor of \(1/e\) (about 37%). It is a measure of how deeply a wave of a given frequency penetrates a metal. Skin depth decreases as frequency increases: at low frequencies a wave reaches far into the material; at high frequencies the energy is confined to a thin surface layer. Skin depth also determines the effective cross-section of a conductor at high frequencies — a copper wire at gigahertz frequencies carries current only in a thin outer shell and behaves as if it were a hollow tube. Skin depth is a property of penetration into a metal, not into building materials; obstacles like walls are governed by diffraction (for wavelengths comparable to the obstacle) and by the wall material's dielectric loss, not by skin depth.
65.2 Antenna size scales with wavelength
Physical antenna dimension is proportional to wavelength (typically \(\sim\lambda/2\)). Higher frequencies allow much smaller antennas, which is why miniaturized devices (phones, wearables) require higher-frequency operation.
65.3 Near-field inductive coupling versus far-field radiation
A benchtop experiment with loop antennas driven by a function generator reveals two regimes:
Near-field inductive coupling: at close spacing or lower frequencies (~1 MHz), the dominant interaction is magnetic flux linkage between the coils — this is the principle of NFC (Near Field Communication).
Far-field radiative propagation: at larger spacings or higher frequencies (10–25 MHz), the true radiative transmission component dominates and becomes more efficient as frequency increases.
Two different boundaries matter here. The reactive near-field region extends out to roughly \(\lambda/(2\pi)\) from the antenna; within this distance, electric and magnetic fields are largely decoupled and stored energy dominates over radiated energy. Beyond \(\lambda/(2\pi)\) but still close to the antenna lies the radiating near-field (Fresnel) region. The far-field (Fraunhofer) region begins at the Fraunhofer distance
where \(D\) is the largest physical dimension of the antenna (or aperture) and \(\lambda\) is the wavelength. Distances \(d > d_F\) are "far field", where the electric and magnetic fields are perpendicular to each other and to the direction of propagation, and the wave's intensity falls off as \(1/d^2\). This is a practical rule of thumb rather than a sharp physical boundary — the actual transition is gradual — but it captures the right scale. For a loop antenna of diameter \(D \approx 0.3\,\text{m}\) at \(f = 1\,\text{MHz}\) (\(\lambda = 300\,\text{m}\)),
so the far-field region begins only a fraction of a millimeter from the loop at this frequency. The benchtop experiment with coil spacings of many centimeters and frequencies up to 25 MHz moves the Fraunhofer distance to much larger values (a few tens of centimeters), so both the reactive near-field and the far-field can be observed in a single setup.
Part IX · 8 chaptersCh 66–73
09
Integrated Problem Solving and Systems Thinking
Part IX · Integrated Problem Solving and Systems Thinking
66
Energy Distribution in the RC Step
2 sections1 min readInteractive model
A first-principles derivation of where the energy goes when a step voltage charges an RC circuit.
Interactive lab
Energy ledger
Adjust the model. Input, stored, and dissipated energy are shown with labelled totals.
66.1 Setup
A voltage source \(V_{DD}\) steps at \(t = 0\), charging a capacitor \(C\) through a resistor \(R\) from an initial \(V_C(0^-) = 0\).
The capacitor charges according to \(V_C(t) = V_{DD}(1 - e^{-t/RC})\) (Chapter 39), and the series current is
Exactly half the source energy is stored in the capacitor, and exactly half is dissipated as heat in the resistor — and the dissipated energy is independent of \(R\). A smaller \(R\) gives a larger peak current over a shorter time constant; a larger \(R\) gives a smaller current over a longer time constant; the time integral is identical. An alternative derivation substituting \(i\,dt = C\,dV_C\) confirms the result concisely.
Part IX · Integrated Problem Solving and Systems Thinking
67
Current-Source-Driven Capacitors
3 sections1 min readInteractive model
67.1 Linear, not exponential
Interactive lab
RC response
Adjust the model. The curve marks τ and prints R, C, and the response formula.
Driving a capacitor with a constant current source\(I_0\) produces a linear voltage change, not the exponential of the voltage-source+resistor case. From KCL:
This is in contrast to the exponential RC discharge, which only asymptotically reaches zero.
67.3 Practical limits
In ideal theory, linear charging continues to infinity. Real systems are constrained by the capacitor's voltage breakdown rating and the current source's compliance limit (the maximum voltage it can sustain while delivering the rated current).
Part IX · Integrated Problem Solving and Systems Thinking
68
Current, Resistor, and Capacitor Combinations
2 sections1 min read
68.1 Source invariance rules
Two fundamental properties simplify analysis:
Series with a current source: inserting a resistor in series with an ideal current source does not change the governing differential equation or voltage behavior of the attached network — the current through all series components is fixed by the source.
Parallel with a voltage source: connecting a resistor in parallel with an ideal voltage source does not change the voltage across the remaining network — only extra energy is dissipated in the parallel resistor.
68.2 Parallel resistor clamps the capacitor voltage
Adding a resistor \(R\) in parallel across a capacitor driven by a constant current \(I_0\) gives a first-order linear ODE whose solution is
\[V_C(t) \;=\; -I_0 R + (V_{DD} + I_0 R)\,e^{-t/RC}.\](68.1)
As \(t \to \infty\), the capacitor acts as an open circuit (DC steady state), all source current flows through the resistor, and the voltage clamps at
a finite steady-state value. The parallel resistor prevents unbounded voltage growth.
Part IX · Integrated Problem Solving and Systems Thinking
69
Switched-Capacitor Energy Transfer
3 sections1 min readInteractive model
A switched-capacitor circuit combines a DC voltage source \(V_{DD}\), series resistor \(R\), capacitor \(C\), non-overlapping switches \(S_1, S_2\), and a constant current sink \(I_0\).
Interactive lab
Switched capacitor
Adjust the model. Non-overlapping φ1 and φ2 phases show charge transfer.
69.1 Phase 1 — charge
\(S_1\) closed, \(S_2\) open, for duration \(T_1 \gg RC\). The capacitor charges exponentially to \(V_{DD}\). The source delivers \(C\,V_{DD}^2\); half is dissipated in \(R\) and half is stored in \(C\).
69.2 Phase 2 — discharge
\(S_1\) open, \(S_2\) closed. The capacitor discharges linearly through \(I_0\). Setting
brings the capacitor voltage from \(V_{DD}\) exactly to zero. The current sink absorbs exactly the stored energy \(\tfrac{1}{2} C\,V_{DD}^2\) during each period.
69.3 The energy ledger
The energy delivered by \(V_{DD}\) during charging (\(C\,V_{DD}^2\)) is split evenly: half dissipated in \(R\) during charge, half transferred to the current sink during discharge. The substitution \(I_0\,dt = -C\,dV_C\) simplifies the energy integrals across arbitrary current/voltage waveforms. Non-overlapping control signals ensure the two switches are never closed simultaneously, avoiding unexpected direct paths between supply nodes.
Part IX · Integrated Problem Solving and Systems Thinking
70
The Zero-Resistance Limit and Radiation Loss
3 sections2 min read
70.1 The pathological case
Connect a constant voltage source \(V_{DD}\) directly to a capacitor with zero series resistance (\(R = 0\)) via an ideal switch. The time constant \(\tau = RC\) drops to zero, so \(V_C\) steps instantaneously to \(V_{DD}\) at \(t = 0\) with an infinite slope. Differentiating the voltage step yields an infinite current impulse at \(t = 0\).
70.2 The missing half of the energy
The source supplies \(C\,V_{DD}^2\). The capacitor stores \(\tfrac{1}{2} C\,V_{DD}^2\). Half is missing. In an ideal lumped circuit with no resistance to dissipate it as heat, the energy accounting is unresolved: the lumped model itself has broken down, because an infinite current derivative would require an infinitely fast change of electromagnetic field, which is unphysical. Stating that the missing energy is "radiated" is a hand-wave because a lumped circuit, by definition, has no radiation — radiation is a distributed-electromagnetic effect. The strict interpretation is that the \(R = 0\) idealization is an unphysical limit; the real answer requires going beyond the lumped model.
70.3 The real-world resolution
In real circuits, small non-zero wire and switch resistances dissipate this energy as heat due to the very high surge current. A more careful analysis that retains the wiring's small parasitic inductance and resistance (or treats the wiring as a transmission line) shows that the energy is shared between resistive dissipation and brief electromagnetic radiation from the fast transient — but this requires going beyond the idealized lumped RC model. The lesson is that the convenient \(R \to 0\) idealization has a hidden energy cost that must be paid by some non-ideality (resistance, and at high enough speeds, radiation). The simpler resolution in first-year analysis is that real \(R\) is never zero, and the half-energy result of Chapter 66 is the correct answer for any non-zero \(R\).
Part IX · Integrated Problem Solving and Systems Thinking
71
Periodic Waveform Generation by Switching
2 sections1 min readInteractive model
A DC voltage source \(V_{DD}\), resistor \(R\), capacitor \(C\), and a current sink \(I_0\) with controlled switching can generate periodic waveforms.
Interactive lab
Switched capacitor
Adjust the model. Non-overlapping φ1 and φ2 phases show charge transfer.
71.1 The shifted asymptote
The governing ODE (from KCL at the capacitor node) reveals that a constant current sink \(I_0\) in parallel shifts the steady-state charging asymptote from \(V_{DD}\) down to
Alternating between exponential charging and linear discharging generates a periodic triangular/sawtooth waveform with predictable period and amplitude. This is the principle behind many function-generator and oscillator circuits.
Part IX · Integrated Problem Solving and Systems Thinking
72
Two-Current-Source Switched-Capacitor Cycles
3 sections1 min readInteractive model
A switched-capacitor circuit driven by two independent current sources \(I_1\) and \(I_2\), active during non-overlapping intervals \(T_1\) and \(T_2\).
Interactive lab
Switched capacitor
Adjust the model. Non-overlapping φ1 and φ2 phases show charge transfer.
72.1 Charging ramp
During phase 1, \(I_1\) charges the capacitor from zero with a linear ramp of slope \(I_1/C\), reaching a peak
During phase 2, \(I_2\) discharges the capacitor back to zero with slope \(-I_2/C\). Applying the boundary condition \(V_C(T_1 + T_2) = 0\) gives the required discharge duration:
which is charge conservation: \(Q = I_1 T_1 = I_2 T_2\).
72.3 Energy transfer
The circuit acts as an energy transfer stage: energy is stored from \(I_1\) into \(C\) during phase 1, and released from \(C\) into \(I_2\) during phase 2. The asymmetric triangular voltage waveform allows exact geometric area calculation, which directly yields the energy transferred per cycle.
Part IX · Integrated Problem Solving and Systems Thinking
The course closes by reconvening its spine: every electronic system senses physical signals, computes on them (in analog or digital domains), and communicates or actuates the results. The laboratory experiments — phone and laptop teardowns, microphone sensing, ADC, filters, RF modulation — each illustrate one leg of this arc.
73.1 From time domain to frequency domain
The first-order time-domain analysis taught here gives intuition for reverse engineering, but designing complex higher-order systems requires tractable frequency-domain techniques — Laplace and Fourier transforms — covered in the courses that follow.
73.2 Two-port abstraction
A complex internal network can be abstracted into a two-port circuit characterized solely by a pair of input and output voltages and currents. This abstraction is the bridge from component-level analysis to system-level design.
73.3 Feedback and stability
Negative feedback maintains system performance and controls settling time (e.g. a climate-control system).
Positive feedback causes instability (e.g. the howl when a microphone gets too close to a speaker).
These concepts, and the operational amplifier (op-amp) as a general-purpose analog building block, are the subject of the next course in the program.
73.4 The road ahead
The foundational sequence that follows builds directly on this book:
Electrical and Electronic Circuits — the op-amp, transistor-level design.
Signals and Systems — Fourier and Laplace transforms, convolution, frequency response.
Control Systems / Sensing — feedback, stability, sensor interfaces.
Digital Systems — logic gates, registers, processors.
Digital Signal Processing (DSP) — real-time versus offline processing of sampled signals.
Electromagnetic Fields & Transmission Lines — at gigahertz frequencies, even short connections behave as transmission lines with distributed resistance, capacitance, and inductance, because the signal wavelength is comparable to the physical dimensions.
The recurring conceptual backbone of this book — KCL/KVL, \(V=IR\), \(P=VI\), capacitor/inductor relations, RC behavior, superposition, sampling and quantization — is precisely the toolkit the rest of the program formalizes and extends. The experiment-first, reverse-engineering habit of mind is the one thing that keeps that formalization grounded in physical reality.