parse_shell_header Subroutine

private pure subroutine parse_shell_header(line, ang_mom, nfunc, stat)

Parse shell header line (e.g., “S 2” or “L 3”)

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: line
character(len=1), intent(out) :: ang_mom
integer, intent(out) :: nfunc
integer, intent(out) :: stat

Called by

proc~~parse_shell_header~~CalledByGraph proc~parse_shell_header parse_shell_header proc~fill_element_basis fill_element_basis proc~fill_element_basis->proc~parse_shell_header proc~parse_element_basis parse_element_basis proc~parse_element_basis->proc~fill_element_basis proc~build_molecular_basis build_molecular_basis proc~build_molecular_basis->proc~parse_element_basis

Variables

Type Visibility Attributes Name Initial
character(len=256), private :: line_trim

Source Code

   pure subroutine parse_shell_header(line, ang_mom, nfunc, stat)
      !! Parse shell header line (e.g., "S 2" or "L 3")
      character(len=*), intent(in) :: line
      character(len=1), intent(out) :: ang_mom
      integer, intent(out) :: nfunc
      integer, intent(out) :: stat

      character(len=256) :: line_trim

      line_trim = adjustl(line)
      ang_mom = line_trim(1:1)

      ! Read the number of functions
      read (line_trim(2:), *, iostat=stat) nfunc

   end subroutine parse_shell_header