get_cn_count_id Function

public pure function get_cn_count_id(cn_count_name) result(cn_count_id)

Translate string into coordination number type

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: cn_count_name

String for coordination number counting function

Return Value integer

ID for coordination number counting function


Source Code

pure function get_cn_count_id(cn_count_name) result(cn_count_id)
   !> String for coordination number counting function
   character(len=*), intent(in) :: cn_count_name
   !> ID for coordination number counting function
   integer :: cn_count_id

   select case(cn_count_name)
   case default
      ! Indicate unknown CN option
      cn_count_id = -1 
   case("exp")
      cn_count_id = cn_count%exp
   case("dexp")
      cn_count_id = cn_count%dexp
   case("erf")
      cn_count_id = cn_count%erf
   case("erf_en")
      cn_count_id = cn_count%erf_en
   case("dftd4")
      cn_count_id = cn_count%dftd4
   end select

end function get_cn_count_id