Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update outputs of EPA app #212

Merged
merged 44 commits into from
Apr 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
13eac1e
Update the features in the read README.md file
jcoulter12 Jan 3, 2024
9c87378
Update features on the introduction page of the website
jcoulter12 Jan 3, 2024
56d2e02
add thickness parameter to user documentation
jcoulter12 Jan 28, 2024
5eb3edd
add thickness variable and input sanity check function
jcoulter12 Jan 28, 2024
9dac301
update units and ensure only the dimensions set in input are looped over
jcoulter12 Jan 28, 2024
5163337
further updates to check that only selected dims are looped over
jcoulter12 Jan 28, 2024
25da46a
a few comments about other places this might be needed
jcoulter12 Jan 28, 2024
60ee015
Merge remote-tracking branch 'origin/develop' into minorFixes
jcoulter12 Jan 28, 2024
1d645bc
Merge branch 'minorFixes' of github.com:mir-group/phoebe into minorFixes
jcoulter12 Jan 28, 2024
9d4a492
Further dimensionality unit improvements to Wigner thermal transport.
jcoulter12 Jan 28, 2024
d4822d1
fix a typo in phonon bte docs
jcoulter12 Jan 28, 2024
c88126d
warn a user if they select an even relaxons mesh
jcoulter12 Jan 28, 2024
961a4a6
fix the warning for even relaxons meshes
jcoulter12 Feb 4, 2024
a183f25
account for possible floating point errors when finding the high symm…
jcoulter12 Feb 4, 2024
3d30427
unblock tetrahedron method for phonons
jcoulter12 Feb 6, 2024
5f9ad12
add a minimum number of iters for variational transport calculations
jcoulter12 Feb 6, 2024
6222795
add many print fixes for 2d case to the viscosity output functions
jcoulter12 Feb 6, 2024
86becf2
initialize specific heat to zero, as this sometimes resulted in nan o…
jcoulter12 Feb 6, 2024
2f5bb58
previously thermal conductivity had dims 3 and 1 flipped in the appli…
jcoulter12 Feb 6, 2024
a7a74a0
wigner transport had dims flipped for thermal cond units
jcoulter12 Feb 6, 2024
a7b4f14
update error message for tetrahedron scattering
jcoulter12 Feb 6, 2024
0db1b7d
update two error messages to be more informative when phonon frequenc…
jcoulter12 Feb 7, 2024
8a0c416
demo call to print dyn to hdf5 in phonon bands app
jcoulter12 Feb 11, 2024
7f241c0
add functions to convert coordinates to the crystal object
jcoulter12 Feb 11, 2024
5c4ea98
add function to write to hdf5
jcoulter12 Feb 11, 2024
99162d8
phonon dynamical matrix to file mistake fixed
jcoulter12 Feb 12, 2024
943fd61
minor bugfix in chemical potential determination -- max/min energy de…
jcoulter12 Feb 24, 2024
d8deffa
Create epa_tau.py, to plot epa_relaxation_times.json [ci skip]
jcoulter12 Mar 25, 2024
9f50c84
Update elEpaTransport.rst to reflect the name of the proper plot script
jcoulter12 Mar 25, 2024
49694a5
Update postProcessing.rst to have a note about epa_tau.py
jcoulter12 Mar 25, 2024
3e0c4a4
improvement of a few error messages, print statements, and spacing/co…
jcoulter12 Mar 26, 2024
893df42
minor updates to the epa transport app tutorial docs, update outputs …
jcoulter12 Mar 26, 2024
745f459
make function to write a dos to json publicly available to other part…
jcoulter12 Mar 26, 2024
e70140b
update print functions to be more descriptive in epa app and to outpu…
jcoulter12 Mar 26, 2024
e3a3dd9
update loop print on fourier bandstructure calculation so that it now…
jcoulter12 Mar 26, 2024
8f16a5b
Merge branch 'minorFixes' of github.com:mir-group/phoebe into minorFixes
jcoulter12 Mar 26, 2024
301cc00
update the plot tau script to work with newer versions of python pack…
jcoulter12 Mar 26, 2024
bf58fc7
merge from develop
jcoulter12 Apr 1, 2024
aeb243d
add a script to read the output of elph_plot_app [ci skip]
jcoulter12 Apr 9, 2024
28b28ee
remove test statement in bands app which was printing the dynmat to hdf5
jcoulter12 Apr 26, 2024
5331522
replace copy and assignment constructors -- these should be removed, …
jcoulter12 Apr 26, 2024
d76e45b
add epa_dos to reference files
jcoulter12 Apr 26, 2024
b4d1291
update the variational onsager coefficients reference file to match n…
jcoulter12 Apr 26, 2024
433d544
update the variational onsager coefficients reference file to match n…
jcoulter12 Apr 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ cmake_minimum_required(VERSION 3.16)
# set cpp standard flags
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_EXTENSIONS OFF)
cmake_policy(SET CMP0144 NEW)

project(Phoebe LANGUAGES C CXX Fortran VERSION 1.0)

Expand Down
15 changes: 7 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,20 @@ If you feel you've found a bug or seen some unexpected behavior, please let us k
### Current functionalities
#### Electronic Transport

* Electron-phonon and phonon-electron scattering by Wannier interpolation
* Electron-phonon and phonon-electron scattering rates by Wannier interpolation
* Electron-phonon scattering within the electron-phonon averaged (EPA) approximation
* Polar correction and boundary scattering contributions to transport
* Electronic transport coefficients (mobility, conductivity, thermal conductivity, and Seebeck coefficient)

#### Phonon Transport

* 3-phonon scattering from thirdOrder.py/ShengBTE or Phono3py force constants
* Boundary and isotope scattering contributions to transport
* Phonon (lattice) thermal conductivity
* Lattice thermal conductivity calculations including ph-el lifetimes
* Phonon (lattice) thermal conductivity, including:
* 3-phonon scattering from thirdOrder.py/ShengBTE or Phono3py force constants
* Boundary, isotope, and phonon-electron scattering contributions
* Lattice thermal conductivity calculations including both ph-ph and ph-el scattering

#### And more...

* BTE solutions by RTA, iterative, variational, and relaxons solvers
* BTE solutions by RTA, iterative, variational, and relaxon solvers
* Calculation of electron and phonon linewidths or relaxation times on a path
* Wigner transport equation correction for electrons and phonons (Zener tunneling contribution to electron transport)
* Wigner transport equation correction for electrons and phonons
* Hydrodynamic transport properties (viscosity) for electrons and phonons
26 changes: 24 additions & 2 deletions doc/sphinx/source/inputFiles.rst
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,8 @@ Phonon BTE Solver

* :ref:`dimensionality`

* :ref:`thickness`

* :ref:`constantRelaxationTime`

* :ref:`withIsotopeScattering`
Expand Down Expand Up @@ -222,6 +224,8 @@ Electron BTE Solver

* :ref:`dimensionality`

* :ref:`thickness`

* :ref:`constantRelaxationTime`

* :ref:`convergenceThresholdBTE`
Expand Down Expand Up @@ -295,6 +299,10 @@ EPA Transport

* :ref:`epaEnergyRange`

* :ref:`dimensionality`

* :ref:`thickness`

* :ref:`kMesh`

* :ref:`temperatures`
Expand Down Expand Up @@ -482,7 +490,7 @@ Electron Lifetimes on a Path

-----------------------------------

Phonon Dos
Phonon DoS
----------

**Functionality:** Compute the phonon density of states.
Expand Down Expand Up @@ -1114,7 +1122,7 @@ convergenceThresholdBTE
dimensionality
^^^^^^^^^^^^^^

* **Description:** Input the dimensionality of the material. As a result, transport coefficients tensors will be of size (dim x dim), and units will be suitably scaled for the desired dimensionality.
* **Description:** Input the dimensionality of the material. As a result, transport coefficient tensors will be of size (dim x dim), and units will be suitably scaled for the desired dimensionality. For 2D materials, note that Phoebe assumes the material is oriented in x-y, with height in z.

* **Format:** *int*

Expand All @@ -1123,6 +1131,20 @@ dimensionality
* **Default:** `3`


.. _thickness:

thickness
^^^^^^^^^^^^^^

* **Description:** Input the thickness of a 2D material. This is only used if :ref:`dimensionality` = 2, and results in a scaling factor of (cell height/thickness) applied to the transport results.

* **Format:** *double*

* **Required:** no

* **Default:** `1.`


.. _constantRelaxationTime:

constantRelaxationTime
Expand Down
16 changes: 9 additions & 7 deletions doc/sphinx/source/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Introduction

Phoebe is a software for the ab-initio prediction of transport properties, such as electron-phonon limited conductivity and phonon thermal conductivity.

Currently, we support integration with the ab-initio software suite Quantum ESPRESSO for electron-phonon properties and anharmonic force constants through ShengBTE. Phoebe also accepts anharmonic force constants from Phono3py, which interfaces with most mainstream DFT packages. Support for more coming soon.
Currently, we support integration with the ab-initio software suite Quantum ESPRESSO for electron-phonon properties and anharmonic force constants through ShengBTE and Phono3py.

Additionally, Phoebe is written in C++ and designed for use on modern HPC infrastructures through hybrid MPI/OpenMP parallelization, distributed memory computation via ScaLAPACK, and support for GPU acceleration using Kokkos.

Expand All @@ -20,17 +20,19 @@ J. Phys. Mater. 5 035003. (2022).

* Electron-phonon limited electronic transport coefficients, including the electrical conductivity, Seebeck coefficient, and electronic thermal conductivity

* Lattice thermal conductivity, including effects from 3-phonon scattering, phonon-isotope and phonon-boundary scattering
* Lattice thermal conductivity, including contributions from 3-phonon, phonon-isotope, phonon-electron, and phonon-boundary scattering

* Electron-phonon scattering through Wannier interpolation, or EPA approximation
* BTE solutions by RTA, iterative, variational, and relaxon solvers

* Calculation of electron and phonon lifetimes (linewidths)
* Electron-phonon transport via Wannier interpolation or EPA approximation

* Electron and phonon viscosities
* Wigner transport equation correction for electrons and phonons

* Calculation of electron and phonon lifetimes/linewidths (including projected onto a band path)

* Plots of electronic band structure and phonon dispersion relations
* Electron and phonon viscosities

* Plots of electron or phonon density of states
* Plots of electron band structures/phonon dispersion, electron and phonon density of states

This documentation contains a brief description of the formalism used to compute these quantities. We expect that the user is already familiar with ab-initio codes and with the fundamentals of solid state physics. A good introduction to the topic is the book "Electrons and Phonons: The Theory of Transport Phenomena in Solids" by Ziman. In the theory section, we add references to contemporary literature for the latest method/algorithm developments.

Expand Down
9 changes: 9 additions & 0 deletions doc/sphinx/source/postProcessing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,15 @@ Plots lifetimes vs energy. Example usage::

See note above under ``tau_path.py`` for more info about calcIndex (the 0 at the end).

epa_tau.py
^^^^^^^^^^^^^^^^^^^^^^^^^

Plots lifetimes vs energy from an EPA calculation. Example usage::

python epa_tau.py epa_relaxation_times.json 0

See note above under ``tau_path.py`` for more info about calcIndex (the 0 at the end).

tau_bandResolved.py
^^^^^^^^^^^^^^^^^^^^^^^^^

Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx/source/theory/phononBTE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -437,5 +437,5 @@ Hence, one can work with the same techniques detailed above, provided that we wo

* Disadvantage 2: note that the symmetric matrix gains two Cartesian coordinate indices. As a result, in the limiting case of no symmetries in the system (only the identity), the matrix :math:`A^{ij}_{\nu^*\nu'^*}` will still be computed on the same number of wavevectors of :math:`A_{\nu\nu'}`, but occupies 3x3 times more memory without adding any information. Therefore, for low-symmetry systems, consider disabling symmetries.

* Disadvantage 3: The symmetries of the BTE are so far not applicable to the variational and relaxons solveres. This is not so much a problem with implementaiton, but instead is because of a need for a derivation of symmetries for these cases.
* Disadvantage 3: The symmetries of the BTE are so far not applicable to the variational and relaxons solvers. This is not so much a problem with implementation, but instead is because of a need for a derivation of symmetries for these cases.

11 changes: 6 additions & 5 deletions doc/sphinx/source/tutorials/elEpaTransport.rst
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ To do this, let's have a look at the input file ``qeToPhoebeEPA.in``::
electronFourierCutoff = 4.
epaMinEnergy = -4. eV
epaMaxEnergy = 10. eV
epaNumBins = 10
epaNumBins = 40
epaSmearingEnergy = 0.05 eV

The parameters in this input file are as follows:
Expand Down Expand Up @@ -278,6 +278,7 @@ Below is an example input file for computing electronic transport properties::

appName = "transportEpa"

useSymmetries = true
electronH0Name = "qe-elph/out/silicon.xml",
epaFileName = "qe-elph/silicon.phoebe.epa.dat"

Expand All @@ -293,6 +294,8 @@ The parameters used here are:

* :ref:`appName` = `"transportEPA"`: selects the app for computing electronic transport properties with EPA.

* :ref:`useSymmetries`: whether or not to use symmetries of the crystal structure in the calculation.

* :ref:`electronH0Name`: points to the Quantum-ESPRESSO ``*.xml`` file created by ``pw.x``, which contains the electronic single-particle energies.

* :ref:`epaFileName`: is the path to the file created at the previous step with ``elPhQeToPhoebe``.
Expand Down Expand Up @@ -340,16 +343,14 @@ You can learn more about how to post-process these files at :ref:`postprocessing

**Files which are always output for this calculation:**

* ``electron_bands.json``: contains the electron band energies used in the calculation.

* ``electron_dos.json``: contains the electron density of states used in the calculation.
* ``epa_dos.json``: contains the electron density of states used in the calculation.

* ``epa_onsager_coefficients.json``: contains the electronic transport coefficients from EPA.

* ``epa_relaxation_times.json``: contains the EPA relaxation times at each energy bin value.


To understand how to parse these files in more detail, take a look at the scripts described by the :ref:`postprocessing` page. In particular, if you want to plot lifetimes vs. energy, look at ``tau.py``. If you want to plot the transport coefficients vs. doping or temperature, check out ``transport_coefficients.py``.
To understand how to parse these files in more detail, take a look at the scripts described by the :ref:`postprocessing` page. In particular, if you want to plot lifetimes vs. energy, look at ``epa_tau.py``. If you want to plot the transport coefficients vs. doping or temperature, check out ``transport_coefficients.py``.

.. note::
It's a good idea to also use bands.py to plot the band structure. Fourier interpolation of the band structure can be a source of error -- you may need to go to higher k-point meshes to get a reasonable interpolation of the band structure. Check the bands at this stage to make sure they are similar to the true DFT bands -- otherwise, your results could be problematic!
Expand Down
72 changes: 36 additions & 36 deletions example/Silicon-el/reference/variational_onsager_coefficients.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,59 +10,59 @@
"electricalConductivity": [
[
[
1067476.083423818,
-289451.1726509079,
6988.620289292474
1067524.755964012,
-289797.97319140926,
4576.259106139662
],
[
-288402.6295156577,
1153574.4448552558,
-339252.03872597613
-290534.25409045833,
1153700.6483462334,
-337794.79923207546
],
[
6298.688866869923,
-338748.84561951895,
999624.5190918705
2423.3550264169166,
-337602.28847748507,
999823.4331092425
]
]
],
"electricalConductivityUnit": "S / m",
"electronicThermalConductivity": [
[
[
1.6784141552068075,
-0.17095390966293136,
-0.1925551757224847
1.6759588003842663,
-0.1695184449742141,
-0.19316637320993976
],
[
-0.16887322607943037,
0.967469430606753,
0.45201855869035085
-0.17307030791637715,
0.9671708308136298,
0.4527993530482056
],
[
-0.191703686958177,
0.4539177794991126,
1.2702570365076697
-0.1895368529229464,
0.4451924672444988,
1.265051833070335
]
]
],
"electronicThermalConductivityUnit": "W / m / K",
"mobility": [
[
[
66.6266227276008,
-18.066122864709598,
0.43619540955680475
66.62966062889252,
-18.087768453901255,
0.28562765358693365
],
[
-18.00067794376874,
72.00046026235661,
-21.1744487251345
-18.133723497245306,
72.00833726542098,
-21.083494981541044
],
[
0.3931332732677861,
-21.14304187885133,
62.3916607941002
0.15125393775778945,
-21.071479404221538,
62.404076031683935
]
]
],
Expand All @@ -71,19 +71,19 @@
"seebeckCoefficient": [
[
[
-3.834412383472706,
-24.797489282120214,
14.089965245893998
-3.7355359725395547,
-24.81297218056885,
14.075023704624254
],
[
-14.256947447646306,
-19.694668984349708,
-14.015560582347534
-14.206137023556979,
-19.708154573007306,
-14.119749174882436
],
[
14.752677089503676,
-8.432328471018659,
-59.49649274673085
15.116531799699265,
-8.807694880433802,
-59.56690767248755
]
]
],
Expand Down
Loading
Loading