I liked this example of a calloway gate, it really demonstrates the concept well:
And it is something anyone can put together and experiment with, like adding a roller cam to lift the magnet over the gate.
note, you can see the bar bending in the video.