You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

240 lines
20 KiB

3 months ago
<!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>grogu package &mdash; Grogu 0.0.1 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" />
<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=d45e8c67"></script>
<script src="_static/doctools.js?v=9a2dae69"></script>
3 months ago
<script src="_static/sphinx_highlight.js?v=dc90522c"></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="prev" title="src" href="modules.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">
Grogu
</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">Contents:</span></p>
<ul class="current">
<li class="toctree-l1 current"><a class="reference internal" href="modules.html">src</a><ul class="current">
<li class="toctree-l2 current"><a class="current reference internal" href="#">grogu package</a><ul>
<li class="toctree-l3"><a class="reference internal" href="#submodules">Submodules</a></li>
<li class="toctree-l3"><a class="reference internal" href="#module-grogu.example">grogu.example module</a></li>
<li class="toctree-l3"><a class="reference internal" href="#module-grogu.jij">grogu.jij module</a></li>
<li class="toctree-l3"><a class="reference internal" href="#module-grogu.useful">grogu.useful module</a><ul>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.RotM"><code class="docutils literal notranslate"><span class="pre">RotM()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.RotMa2b"><code class="docutils literal notranslate"><span class="pre">RotMa2b()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.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="#grogu.useful.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="#grogu.useful.commutator"><code class="docutils literal notranslate"><span class="pre">commutator()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.crossM"><code class="docutils literal notranslate"><span class="pre">crossM()</span></code></a></li>
3 months ago
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.hsk"><code class="docutils literal notranslate"><span class="pre">hsk()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.make_contour"><code class="docutils literal notranslate"><span class="pre">make_contour()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.make_kset"><code class="docutils literal notranslate"><span class="pre">make_kset()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.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="#grogu.useful.print_atomic_indices"><code class="docutils literal notranslate"><span class="pre">print_atomic_indices()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.spin_tracer"><code class="docutils literal notranslate"><span class="pre">spin_tracer()</span></code></a></li>
<li class="toctree-l4"><a class="reference internal" href="#grogu.useful.tau_u"><code class="docutils literal notranslate"><span class="pre">tau_u()</span></code></a></li>
3 months ago
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="#module-grogu">Module contents</a></li>
</ul>
</li>
</ul>
</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">Grogu</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 active">grogu package</li>
<li class="wy-breadcrumbs-aside">
<a href="_sources/grogu.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="grogu-package">
<h1>grogu package<a class="headerlink" href="#grogu-package" title="Link to this heading"></a></h1>
<section id="submodules">
<h2>Submodules<a class="headerlink" href="#submodules" title="Link to this heading"></a></h2>
</section>
<section id="module-grogu.example">
<span id="grogu-example-module"></span><h2>grogu.example module<a class="headerlink" href="#module-grogu.example" title="Link to this heading"></a></h2>
</section>
<section id="module-grogu.jij">
<span id="grogu-jij-module"></span><h2>grogu.jij module<a class="headerlink" href="#module-grogu.jij" title="Link to this heading"></a></h2>
</section>
<section id="module-grogu.useful">
<span id="grogu-useful-module"></span><h2>grogu.useful module<a class="headerlink" href="#module-grogu.useful" title="Link to this heading"></a></h2>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.RotM">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">RotM</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">theta</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">u</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">eps</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">1e-10</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#RotM"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.RotM" title="Link to this definition"></a></dt>
<dd><p>Definition of rotation matrix with angle theta around direction u.</p>
3 months ago
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.RotMa2b">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">RotMa2b</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">a</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">b</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">eps</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">1e-10</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#RotMa2b"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.RotMa2b" title="Link to this definition"></a></dt>
<dd><p>Definition of rotation matrix rotating unit vector a to unit vector b.
Function returns array R such that R&#64;a = b holds.</p>
3 months ago
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.blow_up_orbindx">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</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/grogu/useful.html#blow_up_orbindx"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.blow_up_orbindx" title="Link to this definition"></a></dt>
<dd><p>Function to blow up orbital indeces to make SPIN BOX indices.</p>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.calculate_exchange_tensor">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</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/grogu/useful.html#calculate_exchange_tensor"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.calculate_exchange_tensor" title="Link to this definition"></a></dt>
<dd></dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.commutator">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">commutator</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">a</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">b</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#commutator"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.commutator" title="Link to this definition"></a></dt>
<dd><p>Shorthand for commutator</p>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.crossM">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">crossM</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">u</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#crossM"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.crossM" title="Link to this definition"></a></dt>
<dd><p>Definition for the cross-product matrix.
Acting as a cross product with vector u.</p>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.hsk">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">hsk</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">H</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">ss</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">sc_off</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">k</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">(0,</span> <span class="pre">0,</span> <span class="pre">0)</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#hsk"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.hsk" title="Link to this definition"></a></dt>
<dd><p>One way to speed up Hk and Sk generation</p>
3 months ago
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.make_contour">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">make_contour</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">emin</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">-20</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">emax</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">0.0</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">enum</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">42</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">p</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">150</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#make_contour"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.make_contour" title="Link to this definition"></a></dt>
<dd><p>A more sophisticated contour generator</p>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.make_kset">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">make_kset</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">dirs</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">'xyz'</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">NUMK</span></span><span class="o"><span class="pre">=</span></span><span class="default_value"><span class="pre">20</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#make_kset"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.make_kset" title="Link to this definition"></a></dt>
<dd><p>Simple k-grid generator. Depending on the value of the dirs
argument k sampling in 1,2 or 3 dimensions is generated.
If dirs argument does not contain either of x,y or z
a kset of a single k-pont at the origin is returend.</p>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.parse_magnetic_entity">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</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/grogu/useful.html#parse_magnetic_entity"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.parse_magnetic_entity" title="Link to this definition"></a></dt>
<dd><p>Function to define orbital indeces of a given magnetic entity.
dh: a sisl Hamiltonian object
atom: an integer or list of integers, defining atom (or atoms) in the unicell forming the magnetic entity
l: integer, defining the angular momentum channel</p>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.print_atomic_indices">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">print_atomic_indices</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">pair</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">magnetic_entities</span></span></em>, <em class="sig-param"><span class="n"><span class="pre">dh</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#print_atomic_indices"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.print_atomic_indices" title="Link to this definition"></a></dt>
<dd></dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.spin_tracer">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</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/grogu/useful.html#spin_tracer"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.spin_tracer" title="Link to this definition"></a></dt>
<dd><p>Spin tracer utility.
This akes 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>
</dd></dl>
<dl class="py function">
<dt class="sig sig-object py" id="grogu.useful.tau_u">
<span class="sig-prename descclassname"><span class="pre">grogu.useful.</span></span><span class="sig-name descname"><span class="pre">tau_u</span></span><span class="sig-paren">(</span><em class="sig-param"><span class="n"><span class="pre">u</span></span></em><span class="sig-paren">)</span><a class="reference internal" href="_modules/grogu/useful.html#tau_u"><span class="viewcode-link"><span class="pre">[source]</span></span></a><a class="headerlink" href="#grogu.useful.tau_u" title="Link to this definition"></a></dt>
<dd><p>Pauli matrix in direction u.</p>
3 months ago
</dd></dl>
</section>
<section id="module-grogu">
<span id="module-contents"></span><h2>Module contents<a class="headerlink" href="#module-grogu" title="Link to this heading"></a></h2>
</section>
</section>
</div>
</div>
<footer><div class="rst-footer-buttons" role="navigation" aria-label="Footer">
<a href="modules.html" class="btn btn-neutral float-left" title="src" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left" aria-hidden="true"></span> Previous</a>
</div>
<hr/>
<div role="contentinfo">
<p>&#169; Copyright 2024, Grogu.</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>