A two-transistor amplifier should have a gain of 10. With R_F = 18 kΩ and R_1 = 2 kΩ it has 7.44. Design the feedback network that gives 10 ± 1 % with 20 kΩ of total resistance.
Circuit context: A two-transistor series-shunt pair on SKY130 (NMOS 4/0.5 with 60 kΩ, PMOS 30/0.5) whose input rests at 0.89 V. Design the feedback network that makes a real pair deliver the gain its resistor ratio promised.
A sensor front end uses the feedback pair of lesson E10.2 with different devices. The network below follows the rule 1 + R_F/R_1 = 10. The measured gain is 7.44.
You design only the network: the subcircuit fbnet, with R_F from out to fb and R_1 from fb to ground. The pair itself is fixed. Its input rests at 0.89 V.
The grader measures three things at the tt corner. The gain at 1 kHz must lie between 9.9 and 10.1. The network must measure 19.8 to 20.2 kΩ from out to ground. The output must rest between 0.9 and 1.4 V.
The network also carries the DC current of the second transistor. A new ratio therefore moves the operating point, and the loop gain with it.
What the Grader Measures
Your subcircuit fbnet (ports out, fb) under the grader's own bench, one run per corner (tt):
| Check | Corner | Rule |
|---|---|---|
| Closed-loop gain | tt | 9.9 to 10.1 |
| Total network resistance | tt | 19.8 kΩ to 20.2 kΩ |
| Output level | tt | 900 mV to 1.4 V |
Full specification
.subckt fbnet out fb
* resistors only: from out to fb, and from fb to ground (node 0)
.ends
| Check | Rule | How the grader measures it |
|---|---|---|
| Closed-loop gain | 9.9 to 10.1 | ac: |v(out)| at 1 kHz with AC 1 on the input |
| Total network resistance | 19.8 kΩ to 20.2 kΩ | a second copy of fbnet alone: 1 V on out, fb left open |
| Output level | 0.9 V to 1.4 V | op: v(out) |
The grader runs once, with .lib sky130 tt at 27 °C. The gain of this pair moves with the corner, so the 1 % window is a tt target.
Examples
Example 1
The Starter: The Ideal Ratio- Design
.subckt fbnet out fb * 1 + RF/R1 = 10 RF out fb 18k R1 fb 0 2k .ends
- Measured by the grader
Closed-loop gain: 7.445 (needs 9.9 to 10.1) Total network resistance: 20 kΩ (needs 19.8 kΩ to 20.2 kΩ) Output level: 849 mV (needs 900 mV to 1.4 V)
The total is right. The gain is 26 % low, and the output rests just under its window.
Example 2
The Ideal Ratio at 1 kΩ- Design
.subckt fbnet out fb RF out fb 900 R1 fb 0 100 .ends
- Measured by the grader
Closed-loop gain: 2.799 (needs 9.9 to 10.1) Total network resistance: 1 kΩ (needs 19.8 kΩ to 20.2 kΩ) Output level: 732.8 mV (needs 900 mV to 1.4 V)
A smaller network at the same ratio does not make the feedback stronger. It loads the second transistor, and the loop gain is gone.
Example 3
The Same Ratio at 200 kΩ- Design
.subckt fbnet out fb RF out fb 180k R1 fb 0 20k .ends
- Measured by the grader
Closed-loop gain: 0.6303 (needs 9.9 to 10.1) Total network resistance: 200 kΩ (needs 19.8 kΩ to 20.2 kΩ) Output level: 166.2 mV (needs 900 mV to 1.4 V)
The network also sets the DC current. At 200 kΩ the second transistor is nearly off and the stage does not amplify.
Constraints and Contract
- The netlist defines .subckt fbnet out fb ... .ends exactly once, with these ports in this order.
- Inside fbnet: resistors only, with comments and .param lines.
- Everything outside fbnet is replaced by the grader's bench.
Hints
Hint 1
Three effects lower the gain below 1 + R_F/R_1. Lesson E10.2 gives each a number for its own pair. Which of them does a different resistor ratio correct?
Hint 2
The source of M1 drives the transistor through g_m + g_mb. So the feedback is stronger than the divider ratio says, and you need a smaller R_1 than the ideal rule gives.
Hint 3
Print the operating point after each change. The currents move with R_1, so the loop gain moves too. Two or three trims on the bench reach 1 %.
What the grader checks: The grader places fbnet around its own two-transistor pair. It measures the gain at 1 kHz, the output level and the network's total resistance. It runs at tt and 27 °C only. Engine: ngspice 42 (libngspice0 42+ds-3build1) with the pinned SKY130 models, measured 2026-11-12 with tools/spice-judge.mjs. It does not check other corners, bandwidth or stability.
Run simulates your netlist as written, with your own analyses and measurements. Submit sends it to the grader, which keeps only the subcircuit fbnet and makes 1 ngspice run. The numbers come from ngspice and the SKY130 models the site pins; they prove the measured cases, not every condition a chip meets.
See all 1 steps and the final capstone