1. Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.
    Dismiss Notice

what is differant between LPF circuit and Intigrator and so with HPF circuit and diff

Discussion in 'General Electronics Chat' started by flinty, Jun 11, 2012.

  1. flinty

    flinty New Member

    Joined:
    May 26, 2012
    Messages:
    26
    Likes:
    0
    Location:
    Cairo-Egypt
    dears all
    that confused me alot ,
    i wanna know is the low path filter circuit (input volt , resistance , capacitor) simple one for example,
    how it do filtring and intigration at same time by the way integration my be change polarisation of the signal in time domain i know but is that affect it in F domain. and so with high path filter and diffrentiator.

    THX
     
  2. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ
    Hi,

    The integrator is like the low pass filter in that it attenuates frequencies more the higher they get. Unlike the low pass filter however, the integrator has no limit on how it handles the low frequency inputs especially at DC. This is evident in the following transfer functions for both...

    Low pass filter:
    Hs=1/(s+1)

    Pure integrator:
    Hs=1/s

    where 's' is the complex frequency. If we approximate s to be the angular frequency w, where w=2*pi*f with f being the frequency, for f=1000hz we have:
    Low pass filter: 1/(6284+1)=1/6285=1.5910899e-4
    and
    Integrator: 1/6284=1.5913431e-4

    Not much difference.

    However, if we examine the same two functions at 1Hz, we have:
    Low pass: 1/(1+1)=1/2=0.500
    and
    Integrator:1/1=1.000

    Now we see we have quite a difference, and going lower than 1Hz we see a greater difference.

    At DC which would be f=0, we see:
    Low pass: 1/(1+0)=1.000
    and
    Integrator: 1/0=infinity

    so now we see a huge difference in the response. So in the frequency domain there is a lot of difference.

    In the time domain with a step input:
    Low pass: f(t)=1-e^(-t)
    and
    Integrator: f(t)=t

    and if we evaluate these two functions for large t we see that:
    Low pass: f(t)=1
    and
    Integrator: f(t)=infinity

    So again we see a huge difference in responses. To the point, the low pass filter always has a limited response, while the integrator can have an infinite response at either very low frequency (like DC) or after a very long time has passed.


    For the differentiator vs high pass filter, we have:

    High pass: Hs=s/(s+1)
    Differentiator: Hs=s

    Evaluating these two at infinite frequency, we have:
    High pass: limit as s approaches infinity of s/(s+1)=1.000
    Differentiator:limit as s approaches infinity of s=infinity

    So we see the high pass has very limited output while the differentiator does not.

    In the time domain with step input,
    High pass: f(t)=e^(-t)
    Differentiator: f(t)=impulse at t=0

    So again we see a big difference in responses.

    Note also that as the constant shown as '1' in the two frequency domain transfer functions is allowed to get smaller, the response approaches that of the integrator (or differentialtor). Thus, with a small enough constant we get an approximate integrator or differentiator.
     
    Last edited: Jun 11, 2012
  3. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Flinty,
    in addition to MrAl's very detailed explanation I like to emphasize the following:
    * An ideal integrator cannot be realized (because of "infinity" as mentioned by MrAl). Thus, a real integrator is always a lowpass - however, with a very low cut-off or pole frequency.
    * Nevertheless, each lowpass can be used as an integrator (with some errors resp. restrictions) for operating frequencies far above the low pass cut-off frequency (factor 10 or so) because for these frequencies the phase shift is approximately close enough to 90 deg (which is the ideal phase shift of an integrator).
     
  4. dave

    Dave New Member

    Joined:
    Jan 12, 1997
    Messages:
    -
    Likes:
    0


     
  5. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ

    Hi again,

    I would also like to add this...

    An integrator that is used as a low pass filter will end up integrating any tiny DC offset to infinity. This means it amplifies the DC offset until the output of the circuit saturates. Thus, when we find a circuit being used as an integrator it is either inside a control loop or else has a reset capability where something resets the integrator back to zero to get it ready for another cycle of integration. So in effect it only works over a limited time period. In this application it does function as an integrator though, not a low pass filter.

    The usual circuit is an op amp with a capacitor from output to inverting input, and a resistor from the signal input to the inverting input, and with the non inverting input grounded.

    One thing to note here is that the circuit with a DC input produces a nearly perfect ramp output. With a resistor across the capacitor we end up with a low pass filter, which then means we dont get a ramp anymore but a curved ramp.

    An Integrator like this that are used in a feedback control loop does not have the DC problem because the loop corrects it. In fact, the steady state error of the system goes to a very low value. This is worth looking into also.
     
  6. flinty

    flinty New Member

    Joined:
    May 26, 2012
    Messages:
    26
    Likes:
    0
    Location:
    Cairo-Egypt
    what are you mean by factor 10??
     
  7. flinty

    flinty New Member

    Joined:
    May 26, 2012
    Messages:
    26
    Likes:
    0
    Location:
    Cairo-Egypt
    i red b4 that if we got an rect signal as an input to integrator the o/p witll be integrated rightly if RC=10 pules width??

    is that what you mean with ramp output???
     
  8. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ
    Hi,

    Well, a true integrator integrates the input and so the output is the time integral of the input. The RC value is irrelevant as to the accuracy because it will always be accurate. The RC value does help set the gain, but that still doesnt bother the accuracy.

    However, using a low pass filter for an integrator it is a different story. The low pass filter capacitor has a tendency to discharge over time with zero input while with a true integrator this doesnt happen. This means if we want to "integrate" a pulse with a low pass filter we need to set the RC time constant high enough so we dont get too much ripple on the output. A true integrator will ramp up with each pulse, and never ramp down, while an RC filter will ramp up and then ramp down after the pulse is complete. It ramps up and down with each pulse so that creates a sawtooth output which is usually too objectionable to be useful. With a larger RC time constant (which is sometimes estimated to be 10 RC time constants) the ripple is reduced and the filter becomes usable to some degree. Depending on the actual application however we may even want to go higher than that, such as to 100 RC time constants which provides a much smoother output at the cost of speed of response.

    The kind of circuit you are talking about could be made with a single resistor and single capacitor. This is sometimes called an integrator too but it is not a true integrator. It approximates the action of the true integrator. For certain applications though it can still be of great value, such as in finding the time average of a signal. For RC large enough relative to the signal bandwidth the output approaches the actual time average of the signal input with good accuracy.
     
  9. flinty

    flinty New Member

    Joined:
    May 26, 2012
    Messages:
    26
    Likes:
    0
    Location:
    Cairo-Egypt
    one more quistion:
    if we have simple LPF(single resistance and single capacitor),then we have a sine wave as an I/P (Vm sinωt)it will work as a LPF not as an intgrator which intgrate I/P to be -cos but with filter pathing band which ??
    or both of them ??

    i think if we intgrate the sine wave to negative cosine it mean that we shifted sine wave by -90 degree??
    if you got an explaination please help :confused:
     
  10. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Flinty,

    an ideal integrator always shifts the phase of a sinusoidal signal by -90 deg.
    However, as mentioned before, an ideal integrator does not exist in reality.
    Thus, each REAL integrator is a lowpass. But it acts as an integrating device (with small restrictions) for frequencies much larger (at least factor of 10) than the lowpass corner frequency.
    This holds even for the simple passive RC element. However, in this case the signal will be attenuated in amplitude at least by 20 dB.
     
  11. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ

    Hi again,


    The following discussion refers to a two section RC network rather than a single resistor and capacitor...

    Here you are hitting on a good point. We can use a normal passive RC circuit as an integrator and it works exactly like an integrator. We input a sine wave sin(wt) into the resistor and across the capacitor we get -cos(wt). That's definitely true. So we have ourselves an integrator after all.

    But there's a catch here. The above only works when w=1/RC. With ANY other w, it does not work perfectly as it does at that exact value of w. And the thing is, an integration is a more general operation which does not require a certain frequency to work. We can integrate a wide class of functions and in particular we can integrate sin(wt) without actual regard for w if we use a circuit that is a more true integrator.

    A true integrator always produces a 90 degree phase shift (which way depends on if there is an additional inversion). An RC network produces a 90 degree phase shift for one frequency only. The op amp circuit produces a cos(wt) wave, but it may not be the same amplitude unless we also adjust the resistor and/or capacitor value(s).

    The best way to understand this is to analyze a couple of circuits for AC and calculate the amplitude and the phase shift. Do the op amp circuit and do the passive RC circuit. Use various frequencies. The RC passive is tuned for a give frequency when w=1/RC as mentioned. The op amp provides the correct phase shift, but the amplitude is only correct when w=1/RC.
    Note also that the amplitude of the RC passive is never correct because it is cut by more than 70 percent at the 'correct' frequency which provides a phase shift of 90 degrees.

    Note that the circuit will always have to fit the end application. If the engineer needs a circuit that only has to integrate at only a certain frequency (and do so perfectly but with less gain) he/she may use an RC passive network, if it works for that application. If it doesnt, then he/she needs a different circuit. Often this is where the op amp integrator circuit comes in.

    See, with some of these circuits you may come up with a million questions because there are many aspects of a circuit like this even though it is quite simple. So you may wish to start analyzing some of these yourself so you can investigate any of these ideas. That eventually gives you tremendous insight into these matters. And as you go you learn to analyze with more insight too, which allows you to understand more and more aspects of these circuits as well. No problem if you have more questions though, just thought i would mention that.
     
    Last edited: Jun 16, 2012
  12. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Hello MrAl,

    Sorry, but I cannot resist to comment your explanations.
    According to my knowledge a simple RC element produces a phase shift of -45 deg at w=1/RC (and not -90 deg).
    More than that, a phase shift of -90 deg is generated for infinite frequencies only. That was the reason I have stated in my former contribution that an RC combination NEVER can act as an ideal integrator.
    However, in many applications it can be used as an approximation to an integrator (for frequencies much larger than 1/RC)
    For active integrators the situation is slightly different:
    Because all integrating devices (including opamp integrators) in reality have lowpass characteristics (with a very low corner frequency) the phase starts at 0 deg and reaches -90 deg (+90 deg for the classical inverting Miller integrator) at ONE single frequiency only. For larger frequencies the phase goes beyond this value due to the real nature of the opamp.
    However, normally the phase slope around the -90 deg is very small so that in can be used in a rather broad frequency region for integrating purposes.

    Additional comment regarding the allpass:
    Quote: For a constant phase shift another network that is used is called the "All Pass".
    Just the opposite is true. An allpass provides a (nearly) constant amplitude and a frequency-dependent phase shift. This is the reason an allpass can be used to correct unwanted phase excursions.
     
    Last edited: Jun 16, 2012
  13. flinty

    flinty New Member

    Joined:
    May 26, 2012
    Messages:
    26
    Likes:
    0
    Location:
    Cairo-Egypt
    ok now after we all agree that lpf is an intgrator always so if we want to fliter some frequencies
    only what is the filter will act also as an integrator who could we recover those integrated frequencies??
     
  14. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Flinty, I am very sorry but I do not understand your question. Please, do not write everything in one sentence only.
    What do you mean with "recover those integrated frequencies"?
    What is your main task or question? Filtering or integrating?
     
  15. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ
    Hi Winter,

    yes you're right. Thanks for catching those misquotes. I was thinking of an op amp integrator not a passive RC integrator. I'll include the more correct reply here and i've edited the original to make it more clear. I noted that two RC passive sections could act as a very near perfect integrator, but actually a single section could do it too as i'll show next.

    We can actually get an integration with a single RC section. This isnt hard to do because the capacitor itself is an integrating element:
    dv/dt=i/C

    Thus a single capacitor can be used as an integrator even without a resistor if we measure the output as the voltage across it and the input as the current through it:
    V=(1/C)*Integral(i)dt+K

    As shown, the voltage is the integral of the current over time times a constant with the addition of possibly some initial voltage.

    In a different circuit if we use two RC sections where the second R value is 100 times greater than the first R value and the second C value is 100 times less than the first C value then we will get a 90 degree phase shift at the frequency w=1/RC as indicated. It's pretty close too.

    But what the above suggests is that what we need to do is separate the theoretical from the practical and investigate both areas separately. That's because we would start from some theory and then try to turn that into a practical circuit and we'll find that when we do this we can get whatever we want: either a good integrator or a good low pass filter. It never has to be perfect to work out in practice, it just has to be close enough so that it doesnt cause an error in the system that is too high to manage.

    If you remember those old volt meters from way back maybe in the 70's they used to use integrators to determine the voltage, and they could get 3 and a half digits of accuracy which wasnt too bad really. If they could not create an integrator good enough for that purpose then they would have never been able to achieve that level of accuracy.

    An in theory, it is good to understand the two equations:

    Hs1=1/s

    and

    Hs2=1/(s+A)

    The first is an *ideal* integrator and the second is a low pass filter. Yes the integrator acts as a low pass filter too but has differences as mentioned earlier in this thread. And with the low pass filter we can note that when A gets lower and lower it gets closer and closer to an ideal integrator. That's probably the best way to look at it.

    But also, sometimes the passive single section RC filter can act as an integrator and depending on the signal bandwidth it works just fine just like that. For an example where it works very well is in a signal averaging circuit. With a 10k resistor and 1uf capacitor we can easily find the average of a pulse signal of high enough frequency with only a small amount of ripple. The DC value is very close to the actual average DC of the signal. Here we dont need a certain phase shift, we are using another aspect of the low pass filter which does act as an integrator.

    So to say simply that a low pass RC filter can never act as an integrator is not entirely true either. It depends on the application.
     
    Last edited: Jun 16, 2012
  16. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ
    Hi again,


    Are you talking about first integrating the signal and then trying to use another filter to get the original signal back, such as a differentiator?
     
  17. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Hi MrAl,
    I am afraid, I have to continue the discussion, because I really cannot agree to all of your statements (Quotations in italics):

    I noted that two RC passive sections could act as a very near perfect integrator, but actually a single section could do it too as i'll show next.


    No, that is not the case. The transfer function of an ideal integrating function (as given by you later) has an amplitude slope of -20 dB/dec and, correspondingly, a constant phase shift of -90 deg
    With one single RC sections this can be approximated for frequencies far above the corner frequency 1/RC only (my suggestion: Frequencies at leat w(min)=10/RC).
    I really don't know how a second RC section could improve the situation. I can imagine what your goal is: To bring the phase closer to -90 deg. and to go through this phase at one discrete frequency.
    However, I doubt if this can improve the integrating properties of the whole circuit. Have you ever seen such an integrating device using TWO RC sections?

    We can actually get an integration with a single RC section. This isnt hard to do because the capacitor itself is an integrating element:
    dv/dt=i/C

    Thus a single capacitor can be used as an integrator even without a resistor if we measure the output as the voltage across it and the input as the current through it:
    V=(1/C)*Integral(i)dt+K


    Yes, exactly this is done (better: the current source is approximated by the resistor) by using a resistor to charge the capacitor. That`s the working principle of the RC "integrator" as well as the Miller integrator using opamps. Here the Miller effect enlarges the resistor causing a very small corner frequency of the resulting lowpass with gain (due to the opamp action).

    If we use two RC sections where the second R value is 100 times greater than the first R value and the second C value is 100 times less than the first C value then we will get a 90 degree phase shift at the frequency w=1/RC as indicated. It's pretty close too.

    Yes, every second order circuit is able to produce -90 deg. at one single frequency. But this is not sufficient to be an integrator. What about the gain slope at this point? It will be larger than 20 dB/dec and, thus, cause new errors.

    But also, sometimes the passive single section RC filter can act as an integrator and depending on the signal bandwidth it works just fine just like that. For an example where it works very well is in a signal averaging circuit. With a 10k resistor and 1uf capacitor we can easily find the average of a pulse signal of high enough frequency with only a small amount of ripple. The DC value is very close to the actual average DC of the signal.

    Yes, of course - for a "high enough frequency", which is far above w=1/RC.
    ________________________________________________________________
    Perhaps it would help to show some simulation results (magnitude and phase for one and two RC sections as well as an active integrator).
    I'll try it.
    Regards
     
  18. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ
    Hi again Winterstone,



    Very interesting replies there :)

    First i want to point out that what we are debating here could only be classed as "Application Specific", in that whatever circuit we talk about MUST be linked to an application or as set of applications or some other classification.

    For example, *YOU* say that we can not use a double RC section to integrate, while *I* say that we can. That's because you are looking for a circuit that works in one application while i am explaining how the OP was thinking about the application where the frequency is constant. It is entirely possible to want this function so i cant exclude it. His question was directed at this phenomenon.

    Second, you say that we can not use a single RC section to integrate, but you havent replied to the case where R is either zero or close to zero. We can not leave this out of the theory either because it helps to understand these concepts as well. It's not a second order system either. Take a RC section with very small R (possibly zero). Put a sine voltage across it of some frequency. Measure the current on the scope. Note the relationship between the current and voltage.
     
    Last edited: Jun 16, 2012
  19. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Hi MrAl,

    I think I never have claimed that the voltage-current relationship of a capacitor would not involve a 90 deg phase shift. But I think, this belongs to basics and it neeeds not to be discussed further.
    For my opinion the subject of our discussion was and is a circuit that can be used for integration of signal voltages within a certain frequency band.
    Integration of one single frequency may be of interest in some special cases - however, for most applications (filtering, oscillators, control systems, average generation) it is required that the device can integrate within a certain band.
    In order to illustrate my point I have performed some simulations.
    I have designed 3 different circuits (1 active and 2 passive) based on the requirement that integration with acceptable quality around 1 kHz is possible.
    I think, the results clearly demonstrate that
    (a) the active circuit is best (of course!) with a very good phase characteristic (nearly constant within a range) and with a gain around 0 dB,
    (b) the single RC section also has an acceptable phase response around 1 kHz (which is 100 times larger than f(3dB) - however the "90 deg region" is much smaller than in case (a) and the gain drops down to -40 db (!!)
    (c) the double RC section (in spite of a nearly optimal design) has a relatively poor phase characteristic and crosses the 90 deg line at one single frequency. It cannot compete with case (b).

    Quote MrAl: In a different circuit if we use two RC sections where the second R value is 100 times greater than the first R value and the second C value is 100 times less than the first C value then we will get a 90 degree phase shift at the frequency w=1/RC as indicated. It's pretty close too.

    Remark: As you can see, in case (c) I didn't follow the above suggestion to use two RC sections with two equal time constants. This is nearly the worst case with a double real pole and a rather steep crossing of the 90 deg. phase line.

    Comments are welcome.
    Regards
    W.
     
    Last edited: Jun 16, 2012
  20. MrAl

    MrAl Well-Known Member Most Helpful Member

    Joined:
    Sep 7, 2008
    Messages:
    11,049
    Likes:
    961
    Location:
    NJ
    Hi again Winter,

    Im sorry i just dont see what you are trying to get at. Sure it doesnt work over a wide range of frequencies, but not every circuit has to do that. For example, a line operated circuit works at 50 or 60Hz, or in some cases 400Hz. The frequency wont vary much either.

    Yes there are some circuits that can do some things better than others, depending once again on the application.
     
  21. Winterstone

    Winterstone Banned

    Joined:
    Mar 24, 2012
    Messages:
    536
    Likes:
    15
    Location:
    Europe
    Hello again MrAl,

    to make it clear: It was my only intention to demonstrate that
    (a) a single RC section can approximately act as an integrator for frequencies far beyond the pole frequency only, and
    (b) that a double RC section in this respect (as proposed by you) never can compete with a single RC section - in particular, the dimensioning as mentioned by you (with equal time constants) is the worst one.

    Remark: It is by far not sufficient for realizing an integrating device to have a 90 deg phase shift for one frequency.
    You should not forget the time domain in conjunction with the LAPLACE transform:
    Time integration (time domain) is equivalent to a division by "s" in the frequency domain. This clearly shows that the second-order denominator of two RC sections (like all 2nd order functions) never can be equivalent to a time integration. Thus: An integrator must be a first-order function!
    I hope now you know better what I am trying to get at.
    Thank you.
    W.
     

Share This Page