function linear_orb_ind(a, b) result(ind) integer, intent(in) :: a, b integer :: ind ! see above! ind = orb_ind_mat(a, b) end function linear_orb_ind