UNIVERSITY of PENNSYLVANIA

DEPARTMENT OF ELECTRICAL ENGINEERING

SPICE simulation of an ideal transformers

An ideal transformer can be simulated using mutually coupled inductors. An ideal transformer has a coupling coefficient k=1 and very large inductances. However, Spice does not allow a coupling coefficient of k=1. The ideal transformer can be simulated in Spice by making k close to one, and the inductors L1 and L2 very large, such that wL1 and wL2 is much larger than the resistors in series with the inductors. The secondary circuit needs a DC connection to ground. This can be accomplished by adding a large resistor to ground or giving the primary and secondary circuits a common node.

The following example illustrates how to simulate a transformer.

For the above example, lets make wL2 >> 500 Ohm or L2> 500/(60*2pi) ; lets make L2 at least 10 times larger, ex. L2=20H. L1 can than be found from the turn ratio: L1/L2 = (N1/N2)^2. For a turn ratio of 10 this makes L1=L2x100=2000H. We make K close to 1 lets say 0.99999.

A Spice input listing is given below for the following circuit.

Example transformer
VIN 2 0 SIN(0 170 60 0 0)
* This defines a sinusoid of 170 V amplitude and 60 Hz. RS 2 1 10
L1 1 0 2000
L2 3 0 20
K L1 L2 0.99999
RL 3 0 500
.TRAN 0.2M 25M
.PLOT TRAN V(2)
.PLOT TRAN V(3)
.END

Jan Van der Spiegel;
jan@ee.upenn.edu
Created Sept. 30, 1995; Updated Aug. 1, 1995