Author Topic: Achieving long RC time constant?  (Read 5107 times)

0 Members and 2 Guests are viewing this topic.

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Achieving long RC time constant?
« on: July 02, 2017, 02:15:42 pm »
Hi guys,

I've been assigned a lab project that seems like a trap for young players. It looks simple: replicate a transfer function with an op-amp.
That bit I can do. It's just a matter of choosing nice values for a Sallen-Key topology, right?

Well, the issue is that when I plotted the step response of the system it looks like the system is freaking slow. See the attachment.

Slow responses are problematic in my experience. Why? You need either high resistance or very large capacitances, or even both. Large capacitors have a lot of leakage and high resistances have issues with op-amp input leakage. Sometimes you need both a large capacitance and high resistance.

What would your strategy be? I wanna hear some opinions.
So far I have thought of using a J-FET input op-amp (TL-082), high resistance and the largest film capacitors I have (1uF).

Edit:
If you are curious, the transfer function is:

10 / (s^2 + 3*s + 2)
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 6027
  • Country: de
Re: Achieving long RC time constant?
« Reply #1 on: July 02, 2017, 02:42:07 pm »
First, one comment: strike the Sallen-Key filter completely from your mind. Don't ever think about using that circuit again. Component sensitivities are atrocious, it leaks at higher frequencies and so on. Sallen-Key has only one advantage: it's easy to calculate.

Now to your plot: of course it's slow. Your poles are down at a couple of rad/s, no more. Your step response looks realistic to me.

 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #2 on: July 02, 2017, 03:04:29 pm »
First, one comment: strike the Sallen-Key filter completely from your mind. Don't ever think about using that circuit again. Component sensitivities are atrocious, it leaks at higher frequencies and so on. Sallen-Key has only one advantage: it's easy to calculate.

Now to your plot: of course it's slow. Your poles are down at a couple of rad/s, no more. Your step response looks realistic to me.

I understand. Any alternatives for real world applications? (it's useful to know how to make things work well in the long term)

Just keep in mind that this circuit only has to work once and only for one application: plotting its step response on an oscilloscope and getting a feeling of how one would design more complex stuff.
 
I know it's probably not going to look identical unless I fiddle around with the components, but trust me, my implementation is going to be one of the better ones. :scared:
« Last Edit: July 02, 2017, 03:20:50 pm by ivan747 »
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 6027
  • Country: de
Re: Achieving long RC time constant?
« Reply #3 on: July 02, 2017, 03:27:44 pm »
There are lots of filter topologies out there, but for an implementation that's as simple as Sallen-Key (in terms of number of components), the MFB (multiple feedback) filter is a good choice.
With careful design, you can achieve sensitivities of 1 and on certain parameters even less than 1. It's also leaky at high frequencies, but to a much, much lesser degree that Sallen-Key, so that additional passive post-filtering can solve this.
See: www.ti.com/lit/an/sloa049b/sloa049b.pdf

 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #4 on: July 02, 2017, 03:28:30 pm »
Thanks, Benta!


Sent from my iPhone using Tapatalk
 

Online David Hess

  • Super Contributor
  • ***
  • Posts: 16898
  • Country: us
  • DavidH
Re: Achieving long RC time constant?
« Reply #5 on: July 02, 2017, 08:59:58 pm »
That time constant is not that long; you should not have any trouble achieving it with the input bias current of a JFET input operational amplifier.  Even a super beta bipolar part could do it.

Polypropylene capacitors are the best common ones for low leakage but you may have to qualify them.  The LMC6081 makes a good low input bias current precision operational amplifier with a typical Ib of about 10fA but if you want a guaranteed part, then use the LMC6001.  Use DIP parts so you can air wire the summing node to prevent leakage through the board.  Forget using those white nylon breadboards for this; nylon has terrible leakage.
 
The following users thanked this post: ivan747

Offline danadak

  • Super Contributor
  • ***
  • Posts: 1875
  • Country: us
  • Reactor Operator SSN-583, Retired EE
Re: Achieving long RC time constant?
« Reply #6 on: July 02, 2017, 10:48:03 pm »
Love Cypress PSOC, ATTiny, Bit Slice, OpAmps, Oscilloscopes, and Analog Gurus like Pease, Miller, Widlar, Dobkin, obsessed with being an engineer
 
The following users thanked this post: ivan747

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #7 on: July 02, 2017, 11:22:37 pm »
First, one comment: strike the Sallen-Key filter completely from your mind. Don't ever think about using that circuit again. Component sensitivities are atrocious, it leaks at higher frequencies and so on. Sallen-Key has only one advantage: it's easy to calculate.

Now to your plot: of course it's slow. Your poles are down at a couple of rad/s, no more. Your step response looks realistic to me.

What do you mean by leaky? I have just built a sallen-key circuit of this and I see some (relatively) high frequency noise on the output, even though the input looks clean. Is that what you mean?
 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #8 on: July 02, 2017, 11:24:38 pm »
A discussion of filter sensitivity -


http://pdfserv.maximintegrated.com/en/an/AN738.pdf


http://www.ti.com/lit/ml/sprp524/sprp524.pdf


Regards, Dana.

Thanks! Will read.


That time constant is not that long; you should not have any trouble achieving it with the input bias current of a JFET input operational amplifier.  Even a super beta bipolar part could do it.

Polypropylene capacitors are the best common ones for low leakage but you may have to qualify them.  The LMC6081 makes a good low input bias current precision operational amplifier with a typical Ib of about 10fA but if you want a guaranteed part, then use the LMC6001.  Use DIP parts so you can air wire the summing node to prevent leakage through the board.  Forget using those white nylon breadboards for this; nylon has terrible leakage.


I chose a JFET input op-amp. The only one I had on hand was a TL-082 so that had to be it.
 

Offline T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 21978
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Achieving long RC time constant?
« Reply #9 on: July 02, 2017, 11:30:03 pm »
What do you mean by leaky? I have just built a sallen-key circuit of this and I see some (relatively) high frequency noise on the output, even though the input looks clean. Is that what you mean?

Sort of.

More precisely:

The high frequency attenuation is limited by the output impedance and GBW of the op-amp.  Typical stop-band attenuation is in the -40dB range, i.e., it's rather "leaky".

If all you're ever concerned about is the domain of "what you see on the scope", then nevermind -- you can't resolve more than 40dB of dynamic range on a scope display.

If you're concerned with small signal behavior, high dynamic range, sensitivity, precision and so on, this will be a problem.

The op-amp also adds noise, which: if you don't see it on the input and you do see it on the output, then that's noise.  It shouldn't be much (microvolts), unless your circuit or amp are bad (poor design or poor quality).

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 
The following users thanked this post: kony

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Achieving long RC time constant?
« Reply #10 on: July 02, 2017, 11:32:31 pm »
Thanks Tim. I'm willing to guess that the noise is because of  the setup, then. It's good enough for the application (to prove a concept) but not much for anything else.

I'm learning a lot about active filters thanks to all of you.


Here's the setup. I know that the probing is bad, the power rails aren't decoupled and so on. As a matter of fact, I'm gonna add some decoupling right now.




System response. It's rather accurate, after all.
« Last Edit: July 02, 2017, 11:35:24 pm by ivan747 »
 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Achieving long RC time constant?
« Reply #11 on: July 03, 2017, 02:52:24 am »
Decoupling didn't do anything. Turns out that an important part of the "noise" was actually interference from my desk lamp's CFL light (at 50kHz). Another part of the "noise" is in phase with the AC line. I am using two power supplies and one of them is not regulated, just rectified and smoothed with large caps.

And the rest of it seems to be just... noise.


I can't be bothered to solder this. It's not mandatory to solder it, it isn't so complex that it is unreliable and I feel like I already learned what I have to learn from this and them some (like why it isn't a great topology at the end of the day).
« Last Edit: July 03, 2017, 02:56:49 am by ivan747 »
 

Online Someone

  • Super Contributor
  • ***
  • Posts: 4677
  • Country: au
    • send complaints here
Re: Achieving long RC time constant?
« Reply #12 on: July 03, 2017, 03:36:40 am »
Time for some analog magic care of the classic AN-31 application note. An extremely long time constant without worries of leakage across high value resistors or needing large capacitances, do it all with temperature stable parts and an NPO cap.
« Last Edit: July 03, 2017, 03:42:37 am by Someone »
 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #13 on: July 06, 2017, 03:08:21 am »
Turns out that some other guy independently came up with the same circuit that I did. Back to square one. I've gone through 5 different sallen key circuits. They are the most unstable things I have seen in my life. For instance, right now my oscilloscope is showing a completely different response than what it was showing 3 minutes ago. We're are talking about a 1 second difference in rise time and a ~20% overshoot when it used to be overdamped.

Time for a new topology. I'm thinking either two cascaded first order low pass filters (with buffers in between) or an MFB filter.
« Last Edit: July 06, 2017, 03:14:34 am by ivan747 »
 

Online tszaboo

  • Super Contributor
  • ***
  • Posts: 7587
  • Country: nl
  • Current job: ATEX product design
Re: Achieving long RC time constant?
« Reply #14 on: July 06, 2017, 10:55:48 am »
Just ADC it, run trough a digital filter and DAC it, throw in an opamp somewhere. You will get points for creative thinking. After all, you cannot solve it with "just and opamp", you need other components, right?
 

Offline ludzinc

  • Supporter
  • ****
  • Posts: 506
  • Country: au
    • My Misadventures In Engineering
Re: Achieving long RC time constant?
« Reply #15 on: July 06, 2017, 11:54:57 am »
Turns out that some other guy independently came up with the same circuit that I did. Back to square one. I've gone through 5 different sallen key circuits. They are the most unstable things I have seen in my life. For instance, right now my oscilloscope is showing a completely different response than what it was showing 3 minutes ago. We're are talking about a 1 second difference in rise time and a ~20% overshoot when it used to be overdamped.

Time for a new topology. I'm thinking either two cascaded first order low pass filters (with buffers in between) or an MFB filter.

That's what you get when you don't listen to good advice...

.(snip).  Forget using those white nylon breadboards for this; nylon has terrible leakage.
 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Achieving long RC time constant?
« Reply #16 on: July 06, 2017, 01:21:40 pm »
Yeah... I know...


I will try some perf board and a more robust topology, it I can find one that I can use film caps with (the vast majority of the systems equations I try don't even converge to an answer unless I give them huge caps. That includes sallen key with R1=R2).

I guess one way to do it is to get the cutoff frequency and Q factor of the system I was given, then start trying values with one of those online tools. I can't waste time. This thing is due tomorrow. Thank god I have a large component stock and tools at home. Otherwise I'd be screwed because I work a full time job as well.

My next try will be MFB, calculated the way I said and with perf board or point to point wiring if I can't find perf board.
« Last Edit: July 06, 2017, 01:27:11 pm by ivan747 »
 

Offline Benta

  • Super Contributor
  • ***
  • Posts: 6027
  • Country: de
Re: Achieving long RC time constant?
« Reply #17 on: July 06, 2017, 04:03:53 pm »
Quote
unless I give them huge caps.

Well, your cutoff frequency is at 0.225 Hz. There's no way to avoid large component values at such low frequencies.

 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #18 on: July 06, 2017, 04:04:47 pm »
Quote
unless I give them huge caps.

Well, your cutoff frequency is at 0.225 Hz. There's no way to avoid large component values at such low frequencies.

And that sucks. I'm really trying not to use electrolytic caps but it's getting hard.
 

Offline Kalvin

  • Super Contributor
  • ***
  • Posts: 2145
  • Country: fi
  • Embedded SW/HW.
Re: Achieving long RC time constant?
« Reply #19 on: July 06, 2017, 04:09:54 pm »
Would this be usable: https://en.wikipedia.org/wiki/Capacitance_multiplier At least you could reduce your caps and resistors.
 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #20 on: July 06, 2017, 04:12:35 pm »
That looks very interesting. I am guessing they are referenced to ground, right?


Sent from my iPhone using Tapatalk
 

Offline Kalvin

  • Super Contributor
  • ***
  • Posts: 2145
  • Country: fi
  • Embedded SW/HW.
Re: Achieving long RC time constant?
« Reply #21 on: July 06, 2017, 04:17:40 pm »
That looks very interesting. I am guessing they are referenced to ground, right?

More info can be found here:
https://wiki.analog.com/university/courses/electronics/text/chapter-4#capacitance_multiplier

I guess the "ground" node can be connected to any circuit node as I do not see any reason why it should be referenced to ground only. You could probably try this out with LTSpice and see how it turns out.

Edit: Here is some more info:
https://books.google.fi/books?id=T28-AwAAQBAJ&pg=PA575
« Last Edit: July 06, 2017, 04:34:29 pm by Kalvin »
 

Online David Hess

  • Super Contributor
  • ***
  • Posts: 16898
  • Country: us
  • DavidH
Re: Achieving long RC time constant?
« Reply #22 on: July 06, 2017, 04:25:53 pm »
I would use the breadboard for the power, ground, and low impedance connections and air wire the high impedance points.  Air is an excellent insulator.  Bend the pins for the inverting and non-inverting inputs up into the air.
 

Offline ivan747Topic starter

  • Super Contributor
  • ***
  • Posts: 2046
  • Country: us
Re: Achieving long RC time constant?
« Reply #23 on: July 06, 2017, 04:27:00 pm »
I would use the breadboard for the power, ground, and low impedance connections and air wire the high impedance points.  Air is an excellent insulator.  Bend the pins for the inverting and non-inverting inputs up into the air.

Excellent idea, actually!
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf