ApproxMemReq Subroutine

public subroutine ApproxMemReq()

Arguments

None

Contents

Source Code


Source Code

    subroutine ApproxMemReq()

        ! This routine makes a quick sum of the memory that will be require to
        ! transform the integrals from the HF to the new basis.

        ! Main arrays required are:
        MemAllocRot = 0

        ! Symmetry/Labelling:
        !   - SymLabelLists(NoOrbs) x 3
        !   - SymLabelCounts(32/16 - Spin/Spat)
        MemAllocRot = MemAllocRot + (3 * NoOrbs * 4)
        MemAllocRot = MemAllocRot + (32 * 4)

        ! Finding transformation matrices
        !   - NatOrbsMat(NoOrbs, NoOrbs)
        !   - Evalues(NoOrbs) x 2
        MemAllocRot = MemAllocRot + ((NoOrbs**2) * 8)
        MemAllocRot = MemAllocRot + (2 * NoOrbs * 8)

        ! Transformation of integrals
        !   - CoeffT1(NoOrbs, NoRotOrbs)
        !   - FourIndInts(NoRotOrbs, NoRotOrbs, NoOrbs, NoOrbs)
        !   - Temp4indints(NoRotOrbs, NoOrbs)
        if (tPrintRODump) then
            MemAllocRot = MemAllocRot + (NoOrbs * NoRotOrbs * 8 * 2)
            MemAllocRot = MemAllocRot + ((NoRotOrbs**2) * (NoOrbs**2) * 8)

            ! Transform fock
            !   - ArrNew(NoOrbs) - reduce this?
            MemAllocRot = MemAllocRot + (NoOrbs * 8)

            ! RefillTMAT2D
            !   - TMAT2D(nBasis, nBasis)
            MemAllocRot = MemAllocRot + ((nBasis**2) * 8)
        end if

        write(stdout, '(A72, F20.10, A15)') "Rough estimate of the memory required for the orbital transformation  =  ", &
            real(MemAllocRot, dp) / 1048576.0_dp, " Mb/Processor"

    end subroutine ApproxMemReq