Problem 14.1 - The Fourier Series of a Periodic Square Wave, Part 1
*
* Use the PWL function to describe a symmetric +/- 7-volt square wave
* to be used as the source voltage in the given circuit.
* NOTE: It is important (for mathematical reasons) that a waveform to
* be analyzed for its Fourier components have the same value at the
* start and end of the "window" over which the waveform is being
* observed. That is, if the square wave defined by the PWL function
* starts at zero at t=0, it must have a final value of zero at the end
* of the .TRAN analysis period. You may also start at +7 and end at +7
* or any other value, but the general rule must be observed.
* Draw on paper the PWL waveform described below, to check that the
* waveform is properly defined (it is to be symmetric about the
* middle of the window, also).
*
* Follow the extensive description and instructions in the problem
* statement for a good start in learning about the .FOUR function
* and the Fourier Transform analysis available under PROBE.
*
.OPT NOPAGE NOBIAS
V1 1 0 PWL(0,0,5E-7,7,499.5E-6,7,500.5E-6,-7,999.5E-6,-7,1E-3,0)
R1 1 0 1k
.TRAN ; Complete the .TRAN command for an
; analysis over the 1-millisecond
; period of the PWL function.
.FOUR 1000 V(1) ; Refer to the .FOUR command in Appendix B.
.PROBE
.END