Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revied some variable names, added docs, added demo to docs folder.
- Loading branch information
taylorpatti
committed
Oct 2, 2020
1 parent
d66e1a6
commit 7a810dc
Showing
7 changed files
with
65 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Collective Modes | ||
|
||
A module that calculates the band structure and decay rates of different collective modes of quasimomentum k with functions: | ||
|
||
* [`CollectiveSpins.Omega_k_chain`](@ref) | ||
* [`CollectiveSpins.Gamma_k_chain`](@ref) | ||
|
||
```julia | ||
CollectiveSpins.Omega_k_chain(0.2*pi, 0.2, [1,0,0]) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
import CollectiveSpins | ||
|
||
# Define chain parameters | ||
a = 0.2 # spin-spin distance | ||
polarization_par = [1, 0, 0] | ||
polarization_perp = [0, 1, 1] | ||
|
||
k_max = 10000 | ||
k_list = [iii*pi/(a*k_max) for iii=-k_max:k_max] | ||
println() | ||
|
||
band_structure_par = [] | ||
band_structure_perp = [] | ||
decay_par = [] | ||
decay_perp = [] | ||
for k in k_list | ||
append!(band_structure_par, CollectiveSpins.Omega_k_chain(k, a, polarization_par)) | ||
append!(band_structure_perp, CollectiveSpins.Omega_k_chain(k, a, polarization_perp)) | ||
append!(decay_par, CollectiveSpins.Gamma_k_chain(k, a, polarization_par)) | ||
append!(decay_perp, CollectiveSpins.Gamma_k_chain(k, a, polarization_perp)) | ||
end | ||
|
||
using PyPlot | ||
|
||
subplot(211) | ||
plot(k_list*a/pi, band_structure_par) | ||
plot(k_list*a/pi, band_structure_perp, color="red") | ||
xlabel("k d/pi") | ||
ylabel("Omega(k)/gamma0") | ||
|
||
subplot(212) | ||
plot(k_list*a/pi, decay_par) | ||
plot(k_list*a/pi, decay_perp, color="red") | ||
xlabel("k d/pi") | ||
ylabel("Gamma(k)/gamma0") | ||
|
||
tight_layout() | ||
savefig("band_structure_decay.svg") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters