perform_exact_diag_all_symmetry Subroutine

public subroutine perform_exact_diag_all_symmetry()

Arguments

None

Contents


Source Code

    subroutine perform_exact_diag_all_symmetry()

        integer :: lwork, info
        real(dp), allocatable :: work(:)

        call init_exact_diag()

        ! Create the workspace for dsyev.
        lwork = max(1, 3 * ndets_ed - 1)
        allocate(work(lwork))

        write(stdout, '(1x,a28)', advance='no') "Diagonalising Hamiltonian..."
        call neci_flush(stdout)

        ! Perform the diagonalisation.
        call dsyev('V', 'U', ndets_ed, hamiltonian, ndets_ed, eigv_ed, work, lwork, info)

        write(stdout, '(1x,a9,/)') "Complete."
        call neci_flush(stdout)

        call output_exact_spectrum()

        deallocate(work)

        call end_exact_spectrum()

    end subroutine perform_exact_diag_all_symmetry