Professional Documents
Culture Documents
Table of Contents
Chapter: Applications of Operational Amplifier: Nonlinear Circuits: Lesson II-
Differentiator and Zero-Crossing Detector
1.1 Introduction
1.1.1Basic Differentiator
1.1.2 Frequency Response Of Ideal Op-Amp
1.1.3 Limitations
1.2 Practical Differentiator
1.2.1 Frequency Response Of Practical Op-Amp
1.2.2 Output for Various Input Waveform
1.23 Applications of Differentiator
1.3 Zero- Crossing Detector
1.3.1Inverting Zero-Crossing Detector
1.3.2 Noninverting Zero-Crossing Detector
Summary
Exercise
Glossary
References
1.1Introduction
Op-amp can be used not only for linear circuits like voltage amplifiers, adder, subtractor
amplifier, and current sources but also for nonlinear circuits such as integrator (discussed in
lesson-I), differentiator, wave shapers, and comparators. Output of nonlinear circuits is
different from input signal. In this lesson we shall discuss differentiator and zero-crossing
detector.
Differentiation is the counterpart to integration.Differentiator performs the mathematical
operation of differentiation. This operation is used to (i)extract edges from square waves,
(ii) convert sine waves into cosine waves and (iii)triangular waves into square waves.In
these applications op-amp is used with negative feedback. But in other applications, suchas
comparators, Schmitt Trigger, voltage level detectors and zero-crossing detector op-amp is used in an
open-loop configuration.
1.1.1Basic Differentiator
A basic differentiator is constructed by interchanging the resistor and the capacitor of an
integrator, or itmay alsobe obtainedif the input resistor R1 is replaced by a capacitor C1 in a
basic inverting amplifier.Figure 1 shows the differentiator amplifier. We know thata
capacitor does not allow a dc current to pass through it, so time varying sources (sine,
cosine, triangular etc.) is applied to inverting ‘-‘ (pin-2) terminal . Noninverting terminal ‘+’
(pin-3) is grounded.
𝐼𝑐 = 𝐼𝐵 + 𝐼𝑓 [1.1]
Since IB is very very small. So the current flowing through the input capacitor (𝐼𝑐 ) is equal to
the current flowing through the feedback resistor(𝐼𝑓 ).So
𝐼𝑐 ≈ 𝐼𝐹 [1.2]
𝑑𝑉𝑐
𝐼𝑐 = 𝐶1 𝑑𝑡
[1.3]
𝑑 𝑉 − 𝑉𝑜
𝐶1 𝑉𝑖𝑛 − 𝑉2 = 2
𝑑𝑡 𝑅𝑓
In the case of ideal op-amp gain (𝐴𝑜 ) is infinite, so𝑉𝟐 = 𝑉𝟏 = 0 can be substituted in the above
equation
𝑑 −𝑉𝑜
𝐶1 𝑑𝑡 𝑉𝑖𝑛 = 𝑅𝑓
𝑑
𝑉𝑜 = − 𝑅𝑓 𝐶1 × 𝑑𝑡 𝑉𝑖𝑛 [1.7]
Thus output voltage isproduct the negative instantaneous rate of change of the input
voltage or the derivative of the input wave form with 𝑅𝑓 𝐶1 .The product 𝑅𝑓 𝐶1 is called the
time constant of the differentiator.The negative sign indicates that there is a phase shift
of180o between input and output wave forms.
This differentiator circuit only has current flowing in the input when there is change in V in.
When there is no change in the input voltage, no current will flow and the output voltage V o
will be zero. The basic differentiator circuit only produces an output whenever there is a
change in the input signal.Faster the input voltage changes, larger the magnitude of output
voltage.This is useful in control circuits where rapid response to a change in the control
variable is necessary.
𝑉𝑜 (𝑆) = −𝑆 𝑅𝑓 𝐶1 𝑉𝑖𝑛 𝑆
𝑉𝑜 (𝑗𝜔)
= −𝑗𝜔𝑅𝑓 𝐶1
𝑉𝑖𝑛 𝑗𝜔
To get the frequency response obtain the magnitude of the gain which is
𝑉𝑜 (𝑗𝜔)
𝐴= = −𝑗𝜔𝑅𝑓 𝐶1
𝑉𝑖𝑛 𝑗𝜔
So at very low frequency such as dc. (f=0) the gain is zero. As frequency increases, gain
also increases. The expression for the gain can be written as
𝑓
𝐴=𝑓 [1.9]
𝑎
1
where𝑓𝑎 = , a constant quantity .
2𝜋𝑅𝑓 𝐶1
When 𝑓𝑎 = 𝑓, in Eq.[1.9], 𝐴 = 1 or 20 log A=0 dB. Hence the frequency at which gain is 0
dB is given by
1
𝑓𝑎 = 2𝜋𝑅 [1.10]
𝑓 𝐶1
It is evident from Eq.[1.8] ,that with the increase in frequency gain increases.
The frequency response of an ideal differentiator is shown in figure 2.It can be seen from
𝑓
the response curve that for, 𝑓 < 𝑓𝑎 , the ration𝑓 𝑓𝑎 < 1. Hence 20𝑙𝑜𝑔 is negative. While
𝑓𝑎
at𝑓 = 𝑓𝑎 , the gain becomes 0dB and for frequencies 𝑓 > 𝑓𝑎 gain increases at the rate of 20dB/
decade.
1.1.3Limitations
Gain Instability
Gain of thedifferentiatorincreases with the increase in frequency, see Eq.[1.8]. This makes
the circuit unstable and break into oscillations. There is possibility that op-amp may go into
the saturation.
Noise Magnifier
With the increase in frequency input impedance of capacitor (𝑋𝐶1 ) decreases.So the circuit
becomes very sensitiveto high-frequency noise. After amplification, the noise signals
completely override the differentiated output signal as illustrated in figure 3.
So shape of the output signal will not be what we have expected. i.e. spikes are produced at
output.Hence the differentiator suffers from the limitations on its stability and noise problem
at high frequencies.
Therefore, it is usually avoided in practice.However, solutions are available to reduce the
limitations without losing the desired wave form.
1.2Practical Differentiator
The basicdifferentiator is not generally usable in its present form [see Fig. 1], because of its
limitations [See.sec 1.1.3].Hence it is necessary to modify the circuit. Figure 4 shows a
practical differentiator circuit that overcomes the limitations of the ideal circuit. There are two
modifications to the circuit (basic differentiator, Fig.1), both of which results in the
formation of frequency filters.In this figure resistor (i)R1 is connected in series with
capacitor C1[1st modification] The effect of this resistor is to act as an attenuator for the
high frequency components, and (ii) a capacitor Cf is connected in parallel with feed-back
resistor Rf(2nd modification).At low frequencies capacitor behaves like an open circuit and
acts as a short circuit at high frequencies, so Cfdoesn’t impact the
operation of the circuit at low frequencies, It acts as ashort in parallel with Rfin the feedback
path for the high frequency components of the input signal.
change is caused by the combination of R1C1 andRfCf. fbis known as gain limiting frequency
and is given by
1
𝑓𝑏 = 2𝜋 𝑅 [1.11]
1 𝐶1
where 𝑅1 𝐶1 = 𝑅𝑓 𝐶𝑓
Thus the effects of high-frequency input noise and offsets reduces significantly by the
combination of 𝑅1 𝐶𝑓 and𝑅𝑓 𝐶𝑓 .Generally, the value of 𝑓𝑏 and in turn 𝑅1 𝐶𝑓 and 𝑅𝑓 𝐶𝑓 values
should be selected such that
𝑓𝑎 < 𝑓𝑏 < 𝑓𝑐
1 1
where 𝑓𝑎 = = 2𝜋𝑅
2𝜋𝑅 1 𝐶1 𝑓 𝐶𝑓
For proper differentiation of input signal, the time period T of the input signal is larger than
or equal to RfC1. That is,
𝑇 ≥ 𝑅𝑓 𝐶1
To use the practical differentiator, the highest frequency expected to be differentiated must
fall into this part of the circuit response. As "a rule of thumb" for designing a practical
differentiator,set fc to be 10 times the highest frequency encountered.
1
Gain limiting frequency derivation:𝑓𝑏 = 2𝜋𝑅
1 𝐶1
Body Text:
𝑉𝑜 (S) 𝑍 (𝑆)
Gain of practical integrator shown in Fig.4 is = − 𝑍𝑓 (𝑆) . (i)
𝑉 𝑖𝑛 (𝑆) 1
1 𝑅1 𝐶1 𝑆+1
where 𝑍1 𝑆 = 𝑅1 + = (ii)
𝑆𝐶1 𝐶1 𝑆
1 𝑅
𝑍𝑓 𝑆 = 𝑅𝑓 ‖ 𝑆𝐶 = 1+𝑆𝑅𝑓 (iii)
𝑓 𝑓 𝐶𝑓
𝑉𝑜 (S) 𝑅𝑓 𝐶1 𝑆
=−
𝑉𝑖𝑛 (𝑆) (𝑅1 𝐶1 𝑆 + 1) 1 + 𝑆𝑅𝑓 𝐶𝑓
If 𝑅𝑓 𝐶𝑓 = 𝑅1 𝐶1 , then
𝑉𝑜 (S) 𝑅𝑓 𝐶1 𝑆
=− 2 (iv)
𝑉 𝑖𝑛 (𝑆) 1+𝑆𝑅𝑓 𝐶𝑓
The frequency (f=fb) at which the frequency response of practical differentiator starts
decreasing 20dB/decade (Fig.5) can be determined by equating the denominator of
equation (iv) to zero. Therefore
2
1 + 𝑆𝑅𝑓 𝐶𝑓 = 0 , where 𝑆 = 𝑗𝜔 = 𝑗(2 𝜋𝑓) and f=fa can be negative. Therefore
1
𝑓𝑏 =
2𝜋𝑅1 𝐶1
Since 𝑅𝑓 𝐶𝑓 = 𝑅1 𝐶1
Suggested Reading:
Op-amp and linear Integrated Circuits: Ramakant A. Gayakwad,3rd Edition.
𝐴 𝑓𝑜𝑟 𝑡 ≥ 0
𝑉𝑖𝑛 =
0 𝑓𝑜𝑟 𝑡 < 0
Fig.6 .(a) Step input signal (b) Spike output wave form
𝑑𝑉 𝑖𝑛 𝑑
𝑉𝑜 = − 𝑑𝑡
= − 𝑑𝑡 𝐴 = 0 [1.12]
This is because A is constant. Actually the step input takes finite time to rise from zero to A.
Due to this finite time,the differentiator output is not zero and is shown in figure (6b). It is a
negative going spike output.
𝑇
𝐴 𝑓𝑜𝑟 0 < 𝑡 <
2
𝑉𝑖𝑛 =
𝑇
−𝐴 𝑓𝑜𝑟 <𝑡<𝑇
2
As discussed earlier the output for the positive step input is negative spike so for the
period 0 to T/2 output is negative going spike and for the period T/2 to T output is
positive going spike .Output wave form is shown in figure (7b) and in animation 1.
Animation 1
𝑉𝑜 = 𝐴0 𝑉1 − 𝑉2 [1.13]
where Ao is open loop gain, V1is voltage at noninverting (+) terminal and V2is voltage at
(-) is inverting terminal of op-amp.
If any one of the terminal is grounded or at zero potential, then comparator shown in
Fig.[8] is called zero-crossing detector/ comparator. Output(𝑉𝑜 ) may be saturated at a level
of +𝑉𝑠𝑎𝑡 or -𝑉𝑠𝑎𝑡 .
Characteristics of comparators
Body Text:
𝑉𝑜 = 𝐴𝑜 𝑉1 − 𝑉2
In this application, these two voltages,V1 (applied at + terminal, pin-3) and V2(applied at –
terminal, pin-2) are compared and output(𝑉𝑜 ) may be +𝑉𝑠𝑎𝑡 or -𝑉𝑠𝑎𝑡 , depending upon which
input is the larger.Ao is open loop voltage gain.
𝑉𝑜 = 𝐴𝑜 𝑉𝑖𝑛 − 𝑉𝑟𝑒𝑓 .
𝑉𝑜 = 𝐴𝑜 𝑉𝑟𝑒𝑓 − 𝑉𝑖𝑛
𝑉𝑜 = 𝐴0 −𝑉𝑖𝑛 [1.14]
For ideal op-amp Aois very high, so output (𝑉𝑜 )gets saturatedat±𝑉𝑠𝑎𝑡 .
If 𝑉𝑖𝑛 is positive, output will be saturated at −𝑉𝑠𝑎𝑡 .i.e (𝑉𝑜 = −𝑉𝑠𝑎𝑡 ) and for negative 𝑉𝑖𝑛 (𝑉𝑜 =
+𝑉𝑠𝑎𝑡 ).The output wave forms along input signal and reference voltage are shown in figure 10 .
Fig:10. The output wave forms along input signal and reference voltage for inverting
zero-crossing detector.
Source: Developed by ILLL
In the regions ‘a to b’ and ‘c to d’, (𝑉𝑖𝑛 > 𝑉𝑟𝑒𝑓 = 0) input signal passes through zero to
positive direction, the output is driven into –Vsat. Conversely when input signal passes
through zero to negative direction (b to c), the output switches to +Vsat. Output wave is
rectangular and inverted.ie. out of phase with respect to input. This circuit is also called sine
to square wave generator.
For ideal op-amp Aois very high, so output (𝑉𝑜 ) will be saturated and is equal to ±𝑉𝑠𝑎𝑡 .If 𝑉𝑖𝑛
is positive (𝑉𝑜 = 𝑉𝑠𝑎𝑡 ) and for negative 𝑉𝑖𝑛 (𝑉𝑜 = −𝑉𝑠𝑎𝑡 ).Plot of output wave form, input signal
and reference voltage as a function of time is shown in animation 4
Animation 4:.Plot of output wave form, input signal and reference voltage as a function of time
for noninverting zero-crossing detector..
Developed by ILLL
In the regions ‘ a to b’ and ‘c to d’, (𝑉𝑖𝑛 < 𝑉𝑟𝑒𝑓 = 0)input signal passes through zero to negative
direction, the output is driven into -Vsat. Conversely (𝑉𝑖𝑛 > 𝑉𝑟𝑒𝑓 = 0)i.e when input signal passes
through zero to positive direction ( b to c,d to e ), the output switches to +Vsat. So a triangular
wave is also converted into square wave.
Output wave is in phase with input wave.
In the figure C the resulting output are shown. It can be seen in the time interval
a to c the behavior is as expected as shown (noninverting zero-crossing detector)
in fig.10.But when Vin approaches Vref very slowly or actually hovers close to Vref,
=0 V,( at point d, e, f,g,h and i), Vo can either follow all the noise voltage
oscillations or burst into high frequency oscillation or we can say that the
fluctuationsdue to noise may cause the total input to vary above and below
reference voltage (0 voltage ) several times, thusproducing an erratic output
voltage.
EXERCISES
Question Number Type of question
4..Basic differentiator fails to work at (a) low frequency b) high frequency c) medium
frequency
5. In a zero-level detector, the output changes state when the input
(a) is positive (b) is negative (c) crosses zero (d) has a zero rate of
change
3 Subjective questions
4 Unsolved problem
1.For the basic differentiator circuit shown in figure 1(sec-1.1.1). (C1=100μf and Rf=10 kΩ)
Determine (i) expression for output voltage and (ii) the output voltage for the given input
shown below.
0.2V
0.1sec
2.For a basic differentiator, the input is a sine wave with peak to peak amplitude of 4V at
50Hz. Sketch the output wave form.
3.For a basic differentiator circuit, [c1=0.001 μf ,Rf=2 kΩ ], input is a triangular wave shown
below [ t2=2μsec]. Determine the output and sketch its waveform in relation to the input.
4. An op-amp has the following specification (i) open-loop gain of 60,000. (ii) dc supply
voltages ± 15V, (iii) maximum saturated output levels are ± 12V and Vref= 0V.If a
differential voltage of 0.1 mV rms is applied between the inputs, what is the peak-to-
peak value of the output?
5. Draw the output voltage waveform for the circuit in shown below with respect to the
input. Show voltage levels.
Solutions 1.Ans : (i) = − 𝑑 𝑉𝑖𝑛 𝑉/𝑠𝑒𝑐 (ii) -2V ,For t > 0.1sec,the input is constant so that output
𝑑𝑡
Answers.
voltage is zero.
𝑑
Sol:.𝑉𝑜 = − 𝑅𝑓 𝐶1 × 𝑉𝑖𝑛
𝑑𝑡
𝑑 𝑑
𝑖 𝑉𝑜 = −10 × 103 × 100 × 10−6 × 𝑑𝑡 𝑉𝑖𝑛 = − 𝑑𝑡 𝑉𝑖𝑛 𝑉/𝑠𝑒𝑐 (Ans)
(ii)Input signal is straight (increasing) between 0 to 0.1 sec.
𝑑 0.2−0
𝑉𝑜 = − 𝑑𝑡 𝑉𝑖𝑛 = − 0.1 = −2𝑉. (Ans)
For t > 0.1sec,the input is constant so that output voltage is zero. (Ans)
𝑉𝑝𝑝 4𝑉
Sol:𝑉𝑚 = 2
= 2
= 2𝑉 f=50 Hz, T=0.02 sec, Hence 𝑉𝑖𝑛 = 𝑉𝑚 𝑆𝑖𝑛𝜔𝑡 = 2𝑆𝑖𝑛(2𝜋50𝑡)
𝑑 𝑑
𝑉𝑜 = − 𝑅𝑓 𝐶1 × 𝑉𝑖𝑛 == − 2𝑅𝑓 𝐶1 × 𝑆𝑖𝑛(100𝜋𝑡)
𝑑𝑡 𝑑𝑡
3.Ans: (i)
𝑉𝑜 = − 2𝜇𝑠𝑒𝑐 × 1𝑉/𝑠𝑒𝑐 = −2𝑉
Sol
Given: 𝐶1 = 0.001𝜇𝑓 ,𝑅𝑓 = 2𝑘𝛺, 𝑡2 = 2𝜇𝑠𝑒𝑐 .𝑉𝑖𝑛 = 1𝑉
𝑅𝑓 𝐶1 = 0.001 × 10−6 ∗ 2 × 103 = 2.0𝜇𝑠𝑒𝑐
𝑑
𝑉𝑜 = − 𝑅𝑓 𝐶1 × 𝑉
𝑑𝑡 𝑖𝑛
(i) Positive going ramp is from 0 sec to t 1 sec i.e ( 1sec)
𝑉 1𝑉
Rate of change = 𝑡 𝑖𝑛 = 1𝜇𝑠𝑒𝑐 = 1𝑉 𝜇𝑠𝑒𝑐
1 −0
𝑑
𝑉𝑜 = − 𝑅𝑓 𝐶1 × 𝑉 = 𝑅𝑓 𝐶1 × 𝑟𝑎𝑡𝑒𝑜𝑓𝑐𝑎𝑛𝑔𝑒
𝑑𝑡 𝑖𝑛
𝑉𝑜 = − 2𝜇𝑠𝑒𝑐 × 1𝑉/𝑠𝑒𝑐 = −2𝑉
(i) Negative going ramp is from t 1 sec to t2 sec i.e ( 1sec)
𝑉 𝑖𝑛 1𝑉
Rate of change is negative =− =− = −1𝑉 𝜇𝑠𝑒𝑐
𝑡 2 −𝑡 1 1𝜇𝑠𝑒𝑐
𝑑
𝑉𝑜 = − 𝑅𝑓 𝐶1 × 𝑉 = 𝑅𝑓 𝐶1 × 𝑟𝑎𝑡𝑒𝑜𝑓𝑐𝑎𝑛𝑔𝑒
𝑑𝑡 𝑖𝑛
𝑉𝑜 = − 2𝜇𝑠𝑒𝑐 × −1𝑉/𝑠𝑒𝑐 = +2𝑉
GLOSSARY
Differentiator:A circuit that produces an output which approximates the instantaneous rate
ofchange of the input functions.
Comparator:A comparatorcompares the amplitude of one voltage (signal voltage) with
another fixed voltage (reference voltage).
Node: A point where two or more circuit elements meet.
Inverting amplifier:A amplifierin which amplified output voltage is inverted with respect to
input voltage .
Noninverting amplifier:Aamplifierin which the input signal is applied to the noninverting
terminal.
Frequency response:Graphical representation of variation of gain with frequency of input
signal.
Gain:The ration of output and input voltage/ current.
Critical frequency:The frequency at which the response of anamplifier is 3 dB less than at
midrange.
Bode plot:A graph of the gain in dB versus frequencyused toillustrate the response of an
amplifier.
Noise:Unwanted voltage fluctuations in the signal.