|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!DOCTYPE html>
|
|
|
|
|
<html class="writer-html5" lang="en" data-content_root="../">
|
|
|
|
|
<head>
|
|
|
|
|
<meta charset="utf-8" /><meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
|
|
|
|
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
|
|
<title>grogupy.magnetism module — grogupy 1.0.0 documentation</title>
|
|
|
|
|
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=80d5e7a1" />
|
|
|
|
|
<link rel="stylesheet" type="text/css" href="../_static/css/theme.css?v=e59714d7" />
|
|
|
|
|
<link rel="stylesheet" type="text/css" href="../_static/sphinx-design.min.css?v=95c83b7e" />
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<script src="../_static/jquery.js?v=5d32c60e"></script>
|
|
|
|
|
<script src="../_static/_sphinx_javascript_frameworks_compat.js?v=2cd50e6c"></script>
|
|
|
|
|
<script src="../_static/documentation_options.js?v=8d563738"></script>
|
|
|
|
|
<script src="../_static/doctools.js?v=9a2dae69"></script>
|
|
|
|
|
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
|
|
|
|
|
<script src="../_static/design-tabs.js?v=f930bc37"></script>
|
|
|
|
|
<script src="../_static/js/theme.js"></script>
|
|
|
|
|
<link rel="index" title="Index" href="../genindex.html" />
|
|
|
|
|
<link rel="search" title="Search" href="../search.html" />
|
|
|
|
|
<link rel="next" title="grogupy.utilities module" href="grogupy.utilities.html" />
|
|
|
|
|
<link rel="prev" title="grogupy.io module" href="grogupy.io.html" />
|
|
|
|
|
</head>
|
|
|
|
|
|
|
|
|
|
<body class="wy-body-for-nav">
|
|
|
|
|
<div class="wy-grid-for-nav">
|
|
|
|
|
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
|
|
|
|
|
<div class="wy-side-scroll">
|
|
|
|
|
<div class="wy-side-nav-search" >
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<a href="../index.html" class="icon icon-home">
|
|
|
|
|
grogupy
|
|
|
|
|
</a>
|
|
|
|
|
<div role="search">
|
|
|
|
|
<form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
|
|
|
|
|
<input type="text" name="q" placeholder="Search docs" aria-label="Search docs" />
|
|
|
|
|
<input type="hidden" name="check_keywords" value="yes" />
|
|
|
|
|
<input type="hidden" name="area" value="default" />
|
|
|
|
|
</form>
|
|
|
|
|
</div>
|
|
|
|
|
</div><div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="Navigation menu">
|
|
|
|
|
<p class="caption" role="heading"><span class="caption-text">Getting started</span></p>
|
|
|
|
|
<ul>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../introduction.html">Introduction</a></li>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../quickstart/index.html">Quickstart</a></li>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../cite.html">Citing grogupy</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
<p class="caption" role="heading"><span class="caption-text">User Guide</span></p>
|
|
|
|
|
<ul>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../tutorials/index.html">Tutorials</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
<p class="caption" role="heading"><span class="caption-text">Advanced usage</span></p>
|
|
|
|
|
<ul class="current">
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="modules.html">src</a></li>
|
|
|
|
|
<li class="toctree-l1 current"><a class="reference internal" href="grogupy.html">grogupy package</a><ul class="current">
|
|
|
|
|
<li class="toctree-l2 current"><a class="reference internal" href="grogupy.html#submodules">Submodules</a><ul class="current">
|
|
|
|
|
<li class="toctree-l3"><a class="reference internal" href="grogupy.core.html">grogupy.core module</a></li>
|
|
|
|
|
<li class="toctree-l3"><a class="reference internal" href="grogupy.grogu.html">grogupy.grogu module</a></li>
|
|
|
|
|
<li class="toctree-l3"><a class="reference internal" href="grogupy.io.html">grogupy.io module</a></li>
|
|
|
|
|
<li class="toctree-l3 current"><a class="current reference internal" href="#">grogupy.magnetism module</a><ul>
|
|
|
|
|
<li class="toctree-l4"><a class="reference internal" href="#grogupy.magnetism.blow_up_orbindx"><code class="docutils literal notranslate"><span class="pre">blow_up_orbindx()</span></code></a></li>
|
|
|
|
|
<li class="toctree-l4"><a class="reference internal" href="#grogupy.magnetism.calculate_anisotropy_tensor"><code class="docutils literal notranslate"><span class="pre">calculate_anisotropy_tensor()</span></code></a></li>
|
|
|
|
|
<li class="toctree-l4"><a class="reference internal" href="#grogupy.magnetism.calculate_exchange_tensor"><code class="docutils literal notranslate"><span class="pre">calculate_exchange_tensor()</span></code></a></li>
|
|
|
|
|
<li class="toctree-l4"><a class="reference internal" href="#grogupy.magnetism.parse_magnetic_entity"><code class="docutils literal notranslate"><span class="pre">parse_magnetic_entity()</span></code></a></li>
|
|
|
|
|
<li class="toctree-l4"><a class="reference internal" href="#grogupy.magnetism.spin_tracer"><code class="docutils literal notranslate"><span class="pre">spin_tracer()</span></code></a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="toctree-l3"><a class="reference internal" href="grogupy.utilities.html">grogupy.utilities module</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="toctree-l2"><a class="reference internal" href="grogupy.html#module-grogupy">Module contents</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="environment.html">Environment variables</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
<p class="caption" role="heading"><span class="caption-text">Development</span></p>
|
|
|
|
|
<ul>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../dev/index.html">Contributing to grogupy</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
<p class="caption" role="heading"><span class="caption-text">Extras</span></p>
|
|
|
|
|
<ul>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../changelog/index.html">Changelog</a></li>
|
|
|
|
|
<li class="toctree-l1"><a class="reference internal" href="../bibliography.html">Bibliography</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</nav>
|
|
|
|
|
|
|
|
|
|
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"><nav class="wy-nav-top" aria-label="Mobile navigation menu" >
|
|
|
|
|
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
|
|
|
|
|
<a href="../index.html">grogupy</a>
|
|
|
|
|
</nav>
|
|
|
|
|
|
|
|
|
|
<div class="wy-nav-content">
|
|
|
|
|
<div class="rst-content">
|
|
|
|
|
<div role="navigation" aria-label="Page navigation">
|
|
|
|
|
<ul class="wy-breadcrumbs">
|
|
|
|
|
<li><a href="../index.html" class="icon icon-home" aria-label="Home"></a></li>
|
|
|
|
|
<li class="breadcrumb-item"><a href="modules.html">src</a></li>
|
|
|
|
|
<li class="breadcrumb-item"><a href="grogupy.html">grogupy package</a></li>
|
|
|
|
|
<li class="breadcrumb-item active">grogupy.magnetism module</li>
|
|
|
|
|
<li class="wy-breadcrumbs-aside">
|
|
|
|
|
<a href="../_sources/implementation/grogupy.magnetism.rst.txt" rel="nofollow"> View page source</a>
|
|
|
|
|
</li>
|
|
|
|
|
</ul>
|
|
|
|
|
<hr/>
|
|
|
|
|
</div>
|
|
|
|
|
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
|
|
|
|
|
<div itemprop="articleBody">
|
|
|
|
|
|
|
|
|
|
<section id="module-grogupy.magnetism">
|
|
|
|
|
<span id="grogupy-magnetism-module"></span><h1>grogupy.magnetism module<a class="headerlink" href="#module-grogupy.magnetism" title="Link to this heading"></a></h1>
|
|
|
|
|
<dl class="py function">
|
|
|
|
|
<dt class="sig sig-object py" id="grogupy.magnetism.blow_up_orbindx">
|
|
|
|
|
<span class="sig-prename descclassname"><span class="pre">grogupy.magnetism.</span></span><span class="sig-name descname"><span class="pre">blow_up_orbindx</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">orb_indices</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/grogupy/magnetism.html#blow_up_orbindx"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogupy.magnetism.blow_up_orbindx" title="Link to this definition"></a></dt>
|
|
|
|
|
<dd><p>Function to blow up orbital indices to make SPIN BOX indices.</p>
|
|
|
|
|
<dl class="simple">
|
|
|
|
|
<dt>Args:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>orb_indices<span class="classifier">np.array_like</span></dt><dd><p>These are the indices in ORBITAL BOX</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>Returns:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>orb_indices<span class="classifier">np.array_like</span></dt><dd><p>These are the indices in SPIN BOX</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd></dl>
|
|
|
|
|
|
|
|
|
|
<dl class="py function">
|
|
|
|
|
<dt class="sig sig-object py" id="grogupy.magnetism.calculate_anisotropy_tensor">
|
|
|
|
|
<span class="sig-prename descclassname"><span class="pre">grogupy.magnetism.</span></span><span class="sig-name descname"><span class="pre">calculate_anisotropy_tensor</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">mag_ent</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/grogupy/magnetism.html#calculate_anisotropy_tensor"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogupy.magnetism.calculate_anisotropy_tensor" title="Link to this definition"></a></dt>
|
|
|
|
|
<dd><p>Calculates the renormalized anisotropy tensor from the energies.</p>
|
|
|
|
|
<p>It uses the grogu convention for output.</p>
|
|
|
|
|
<dl class="simple">
|
|
|
|
|
<dt>Args:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>mag_ent<span class="classifier">dict</span></dt><dd><p>An element from the magnetic entities</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>Returns:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>K<span class="classifier">np.array_like</span></dt><dd><p>elements of the anisotropy tensor</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd></dl>
|
|
|
|
|
|
|
|
|
|
<dl class="py function">
|
|
|
|
|
<dt class="sig sig-object py" id="grogupy.magnetism.calculate_exchange_tensor">
|
|
|
|
|
<span class="sig-prename descclassname"><span class="pre">grogupy.magnetism.</span></span><span class="sig-name descname"><span class="pre">calculate_exchange_tensor</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">pair</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/grogupy/magnetism.html#calculate_exchange_tensor"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogupy.magnetism.calculate_exchange_tensor" title="Link to this definition"></a></dt>
|
|
|
|
|
<dd><p>Calculates the exchange tensor from the energies.</p>
|
|
|
|
|
<p>It produces the isotropic exchange, the relevant elements
|
|
|
|
|
from the Dzyaloshinskii-Morilla (Dm) tensor, the symmetric-anisotropy
|
|
|
|
|
and the complete exchange tensor.</p>
|
|
|
|
|
<dl class="simple">
|
|
|
|
|
<dt>Args:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>pair<span class="classifier">dict</span></dt><dd><p>An element from the pairs</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>Returns:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>J_iso<span class="classifier">float</span></dt><dd><p>Isotropic exchange (Tr[J] / 3)</p>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>J_S<span class="classifier">np.array_like</span></dt><dd><p>Symmetric-anisotropy (J_S = J - J_iso * I ––> Jxx, Jyy, Jxy, Jxz, Jyz)</p>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>D<span class="classifier">np.array_like</span></dt><dd><p>DM elements (Dx, Dy, Dz)</p>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>J<span class="classifier">np.array_like</span></dt><dd><p>Complete exchange tensor flattened (Jxx, Jxy, Jxz, Jyx, Jyy, Jyz, Jzx, Jzy, Jzz)</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd></dl>
|
|
|
|
|
|
|
|
|
|
<dl class="py function">
|
|
|
|
|
<dt class="sig sig-object py" id="grogupy.magnetism.parse_magnetic_entity">
|
|
|
|
|
<span class="sig-prename descclassname"><span class="pre">grogupy.magnetism.</span></span><span class="sig-name descname"><span class="pre">parse_magnetic_entity</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">dh</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">atom</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">l</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">None</span></span></em>, <em class="sig-param"><span class="o"><span class="pre">**</span></span><span class="n"><span class="pre">kwargs</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/grogupy/magnetism.html#parse_magnetic_entity"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogupy.magnetism.parse_magnetic_entity" title="Link to this definition"></a></dt>
|
|
|
|
|
<dd><p>Function to define orbital indexes of a given magnetic entity.</p>
|
|
|
|
|
<dl class="simple">
|
|
|
|
|
<dt>Args:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>dh<span class="classifier">sisl.physics.Hamiltonian</span></dt><dd><p>Hamiltonian from sisl</p>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>atom<span class="classifier">integer or list of integers, optional</span></dt><dd><p>Defining atom (or atoms) in the unit cell forming the magnetic entity. Defaults to None</p>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>l<span class="classifier">integer, optional</span></dt><dd><p>Defining the angular momentum channel. Defaults to None</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>Returns:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>list</dt><dd><p>The orbital indexes of the given magnetic entity</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd></dl>
|
|
|
|
|
|
|
|
|
|
<dl class="py function">
|
|
|
|
|
<dt class="sig sig-object py" id="grogupy.magnetism.spin_tracer">
|
|
|
|
|
<span class="sig-prename descclassname"><span class="pre">grogupy.magnetism.</span></span><span class="sig-name descname"><span class="pre">spin_tracer</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">M</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/grogupy/magnetism.html#spin_tracer"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogupy.magnetism.spin_tracer" title="Link to this definition"></a></dt>
|
|
|
|
|
<dd><p>Spin tracer utility.</p>
|
|
|
|
|
<p>This takes an operator with the orbital-spin sequence:
|
|
|
|
|
orbital 1 up,
|
|
|
|
|
orbital 1 down,
|
|
|
|
|
orbital 2 up,
|
|
|
|
|
orbital 2 down,
|
|
|
|
|
that is in the SPIN-BOX representation,
|
|
|
|
|
and extracts orbital dependent Pauli traces.</p>
|
|
|
|
|
<dl class="simple">
|
|
|
|
|
<dt>Args:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>M<span class="classifier">np.array_like</span></dt><dd><p>Traceable matrix</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
<dt>Returns:</dt><dd><dl class="simple">
|
|
|
|
|
<dt>dict</dt><dd><p>It contains the traced matrix with “x”, “y”, “z” and “c”</p>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd>
|
|
|
|
|
</dl>
|
|
|
|
|
</dd></dl>
|
|
|
|
|
|
|
|
|
|
</section>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
|
|
|
|
|
<a href="grogupy.io.html" class="btn btn-neutral float-left" title="grogupy.io module" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
|
|
|
|
|
<a href="grogupy.utilities.html" class="btn btn-neutral float-right" title="grogupy.utilities module" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right" aria-hidden="true"></span></a>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<hr/>
|
|
|
|
|
|
|
|
|
|
<div role="contentinfo">
|
|
|
|
|
<p>© Copyright 2024, grogupy.</p>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
Built with <a href="https://www.sphinx-doc.org/">Sphinx</a> using a
|
|
|
|
|
<a href="https://github.com/readthedocs/sphinx_rtd_theme">theme</a>
|
|
|
|
|
provided by <a href="https://readthedocs.org">Read the Docs</a>.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</footer>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</section>
|
|
|
|
|
</div>
|
|
|
|
|
<script>
|
|
|
|
|
jQuery(function () {
|
|
|
|
|
SphinxRtdTheme.Navigation.enable(true);
|
|
|
|
|
});
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
</body>
|
|
|
|
|
</html>
|