I'm having some problems with this circuit from a tutorial website: enter image description here

When the switch is open, the LED is on. When the switch is closed, the LED turns off and the timer begins. After a while, the LED will soon turn on. It changes with depending values of the resistor and capacitor (so i think its an RC circuit with a transistor). Im wondering how you would find like an equation that will determine the time constant of this LED turning on when the switch is closed.

Note: the capacitor already has a voltage when the switch is open and it begins to decrease when the switch is closed. When it reaches zero, the voltage goes in the opposite direction (negative), until it hits -0.6V and allows the transistor to turn on and allow the current through. Is the capacitor actually discharging???

Any help appreciated!Thanks! :)


1 Answer 1


The capacitor charges through R1 to +9V - Vbe = 8.3V when the switch is open.

When you close the switch the left end of the capacitor becomes 0V, so the right jumps to -8.3V (exceeding the absolute maximum rating of -6V on Q1, by the way).

Ideally the transistor does not instantly die from this abuse and the capacitor begins to charge towards 0V - Vbe = -0.6V (putting reverse bias on the polarized capacitor, also frowned upon in some circles).

The time constant is \$\tau = R_2 C_1\$. Time Constant has a specific meaning- it is not the same as the time for the transistor to switch because the threshold is not at 63% discharge but more like 50%. The discharge follows an exponential curve. (as pointed out in the comments, the vertical axis is not really right, but the shape is correct).

enter image description here

To clarify the actual discharge curve measured at the right-hand side of the capacitor, so relative to ground, (and ignoring the transistor base for now) can be shown to be \$v(t) = 9 - 17.2e^{-t/\tau}\$ where t>=0 is the time since the switch was closed. The transistor will switch (and the curve will deviate from the ideal since the base clamps it) when v(t) is about +0.7 so that is at \$t = \tau\cdot \ln(0.483)\$ or about \$0.73 R_2 C_1\$. In this particular case C1 = 470uF and R2 = 22K, so the time should be ~7.5 seconds. It may vary a bit from that because the transistor needs some current to operate the LED and also because the 470uF capacitor probably has a large tolerance.

You can easily simulate this in circuitlab to verify the design- the top curve shows the LED current, and the bottom curve the voltage at the base of Q1.


simulate this circuit – Schematic created using CircuitLab

enter image description here

  • \$\begingroup\$ @TisteAndii, the initial voltage across the capacitor is 8.3V with the more positive end connected to the zero volt reference. Thus, the more negative end, which is connected to the base of the transistor, is at -8.3V \$\endgroup\$ Commented Aug 6, 2016 at 10:53
  • \$\begingroup\$ @AlfredCentauri Oh, I understand that. The p.d is still the same. I saw that before but somehow it skipped my mind after I asked the first question. \$\endgroup\$ Commented Aug 6, 2016 at 11:13
  • \$\begingroup\$ Rephrasing, could you clarify your last paragraph about the time constant? \$\endgroup\$ Commented Aug 6, 2016 at 11:14
  • 2
    \$\begingroup\$ Nitpicking, I know, but there appears to be something wrong with that exponential curve: the tangent at t=0 should intersect the time axis at time RC. It appears the C axis is not linear. Anyhow +1 for "also frowned upon in some circles". \$\endgroup\$ Commented Aug 6, 2016 at 11:29
  • 1
    \$\begingroup\$ Maybe you didn't let the cap charge for long enough- so R1 did actually matter. The solution to the differential equation is of form a + b*e^(-t/tau) and we know the initial condition v(0) is -8.2V and v(infinity) is +9V (if the base wasn't there clamping it) so the values of a, b fall out. \$\endgroup\$ Commented Aug 6, 2016 at 21:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.