# Resistance, and learning for beginners

I am building an electrified "fence" of sorts to keep slugs out of my raised garden beds. The "fence" consists of two 18ga galvanized steel wires, stapled to wood and connected to a 9V battery. The circuit is open until the slug touches both wires, at which point he completes the circuit and gets a little shock. This works great in small scale tests, but my garden bed as a circumference of 30' (9.1 meters) and I'm concerned that a little 9V battery will have a hard time working at full power over that distance of wire.

Because I don't really know how resistance works (I just know how to get my volt meter to measure resistance so that I can make sure my solders are done well) I'm not sure how to do the math to see what kind of a drop in voltage I'm going to get.

If someone can answer this question directly, great. But I'd also love a website that I can use to help learn about this stuff.

• How can I find out the resistance of this wire? (Doesn't resistance change with voltage/amperage?)
• How does that resistance compound over distance?
• Are there simple parts (transistors, resistors, whatever) that I can go get at Radio Shack or the like that will help get over this resistance or should I just wire a second 9V battery into the system?

Bonus question: While 9V is a very light charge, if you imagine I'm building a much more powerful electric fence, what would I have to do to protect the battery if the circuit were completed for an extended period of time? (A slug dies on the line or something.) I wouldn't want some grass completing the circuit and having my battery explode.

• Just a side thought...wood will get damp and when it does it starts to conduct a bit of current. You might be better off using something plastic to hold your wires, perhaps a few lengths of PVC pipe, so that your battery will last longer. – Joe Hass May 27 '14 at 19:44
• Fun poject. I bought a "slug fence" a couple of years ago. It uses a plastic mesh/net band with a couple of thin metal wires in it. The net is held up by some plastic legs. Everything is powered by a wall wart. – Dejvid_no1 May 27 '14 at 19:55
• Since this kind of application use hv in quite high frequency, litz wire is proposed. – GR Tech May 27 '14 at 20:34

The wire suggested wire is adequate- the resistance is about 130 ohms/km. I got that from kinda a long route. I used the table for copper (AWG) wire resistance per km, adjusted that for the ratio between copper and steel resistivity, and then for the ratio (squared) between the diameters for AWG and the gauge system used for steel wires (whew!) which is "Washburn & Moen; Roebling; or American Steel and Wire".

So only maybe 2.5 ohms for your circuit (based on two wires, 9.1m each, connected at one end.

You might want to use something other than wood for the supports, insulate the wire from the posts, or at least seal the wood with epoxy. If, say, you were in Portland OR, it will (on average) rain 144 days per year and the leakage through the wet wood would tend to drain the battery.

Here are some insulators used on commercial electric fences.

In terms of $per kWh, AA batteries are a much better deal than 9V batteries, and six AA cells in series would give you 9V. Energy capacity being a lot higher, it also means that you won't need to replace the batteries as often. There is a good reason why 9V batteries are seldom found in modern electronics. AA cells have a short-circuit current in the amperes, so a current limiting resistor as Andy suggests would be a very good idea, or you could use a blinking LED in series such as this Lumex one, available from distributors such as Digikey for$1 each.

If you see the LED blinking, the wire is shorted.

• How are those plastic insulators the slightest bit relevant to preventing the movement of slugs? Do you have some reason to think that there will be many kWh of energy used so that the cost of AA batteries will make a difference in this application? – Joe Hass May 27 '14 at 19:53
• I'm actually 30 minutes outside of Portland, OR. Lots of rain, which is why I used galvanized steel instead of copper or something that would corrode. I'm not sure if I can easily get around the wet wood issue though. My plan was to staple the wire directly onto the vertical walls of my cedar garden bed. My assumption was that wet wood would have huge resistance and wouldn't really be an issue. (It's not like we're dealing with salt water.) – Tyler V. May 27 '14 at 20:01
• @JoeHass If the battery goes dead because of wet wood, the slugs will have his lettuce for lunch, so I think it is very much relevant. I do think they'll leak regardless (he's apparently in the PNW part of the US, where it rains a lot of the time), and acid rain is somewhat conductive. I'd definitely use AA batteries if I was making one. – Spehro Pefhany May 27 '14 at 20:01
• Also, should my resistor or LED be on the + or - side of the circuit? – Tyler V. May 27 '14 at 20:02
• @JoeHass The photo is of an insulator attached to a post, so I thought it might stimulate some ideas for attaching a plastic insulator of some kind to the wood he wants to use (in some unknown configuration). (hey, much as your comment on PVC pipes, which I didn't quite visualize.. but that's probably my lack of 3D imagination). It was not a specific product recommendation, of course, those things are designed for livestock fences (as a kid I used to get shocks from horse fences). You really think it's that terrible to include it to warrant a downvote? – Spehro Pefhany May 27 '14 at 20:41

18 gauge wire (assuming AWG) is about 21 ohms per kilometre - see this table for other gauges.

With 9.1 metres your total resistance is going to be 0.189 ohms and won't have a problem with the circuit you described. Resistance changes as wire heats up but on your circuit there'll be no heating up and I'd employ a current limit resistor in series with the battery to make sure - probably 1 kohm is large enough to prevent rapid discharge of the battery should a short occur but no so large as to prevent the little garden friends receiving a tingle or two.

• Thanks Andy. Will the resistor lower the volts delivered to the slugs, or just limit the amount of electricity making it back into the battery? Also, I plan on putting this very close to the battery in the circuit, but I don't know if it should be on the + or - wire. – Tyler V. May 27 '14 at 19:37
• It doesn't matter which wire but what you can do is not use the resistor and use a meter measuring current initially. If the slugs are deterred at 1mA flowing thru their bodies then probably something lower like 330 ohms will be better. Alternatively a small constant current circuit might be better - it'll "drop" fewer volts when current flows and still provide the little kick to the pesky slugs. Enjoy your lettuce, tomatoes, cucumber and radishes!! – Andy aka May 27 '14 at 20:12

The resistance of the wire can be measured using the ohm or R setting of the multimeter. If you touch one probe to the one end and the other to the other end, you'll get the resistance in-between. Note that if it's touching itself (curled up) then the resistance won't be accurate, it would need to be not in contact with itself if it's uninsulated. Since the resistance of the wire is so low, your multimeter may not measure a resistance at all.

Resistance is a physical property of the wire. It doesn't change with the voltage or current, however it does determine how the current will change relative to the voltage.

Resistance increases proportionately with length. A wire of double the length will have double the resistance. Half the length will have half the resistance.

Since the resistance of the wire is so low, you won't really have an issue with the 9V supply. However it will be a good idea to put a resistor in line with the 9v battery just so that if something causes a short (like if it rains) then there will be a current limiting mechanism in place.