## Example of Using Berkeley SPICE with nanoHUB

### Frequency response of a common emittor amplifier

Consider the circuit shown below:
In which the components have the following values:
ComponentValue
VCC 15 V
VEE 15 V
Rin 1 kΩ
Cin 0.1 μF
Q1 2N3904
RB 10 kΩ
VB 2.5 V
RE 500 Ω
RC 4 kΩ
RL 10 kΩ
Cout 0.1 μF
The input to the amplifier is composed of the ideal AC voltage source Vin(t) with impedance Rin and the voltage source VB and RB provide a bias voltage for the transistor. An equivalent circuit could be constructed from a voltage divider between VCC and VEE. The capacitors Cin and Cout block the DC component of the input and output voltages, but limit the low-frequency response to be f-3 db=1/(2πRBCin)=160 Hz.

#### SPICE netlist

The SPICE netlist, including the model for the transistor is as follows:

The AC response analysis results in the following output:

The low frequency cutoff is actually seen to be f-3 db=200 Hz, which can be understood by considering the actual input impedance of the amplifier to be

Zin = (1/RB + 1/(β RE))-1 = 8.3 kΩ
which gives f-3 db(in)=1/(2π(Zin+Rin)Cin))=171 Hz and by considering the low-frequency response of the output: f-3 db(out)=1/(2π(RC+Rout)Cout)=113 Hz. The combination of high-pass filters at the input and the output is effectively a second-order filter, which results in the higher -3 db cutoff frequency found in the simulation.

### High frequency response

With these component values, the high frequency cutoff is found to be approximately f-3 db=6.6 MHz. Reducing RC will reduce the gain, but also increases the high frequency cutoff:
AV f-3 db
-5 6.6
-4 8.7
-3 11.5
-2 15.1
This effect is caused by the parasitic capacitance in the transistor junction between the collector and the base, which couples the amplified, but inverted, signal at the collector directly to the base, cancelling the input signal. The following modification to the circuit includes a second transistor in a "cascode" configuration:
The second transistor shields the base of Q1 from the amplified signal. The netlist for this circuit gives the following frequency response:

and has the following dependence on the gain of the amplifier.

AV f-3 db
-5 14.5
-4 20.0
-3 26.3
-2 34.1