Modules¶
Overview:
- ExchangeField
- StrayField
- AnisotropyField
- ExternalField
- LandauLifshitzGilbert
LandauLifshitzGilbert¶
This is the module that is needed to compute the Landau-Lifshitz-Gilbert equation. It is included by default by the create_solver function and thus must not be specified in its module inclusion list.
Variable | Mode | Type | Unit | Description |
---|---|---|---|---|
M | in/out | VF | A/m | The current magnetization vector field |
dMdt | out | VF | A/m per s | Change of magnetization M (e.g. LHS of LLG-Equation) |
H_eff | out | VF | A/m | Effective magnetic field |
E_eff | out | S | J | Effectice field energy |
alpha | parameter | F | Damping constant | |
Ms | parameter | F | A/m | Saturation magnetization |
Input variables: Any effective field contribution H_xyz from activated modules (A/m, VF)
ExchangeField¶
Variable | Mode | Type | Unit | Description |
---|---|---|---|---|
H_exch | out | VF | A/m | Exchange field |
E_exch | out | S | J | Exchange field energy |
A | parameter | F | J/m | Exchange stiffness constant |
Input variables: M (A/m, VF), Ms (A/m, F)
StrayField¶
Variable | Mode | Type | Unit | Description |
---|---|---|---|---|
H_stray | out | VF | A/m | Strayfield |
E_stray | out | S | J | Strayfield energy |
Input variables: M (A/m, VF)
Example:
from magnum import *
# 100x100 cells, cellsize 1 nm x 1 nm x 4 nm
mesh = RectangularMesh((100,100,1), (1e-9, 1e-9, 4e-9))
world = World(mesh, Body("all", Material.Py(), Everywhere()))
solver = create_solver(world, [StrayField, ExchangeField])
# Initialize magnetization M
solver.state.M = (8e5,0,0)
# or:
# solver.state.M = readOMF("M.omf")
# Calculate and store stray field generated by M
writeOMF("strayfield.ohf", solver.state.H_stray)
# Print stray field energy
print(solver.state.E_stray)
AnisotropyField¶
- Inputs: M
- Outputs: H_aniso, E_aniso
- Defines parameters: k_uniaxial, k_cubic, axis1, axis2