Skip to content

Commit

Permalink
build based on a229d13
Browse files Browse the repository at this point in the history
Documenter.jl committed Dec 4, 2024
1 parent 2a2816d commit c8aa394
Showing 27 changed files with 4,088 additions and 4,088 deletions.
2 changes: 1 addition & 1 deletion dev/.documenter-siteinfo.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"documenter":{"julia_version":"1.11.2","generation_timestamp":"2024-12-04T02:31:43","documenter_version":"1.8.0"}}
{"documenter":{"julia_version":"1.11.2","generation_timestamp":"2024-12-04T06:26:00","documenter_version":"1.8.0"}}
398 changes: 199 additions & 199 deletions dev/examples/Graphene/9bcfff53.svg → dev/examples/Graphene/6983e411.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
710 changes: 355 additions & 355 deletions dev/examples/Graphene/a0da9858.svg → dev/examples/Graphene/cba56800.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions dev/examples/Graphene/index.html
Original file line number Diff line number Diff line change
@@ -22,7 +22,7 @@
energybands = graphene(:EB, EnergyBands(path))

# plot the energy bands
plot(energybands)</code></pre><img src="9bcfff53.svg" alt="Example block output"/><h2 id="Edge-states"><a class="docs-heading-anchor" href="#Edge-states">Edge states</a><a id="Edge-states-1"></a><a class="docs-heading-anchor-permalink" href="#Edge-states" title="Permalink"></a></h2><p>Graphene supports flatband edge states on zigzag boundaries. Only minor modifications are needed to compute them:</p><pre><code class="language-julia hljs"># define a cylinder geometry with zigzag edges
plot(energybands)</code></pre><img src="6983e411.svg" alt="Example block output"/><h2 id="Edge-states"><a class="docs-heading-anchor" href="#Edge-states">Edge states</a><a id="Edge-states-1"></a><a class="docs-heading-anchor-permalink" href="#Edge-states" title="Permalink"></a></h2><p>Graphene supports flatband edge states on zigzag boundaries. Only minor modifications are needed to compute them:</p><pre><code class="language-julia hljs"># define a cylinder geometry with zigzag edges
lattice = Lattice(unitcell, (1, 100), (&#39;P&#39;, &#39;O&#39;))

# define the new Hilbert space corresponding to the cylinder
@@ -38,7 +38,7 @@
edgestates = zigzag(:EB, EnergyBands(path))

# plot the energy bands
plot(edgestates)</code></pre><img src="a0da9858.svg" alt="Example block output"/><h2 id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix"><a class="docs-heading-anchor" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix">Auto-generation of the analytical expression of the Hamiltonian matrix</a><a id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix-1"></a><a class="docs-heading-anchor-permalink" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix" title="Permalink"></a></h2><p>Combined with <a href="https://github.com/JuliaPy/SymPy.jl">SymPy</a>, it is also possible to get the analytical expression of the free Hamiltonian in the matrix form:</p><pre><code class="language-julia hljs">using SymPy: Sym, symbols
plot(edgestates)</code></pre><img src="cba56800.svg" alt="Example block output"/><h2 id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix"><a class="docs-heading-anchor" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix">Auto-generation of the analytical expression of the Hamiltonian matrix</a><a id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix-1"></a><a class="docs-heading-anchor-permalink" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix" title="Permalink"></a></h2><p>Combined with <a href="https://github.com/JuliaPy/SymPy.jl">SymPy</a>, it is also possible to get the analytical expression of the free Hamiltonian in the matrix form:</p><pre><code class="language-julia hljs">using SymPy: Sym, symbols
using QuantumLattices
using TightBindingApproximation

@@ -55,4 +55,4 @@

k₁ = symbols(&quot;k₁&quot;, real=true)
k₂ = symbols(&quot;k₂&quot;, real=true)
m = matrix(graphene, [k₁, k₂])</code></pre><p class="math-container">\[\left[\begin{smallmatrix}0 &amp; t e^{i \left(- \frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} + t e^{i \left(\frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} + t\\t + t e^{- i \left(\frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} + t e^{- i \left(- \frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} &amp; 0\end{smallmatrix}\right]\]</p></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Introduction/">« Introduction</a><a class="docs-footer-nextpage" href="../Superconductor/">p+ip Superconductor on Square Lattice »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 02:31">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
m = matrix(graphene, [k₁, k₂])</code></pre><p class="math-container">\[\left[\begin{smallmatrix}0 &amp; t e^{i \left(- \frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} + t e^{i \left(\frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} + t\\t + t e^{- i \left(\frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} + t e^{- i \left(- \frac{k₁}{2} - \frac{\sqrt{3} k₂}{2}\right)} &amp; 0\end{smallmatrix}\right]\]</p></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Introduction/">« Introduction</a><a class="docs-footer-nextpage" href="../Superconductor/">p+ip Superconductor on Square Lattice »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 06:26">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
2 changes: 1 addition & 1 deletion dev/examples/Introduction/index.html

Large diffs are not rendered by default.

520 changes: 260 additions & 260 deletions dev/examples/Kagome/68f17b43.svg → dev/examples/Kagome/2a08e354.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
400 changes: 200 additions & 200 deletions dev/examples/Kagome/331e3727.svg → dev/examples/Kagome/797b0eda.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1,152 changes: 576 additions & 576 deletions dev/examples/Kagome/377700da.svg → dev/examples/Kagome/8d6e04c0.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
396 changes: 198 additions & 198 deletions dev/examples/Kagome/d7fe71d8.svg → dev/examples/Kagome/99195500.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
204 changes: 102 additions & 102 deletions dev/examples/Kagome/e7e7dccf.svg → dev/examples/Kagome/9e219acb.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
432 changes: 216 additions & 216 deletions dev/examples/Kagome/c97a4772.svg → dev/examples/Kagome/a3746ede.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
376 changes: 188 additions & 188 deletions dev/examples/Kagome/e80ca2c3.svg → dev/examples/Kagome/a9a953ca.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 9 additions & 9 deletions dev/examples/Kagome/index.html
Original file line number Diff line number Diff line change
@@ -9,7 +9,7 @@
lattice = Lattice(unitcell, (8, 8))

# plot the finite lattice
plot(lattice, 1)</code></pre><img src="377700da.svg" alt="Example block output"/><h2 id="Energy-bands"><a class="docs-heading-anchor" href="#Energy-bands">Energy bands</a><a id="Energy-bands-1"></a><a class="docs-heading-anchor-permalink" href="#Energy-bands" title="Permalink"></a></h2><p>Now let&#39;s calculate the energy bands of the Kagome lattice:</p><pre><code class="language-julia hljs">using TightBindingApproximation
plot(lattice, 1)</code></pre><img src="8d6e04c0.svg" alt="Example block output"/><h2 id="Energy-bands"><a class="docs-heading-anchor" href="#Energy-bands">Energy bands</a><a id="Energy-bands-1"></a><a class="docs-heading-anchor-permalink" href="#Energy-bands" title="Permalink"></a></h2><p>Now let&#39;s calculate the energy bands of the Kagome lattice:</p><pre><code class="language-julia hljs">using TightBindingApproximation

# define the Hilbert space (single-orbital spinless complex fermion)
hilbert = Hilbert(site=&gt;Fock{:f}(1, 1) for site=1:length(unitcell))
@@ -27,39 +27,39 @@
energybands = kagome(:EB, EnergyBands(path))

# plot the energy bands
plot(energybands)</code></pre><img src="331e3727.svg" alt="Example block output"/><h2 id="Density-of-states"><a class="docs-heading-anchor" href="#Density-of-states">Density of states</a><a id="Density-of-states-1"></a><a class="docs-heading-anchor-permalink" href="#Density-of-states" title="Permalink"></a></h2><p>The total DOS can be computed as follows:</p><pre><code class="language-julia hljs"># define the Brillouin zone
plot(energybands)</code></pre><img src="797b0eda.svg" alt="Example block output"/><h2 id="Density-of-states"><a class="docs-heading-anchor" href="#Density-of-states">Density of states</a><a id="Density-of-states-1"></a><a class="docs-heading-anchor-permalink" href="#Density-of-states" title="Permalink"></a></h2><p>The total DOS can be computed as follows:</p><pre><code class="language-julia hljs"># define the Brillouin zone
brillouinzone = BrillouinZone(reciprocals(unitcell), 120)

# compute the total DOS and plot the results
dos = kagome(
:TotalDensityOfStates,
DensityOfStates(brillouinzone; emin=-5.0, emax=5.0, ne=201, fwhm=0.1)
)
plot(dos)</code></pre><img src="c97a4772.svg" alt="Example block output"/><p>There are three peaks in the DOS. The one at 2 reflects the flat upper energy band, and the ones at 0 and -2 implies the Van Hove singularities of the middle and lower energy bands, respectively.</p><p>On the other hand, the DOS of a specific generalized orbital on a given sets of bands can also be computed:</p><pre><code class="language-julia hljs"># the total DOS of the lower two bands
plot(dos)</code></pre><img src="a3746ede.svg" alt="Example block output"/><p>There are three peaks in the DOS. The one at 2 reflects the flat upper energy band, and the ones at 0 and -2 implies the Van Hove singularities of the middle and lower energy bands, respectively.</p><p>On the other hand, the DOS of a specific generalized orbital on a given sets of bands can also be computed:</p><pre><code class="language-julia hljs"># the total DOS of the lower two bands
dos = kagome(
:DensityOfStatesWithoutUpperBand,
DensityOfStates(brillouinzone, 1:2; emin=-5.0, emax=5.0, ne=201, fwhm=0.1)
)
plot(dos)</code></pre><img src="d7fe71d8.svg" alt="Example block output"/><pre><code class="language-julia hljs"># the total DOS of the three sublattices, respectively (degenerate)
plot(dos)</code></pre><img src="99195500.svg" alt="Example block output"/><pre><code class="language-julia hljs"># the total DOS of the three sublattices, respectively (degenerate)
dos = kagome(
:SublatticeDensityOfStates,
DensityOfStates(brillouinzone, :, [1], [2], [3]; emin=-5.0, emax=5.0, ne=201, fwhm=0.1)
)
plot(dos; labels=[&quot;Sublattice 1&quot; &quot;Sublattice 2&quot; &quot;Sublattice 3&quot;], legend=true)</code></pre><img src="e80ca2c3.svg" alt="Example block output"/><pre><code class="language-julia hljs"># the DOS of the three sublattices on the lower two bands, respectively (degenerate)
plot(dos; labels=[&quot;Sublattice 1&quot; &quot;Sublattice 2&quot; &quot;Sublattice 3&quot;], legend=true)</code></pre><img src="a9a953ca.svg" alt="Example block output"/><pre><code class="language-julia hljs"># the DOS of the three sublattices on the lower two bands, respectively (degenerate)
dos = kagome(
:SublatticeDensityOfStatesWithoutUpperBand,
DensityOfStates(brillouinzone, 1:2, [1], [2], [3]; emin=-5.0, emax=5.0, ne=201, fwhm=0.1)
)
plot(dos; labels=[&quot;Sublattice 1&quot; &quot;Sublattice 2&quot; &quot;Sublattice 3&quot;], legend=true)</code></pre><img src="68f17b43.svg" alt="Example block output"/><h2 id="Fermi-surface"><a class="docs-heading-anchor" href="#Fermi-surface">Fermi surface</a><a id="Fermi-surface-1"></a><a class="docs-heading-anchor-permalink" href="#Fermi-surface" title="Permalink"></a></h2><p>When the Fermi level of the system sets at the Van Hove singularity of the lower band, the FS is also in the shape of a Kagome lattice:</p><pre><code class="language-julia hljs"># define a reciprocal zone proper to show the FS
plot(dos; labels=[&quot;Sublattice 1&quot; &quot;Sublattice 2&quot; &quot;Sublattice 3&quot;], legend=true)</code></pre><img src="2a08e354.svg" alt="Example block output"/><h2 id="Fermi-surface"><a class="docs-heading-anchor" href="#Fermi-surface">Fermi surface</a><a id="Fermi-surface-1"></a><a class="docs-heading-anchor-permalink" href="#Fermi-surface" title="Permalink"></a></h2><p>When the Fermi level of the system sets at the Van Hove singularity of the lower band, the FS is also in the shape of a Kagome lattice:</p><pre><code class="language-julia hljs"># define a reciprocal zone proper to show the FS
reciprocalzone = ReciprocalZone(
[[4*pi/√3, 0.0], [0.0, 4*pi/√3]], -1.0=&gt;1.0, -1.0=&gt;1.0;
length=600, ends=(true, true)
)

# Fermi level at -2, i.e., the lower Van Hove singularity
fs = kagome(:FermiSurface, FermiSurface(reciprocalzone, -2))
plot(fs; size=(450, 400), clims=(0, 10))</code></pre><img src="740dcbab.svg" alt="Example block output"/><p>As is similar to DOS, specific orbital components of a specific set of bands on the Fermi level can also be computed.</p><p>When the Fermi level sets at -2, actually, only the lower band contributes to the Fermi surface. Therefore, the contributions of the upper two bands are zero, as will be shown by the following computation:</p><pre><code class="language-julia hljs"># Fermi level at -2, the contributions of the upper two bands to the FS
plot(fs; size=(450, 400), clims=(0, 10))</code></pre><img src="41c87f90.svg" alt="Example block output"/><p>As is similar to DOS, specific orbital components of a specific set of bands on the Fermi level can also be computed.</p><p>When the Fermi level sets at -2, actually, only the lower band contributes to the Fermi surface. Therefore, the contributions of the upper two bands are zero, as will be shown by the following computation:</p><pre><code class="language-julia hljs"># Fermi level at -2, the contributions of the upper two bands to the FS
fs = kagome(:FermiSurfaceWithoutLowerBand, FermiSurface(reciprocalzone, -2, 2:3))
plot(fs; size=(450, 400), clims=(0, 5))</code></pre><img src="b4292e0b.svg" alt="Example block output"/><p>The components of the three sublattices at the FS can be computed as follows:</p><pre><code class="language-julia hljs"># Fermi level at -2, the three sublattice components at the FS, respectively
plot(fs; size=(450, 400), clims=(0, 5))</code></pre><img src="7b2f5a54.svg" alt="Example block output"/><p>The components of the three sublattices at the FS can be computed as follows:</p><pre><code class="language-julia hljs"># Fermi level at -2, the three sublattice components at the FS, respectively
fs = kagome(:SublatticeFermiSurface, FermiSurface(reciprocalzone, -2, :, [1], [2], [3]))
plot(fs; nrow=1, ncol=3, size=(780, 330), clims=(0, 5), xlabelfontsize=8, ylabelfontsize=8)</code></pre><img src="e7e7dccf.svg" alt="Example block output"/></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Superconductor/">« p+ip Superconductor on Square Lattice</a><a class="docs-footer-nextpage" href="../Phonon/">Phonons on Square Lattice »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 02:31">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
plot(fs; nrow=1, ncol=3, size=(780, 330), clims=(0, 5), xlabelfontsize=8, ylabelfontsize=8)</code></pre><img src="9e219acb.svg" alt="Example block output"/></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Superconductor/">« p+ip Superconductor on Square Lattice</a><a class="docs-footer-nextpage" href="../Phonon/">Phonons on Square Lattice »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 06:25">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
358 changes: 179 additions & 179 deletions dev/examples/Phonon/1d337040.svg → dev/examples/Phonon/6a8b3eed.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
370 changes: 185 additions & 185 deletions dev/examples/Phonon/aa758ee1.svg → dev/examples/Phonon/ee49b89e.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions dev/examples/Phonon/index.html
Original file line number Diff line number Diff line change
@@ -30,12 +30,12 @@
energybands = phonon(:EB, EnergyBands(path))

# plot the energy bands
plot(energybands)</code></pre><img src="1d337040.svg" alt="Example block output"/><h2 id="Inelastic-neutron-scattering-spectra"><a class="docs-heading-anchor" href="#Inelastic-neutron-scattering-spectra">Inelastic neutron scattering spectra</a><a id="Inelastic-neutron-scattering-spectra-1"></a><a class="docs-heading-anchor-permalink" href="#Inelastic-neutron-scattering-spectra" title="Permalink"></a></h2><p>The inelastic neutron scattering spectra of phonons can also be computed:</p><pre><code class="language-julia hljs"># fwhm: the FWHM of the Gaussian to be convoluted
plot(energybands)</code></pre><img src="6a8b3eed.svg" alt="Example block output"/><h2 id="Inelastic-neutron-scattering-spectra"><a class="docs-heading-anchor" href="#Inelastic-neutron-scattering-spectra">Inelastic neutron scattering spectra</a><a id="Inelastic-neutron-scattering-spectra-1"></a><a class="docs-heading-anchor-permalink" href="#Inelastic-neutron-scattering-spectra" title="Permalink"></a></h2><p>The inelastic neutron scattering spectra of phonons can also be computed:</p><pre><code class="language-julia hljs"># fwhm: the FWHM of the Gaussian to be convoluted
# scale: the scale of the intensity
spectra = phonon(
:INSS,
InelasticNeutronScatteringSpectra(path, range(0.0, 2.5, length=501); fwhm=0.05, rescale=x-&gt;log(1+x))
)
plt = plot()
plot!(plt, spectra)
plot!(plt, energybands, color=:white, linestyle=:dash)</code></pre><img src="aa758ee1.svg" alt="Example block output"/></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Kagome/">« Free Spinless Fermions on Kagome Lattice</a><a class="docs-footer-nextpage" href="../../manual/">Manual »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 02:31">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
plot!(plt, energybands, color=:white, linestyle=:dash)</code></pre><img src="ee49b89e.svg" alt="Example block output"/></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Kagome/">« Free Spinless Fermions on Kagome Lattice</a><a class="docs-footer-nextpage" href="../../manual/">Manual »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 06:25">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 7 additions & 7 deletions dev/examples/Superconductor/index.html
Original file line number Diff line number Diff line change
@@ -33,14 +33,14 @@
energybands = sc(:EB, EnergyBands(path))

# plot the energy bands
plot(energybands)</code></pre><img src="aaa6e910.svg" alt="Example block output"/><h2 id="Berry-curvature-and-Chern-number"><a class="docs-heading-anchor" href="#Berry-curvature-and-Chern-number">Berry curvature and Chern number</a><a id="Berry-curvature-and-Chern-number-1"></a><a class="docs-heading-anchor-permalink" href="#Berry-curvature-and-Chern-number" title="Permalink"></a></h2><p>The Berry curvatures and the Chern numbers of the quasiparticle bands can be calculated in the unitcell of the reciprocal space:</p><pre><code class="language-julia hljs"># define the Brillouin zone
plot(energybands)</code></pre><img src="83612983.svg" alt="Example block output"/><h2 id="Berry-curvature-and-Chern-number"><a class="docs-heading-anchor" href="#Berry-curvature-and-Chern-number">Berry curvature and Chern number</a><a id="Berry-curvature-and-Chern-number-1"></a><a class="docs-heading-anchor-permalink" href="#Berry-curvature-and-Chern-number" title="Permalink"></a></h2><p>The Berry curvatures and the Chern numbers of the quasiparticle bands can be calculated in the unitcell of the reciprocal space:</p><pre><code class="language-julia hljs"># define the Brillouin zone
brillouin = BrillouinZone(reciprocals(unitcell), 100)

# compute the Berry curvatures and Chern numbers of both quasiparticle bands
berry = sc(:BerryCurvature, BerryCurvature(brillouin, [1, 2]));

# plot the Berry curvatures
plot(berry)</code></pre><img src="5b8d358b.svg" alt="Example block output"/><p>The Berry curvatures can also be computed on a reciprocal zone beyond the reciprocal unitcell:</p><pre><code class="language-julia hljs"># define the reciprocal zone
plot(berry)</code></pre><img src="a4770366.svg" alt="Example block output"/><p>The Berry curvatures can also be computed on a reciprocal zone beyond the reciprocal unitcell:</p><pre><code class="language-julia hljs"># define the reciprocal zone
reciprocalzone = ReciprocalZone(
reciprocals(unitcell), -2.0=&gt;2.0, -2.0=&gt;2.0;
length=201, ends=(true, true)
@@ -50,11 +50,11 @@
berry = sc(:BerryCurvatureExtended, BerryCurvature(reciprocalzone, [1, 2]))

# plot the Berry curvature
plot(berry)</code></pre><img src="498fffec.svg" alt="Example block output"/><p>The total Berry curvatures of occupied bands can also be computed on a reciprocal path with Kubo method:</p><pre><code class="language-julia hljs"># compute the total Berry curvature
plot(berry)</code></pre><img src="14996203.svg" alt="Example block output"/><p>The total Berry curvatures of occupied bands can also be computed on a reciprocal path with Kubo method:</p><pre><code class="language-julia hljs"># compute the total Berry curvature
berry = sc(:BerryCurvaturePath, BerryCurvature(path, Kubo(0.0)))

# plot the Berry curvature
plot(berry)</code></pre><img src="f618f5bb.svg" alt="Example block output"/><h2 id="Edge-states"><a class="docs-heading-anchor" href="#Edge-states">Edge states</a><a id="Edge-states-1"></a><a class="docs-heading-anchor-permalink" href="#Edge-states" title="Permalink"></a></h2><p>With tiny modification on the algorithm, the edge states of the p+ip topological superconductor could also be computed:</p><pre><code class="language-julia hljs"># define a cylinder geometry
plot(berry)</code></pre><img src="1802fcee.svg" alt="Example block output"/><h2 id="Edge-states"><a class="docs-heading-anchor" href="#Edge-states">Edge states</a><a id="Edge-states-1"></a><a class="docs-heading-anchor-permalink" href="#Edge-states" title="Permalink"></a></h2><p>With tiny modification on the algorithm, the edge states of the p+ip topological superconductor could also be computed:</p><pre><code class="language-julia hljs"># define a cylinder geometry
lattice = Lattice(unitcell, (1, 100), (&#39;P&#39;, &#39;O&#39;))

# define the new Hilbert space corresponding to the cylinder
@@ -70,11 +70,11 @@
edgestates = sc(:Edge, EnergyBands(path))

# plot the energy bands
plot(edgestates)</code></pre><img src="a27972fa.svg" alt="Example block output"/><p>Note that when μ&gt;4 or μ&lt;-4, the superconductor is topologically trivial such that there are no gapless edge states on the cylinder geometry:</p><pre><code class="language-julia hljs"># compute the edge states with a new onsite energy such that the superconductor is trivial
plot(edgestates)</code></pre><img src="4df7cafb.svg" alt="Example block output"/><p>Note that when μ&gt;4 or μ&lt;-4, the superconductor is topologically trivial such that there are no gapless edge states on the cylinder geometry:</p><pre><code class="language-julia hljs"># compute the edge states with a new onsite energy such that the superconductor is trivial
trivial = sc(:Trivial, EnergyBands(path), parameters=(μ=4.5,))

# plot the energy bands
plot(trivial)</code></pre><img src="b982ff64.svg" alt="Example block output"/><h2 id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix"><a class="docs-heading-anchor" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix">Auto-generation of the analytical expression of the Hamiltonian matrix</a><a id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix-1"></a><a class="docs-heading-anchor-permalink" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix" title="Permalink"></a></h2><p>Combined with <a href="https://github.com/JuliaPy/SymPy.jl">SymPy</a>, it is also possible to get the analytical expression of the free Hamiltonian in the matrix form:</p><pre><code class="language-julia hljs">using SymPy: Sym, symbols
plot(trivial)</code></pre><img src="5f0cdc6c.svg" alt="Example block output"/><h2 id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix"><a class="docs-heading-anchor" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix">Auto-generation of the analytical expression of the Hamiltonian matrix</a><a id="Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix-1"></a><a class="docs-heading-anchor-permalink" href="#Auto-generation-of-the-analytical-expression-of-the-Hamiltonian-matrix" title="Permalink"></a></h2><p>Combined with <a href="https://github.com/JuliaPy/SymPy.jl">SymPy</a>, it is also possible to get the analytical expression of the free Hamiltonian in the matrix form:</p><pre><code class="language-julia hljs">using SymPy: Sym, symbols
using QuantumLattices
using TightBindingApproximation

@@ -96,4 +96,4 @@

k₁ = symbols(&quot;k₁&quot;, real=true)
k₂ = symbols(&quot;k₂&quot;, real=true)
m = matrix(sc, [k₁, k₂])</code></pre><p class="math-container">\[\left[\begin{smallmatrix}2 t \cos{\left(k₁ \right)} + 2 t \cos{\left(k₂ \right)} + μ &amp; - Δ e^{i k₁} + i Δ e^{i k₂} - i Δ e^{- i k₂} + Δ e^{- i k₁}\\Δ e^{i k₁} + i Δ e^{i k₂} - i Δ e^{- i k₂} - Δ e^{- i k₁} &amp; - 2 t \cos{\left(k₁ \right)} - 2 t \cos{\left(k₂ \right)} - μ\end{smallmatrix}\right]\]</p></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Graphene/">« Graphene</a><a class="docs-footer-nextpage" href="../Kagome/">Free Spinless Fermions on Kagome Lattice »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 02:31">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
m = matrix(sc, [k₁, k₂])</code></pre><p class="math-container">\[\left[\begin{smallmatrix}2 t \cos{\left(k₁ \right)} + 2 t \cos{\left(k₂ \right)} + μ &amp; - Δ e^{i k₁} + i Δ e^{i k₂} - i Δ e^{- i k₂} + Δ e^{- i k₁}\\Δ e^{i k₁} + i Δ e^{i k₂} - i Δ e^{- i k₂} - Δ e^{- i k₁} &amp; - 2 t \cos{\left(k₁ \right)} - 2 t \cos{\left(k₂ \right)} - μ\end{smallmatrix}\right]\]</p></article><nav class="docs-footer"><a class="docs-footer-prevpage" href="../Graphene/">« Graphene</a><a class="docs-footer-nextpage" href="../Kagome/">Free Spinless Fermions on Kagome Lattice »</a><div class="flexbox-break"></div><p class="footer-message">Powered by <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> and the <a href="https://julialang.org/">Julia Programming Language</a>.</p></nav></div><div class="modal" id="documenter-settings"><div class="modal-background"></div><div class="modal-card"><header class="modal-card-head"><p class="modal-card-title">Settings</p><button class="delete"></button></header><section class="modal-card-body"><p><label class="label">Theme</label><div class="select"><select id="documenter-themepicker"><option value="auto">Automatic (OS)</option><option value="documenter-light">documenter-light</option><option value="documenter-dark">documenter-dark</option><option value="catppuccin-latte">catppuccin-latte</option><option value="catppuccin-frappe">catppuccin-frappe</option><option value="catppuccin-macchiato">catppuccin-macchiato</option><option value="catppuccin-mocha">catppuccin-mocha</option></select></div></p><hr/><p>This document was generated with <a href="https://github.com/JuliaDocs/Documenter.jl">Documenter.jl</a> version 1.8.0 on <span class="colophon-date" title="Wednesday 4 December 2024 06:25">Wednesday 4 December 2024</span>. Using Julia version 1.11.2.</p></section><footer class="modal-card-foot"></footer></div></div></div></body></html>
2 changes: 1 addition & 1 deletion dev/index.html

Large diffs are not rendered by default.

30 changes: 15 additions & 15 deletions dev/manual/index.html

Large diffs are not rendered by default.

0 comments on commit c8aa394

Please sign in to comment.