Monday, April 27, 2026

The Inductor Fights Back: Building and Understanding Negative Voltage from Scratch

 

Introduction: A Voltage That Seems Impossible

If I told you that a single 12V battery could produce a voltage below ground, it might sound like a trick. Yet with just an inductor, a diode, a switch, and your own finger, you can generate a real negative voltage relative to your reference point, enough to light an LED wired backwards.

This is not magic. It is energy moving between electric and magnetic forms, and we are going to see it happen.

This article flips the usual order. We will build first, observe what seems wrong, and use those failures to uncover what is actually happening.

What You Will Need

You will need an inductor between 100 and 470 microhenries to store energy in a magnetic field. You need a Schottky diode like the 1N5818 or 1N5819 because it switches fast and has a low forward voltage drop. Any LED will work as a visual indicator. A 470 ohm resistor limits current through the LED. A simple pushbutton switch gives you manual control. You will also try two capacitors, a 0.1 microfarad and a 100 microfarad, for later experiments. Finally you need a 12V DC supply like a battery or bench power supply.

A note on the diode. A common 1N4007 will work, but poorly. That poor behavior turns out to be instructive.

Experiment 1: The Raw Inductive Kick

Build the circuit as described. Connect the positive supply to one end of the inductor. Connect the other end of the inductor to the switch. Connect the switch to ground through a small 10 ohm resistor for safety. Connect the striped end of the diode, called the cathode, to the junction between the inductor and switch. Connect the non striped end of the diode, called the anode, to your 470 ohm resistor. Connect the other end of that resistor to the short leg or cathode of the LED. Finally connect the long leg or anode of the LED to ground.

Now press and release the switch. Watch the LED.

What you will see is that the LED flashes only when you release the switch. Not when you press. Only when you let go.

Try holding the switch for five seconds, then releasing. The flash is no brighter than when you held it for a tenth of a second. The inductor reaches near its maximum energy very quickly in this circuit.

What Is Actually Happening

When you close the switch, current flows from the positive supply through the inductor and down to ground. The inductor builds a magnetic field and stores energy. The amount of energy stored depends on the inductance and the square of the current.

When you open the switch, the inductor resists the sudden drop in current. It generates whatever voltage is necessary to keep that current flowing. Because the path to ground is now broken, the inductor drives its output node below ground potential. This negative voltage forward biases the diode and pushes current through the LED. That is your flash.

The Subtle Point

Notice that the LED is wired backwards. Its anode goes to ground and its cathode goes to the circuit node. But during the spike, ground is at a higher potential than that node. So current flows normally through the LED from its anode to its cathode. The LED does not know or care that we call one side ground. It only sees that its anode is more positive than its cathode.

Experiment 2: The Capacitor That Kills the Flash

Now add a 0.1 microfarad capacitor between the diode output and ground. Here is a critical detail. The capacitor positive terminal connects to ground. Yes, read that again. The positive side goes to ground.

What you will see is that the LED flash disappears or becomes so dim you can barely see it in a dark room.

What Changed

The inductor still releases roughly the same stored energy, but now the capacitor absorbs and spreads it over time. The voltage rises more slowly and the peak voltage drops. For a given amount of energy, a larger capacitor results in a lower voltage. If that voltage never reaches the LED forward voltage of about 1.8 volts, the LED will not light.

This is the first crucial insight. A single inductive pulse contains plenty of energy to light an LED brightly, as proved in Experiment 1. But that energy is delivered in microseconds. When you add a capacitor, the same energy spreads across time. The peak voltage drops. The LED dims or vanishes.

Experiment 3: Why Your Finger Is Not Fast Enough

Now try to build a steady negative voltage by tapping the switch repeatedly. Tap as fast as you can. Maybe fifty times. Maybe a hundred times. Then measure the voltage across the capacitor with a multimeter.

What you will find is perhaps negative 1 volt or negative 2 volts. Maybe negative 3 volts if you tap very fast. But definitely not negative 12 volts.

Why It Fails

Each tap delivers a small amount of energy to the capacitor. Your finger can manage maybe two to five taps per second. A proper switching regulator operates at tens of thousands of cycles per second. That is thousands of times faster.

Meanwhile the capacitor leaks charge through the circuit and the diode drops some voltage with every cycle. Losses accumulate. You simply cannot deliver energy fast enough to overcome these losses. Your finger is the bottleneck.

To charge a 100 microfarad capacitor to negative 12 volts requires about 0.0072 joules of stored energy. Each tap might deliver on the order of 0.0001 joules under ideal conditions. In theory that suggests dozens of taps, but in practice losses and increasing opposition from the capacitor prevent the voltage from ever reaching negative 12 volts.

Experiment 4: The Diode That Was Not Fast Enough

Replace your Schottky diode with a common 1N4007. Use the circuit without the capacitor so you can see the LED flash clearly.

What you will observe is that the LED still flashes, but much dimmer than before.

Why

The inductive spike is very fast, lasting only a few microseconds. The 1N4007 takes much longer to respond. By the time the diode begins to conduct, most of the energy is already gone. It dissipates as heat instead of reaching the LED.

The lesson here is that a diode forward voltage matters, but its switching speed matters just as much. For inductive kick applications, Schottky diodes are worth using.

Rethinking Ground and Negative Voltage

At this point you might be confused about something fundamental. How can ground be the positive terminal of a capacitor? How can an LED light with its anode connected to ground?

The answer is that ground is not the lowest voltage. Ground is simply a reference point. It is the zero on your ruler. Nothing more.

A Better Mental Model

Imagine a flat plane. A ball placed anywhere on it does not roll. Now tilt the plane. The ball rolls downhill.

Voltage works the same way. Current always flows from higher voltage to lower voltage. Positive voltage means above your reference. Negative voltage means below your reference.

In our circuit, when the inductor kicks, it creates a point that is below ground. Current flows from ground, which is higher, to that point, which is lower. The LED anode connects to ground and its cathode connects to the lower point. The LED sees forward voltage and conducts even though its anode is connected to ground.

This is not a trick and not a special case. This is how voltage works everywhere all the time. We just rarely think about it because most circuits keep everything positive relative to ground.

The Current Path That Changes Everything

Here is the detail that separates understanding from memorization. During the inductive kick, the collapsing magnetic field drives current in a closed loop. Ground is part of that loop. It is not a source of energy, just a reference node and a return path.

Trace the loop with your finger starting at ground. Go through the LED from its anode to its cathode. Go through the 470 ohm resistor. Go through the diode from its anode to its cathode. Arrive at the inductor. The loop closes through the inductor back to the starting point.

This entire loop is driven by the energy stored in the inductor magnetic field.

What the Diode Is Really Doing

The diode orientation never changes. What changes is the voltage across it.

During the charging phase with the switch closed, the diode cathode is at about positive 12 volts and its anode is at about ground. The diode is reverse biased and does not conduct.

During the kick with the switch open, the diode cathode goes negative while its anode remains near ground. The diode now sees a positive voltage from its anode to its cathode. It becomes forward biased and conducts normally.

The diode does not know or care that we call one side ground. It only responds to the voltage across its two terminals.

What the Failures Taught Us

The LED flashes only on release, not on press. That shows that energy is released at switch off.

Adding a capacitor kills the flash. That shows that spreading energy over time lowers the peak voltage.

Fast tapping does not reach negative 12 volts. That shows that energy delivery rate matters.

The 1N4007 performs poorly. That shows that switching speed is critical.

The LED lights with its anode connected to ground. That shows that voltage is relative, not absolute.

Where This Leads

The natural next step is to replace your finger with a transistor. Then replace the pushbutton with an oscillator that drives that transistor. Then replace the oscillator with a dedicated switching regulator integrated circuit.

Each step increases the switching frequency. At high frequency, the capacitor does not have time to discharge between pulses. The voltage builds to a steady negative value. That is how real DC to DC converters work.

But that is another step. For now you understand what those circuits are doing internally.

Final Thought

Inductors are often called passive components. But in this experiment they do not appear passive. They resist change. They generate voltage from stored magnetic energy. They enforce current flow when you try to stop it.

This is not because they are active devices, but because physics demands continuity. The current through an inductor cannot change instantly. When you try to stop it, the inductor responds by generating whatever voltage is necessary to keep the current flowing.

Understanding that response changes how you see every circuit that contains an inductor.

Appendix

Schottky diodes have a lower forward voltage and switch much faster than standard diodes. That makes them suitable for fast transient events like inductive spikes.

The capacitor positive terminal connects to ground because ground is at a higher potential than the negative output node.

Small inductors at low current are generally safe to experiment with, but voltage spikes can be high. Larger inductors or higher currents can be dangerous. Do not use mains power for this experiment, and do not reverse connect electrolytic capacitors.

Tuesday, April 21, 2026

What is VRMS? The Story of 220 Volts


If you have ever looked at an electrical appliance and seen "220V" or "110V" written on it, you have encountered VRMS, even if you did not know it. This article explains what VRMS means, where it comes from, and why it matters, without assuming any prior knowledge.


Part 1: The Basic Problem

Electricity in your wall is not steady

When you plug something into a wall outlet, the electricity is not constant like a battery. It continuously changes. It rises to a positive voltage, falls back to zero, goes negative, and returns again. This repeats about 50 or 60 times every second. This is called Alternating Current, or AC.

A battery provides a steady voltage. That is Direct Current, or DC.

So we face a problem. Since AC voltage is always changing, what does it even mean to say "the voltage is 220V"?

At some instants it is about 311V, at others it is zero, and at others it is negative. None of those alone describes what the electricity can actually do.

We need a single number that represents its ability to do work, such as heating, lighting, or driving a motor.

That number is VRMS.


Part 2: The Meaning of VRMS

One sentence definition

VRMS is the steady DC voltage that would deliver the same amount of power to a load as the AC voltage does.

In simple terms, a heater connected to 220V AC produces the same heat as if it were connected to 220V DC.

That is why we call mains supply 220V. That number is not the peak. It is the effective or working value.

The same idea also applies to current. An AC current of 10 amps RMS produces the same heating effect as 10 amps of DC.


Part 3: Peaks and the Actual Wave

Although we say 220V, the instantaneous voltage is not 220V most of the time.

For a 220V RMS sine wave:

The peak voltage is about 311V
The voltage swings from -311V to +311V

But these values do not represent how much useful work is done.

The peak is only reached for an instant. Using it to calculate power would give an incorrect result. The RMS value correctly represents the real energy delivered over time.


Part 4: Why it is called RMS

The name describes the calculation process.

First, square the voltage. This makes all values positive and reflects how power depends on voltage squared.

Second, take the mean. This averages the squared values over time and captures how long each voltage level exists.

Third, take the square root. This brings the value back to normal voltage units.

The result is a single number that represents the whole waveform.

For a sine wave, the RMS value is equal to the peak divided by the square root of 2. This factor comes from the geometry of the sine wave and the way its energy is distributed over time.


Part 5: The Key Insight

Duration and strength both matter

Different voltage levels occur for different amounts of time, and each contributes differently to total energy.


How time is distributed

For a sine wave:

The exact peak exists only for an instant
Values near the peak exist for a short time
Mid range voltages occupy a larger portion of the cycle
The waveform passes through zero quickly

To make this more precise, we compare equal-width voltage ranges. For example, a 50V or 100V wide band around the mid range contains more time than a similar-sized band near the peak or near zero.

For a 50 Hz sine wave, one half-cycle lasts 10 milliseconds. A mid-range band such as roughly 150V to 250V occupies a larger portion of that time than bands of the same width near the extremes.


How energy is calculated

Each moment contributes energy based on two factors:

How strong the voltage is
How long that voltage exists

Power depends on voltage squared, so higher voltages contribute more strongly at each instant.


Why mid-range dominates

Peak voltages are very strong but too brief
Low voltages are weak and also brief
Mid range voltages are moderately strong and occur over a larger portion of time

When you divide the voltage into equal-width bands, the bands around roughly 60 to 80 percent of the peak voltage contribute the most to total energy.

This is why, for a sine wave, the RMS value ends up at about 70.7 percent of the peak.

The RMS value is the single constant voltage that produces the same total energy.


Part 6: Visualizing the Idea

The mountain analogy

Imagine a mountain shaped like a smooth hill.

Height represents voltage
Horizontal spread represents how much time the waveform spends near that voltage
Density increases with voltage squared

The peak is very high but extremely narrow
The middle region is wider and still fairly dense
The base is not dominant because the waveform passes through zero quickly

The total mass comes mainly from the mid region.

The RMS value is the height of a flat plateau that would have the same total mass as this mountain.


The energy analogy

Imagine that each instant produces energy units proportional to voltage squared.

At high voltage, many units are produced, but only briefly
At mid voltage, a moderate number is produced over a longer time
At low voltage, very few units are produced

Add all units over time. Then ask what constant voltage would produce the same total rate of energy.

That voltage is the RMS value.


Part 7: Common Misconceptions

The RMS value is not the simple average voltage. The average of a full sine wave is zero. RMS is a different type of average based on energy.

Peak voltage is not what determines power. RMS determines heating, lighting, and motor performance. Peak matters mainly for insulation and component limits.

It is not correct to say lower voltages dominate because they last longest. The waveform does not stay at zero. It passes through quickly. The important region is the mid range.


Part 8: Real World Meaning

When a device is labeled 220V, it is designed for 220V RMS.

Internally, it must tolerate the higher peak voltage, but its performance is based on RMS.

A heater produces the same heat with 220V DC or 220V RMS AC.

A motor is designed based on RMS voltage, not peak.

Power supplies convert AC RMS into usable DC internally.


Part 9: Other Waveforms

The relationship between peak and RMS depends on waveform shape.

For a sine wave, RMS equals peak divided by about 1.414.

For a square wave, RMS equals the peak because the voltage stays at that level.

For a triangle wave, RMS equals peak divided by the square root of 3, which is about 0.577 times the peak.


Part 10: What About Frequency (50 Hz vs 60 Hz)

Frequency describes how fast the AC waveform repeats. A 50 Hz supply completes 50 cycles per second, while a 60 Hz supply completes 60 cycles per second.

It is important to understand that frequency does not change the RMS voltage itself.

If two supplies are both 220V RMS, one at 50 Hz and one at 60 Hz, they will deliver the same amount of power to a simple resistive load like a heater. The heating effect depends on RMS voltage, not frequency.

However, frequency does affect how electrical systems behave.

Higher frequency means the waveform repeats more often, so energy is delivered in smaller, more frequent cycles. Lower frequency means fewer, longer cycles.

Frequency becomes important in devices such as motors, transformers, and circuits that use capacitors or inductors. For example:

Motors change speed depending on frequency
Transformers are designed for a specific frequency and may overheat if used at the wrong one
Capacitors and inductors respond differently depending on frequency

So while RMS tells you how much effective voltage is present, frequency tells you how fast the waveform is changing.


Part 11: A Note on History

The RMS method was developed in the late 1800s when engineers needed a fair and consistent way to compare AC and DC power.


Part 12: Final Summary

AC voltage changes continuously, so a single number is needed to describe its real effect.

VRMS is that number. It is the equivalent DC voltage that delivers the same power.

In a 220V system, the voltage actually swings between about -311V and +311V, but 220V is the effective value that determines real world behavior.

The RMS value comes from combining how strong the voltage is and how long it exists at each level.


Final core idea

VRMS is not about the highest voltage or the lowest voltage. It is about the total energy delivered over time.

It is the most honest way to describe what AC electricity can actually do.



 

LED Resistor Calculator: A Clear and Practical Guide

Introduction

When working with light-emitting diodes (LEDs), one of the most common questions is: What resistor value should I use?

A widely used formula provides the answer:

R = (Vsupply - VLED) / ILED

At first glance, this expression can seem abstract. However, once the meaning of each term is understood, the calculation becomes straightforward and intuitive. This article explains the formula, clarifies the underlying electrical principles, and demonstrates its use through practical examples.

Understanding the Circuit

A basic LED circuit consists of three components:

  • A voltage source (battery or power supply)

  • An LED

  • A resistor connected in series

The key point is that LEDs are current-controlled devices. They do not inherently limit current. If connected directly to a voltage source, the current can increase rapidly, causing overheating and permanent damage.

The resistor's role is to limit the current to a safe level.

Core Concept: Voltage Distribution

In a series circuit, the supply voltage is divided between components.

  • The LED has a characteristic forward voltage (VLED), typically determined by its material and operating current.

  • The remaining voltage appears across the resistor.

This relationship is:

Vresistor = Vsupply - VLED

In practical terms: The resistor must account for the difference between the supply voltage and the LED's forward voltage.

Deriving the Formula

Using Ohm's Law:

R = V / I

Substituting the voltage across the resistor:

R = (Vsupply - VLED) / ILED

In plain terms:

Resistor value = Voltage to be dropped ÷ Desired current

Worked Example

Given:

  • Supply voltage: 9V

  • Red LED forward voltage: 2.0V

  • Desired current: 20 mA (0.020 A)

Step 1: Voltage across resistor

9 - 2.0 = 7.0V

Step 2: Resistance

R = 7.0 / 0.020 = 350 ohms

Step 3: Choose a standard value

Common options:

  • 330 ohms → slightly brighter

  • 360 ohms → slightly safer

In most cases, rounding up is preferred to reduce current and improve reliability.

Typical LED Forward Voltages

Here are typical forward voltages by LED color:

  • Red: 1.8 to 2.2 volts

  • Yellow: 2.0 to 2.2 volts

  • Green: 2.0 to 3.0 volts

  • Blue: 3.0 to 3.4 volts

  • White: 3.0 to 3.4 volts

These values vary with current and manufacturing differences, so they should be treated as approximations.

Choosing the Operating Current

For standard 3 mm and 5 mm LEDs:

  • Typical range: 10 to 20 mA

  • Recommended: 15 mA (0.015 A)

  • Maximum (not for continuous use): about 30 mA

Lower current improves lifespan and reduces heat at the cost of brightness.

Additional Examples

Example 1: 5V Supply with Red LED

R = (5 - 2.0) / 0.015 = 200 ohms

Use: 220 ohms

Example 2: 12V Supply with Blue LED

R = (12 - 3.2) / 0.020 = 440 ohms

Use: 470 ohms

Example 3: 3.3V Supply with White LED

R = (3.3 - 3.2) / 0.015 = about 6.7 ohms

This is a low voltage margin scenario. Small variations in supply voltage or LED characteristics can cause large current changes.

Design guideline: Aim for at least 1 to 2 volts across the resistor for stable operation.

Practical Shortcut

If calculation is not convenient, the following conservative values are safe:

  • 5V supply → 470 to 560 ohms

  • 9V to 12V supply → 1,000 ohms (1k ohm)

These values prioritize safety over brightness.

Resistor Power Rating

Resistors dissipate power as heat. Power can be calculated using:

P = I × I × R (I squared times R)

or equivalently:

P = V × I

For the 9V example:

P = (0.020 × 0.020) × 350 = 0.14 watts

A 0.25 watt (1/4 watt) resistor is sufficient.

Common Mistakes to Avoid

  1. Using milliamps instead of amps

    • 20 mA = 0.020 A

  2. Incorrect LED voltage assumptions

    • Voltage depends on LED type and color

  3. Omitting the resistor

    • Leads to immediate LED failure

  4. Using one resistor for multiple parallel LEDs

    • Causes uneven current distribution

  5. Selecting too small a resistor

    • When uncertain, choose a higher value

Quick Reference

Formula:

R = (Vsupply - VLED) / ILED

Steps:

  1. Subtract LED voltage from supply voltage

  2. Divide by current (in amps)

  3. Round up to a standard resistor value

Typical VLED values:

  • Red/Yellow: 2.0V

  • Green: 2.2V

  • Blue/White: 3.2V

Recommended current: 15 mA (0.015 A)

Conclusion

Selecting a resistor for an LED is a direct application of basic circuit theory:

  1. Determine the voltage difference (Vsupply - VLED)

  2. Choose a safe current (0.015 A for standard LEDs)

  3. Apply Ohm's Law: R = V / I

  4. Select the nearest higher standard resistor

This method ensures safe operation, predictable behavior, and long component life.

With these principles understood, LED circuit design becomes both reliable and efficient.