To visualise the magnetic fields around arbitrary conducting lines, a
computer simulation program was written. Because the magnetic field
is always perpendicular to the sample plane (confer figure
1.10) the program only needs to calculate the
magnitude of the magnetic field, which reduces the problem to
two-dimensions (please see the CD for the source code of the simulation
program).
0.5
![]() |
The following variables have to be defined for the computer-simulations
to calculate the magnetic fields. First of all, a matrix of
grid points is set and the size of one grid point is defined. Then, the
conducting lines are set into the matrix by defining the start- and
endpoint of the conducting line. Additionally, the width of the
conducting line and the current through it is set. Finally, the number
of iterations per gridwidth for the conducting lines is set. So the
conducting line is cut into many pieces, and for every piece the
magnetic field is calculated at every gridpoint
with the law of
Biot-Savart (see figure 1.11). The accuracy of the
output can be tested by incrementing the iterations per gridwidth until
the output doesn't change significantly and by comparing with analytic
solutions of model problems.
[Four crossing lines that are not connected to each other] ![]() ![]() |
The output of the program is a matrix, containing the magnitude of the magnetic field for every grid point. The resulting matrix can then easily be normalised and displayed as a coloured images. Figure 1.12 shows two examples of the computer-simulations. The top image shows the defined conducting lines and the bottom image the normalised magnetic field. The magnetic field changes in the bottom images from low (black) to high (white). The images also show lines of equal magnetic fields to enhance the visibility. It is easy to spot the gradient that is perpendicular to the equipotential lines. As can be seen in figure 1.12(a), the corners of crossing conducting lines have the highest magnetic field and are local maxima. The inner corners have higher fields due to higher fractions of all four lines, although the outer corners are still local maxima. In figure 1.12(b) it can be seen that the magnetic gradient points to the smallest distance between the two conducting lines.
Although the program was a good starting point to develop the different designs that were used for the conducting lines in this thesis, it is neither fast nor sophisticated enough to calculate a complete setup in a reasonable time. Furthermore, it would be advantageous to be able to simulate the influence of the viscosity together with the magnetic force in order to gain insight in the real flowing behaviour of a bead. A professional finite-element simulation program would be more suitable for such a task.