Magnetic field calculations are often a bit more complicated than electrostatic ones since potential is a vector and there are complications of permeability, current density, and hysteresis.
In SIMION, there are two main ways to define a magnetic field:
- in terms of magnetic scalar potentials
- in terms of magnetic field vectors
These two cases are explained below:
- in terms of magnetic scalar potentials – Scalar magnetic potential is analogous to scalar potential in electric fields (i.e. voltage). The magnetic field vector is the negative gradient of scalar magnetic potential, just as the electric field vector is the negative gradient of electrostatic potential. SIMION can solve scalar magnetic potential using the Laplace equation in the same manner as electric potential is solved, and after doing so the magnetic field vector can be immediately obtained and used for particle trajectory solving. Unfortunately, not all magnetic fields can be expressed as scalars but rather as vectors, and the meaning of potential can be less intuitive with magnetic fields. Magnetic potential will be a scalar under certain conditions, such as when there is no current density in the domain modeled (and in a different way if the system has 2D planar symmetry). Beware also that, unlike the electrostatic case, magnetic pole surfaces do not generally have totally uniform magnetic potential across their surfaces, permeability not being infinite (see p. 2-10 of chapter 2 the SIMION 8.0/7.0 manual for a discussion of this). This presents a difficulty because surfaces of constant potential are normally used to define boundary conditions for the field solver. However, if permeabilities are infinite, or at least very large, and the region is sufficiently defined, then surfaces will have constant potential, and the boundary conditions are more readily definable in SIMION. Often, there is only one potential difference (i.e. between two poles) to define, and that potential can be scaled to give the desired field intensity between the magnetic poles.
Technically speaking, in SIMION, scalar magnetic potential is
typically expressed in terms of a SIMION potential array. In
SIMION, you can create a magnetic potential array just like you
create an electrostatic potential array; a magnetic potential array
can contain magnetic electrodes of arbitrary shape and that are
assigned scalar magnetic potentials. You can then have SIMION
refine it, in which case SIMION calculates scalar magnetic
potential of the non-pole points by using the Laplace equation,
just like for electrostatic electrodes. SIMION then uses these to
compute magnetic fields in space. You may need to set the magnetic
scaling factor so that the fields corresponds to real units of
Gauss. The calculated fields can even be non-uniform with fringing
effects as seen in SIMION's magnet examples (e.g. see
`screenshots Related Resources: It’s very common to require simply a constant magnetic field, so we
describe that here. There are two main methods to define a constant
magnetic field in SIMION: with a user program or without a user
program. Each is explained below. Both methods are almost equally
suitable, but the user program approach is recommended because it
avoids magnetic potentials and therefore can be more intuitive. For this example, we’ll assume you want a constant 100 Gauss
magnetic field in the +X direction. This works as follows. When you fly particles, SIMION sees the
system contains mag.pa. SIMION then looks for a corresponding user
program of the same name (mag.prg) and loads it if it finds it.
Now, whenever a particle is flying inside mag.pa, the user program
applies a constant magnetic field to the particle. Some important points: Though the above solution works in SIMION 8 too, in SIMION 8 you
may alternately write the program in Lua. Create the file
“system.lua” (assuming “system.iob” is the name of your
‘’workbench’‘) as follows: An alternate method of creating a magnetic field is to create
magnetic pole in a magnetic PA. The negative gradient of the scalar
magnetic potential then defines the magnetic field. This is
suggested on p. 2-10 of the SIMION 7.0 manual. It is illustrated
below. In particular note the annotations in red: Mu metals (i.e. high permeability) can be well handled in SIMION.
See the discussion in Floating Conductor and the user group
posts linked from that page. The approach for doing Mu metals is
similar as noted in the user group posts.
Applying a constant magnetic field¶
Via a user program in SIMION 6 or 7 (also works in 8)¶
defa bx 100 ; Gauss
seg mfield_adjust
rcl bx sto ion_bfieldx_gu
Via a user program in SIMION 8¶
simion.workbench_program()
adjustable bx = 100
function segment.mfield_adjust()
ion_bfieldx_gu = bx -- gauss
end
Via magnetic potentials in a PA¶
Mu Metals (High Permeability)¶
