Magnetic field lines of a bar magnet in the plane of a sheet of paper.
As the needle has a small mass and is mobile, it changes its position, taking a direction parallel to the field created by the object. The mapping of magnetic field lines provides information about the strength of a possible interaction between two magnetized objects. As we know, the interaction is greatest in the region close to the magnetic poles.
Look at the figure above: the magnetic field lines are closer together in the region of the poles than in the others. Thus, the closer the magnetic field lines are, the more intense the interaction with another magnetized object placed in that region will be.
The lines representing the magnetic field are closed, that is, they have no beginning or end. This can be observed when we place iron filings on a sheet of paper, over a bar magnet: the pattern of lines formed continues on the part of the paper that is on the magnet, closing.
No magnetic monopole
The theory of magnetism establishes a relationship between the fact that the magnetic field lines are closed and the magnetic poles, inseparable. According to this theory, closed lines evidence the impossibility of the existence of a single isolated magnetic pole: if it existed, the magnetic field lines would either start from it or end in it and would not be closed.