Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | nI(nel) | |||
integer, | intent(in) | :: | ex(2) | |||
integer, | intent(out) | :: | nJ(nel) | |||
integer, | intent(out) | :: | ex2(2) |
subroutine swap_excitations_singles(nI, ex, nJ, ex2)
integer, intent(in) :: nI(nel), ex(2)
integer, intent(out) :: nJ(nel), ex2(2)
nJ = nI
where (nJ == ex(1)) nJ = ex(2)
call sort(nJ)
ex2 = ex
call swap(ex2(1), ex2(2))
end subroutine swap_excitations_singles