Overview¶
Introduction¶
We will continue using a FeelTech FY3200S signal generator and a Tektronix TBS 1072B-EDU digital oscilloscope to measure the waveforms connected to series resistor and capacitor circuits.
Part 1 of this lab is to measure and compare peak-to-peak and rms voltages. The peak-to-peak voltage is the actual amplitude of an alternating signal between the highest peak to the lowest peak. Diagrams of three waveforms (sine, square, and triangle) are shown in Figure 1. The period and peak-to-peak voltage are labeled.
Figure 1:A (a) sine wave, (b) square wave, and (c) triangle wave form. The rms voltages are for the sine waveform, for the square waveform, and for the triangle waveform.
Part 2 of this lab is to measure the response or output of series resistor and capacitor (RC) circuits when given DC or AC input.
Experiment¶
Part 1 Theory of RMS Voltage¶
Periodic voltages without DC voltage contribution such as sine-, square- or triangular- wave voltages, see Fig. 2, are characterized by the period T, frequency f = 1/T, amplitude V, peak-to-peak value Vpp = 2V, and rms value Vrms. The rms value corresponds to the value of a DC voltage which – at a given electrical resistance – leads to the same dissipated power as the AC voltage. The rms voltage can be calculated by averaging the square of the AC voltage, V(t):
where is the average of the voltage squared. Evaluation of this integral leads to different effective values for the voltage-time characteristics as shown in Figure 1.
Part 1 Measurements¶
Create each of these signals as with the signal generator such that they are Volts for a frequency of Hz. Connect a BNC to alligator clips cable to the signal generator. Measure the rms voltage using a multimeter set to AC Volts. Connect a BNC to BNC cable so that you can measure the signal on the oscilloscope. Adjust your oscilloscope such that you see approximately 2 periods of the wave. Repeat these activities for 100 Hz. You should include estimated uncertainties.
Table 1:Comparison of peak-to-peak and rms voltages at 1 kHz and 100 Hz.
Signal Wave | RMS Voltage | Peak-to-peak Voltage |
---|---|---|
Sine | ||
Square | ||
Triangle |
Part 2a Theory of RC Circuits¶
A series circuit consists of a resistance, , and a capacitor, . Draw the circuit in your lab notebook including the AC input square wave. At seconds a square voltage is applied to this circuit, such that a current flows. This current charges the capacitor. The voltage across the capacitor is measured over time and shows an increasing voltage with time from a value of zero approaching the applied voltage, , of the square wave. According to Kirchhoff’s loop rules, the sum of the voltages across the capacitor and resistor must add to the applied voltage. The voltage on the capacitor has the form , and the resistor voltage is . Summing them gives
The current is the amount of charge flowing through the circuit per unit time, . Replace the current in the above equation to obtain a differential equation of . This leads to a linear, non-homogeneous differential equation of first order:
Solve this to obtain the time-dependent charging on the capacitor that can be converted to voltage on the capacitor
Follow similar logic for discharging when the square wave goes to zero () to obtain
This result implies that there is a characteristic time for charging and discharging. This characteristic time is defined as the time when . This simplifies the equation for capacitor voltage to
In principle the capacitor needs infinitely long to charge or discharge, since the exponential function reaches zero only for infinitely long time spans. In the measurement, however, one obtains sufficiently good accuracy, when choosing the period of the square wave voltage such that it is large compared to the relaxation time, . If this condition is not fulfilled, the charging starts with a voltage and reaches a voltage , i.e. the oscilloscope shows only a fraction of the charging and discharging of the capacitor’s voltage-time curve.
Part 2a - Measurements¶
Let’s set up the circuit and oscilloscope to observe this. You will need to add an offset such that the square wave has its minimum at zero. Once you have observed the effect, change the frequency of your input square wave so that the period is longer (~5-10 times) than the RC time constant. You can estimate this by calculating . The capacitor you have is . We will start with . Then, adjust the frequency such that (). What frequency is this? You should be able to adjust the oscilloscope to look like Figure 2. What X and Y settings are you using on your oscilloscope? Do these make sense? Explain.
Figure 2:(a) A square wave input (blue) and (b) output (red) measured across a capacitor in an RC circuit.
In order to get an accurate value of , we should zoom in on the charging and discharging as shown in Figure 3.
Figure 3:A close-up image of the charging and discharging capacitor circuit with a series resistor.
Part 2b - Theory of AC Impedances¶
A single capacitor circuit with a sinusoidal input voltage will have a time-dependent voltage across the capacitor that is ideally
The current can be calculated by using the capacitor charge and to obtain
indicating a phase shift rad between the voltage and current on the capacitor. The maximum current is , which comes from the amplitude of the derivative to find the time-dependent current. Similar to resistance in Ohm’s Law, there is a capacitive reactance, , for the maximum current and voltage
Capacitive reactance is a resistance to voltage changes rather than resistance to current changes as observed in a resistor. Because it is a type of resistance, it can be added to resistor resistance as a total impedance, , of an RC circuit. The equation above is only a relationship for the maximum values of voltage and current due to the phase difference between the time-dependent values. Using the idea that the two impedance values are 90^\circ} out of phase means they can be treated like orthogonal vectors (phasors) - see Figure 4. We can compute the total impedance using something analogous to the Pythagorean Theorem.
Figure 4:A diagram of impedance phasors.
The voltage is a sum of the voltages on the resistor and capacitor (circuit loop rule 1). In a simple resistor circuit the voltage and current would follow one another as . As noted above the voltage and current for a capacitor are 90^\circ} out of phase.
where the imaginary indicates an independent vector (phasor) direction that is due to the frequency dependence of the capacitor impedance. For a series circuit, we can describe the total impedance by
The magnitude of each impedance determines the phase angle between input voltage and the voltage across the resistor in the circuit. The current in the circuit can be measured by the voltage drop in the resistor because there is no phase added by the resistor. Using Figure 4 one can find a relationship between the impedances
From this, we can define a crossover frequency when ω = 1/RC, θ = 45o. This is where the resistor voltage equals the capacitor voltage (see Fig. 6). The phase will be between 0 and 90o depending on ω, R, and C, and you will see something like Fig. 5 on your oscilloscope.
Figure 5:A plot showing the phase shift in a series RC circuit. The phase shift is .
We can make substitutions to derive the maximum current in the circuit
and the maximum voltage on the resistor
and capacitor
Part 2b - Measurements¶
Use the oscilloscope to verify these relationships by setting V for sine wave input and measuring and using and . Use your oscilloscope to measure and as a function of ω. You will need at least 10 points over the range . Plot on the same graph vs. \omeg and vs. ω. They should look like Figure 6. Plot (13) and (14) on top of your data and comment on the accuracy of the theoretical model. Code to assist you is shown below.
Figure 6:The voltages across a resistor (blue) and capacitor (orange) in a series circuit as a function of input sinusoidal frequency, ω.
Because the resistor voltage increases with frequency, it can be used as a high-pass filter, passing only voltages of high frequency. Contrary to the resistor, the capacitor passes only low frequency voltages. It can therefore be used as a low-pass filter.
Vo = #peak-to-peak voltage
R = #resistor value
C = #capacitor value
f = np.linspace(0, 5000, 5001)#range of frequencies
omega = 2*np.pi*f #range of omegas
VR = #Use values above for R,C,omega to plot theoretical curves
VC =
#Enter your data below for f, VR, VC
f_meas = np.array([10, 100, 200, 300, 400, 500, 600, 800, 1000, 2000, 5000])
w_meas = f_meas * 2 * np.pi
VR_meas = np.array([0.5, 1.96, 3.16, 3.76, 4.2, 4.64, 4.6, 4.78, 5, 5.16, 5.1])
VC_meas = np.array([5, 4.72 ,4, 3.36, 2.8, 2.36, 2, 1.6, 1.28, 0.656, 0.27])
V_unc = np.ones(11)*0.15
plt.plot(omega, VR, '-.c', label=r'$V_R$')
plt.plot(omega, VC, '-m', label=r'$V_C$')
plt.errorbar(w_meas, VR_meas, yerr=V_unc, fmt='oc', label=r'$V_C$ measured')
plt.errorbar(w_meas, VC_meas, yerr=V_unc, fmt='*m', label=r'$V_C$ measured')
plt.xlabel(r'$\omega$ (rad/s)')
plt.ylabel('Voltage')
plt.legend()
plt.savefig('RCfilter.svg')
plt.show()
Fun with RC Circuits¶
Write these up for extra fun stuff to do