• Practice
  • About 25 min
  • 5 practice questions

Transistor circuits and digital electronics: load line, switch, amplifier, oscillator, logic gates and Boolean algebra

Draw a DC load line and choose a Q point, explain the transistor as a switch, amplifier and oscillator, and use logic gates, Boolean laws and De Morgan's theorems.

If something looks wrong, please tell us.

By the end of this lesson you can

  • Draw the DC load line, find the operating point and relate it to amplifier and switch use.
  • Explain the transistor as a switch (NOT gate) and as a CE amplifier with 180° phase reversal.
  • Describe an LC oscillator, Barkhausen conditions and f = 1/2π√(LC).
  • Write truth tables and Boolean expressions for AND, OR, NOT, NAND, NOR and Ex-OR.
  • Simplify expressions with Boolean laws and prove De Morgan's theorems.

Knowing how a transistor behaves, we can put it to work: as an electronic switch, as an amplifier that makes a weak signal strong, and as an oscillator that turns DC into AC. Switches that are only ON or OFF lead naturally to digital electronics, where logic gates and Boolean algebra describe every computer.

DC load line and operating point

For an NPN transistor in CE mode with collector resistor R_C and supply V_CC, Kirchhoff's law for the output loop gives V_CE = V_CC − I_C R_C. This is a straight line on the output characteristics, the DC load line, joining A (V_CE = V_CC, I_C = 0) and B (V_CE = 0, I_C = V_CC/R_C). The point where the load line meets the curve for the chosen base current is the operating point or quiescent (Q) point. For an amplifier the Q point is placed near the middle of the load line, allowing the largest undistorted output swing. For an OFF switch it is placed in cut-off; for an ON switch, in saturation.

Transistor as a switch

With a low input (say 0 V), I_B = 0 and the transistor is cut off: I_C = 0, there is no drop across R_C and the output V₀ = V_CC − I_C R_C = V_CC is high. The transistor is an open switch (OFF). With a high input (say +5 V), I_B is large and the transistor saturates: I_C is maximum, almost all of V_CC drops across R_C, and the output is nearly zero. It is a closed switch (ON). A high input gives a low output and vice versa, so this circuit is an inverter, a NOT gate.

Transistor as a CE amplifier

A single-stage amplifier uses an NPN transistor in CE mode. Resistors R₁, R₂ and R_E set and stabilise the Q point near the middle of the load line. The input capacitor C₁ passes only the AC signal V_s to the base-emitter; the bypass capacitor C_E gives the amplified AC an easy path around R_E; the coupling capacitor C_C passes the output to the next stage. The output is taken across collector and emitter. In the positive half cycle of the input, the forward bias rises, I_B rises, I_C rises β times, the drop I_C R_C rises and V_CE = V_CC − I_C R_C falls. In the negative half cycle the opposite happens. So the output is an enlarged copy of the input, reversed in phase by 180°.

Transistor as an oscillator

An oscillator converts DC energy into AC, from a few hertz to many megahertz, without any input signal. Oscillations may be sinusoidal or non-sinusoidal (square, triangular, sawtooth), and damped (amplitude dies away) or undamped (constant amplitude). An oscillator has three parts: an LC tank circuit, in which energy passes back and forth between the inductor and the capacitor; an amplifier; and a feedback network that feeds part of the output back to the input. Resistance in the coils makes the tank's oscillations damped, so positive feedback (in phase with the input) is used to replace the lost energy. The frequency is f = 1/(2π√(LC)).

Barkhausen conditions for sustained oscillations: (1) the feedback must be positive; (2) the total phase shift round the loop must be 0° or a whole multiple of 2π; (3) the loop gain must be one, Aβ = 1, where A is the amplifier's voltage gain and β the feedback ratio. Common types include the Hartley, Colpitts, phase-shift and crystal oscillators. Uses: sinusoidal and non-sinusoidal waves for radio and TV, clock signals in digital circuits, and sweep circuits in TVs and CROs.

How an oscillator keeps going

  1. Tank circuit oscillates Energy swaps between L and C at f = 1/2π√(LC)
  2. Amplifier boosts the signal Transistor in active mode
  3. Positive feedback returns part of the output In phase, loop gain Aβ = 1
  4. Energy losses are replaced Oscillations stay undamped

Then back to step 1: Tank circuit oscillates

Analog and digital signals

An analog signal varies continuously with time; a digital signal has only discrete values, usually two: high (ON, 1) and low (OFF, 0). Digital signals are preferred for their accuracy, speed, flexibility and immunity to noise. With levels of 5 V and 0 V, positive logic takes 5 V as 1 and 0 V as 0; negative logic takes 0 V as 1 and 5 V as 0.

Logic gates

A logic gate is a circuit with one output and one or more binary inputs. AND, OR and NOT are the basic gates; NAND and NOR are universal gates (any other gate can be built from them alone); Ex-OR is a further useful gate. In this lesson a bar over a letter, A̅, means NOT A, and NOT(…) means the complement of a whole expression.

Truth table for the two-input gates (NOT simply turns 0 into 1 and 1 into 0)
ABAND A·BOR A + BNANDNOREx-OR
0000110
0101101
1001101
1111000
  • AND (logical multiplication, Y = A·B): output 1 only when all inputs are 1.
  • OR (logical addition, Y = A + B): output 1 when any input is 1.
  • NOT (inverter, Y = A̅): output is the complement of the input.
  • NAND = AND followed by NOT: output 0 only when all inputs are 1.
  • NOR = OR followed by NOT: output 1 only when all inputs are 0.
  • Ex-OR (Y = A·B̅ + A̅·B): output 1 when the inputs differ; with more inputs, 1 when an odd number of inputs are 1.

Boolean algebra and De Morgan's theorems

George Boole's algebra of two values (1854) became the language of switching circuits and computers. Its laws, for any variable A:

  • Complement laws: A·A̅ = 0, A + A̅ = 1, and NOT(A̅) = A.
  • OR laws: A + 0 = A, A + 1 = 1, A + A = A.
  • AND laws: A·0 = 0, A·1 = A, A·A = A.
  • Commutative: A + B = B + A, A·B = B·A. Associative: A + (B + C) = (A + B) + C, A·(B·C) = (A·B)·C. Distributive: A·(B + C) = A·B + A·C.

De Morgan's first theorem: the complement of a sum equals the product of the complements: NOT(A + B) = A̅·B̅. So a NOR gate equals an AND gate with inverted ('bubbled') inputs. De Morgan's second theorem: the complement of a product equals the sum of the complements: NOT(A·B) = A̅ + B̅. So a NAND gate equals a bubbled OR gate. Each is proved by comparing the truth tables of the two sides for all four input combinations.

De Morgan: NOT(A + B) = A̅·B̅ (NOR = bubbled AND); NOT(A·B) = A̅ + B̅ (NAND = bubbled OR).

Integrated circuits: an IC (chip) holds thousands to millions of transistors, resistors and capacitors on a small piece of semiconductor, normally silicon. ICs are cheap, fast and small; with Very Large Scale Integration (VLSI) ever more transistors fit on the same chip. Digital ICs use logic gates and work with 0s and 1s (computers, networks); analog (linear) ICs work with continuous values (audio and radio circuits).

Worked example 1: load line and Q point

In a CE circuit V_CC = 12 V, R_C = 2.0 kΩ, the base is fed from 3.0 V through R_B = 300 kΩ, β = 200, and V_BE is ignored. Step 1 (load line end points): I_C = 0 gives V_CE = 12 V; V_CE = 0 gives I_C = 12/2000 = 6.0 mA. Step 2: I_B = 3.0/(300 × 10³) = 10 μA. Step 3: I_C = βI_B = 200 × 10 μA = 2.0 mA. Step 4: V_CE = 12 − (2.0 × 10⁻³ × 2000) = 12 − 4.0 = 8.0 V. The Q point is (8.0 V, 2.0 mA), on the load line in the active region.

Worked example 2: oscillator capacitor range

An LC oscillator with L = 200 μH must cover 600 kHz to 1200 kHz. From f = 1/(2π√(LC)), C = 1/(4π²f²L). At 600 kHz: C = 1/(39.48 × (6.0 × 10⁵)² × 2.0 × 10⁻⁴) = 1/(39.48 × 3.6 × 10¹¹ × 2.0 × 10⁻⁴) = 1/(2.84 × 10⁹) = 3.52 × 10⁻¹⁰ F = 352 pF. At 1200 kHz: doubling f divides C by 4, giving 88 pF. The variable capacitor must range from about 88 pF to 352 pF.

Worked example 3: simplifying with Boolean laws

(a) Simplify Y = A·B + A·B̅. Distributive law: Y = A·(B + B̅) = A·1 = A. (b) Show that A + A·B = A. Y = A·1 + A·B = A·(1 + B) = A·1 = A (OR law: 1 + B = 1). (c) Find the output of NOT(A + B) for A = 1, B = 0: A + B = 1, so the NOR output is 0; by De Morgan, A̅·B̅ = 0·1 = 0 as well.

Key takeaways

  • Load line V_CE = V_CC − I_C R_C; Q point mid-line for amplifiers, cut-off/saturation for switches.
  • Switch: low in, high out, so the transistor is a NOT gate; CE amplifier output is 180° out of phase.
  • Oscillator = tank + amplifier + positive feedback, with Aβ = 1 and f = 1/2π√(LC).
  • AND, OR, NOT are basic; NAND and NOR are universal; Ex-OR gives 1 when inputs differ.
  • De Morgan: NOT(A + B) = A̅·B̅ and NOT(A·B) = A̅ + B̅.

Check your understanding

  1. 1. In a CE circuit V_CC = 10 V and R_C = 2.5 kΩ. The DC load line meets the I_C axis (V_CE = 0) at:

    1. 4.0 mA
    2. 25 mA
    3. 0.25 mA
    4. 10 mA
    Show answer

    Answer: A. At V_CE = 0, I_C = V_CC/R_C = 10/2500 = 4.0 × 10⁻³ A = 4.0 mA. The other end is at V_CE = 10 V, I_C = 0.

  2. 2. The phase difference between input and output voltages of a single-stage CE amplifier is:

    1. 0°
    2. 90°
    3. 180°
    4. 270°
    Show answer

    Answer: C. When the input rises, I_C rises, the drop I_C R_C rises and V_CE falls. The output therefore moves opposite to the input: a 180° phase reversal.

  3. 3. Which gate gives an output of 1 only when both inputs are 0?

    1. NAND
    2. Ex-OR
    3. AND
    4. NOR
    Show answer

    Answer: D. NOR is OR followed by NOT. OR is 0 only for inputs 0, 0, so NOR is 1 only for 0, 0.

  4. 4. By De Morgan's theorem, NOT(A·B) equals:

    1. A̅·B̅
    2. A̅ + B̅
    3. A + B
    4. A·B
    Show answer

    Answer: B. De Morgan's second theorem: the complement of a product is the sum of the complements, NOT(A·B) = A̅ + B̅. This is why a NAND gate equals a bubbled OR gate.

  5. 5. The Boolean expression A·(A + B) simplifies to:

    1. B
    2. A·B
    3. A
    4. 1
    Show answer

    Answer: C. A·(A + B) = A·A + A·B = A + A·B = A·(1 + B) = A·1 = A.

Privacy · Terms · Refunds · Delivery