This function returns a string describing the type of smearing associated to a given smr_index integer value.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | smearing_index | The integer index for which we want to get the string |
function param_get_smearing_type(smearing_index)
!! This function returns a string describing the type of smearing
!! associated to a given smr_index integer value.
integer, intent(in) :: smearing_index
!! The integer index for which we want to get the string
character(len=80) :: param_get_smearing_type
character(len=4) :: orderstr
if (smearing_index > 0) then
write (orderstr, '(I0)') smearing_index
param_get_smearing_type = "Methfessel-Paxton of order "//trim(orderstr)
else if (smearing_index .eq. 0) then
param_get_smearing_type = "Gaussian"
else if (smearing_index .eq. -1) then
param_get_smearing_type = "Marzari-Vanderbilt cold smearing"
else if (smearing_index .eq. -99) then
param_get_smearing_type = "Fermi-Dirac smearing"
else
param_get_smearing_type = "Unknown type of smearing"
end if
end function param_get_smearing_type