• Aceticon@lemmy.world
    link
    fedilink
    arrow-up
    21
    ·
    edit-2
    6 hours ago

    Well, I have an EE Degree specialized in Digital Systems - pretty much the opposite side of Electronic Engineering from the High Power side - and I would be almost as clueless as that guy when it comes to testing a 10,000V fence for power.

    On the other hand I do know a lot of interesting things about CPU design ;)

    • dependencyinjection@discuss.tchncs.de
      link
      fedilink
      arrow-up
      5
      ·
      3 hours ago

      What’s the most interesting thing you could tell us about CPU design, something that a layman could appreciate.

      You should know as a software developer I write inefficient code and appreciate all the extra clock cycles we get these days haha.

      • Aceticon@lemmy.world
        link
        fedilink
        arrow-up
        11
        ·
        edit-2
        2 hours ago

        First a fair warning: I learned this stuff 3 decades ago and I’ve actually been working as a programmer since then. I do believe the example I’ll provide still applies up to a point, though CPUs often implement strategies to make this less of a problem.

        =====

        CPU’s are internally like an assembly line or a processing pipeline, were the processing of an assembly instruction is broken down into a number of steps. A rough example (representative but not exactly for any specific CPU architecture) would be:

        • Step 1: fetch assembly instruction from memory
        • Step 2: fetch from into the CPU data in memory that the instruction requires (if applicable).
        • Step 3: execute arithmetic or binary operation (if applicable).
        • Step 4: evaluate conditions (if applicable)
        • Step 5: write results to memory (if applicable)

        Now, if the CPU was waiting for all the steps to be over for the processing of an assembly opcode before starting processing of the next, that would be quite a waste since for most of the time the functionality in there would be available for use but not being used (in my example, the Arithmetic Processing Unit, which is what’s used in step #3, would not be used during the time when the other steps were being done).

        So what they did was get CPUs to process multiple opcodes in parallel, so in my example pipeline you would have on opcode on stage #1, another that already did stage #1 and is on stage #2 and so on, hence why I also called it an assembly line: at each step a “worker” is doing some work on the “product” and then passing it to the next “worker” which does something else on it and they’re all working at the same time doing their thing, only each doing their bit for a different assembly instruction.

        The problem with that technique is: what happens if you have an opcode which is a conditional jump (i.e. start processing from another point in memory if a condition is valid: which is necessary to have to implement things like a “for” or “while” loop or jumping over of a block of code in an “if” condition fails)?

        Remember, in the my example pipeline the point at which the CPU finally figures out if it should jump or not is almost at the end of the pipeline (step #4), so everything before that in the pipeline might be wrong assembly instructions being processed because, say, the CPU assumed “no-jump” and kept picking up assembly instructions from the memory positions after that conditional-jump instruction but it turns out it does have to jump so it was supposed to be processing instructions from somewhere else in memory.

        The original naive way to handle this problem was to not process any assembly instructions after a conditional jump opcode had been loaded in step #1 and take the processing of the conditional jump through each step of the pipeline until the CPU figured out if the jump should occur or not, by which point the CPU would then start loading opcodes from the correct memory position. This of course meant every time a conditional jump appeared the CPU would get a lot slower whilst processing it.

        Later, the solution was to do speculative processing: the CPU tried to guess if it would the condition would be true (i.e. jump) or false (not jump) and load and start processing the instructions from the memory position matching that assumption. If it turned out the guess was wrong, all the contents of the pipeline behind that conditional jump instruction would be thrown out. This is part of the reason why the pipeline is organised in such a way that the result of the work only ever gets written to memory at the last step - if it turns out it was working in the wrong instructions, it just doesn’t do the last step for those wrong instructions. This is in average twice as fast as the naive solution (and better guessing makes it faster still) but it still slowed down the CPU every time a conditional jump appeared.

        Even later the solution was to do the processing of both branches (i.e. “jump” and “no-jump”) in parallel and then once the condition had been evaluated throw out the processing for the wrong branch and keep doing the other one. This solved the speed problem but at the cost of having double of everything, plus had some other implications on things such as memory caching (which I’m not going to go into here as that’s a whole other Rabbit Hole)

        Whilst I believe modern CPUs of the kind used in PCs don’t have this problem (and probably also at least ARM7 and above), I’ve actually been doing some Shader programming of late (both Computing and Graphics Shaders) and if I interpreted what I read correctly a version of this kind of problem still affected GPUs not that long ago (probably because GPUs work by having massive numbers of processing units which work in parallel, so by necessity they are simple) though I believe nowadays it’s not as inadvisable to use “if” when programming shaders as it used to be a few years ago.

        Anyways, from a programming point of view, this is the reason why C compilers have an optimization option of doing something called “loop unrolling” - if you have a “for” loop with a fixed number of iterations known at compile time - for example for(int i = 0; i < 5; i++){ /* do stuff */ } - the compiler instead of generating in assembly a single block of code with the contents of the “for” loop and a conditional jump at the end, will instead “unroll the loop” by generating the assembly for the body of the loop as many times as the loop would loop - so in my example the contents of that “for” loop would end up as 5 blocks in assembly each containing the assembly for the contents, one after the other, the first for i=0, the next for i=1 and so on.

        As I said, it’s been a long time since I’ve learned this and I believe nowadays general CPUs implement strategies to make this a non-problem, but if you’re programming microcontrollers or doing stuff like Compute Shaders to run on GPUs, I believe it’s actually the kind of thing you still have to take in account if you want max performance.

        Edit: Just remembered that even the solution of doing the parallel execution of both branches doesn’t solve everything. For example, what if you have TWO conditional jump instructions one after the other? Theoretically would need almost 4 or everything to handle parallel execution for it. How about 3 conditional jumps? “Is you nested for-loop screwing your performance? More news at 11!”. As I said, this kind of stuff is a bit of a Rabbit Hole.

  • MehBlah@lemmy.world
    link
    fedilink
    English
    arrow-up
    16
    arrow-down
    2
    ·
    8 hours ago

    He is already standing too close and that stick would arc with that many volts flowing through it. The most likely outcome in reality if it had been energized. The arc would have jumped from the stick to him and no more New Zealand guy.

    • MonkderVierte@lemmy.ml
      link
      fedilink
      arrow-up
      4
      ·
      3 hours ago

      With only 10’000 V? That’s a common Livestock Guardian*. Reaches at most 1 cm.

      * though it probably has enough ampere to kill a cow

  • Th4tGuyII@fedia.io
    link
    fedilink
    arrow-up
    48
    ·
    12 hours ago

    As someone who has worked with academics, the more specialised the person, the less common sense they seem to hold onto.

    As such, if this was outside their PhD specialisation, then it’d absolutely make sense that this wouldn’t occur to them.

    • NewAgeOldPerson@lemmy.world
      link
      fedilink
      arrow-up
      6
      ·
      6 hours ago

      My professor (computer science - NP complete problems specific) had a theory.

      Higher up your education, more and more you learn about less and less.

      I am convinced he accidentally stumbled across Buddhism all on his own (he was a religious Christian, the generous, do not judge others kind). Because Buddha seems to have done his PhD in nothing. Even “wrote” the whole dissertation on nothingness.

    • cynar@lemmy.world
      link
      fedilink
      English
      arrow-up
      4
      ·
      6 hours ago

      My university basically gave up with a couple of professors. They hired a personal assistant, full time, just to try and keep them organised. They apparently settled on 3 phone calls, to make sure they made lectures on time. It even extended to things like reminding them to actually get their wives birthday presents, and personal book keeping.

      It seems the human brain has a capacity limit. The more specialist knowledge shoved in, the less room for more normal knowledge. Eventually it displaces even the most basic common sense.

      • bleistift2@sopuli.xyz
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        2 hours ago

        Meet the German word Fachidiot: (derogatory) A person who is only interested in their own trade or research area and has few or no other interests or skills.

    • Case@lemmynsfw.com
      link
      fedilink
      arrow-up
      4
      ·
      7 hours ago

      I’d like to report that the more specialized a medical doctor is, the less common sense they have.

      Had a doctor chew me out because he couldn’t be bothered to simply turn the computer on.

      That was the issue. Pushing a button was beneath him. Cool man, I’m the only one here at this hour and the phones have to be manned constantly. That ticket can go to another department and wait until they come in morning.

      Also, low priority and I noted that the doctor refused to simply turn it on.

      I think that ticket sat there for over a month.

  • Lev_Astov@lemmy.world
    link
    fedilink
    arrow-up
    88
    ·
    edit-2
    20 hours ago

    At 10kV, a random stick would be all it takes to start an arc. He knows what he’s doing.

    • Aceticon@lemmy.world
      link
      fedilink
      arrow-up
      5
      arrow-down
      1
      ·
      edit-2
      6 hours ago

      I’m genuinelly curious were you got that from.

      I actually went and checked the minimum air gap to avoid arcing at 10,000V at standard sea level air pressure and it’s actually measured in millimeters.

      Further, is the voltage differential there between parallel conducting lines or is it between the lines and the ground?

      I’m really having trouble seing how a dry stick would cause arcing between two of those lines short of bringing them nearer than 4 mm in the first case, much less between one of the lines and the ground in the second case if its being held at chest level.

      PS: Mind you, it does make sense with a stick which is not dry - since the water in it makes it conductive - but then the guy himself would be part of the conductive circuit, which kinda defeats the point of using a stick.

      • BearGun@ttrpg.network
        link
        fedilink
        arrow-up
        3
        ·
        2 hours ago

        What you want to do is create an arc between the stick and the line, and not have it transfer to you. A dry stick would do this quite well, since it would be at ground voltage and as such would provoke a short arc without electrocuting yourself. The fence also probably doesn’t have all that much power, likely can’t deliver more than a few amps, so it would be quite safe even.

    • stupidcasey@lemmy.world
      link
      fedilink
      arrow-up
      40
      ·
      edit-2
      18 hours ago

      True, True… Hay who thought it was safe to run 10,000V Wire through a flammable overgrown jungle?

  • vzq@lemmy.blahaj.zone
    link
    fedilink
    arrow-up
    194
    arrow-down
    1
    ·
    1 day ago

    As a PhD who has tried doing home improvement projects, it’s the most believable thing in the film.

    • ByteOnBikes@slrpnk.net
      link
      fedilink
      English
      arrow-up
      21
      ·
      22 hours ago

      Some pleeb shouted at me, “I thought you were an engineer!” And I shouted back, “A software engineer!” while I hammer a nail with my shoe.

        • skulblaka@sh.itjust.works
          link
          fedilink
          arrow-up
          13
          ·
          21 hours ago

          The difference between a regular idiot doing a dangerous job and an engineer doing a dangerous job is the engineer knows which parts of the job he’s risking imminent death on. There may often be no other difference.

          • Aceticon@lemmy.world
            link
            fedilink
            arrow-up
            2
            ·
            edit-2
            6 hours ago

            When it comes to an engineer doing a dangerous job in a domain other than his or her own, I would say that all the engineer knows is how bad things can be fucked up when one is trying to do expert stuff outside one’s own domain, because they’ve been in a position were they were the experts and some non-expert was saying things and trying stuff for their expert domain.

            After seeing others do it in one’s own expert domain one generally realizes that “maybe, just maybe, that’s exactly how I look outside my domain of expertise to the experts of that domain when I open my big fat mouth”.

    • Bob@feddit.nl
      link
      fedilink
      arrow-up
      37
      arrow-down
      1
      ·
      1 day ago

      Actually some of the most naïve people I’ve ever met were theretofore academically successful.

    • 0x4E4F@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      20
      ·
      edit-2
      1 day ago

      Really?

      Genuinely asking, I’m just an engineer… with very very bad grades. Passed was enough for me.

      Once a professor asked me if I wanted to take the exam again because it was clear that I knew more than what I showed on the exam (a lot of 2 + 2 = 5 mistakes, I was fairly good at that and owe most of my low grades to that). I asked him if I passed, he said yes. Fuck that shit, I’m taking that grade and parading it across town, wooohoo 🥳.

  • MalReynolds@slrpnk.net
    link
    fedilink
    English
    arrow-up
    36
    arrow-down
    1
    ·
    22 hours ago

    I don’t remember the scene, but personally I’d test an electric fence with a nonconductor. You’ll probably get some sparks but won’t die. You do you, ppl in this thread.

    • Aceticon@lemmy.world
      link
      fedilink
      arrow-up
      6
      ·
      6 hours ago

      At 10,000V and at sea level, you need to be at about 4mm from that fence for the air to arce.

      A few posts above I was curious and actually went and checked it.

    • SzethFriendOfNimi@lemmy.world
      link
      fedilink
      arrow-up
      47
      ·
      1 day ago

      Air only has so much resistance itself. High enough voltage and the closest path to ground is where the charge will go.

      Just like with Lightning

      • nilloc@discuss.tchncs.de
        link
        fedilink
        English
        arrow-up
        5
        ·
        8 hours ago

        Humidity in the air makes that wayyy more dangerous because your skin will be highly conductive and the lower the resistance, the higher the current (which is what really hurts).

        I’ve been a human grounding strap a couple times and don’t recommend it. I think the vibrating pain of AC (someone reenergized the outlet on me) is worse than the punch of high voltage (failing spark plug wire I grabbed with metal pliers while diagnosing a misfire).

    • thefartographer@lemm.ee
      link
      fedilink
      arrow-up
      33
      ·
      1 day ago

      My arm once got pulled into an electric fence when I was a kid and I couldn’t stop getting shocked until someone physically pulled me away. It was more of a self-control issue than accidentally bridging the gap.

      That was the day I learned that some pain can be pleasant. The owner of the property didn’t seem as pleased with my discovery as I did. He had to shut off the fence and yanked my arm away and then told me to go explore my perversions somewhere else. I was too young to understand the word “perversion,” and I’m now eternally grateful to that poor unprepared rancher.

      • Faresh@lemmy.ml
        link
        fedilink
        English
        arrow-up
        5
        ·
        23 hours ago

        You find it enjoyable? I regularly touch electric fences, but not because I want to but because I’m too stupid to think of another way to figure out if the thing is working. I find it to be the opposite of pleasant.

        • bastion@feddit.nl
          link
          fedilink
          arrow-up
          8
          ·
          21 hours ago

          Oh. Here’s your fix:

          A longish piece of green grass. Hold it by one end, then slide it on the fence wire like the grass was a violin bow, getting your fingers closer and closer to the fence. At some point you notice a pinging, or your fingers are touching the fence.

          You can use this to gauge, very roughly, how powerful the charge is at that point.

        • thefartographer@lemm.ee
          link
          fedilink
          arrow-up
          10
          arrow-down
          2
          ·
          edit-2
          13 hours ago

          I never said it was pleasant. But sometimes some types of pain are the right kind of pain.

          Example of the opposite: when I’m swapping a switch in my old-ass house, sometimes I’m too lazy to turn off the breaker. When I inevitably shock myself, I say “dammit” because I’m trying to concentrate, not discover my preteen proclivities.

          Edit: well slap me silly and call me a liar, I literally said the words “some pain can be pleasant.” I blame this error on undeserved confidence and complacency.

    • absGeekNZ@lemmy.nz
      link
      fedilink
      English
      arrow-up
      16
      ·
      1 day ago

      At approx 3kV/mm, you would have to be pretty close to a 10kV fence.

      Humidity plays a big role as does the frequency that the fence is running on. But you would be pretty safe standing a meter away, on that dry sunny day in the picture.

      Also above a point, the high voltage causes the conductors to buzz.

      • Aceticon@lemmy.world
        link
        fedilink
        arrow-up
        1
        ·
        6 hours ago

        If I’m not mistaking the buzz is because it’s AC hence the buzz frequency is the same as the AC’s.

        Certainly it makes sense that the high voltage would be generated from mains power using a big fat transformer since that’s probably the simplest way to do it.

        • absGeekNZ@lemmy.nz
          link
          fedilink
          English
          arrow-up
          2
          ·
          2 hours ago

          Yep.

          The highest DC voltage I have been near is around 1000V, it didn’t buzz, but 1000V AC also doesn’t buzz…

        • Zink@programming.dev
          link
          fedilink
          arrow-up
          1
          ·
          8 hours ago

          An interesting way to hear this without endangering yourself is to be near transmission lines in a light rain. Some go over a local park near me, and it’s wild how well you can hear it sometimes.

        • absGeekNZ@lemmy.nz
          link
          fedilink
          English
          arrow-up
          4
          ·
          23 hours ago

          In some way it is comforting, you know the power is where it is supposed to be… Walking around a 11kV switchyard that buzz is good.

    • Grumpy@sh.itjust.works
      link
      fedilink
      arrow-up
      12
      ·
      1 day ago

      I have a 10KV electric fence. 5KV to 15KV is typical electric fence voltage in a farm or bear prevention fence. Can’t feel a thing unless you actually touch it.

      They are also not lethal. Very low current, just very high voltage. So it only hurts like fuck, but won’t kill a human, cow, or any other mammal that touches it.

      • bastion@feddit.nl
        link
        fedilink
        arrow-up
        5
        arrow-down
        1
        ·
        21 hours ago

        They can kill an animal (including a mammal) if they become entangled and give up out of suffering, though.

        This is pretty rare, but can happen.

        It’s virtually zero risk to a human, though, who can cognize things like getting their hand disentangled from a string (even in a panic situation), or to most mammals, which tend to jerk backwards on contact.

    • jubilationtcornpone@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      8
      ·
      1 day ago

      This is why you should never try to remove a tree from a power line yourself.

      Electricity always takes the path of least resistance back to the source. A tree, and possibly your body, may end up being the “path of least resistance”.

      You won’t know if YOU are the path of least resistance or it the line is even energized until it’s too late.