Vortex toolbox

Currently, the vortex toolbox contains functions to generate a magnetization state that approximates a vortex and to find the position of a vortex core inside a world region.

magnum.micromagnetics.toolbox.vortex.magnetizationFunction(core_x, core_y, polarization=1, chirality=1, core_radius=1e-08)

Creates a magnetization function of the form ‘lambda state,x,y,z: ...’ that is suitable to be used with the magneto.Solver.setM() method.

  • core_x – the core x position in meters
  • core_y – the core y position in meters
  • polarization – the vortex polarization, either +1 or -1 (default is +1)
  • chirality – the vortex chirality, either +1 or -1 (default is +1)
  • core_radius – a core radius parameter (default is 10e-9 meters)

the magnetization function

magnum.micromagnetics.toolbox.vortex.findCore(solver, origin_x=0.0, origin_y=0.0, body_id=None)

Tries to determine the vortex core position by finding the absolute maximum of absolute value of the z-component of the magnetization. Only 2d rectangular meshes are supported. The vortex core is determined with sub-cell precision via interpolation. The returned position can be optionally translated by (origin_x, origin_y).

  • solver (magneto.Solver) – A magneto.Solver object. The magnetization that is analyzed for the vortex core detection is taken from the magnetization of the current simulation state of the given solver object.
  • origin_x (float) – see above
  • origin_y (float) – see above
  • body_id – if given, restrict the search to this body
Return type:

2-tuple of floats

Return type:



the best guess for the vortex core position