feeLLGood – finite element LLG object oriented development

feeLLGood – Tips and tricks

Here is a random collection of tips that can help you make better use of feeLLGood.

Usual workflow

The usual way to use feellgood to do some simulations is to follow the following workflow:

  1. First, prepare you mesh, using gmsh or any other mesh generation software that can provide a mesh in gmsh format. Optionally, use the rev_CMK tool if you have to reduce index spectrum.

  2. Once your mesh is ready, you have to create a YAML file with the input parameters needed by the feellgood executable. You can create the file with a text editor, or use the Python helper script settingsMaker.py to create the file in JSON format. As JSON is a subset of YAML, it is acceptable as feeLLGood's input.

  3. Run your simulation, either from a script, or with the command line using your YAML file as an input for the executable feellgood.

  4. You will need to visualize your data and/or perform some calculations on them. A tool to convert feellgood output files is provided in the tools directory. It converts the magnetization distribution in the output text files .sol in a format paraview can read directly. Some more information about the convert2vtk script is available in the section tools.

Creating a good mesh

FeeLLGood expects the mesh to be made of first order tetrahedrons and triangles, and stored in a file in the “.msh” file format. Such a mesh can be built by Gmsh. It is strongly recommended to use a constant density of tetrahedrons in the material, since it is well known that domain-walls would be strongly affected in their motion if non-uniform meshing was used. Usual other recommendations while meshing also apply while solving LLG with finite element method:

Generally speaking, a micromagnetic simulation should not depend on the mesh, so it is recommended to check the results with different meshes, and/or various meshing techniques: extrusion, 3D meshing, or others.

In a separate YAML file, you will provide all the parameters that describe your material in accordance with the region numbering system of gmsh. \( M_s \) , \( \alpha \) , and other parameters such as anisotropy constants are provided here.

Since feellgood needs regions to define boundary conditions, it is necessary to use a .geo script to generate numbered surface and volume regions. Once the mesh is done, the user just have to write a YAML file to give each material parameters for each regions.

See user documentation for more information on all the possible parameters.

Validating the simulation results

In order to qualify the simulation results, it is recommended to slightly vary:

This does definitely not prove that the calculation is correct, but at least you are sure feeLLGood converged towards a possible solution of the micromagnetic problem.