generating bode plots - virginia techliab/matlab/generating bode plots.pdf · bode plots •the...

17
Generating Bode Plots In PSpice and using your oscilloscope

Upload: tranlien

Post on 29-Apr-2018

226 views

Category:

Documents


3 download

TRANSCRIPT

Generating Bode Plots

In PSpice and using your oscilloscope

Bode Plots

• The magnitude of a signal as a function of frequency is the plot generated during an AC Sweep. – Note that the voltage source must be changed from

Vsin to Vac. • The magnitude is typically changed to dB where:

• Phase angles as a function of frequency will be plotted in PSpice during an AC Sweep.

• P() marco will display the phase angle of the parameter inserted [e.g., V(R2:2)]

ref

signal

V

VdB log20

To Change to dB

• If your reference signal is 1V, you can double-click on the label for the curve, select DB() from the list of macros on the right of the pop-up window, and then type in the name of the signal that you would like plotted in dB.

Example

1. Double click on the label (boxed in green). 2. Select DB from the list of Functions or Macros 3. Type the name of the signal in the parenthesis in the Trace Expression. 4. Click OK.

If the reference is not 1V or 1A

The signal should be divided by the reference signal in the Trace Expression. You can also add additional curves to be plotted. Plotting a line at -3dB may help when determining the corner frequency. This can be done using the Add Trace option under Trace toolbar.

To Plot Phase Angle vs. Frequency

Add a Trace to the New Plot

Select P() in the List of Functions or Macros

Select Voltage or Current from the List of Simulation Output Variables

• It will appear within the paraphrases as the argument of the phase function. You can add multiple traces at once by putting a comma between each on the list at the bottom of the pop-up window. Then, click OK.

To Change the x axis to Log(f)

Phase Angle in Degrees Vs. Frequency

The angle in phasor notation should be between -180o to +180o.

Phase Angle Measurement

• Two techniques using the Velleman scope – Waveform Parameters

• Measurement of relative phase to internal reference at the operating frequency of the arbitrary function generator.

– Bode Plotter • Measurement of the phase of the signal on Channel 1

with respect to the signal on Channel 2 over a frequency range specified by the user.

– Follow the instructions to make sure that the appropriate signal is used as the reference signal.

Waveform Parameters

Bode Plot

Select Phase Plot from View menu after having set the Frequency Range, Frequency Start, and other measurement parameters and then click Start to obtain the phase measurement.

Y-Axis Scale

The magnitude of the signal can be plotted in Volts or in dB by selecting the appropriate Vertical Scale

Plot of Phase Angle

To plot the phase angle at the same time that a plot of the magnitude is displayed, select Phase Plot from the View toolbar on the Bode Plotter.

Bode Plot

The solid line is the magnitude and the dashed line is the phase angle.