spirit-code / spirit

Atomistic Spin Simulation Framework
http://spirit-code.github.io
MIT License
117 stars 52 forks source link

Docs update #564

Closed GPMueller closed 3 years ago

GPMueller commented 4 years ago

Closes issue #251. Closes issue #534.

coveralls commented 4 years ago

Coverage Status

Coverage remained the same at 79.423% when pulling 8ee744a605e1119a61c9a047035c323b365cf6c7 on docs-update into 55cc299074d9947a3838d47c31e41f1a1ea691ba on develop.

codecov[bot] commented 4 years ago

Codecov Report

Merging #564 (8ee744a) into develop (55cc299) will not change coverage. The diff coverage is n/a.

@@           Coverage Diff            @@
##           develop     #564   +/-   ##
========================================
  Coverage    50.26%   50.26%           
========================================
  Files           88       88           
  Lines        10179    10179           
========================================
  Hits          5116     5116           
  Misses        5063     5063           
GPMueller commented 4 years ago

@MSallermann pointed out that the Hamiltonian has a visual bug in the pairs <ij>:

\begin{alignedat}{1}
    \mathcal{H} =
      &- \sum_i \mu_i \vec{B}\cdot\vec{n}_i
       - \sum_i \sum_j K_j (\hat{K}_j\cdot\vec{n}_i)^2\\
      &- \sum\limits_{\braket{ij}}\, J_{ij} \vec{n}_i\cdot\vec{n}_j
       - \sum\limits_{\braket{ij}}\, \vec{D}_{ij} \cdot (\vec{n}_i\times\vec{n}_j)\\
      &+ \frac{1}{2}\frac{\mu_0}{4\pi} \sum_{\substack{i,j \\ i \neq j}} \mu_i \mu_j \frac{(\vec{n}_i \cdot \hat{r}_{ij}) (\vec{n}_j\cdot\hat{r}_{ij}) - \vec{n}_i \vec{n}_j}{{r_{ij}}^3}
\end{alignedat}

produces Equation


Also, any suggestions where to put things like the topological charge?

Q = \frac{1}{4\pi} \int_{\mathbb{R}^2} \vec{n} \cdot (\partial_x \vec{n} \times \partial_y \vec{n})\, \mathrm{d}\vec{r} 

and discretised

Q= \frac{1}{4\pi}\sum_l A_l
\cos\left(\frac{A_l}{2}\right)=\frac{1  + \vec{n}_i \cdot \vec{n}_j + \vec{n}_i \cdot \vec{n}_k + \vec{n}_j \cdot \vec{n}_k}
    {\sqrt{2\left(1+\vec{n}_i\vec{n}_j\right)\left(1+\vec{n}_j\vec{n}_k
    \right)\left(1+\vec{n}_k\vec{n}_i\right)}}

Equation etc.

It might also be nice to add our definitions for the equations for LLG, GNEB and HTST somewhere. Personally, I would not add equations into API docs, maybe a centralised "definitions" page would be better?

GPMueller commented 4 years ago

Actually, we can use much wider equations, as the page width gives plenty room: https://spirit-docs.readthedocs.io/en/docs-update/core/docs/Input.html#heisenberg-hamiltonian-a-name-heisenberg-a