James gave some great info.
From my experiences with charges, I'd suggest not going with less than 2 joules. A shorter circuit is going to give you a harder pop than a really long circuit.
I had a 1.2 joule fence (rated for 15 miles) on a 600'~ circuit. It left welts on my skin when I hit it. On a much larger circuit the pop was way less. We run a 6 joule now on many, many miles of fencing. And as long as it's not grounded it it'll pop your socks off.
So the beauty of electric fencing, IMO, is it's super cheap, can be redone/moved very easily, and it's a psychological barrier, so even when it's not working/turned off, animals trained to it still won't be eager to go near it.
If it were me doing this fence on an AC setup, I could easily see doing it for maybe less than $500.
AC charge units are cheap and powerful! You can plug your charger in wherever it's convenient to your outlet. Something like this randomly selected 2 joule charger is $100~. You might pay up to $200 for a 'really' nice, powerful model for what you need.
https://www.amazon.com/Zareba-EAC50M-Z-AC-Powered-Low-Impedence-50-Mile-Range/dp/B0079GH4ZW/ref=sr_1_4?keywords=electric+fence+charger+2+joule&qid=1577573434&s=lawn-garden&sr=1-4
Grounding rods and fence pots have the most potential for expense. Grounding rods might be $14 a piece at a hardware or farm supply store. I've seen them as high as $45, but it depends on if you're going with copper or steel. Sometimes multiple steel rods are better than fewer copper rods. I've moved my charges many times and have rods that couldn't be extracted, so they had to be left in the ground. If you have a wet area, try sinking your rods there for better grounding. Like James said, the biggest problem with electric fencing is usually grounding issues.
Fence posts can be cheap and easy. If you don't care about aesthetic, since it's not a weight or load bearing fence (animals aren't pushing on it) you can use just about anything, as long as your wire is attached by some means of insulated clip, or the post itself is insulated. Insulated here meaning "won't conduct electricity". You can't tack hotwire to a tree or
wood post directly, it will conduct tiny amounts of electricity, more when wet. But I've strung hotwire off
trees re-using baling twine. Or twine/fencing clip combos. You can install wood posts, sure, but they're not cheap, usually $10-15 per post. There are step-in fiberglass and plastic posts made for temporary/mobile hotwire setups, these usually run $3-5 a post these days. Since it's not load bearing, you can put the posts pretty far apart (maybe 20' or more) and just tighten the wire really well. It'll need to be tightened more down the road as the materials relax and sag. Spacing your posts will save even more money.
Clips and insulators can be made out of repurposed
irrigation hose, garden hoses, and other plastics. The cheapest way to buy them, I've found, is
online in packs of 50-100+. These can get to be expensive if you're running a lot of strands of wire or buying in small quantities.
Here's a randomly selected 50 pack of clips for $17 ($.32/ea), the kind you nail to wood posts:
https://www.amazon.com/Fi-Shock-IWKNY-FS-Yellow-Economy-Insulator/dp/B00BAA4PKA/ref=sr_1_1?keywords=fencing+insulator+clips&qid=1577575334&s=lawn-garden&sr=1-1
And a randomly selected 25 pack of t-post clip insulators for $4~ ($.16/ea)
https://www.amazon.com/Zareba-ITY-Z-Standard-Snug-fitting-Insulator/dp/B005MNJOA2/ref=sr_1_2?keywords=fencing+insulator+clips&qid=1577575334&s=lawn-garden&sr=1-2
The wire itself is up to you. I've tried hard, solid wire, but it breaks easily (especially when cows abuse it) and can't be tensioned. It's also hard to see, has poor visibility. Poly tape likes to rip and break too, but has the best visibility. Visibility factor is important when you want a critter to SEE the fence and WANT to avoid it. I'm a big fan of poly rope/wire. Don't get less than 6-strand polywire if you go with that. Polywire is also the cheapest, as far as I've ever seen. I buy it in bulk online, but the 6 or 9 strand polywire at a
feed store usually isn't too badly priced. They often come in
This randomly selected 6-strand yellow polywire is 1,312 feet for $30, or $0.022 cents per foot:
https://www.amazon.com/Farmily-Portable-Electric-Polywire-Conductor/dp/B01984BOG2/ref=sr_1_1_sspa?keywords=polywire&qid=1577574314&s=lawn-garden&sr=1-1-spons&psc=1&spLa=ZW5jcnlwdGVkUXVhbGlmaWVyPUEyTVcxTTdUQk9MMVRVJmVuY3J5cHRlZElkPUEwOTU1ODEzMkMxQ0YwRzc3U1VPNiZlbmNyeXB0ZWRBZElkPUEwNjI0OTA4UUdCQzk3UkwwSjFWJndpZGdldE5hbWU9c3BfYXRmJmFjdGlvbj1jbGlja1JlZGlyZWN0JmRvTm90TG9nQ2xpY2s9dHJ1ZQ==
If you've got 1/4 acre, that's 50x50x50x50, correct? So one strand of hotwire for you property would be about 200'. That $30 roll of polywire would give you 6-strand fencing with a little extra to spare. Not that you'd need that much.
So a good bear fencing would need, more than anything, VISIBILITY. This can be done with polytape, or you can use a bright red duct tape and make little flags on your wire every few feet. Make the fence flashy somehow so the animal knows EXACTLY what it just touched that bit it so hard. Bears will not want to touch it again, especially if you popped it on the nose. The best way to do that is to bait the fence after you've got it working. Tie a hotdog or something strong and tasty onto it and the bear will try to take a bite and get popped in the face. It's not going to damage an animal, but it'll scare the wits out of it. Confusion is what makes the hotwire work; the animal doesn't know why it just got bit so hard, and it's not about to figure out how to mess with the fence without getting bit. It will just avoid the fence because it desperately doesn't want to repeat that
experience.
Baiting the fence with food is also good because the bear will get hit while intentionally interacting with the fence. So normally, if an animal tries to push through hotwire for the first time, it'll get zapped and bolt FORWARD, which puts it on the wrong side of the fence. If you bait the animal into approaching the fence, then stopping to interact with it, it will more likely run AWAY from the fence, back where it came from, and you won't have an angry, confused bear on the wrong side of your hotwire.
Once you decide on your wire choice (mesh fence, polytape, polywire, or hard wire, which can include barbed wire), you need to decide on your strand placement. I fence for goats and pigs, mostly, and to keep dogs out, so I start LOW to the ground and alternate a ground wire (which is cheap because you don't need insulator clips) and hot wires. The theory is that they get an extra hard pop when they complete the circuit by touching the hot and ground wires at the same time. Keeps critters from trying to sneak between strands. It will also zap a jumping critter if they try and jump through it. But that's different than bears. I would expect someone else here can share some bear-specific wisdom on strand placement. I'd guess that having a hotwire at 2' and at 3', with a ground in between would suffice. Get the tall bears and the small bears both. That would be a 3-strand circuit, 2 hots and a ground. But I don't know if my idea is ideal for bear deterrent.
So if you did it yourself you might have on the lowest, cheapest end:
$100 charger
$30 polywire
10 posts; every 20' in a 200' perimeter, $4~ per post = $40
No less than 4 steel grounding rods at $15~ each = $60
A few feet of copper wire for the ground (though I've used doubled-over polywire just fine), say $5 maybe
Insulator clips @ $0.35/ea, 2 clips per post if using 2 hot lines, so say 20 clips, $7
Some bright duct tape for flagging the rope, $5
If I did it myself this way I'd be paying $245 for the whole deal. If you want fancier posts, fancier wire, posts closer together (i.e. more posts), more strands, etc etc, you might run it up to the $500 mark.
The biggest things are to make sure your fence is working properly the first time the bear(s) hit it. Check it often. Get a charger that tells you how well it's working if you can (they come with light indicators or gauges to tell you if it's grounded out). And also to not pop yourself with it, lol. I hate it when I hit the electric fence...!
Edit:
You asked about a hard fence with electric strands. If I were doing it budget-style, I would do what I said above, same prices all around, but I would put a hot strand at face-level with the bear, and a hot strand over the top line of the hard fence, so hovering just above the fence if it tried to climb the fence. If you wanted a wire mesh fence, regular field fencings, which has the 6x6" squares at the top, tapering to 2x6" rectangles at the bottom, is $175~ for 360~ ft right now. That's just shy of $.50/foot. So add a $175 roll and maybe $10 in fencing staples to your fencing total.
Field fencing is hands-down the cheapest wire fencing you can buy. On it's own it's not that great. It's heavy gauge and woven together, which makes it very durable, but the large 6" squares lend to sagging and twising. Ungulates easily smash, warp, and abuse it if it's not reinforced with top and bottom rails, ir electrified. Poultry also easily fits through the holes. However. We use this fencing in conjunction with hotwire and it works just fine. We electrify for pigs and goats and dogs, like I said, so we put a hot strand about 6" off the ground to keep animals from fussing with the bottom/digging under/lifting the fence, a hot line about 2' up, at chest level with the goats so they don't climb on or rub on the fence, and a strand just over the top of the fence so if anyone DOES try to climb it, they'll still get fried at the top. Works like a charm.
We had a bear go through this setup once. The bear actually entered the pen by climbing over a wooden gate, and on its way out, it tried to climb the electrified hard wire field fence, hit the electric strand above it, freaked out, and utterly destroyed about 100' of fencing as it bolted through the wire fence, ripped it from its moorings and stretched/smashed the wire fence as it dragged the mixed fencing around, tangled in the hotwire that it also ripped off. The bear never came back. If affected about 100' of fencing and it's all funny looking now, I had to double it over to suck up the warped/stretched slack in the field fence, and reattach it to the trees it was originally stapled to. The hotwire didn't snap, all it did was pop off the insulators. I've actually never had an animal break polywire, even the cheap 3-strand stuff that I've been reusing for 4 years. It stretches out and occasionally the wire strands in it break, but I've never had the plastic wire actually break on me. I highly recommend it.