mirror of
https://github.com/QuantumPackage/qp2.git
synced 2025-01-05 09:58:42 +01:00
Working on obtain I for alpha.
This commit is contained in:
parent
0234e46e1b
commit
4b3b6300ef
@ -316,85 +316,34 @@ subroutine obtain_connected_I_foralpha(idxI, Ialpha, connectedI, idxs_connectedI
|
|||||||
extyp = 3
|
extyp = 3
|
||||||
if(N_int .eq. 1) then
|
if(N_int .eq. 1) then
|
||||||
IJsomo = IEOR(Isomo, Jsomo)
|
IJsomo = IEOR(Isomo, Jsomo)
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! p = (popcnt(ieor( IAND(Isomo,IJsomo) , IAND(Isomo,IJsomo) -1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
p = TRAILZ(IAND(Isomo,IJsomo)) + 1
|
p = TRAILZ(IAND(Isomo,IJsomo)) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
IJsomo = IBCLR(IJsomo,p-1)
|
IJsomo = IBCLR(IJsomo,p-1)
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! q = (popcnt(ieor(IJsomo,IJsomo-1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
q = TRAILZ(IJsomo) + 1
|
q = TRAILZ(IJsomo) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
!print *," p=",p," q=",q
|
!print *," p=",p," q=",q
|
||||||
!call get_single_excitation_cfg(Jcfg, Icfg, p, q, N_int)
|
!call get_single_excitation_cfg(Jcfg, Icfg, p, q, N_int)
|
||||||
else
|
else
|
||||||
exc = 0
|
! Find p
|
||||||
do ii = 1,2
|
do ii=1,N_int
|
||||||
ishift = 1-bit_kind_size
|
Isomo = Ialpha(ii,1)
|
||||||
do l=1,N_int
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
ishift = ishift + bit_kind_size
|
IJsomo = IEOR(Isomo, Jsomo)
|
||||||
if (Jcfg(l,ii) == Icfg(l,ii)) then
|
if(popcnt(IAND(Isomo,IJsomo)) > 0)then
|
||||||
cycle
|
p = TRAILZ(IAND(Isomo,IJsomo)) + 1 + ii * bit_kind_size
|
||||||
|
EXIT
|
||||||
endif
|
endif
|
||||||
tmp = xor( Jcfg(l,ii), Icfg(l,ii) )
|
|
||||||
particle = iand(tmp, Icfg(l,ii))
|
|
||||||
hole = iand(tmp, Jcfg(l,ii))
|
|
||||||
if (particle /= 0_bit_kind) then
|
|
||||||
tz = trailz(particle)
|
|
||||||
exc(0,2,ii) = 1
|
|
||||||
exc(1,2,ii) = tz+ishift
|
|
||||||
!print *,"part ",tz+ishift, " ii=",ii, exc(1,2,2)
|
|
||||||
endif
|
|
||||||
if (hole /= 0_bit_kind) then
|
|
||||||
tz = trailz(hole)
|
|
||||||
exc(0,1,ii) = 1
|
|
||||||
exc(1,1,ii) = tz+ishift
|
|
||||||
!print *,"hole ",tz+ishift, " ii=",ii, exc(1,1,2)
|
|
||||||
endif
|
|
||||||
|
|
||||||
if ( iand(exc(0,1,ii),exc(0,2,ii)) /= 1) then ! exc(0,1,ii)/=1 and exc(0,2,ii) /= 1
|
|
||||||
cycle
|
|
||||||
endif
|
|
||||||
|
|
||||||
high = max(exc(1,1,ii), exc(1,2,ii))-1
|
|
||||||
low = min(exc(1,1,ii), exc(1,2,ii))
|
|
||||||
|
|
||||||
ASSERT (low >= 0)
|
|
||||||
ASSERT (high > 0)
|
|
||||||
|
|
||||||
k = shiftr(high,bit_kind_shift)+1
|
|
||||||
j = shiftr(low,bit_kind_shift)+1
|
|
||||||
m = iand(high,bit_kind_size-1)
|
|
||||||
n = iand(low,bit_kind_size-1)
|
|
||||||
|
|
||||||
if (j==k) then
|
|
||||||
nperm = nperm + popcnt(iand(Jcfg(j,ii), &
|
|
||||||
iand( shiftl(1_bit_kind,m)-1_bit_kind, &
|
|
||||||
not(shiftl(1_bit_kind,n))+1_bit_kind)) )
|
|
||||||
else
|
|
||||||
nperm = nperm + popcnt( &
|
|
||||||
iand(Jcfg(j,ii), &
|
|
||||||
iand(not(0_bit_kind), &
|
|
||||||
(not(shiftl(1_bit_kind,n)) + 1_bit_kind) ))) &
|
|
||||||
+ popcnt(iand(Jcfg(k,ii), &
|
|
||||||
(shiftl(1_bit_kind,m) - 1_bit_kind ) ))
|
|
||||||
|
|
||||||
do iii=j+1,k-1
|
|
||||||
nperm = nperm + popcnt(Jcfg(iii,ii))
|
|
||||||
end do
|
end do
|
||||||
|
! Find q
|
||||||
|
do ii=1,N_int
|
||||||
|
Isomo = Ialpha(ii,1)
|
||||||
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
|
IJsomo = IEOR(Isomo, Jsomo)
|
||||||
|
IJsomo = IBCLR(IJsomo,p-1)
|
||||||
|
if(popcnt(IJsomo) > 0)then
|
||||||
|
q = TRAILZ(IJsomo) + 1 + ii * bit_kind_size
|
||||||
|
EXIT
|
||||||
endif
|
endif
|
||||||
|
|
||||||
! Set p and q
|
|
||||||
q = max(exc(1,1,1),exc(1,1,2))
|
|
||||||
p = max(exc(1,2,1),exc(1,2,2))
|
|
||||||
exit
|
|
||||||
|
|
||||||
enddo
|
enddo
|
||||||
enddo
|
endif
|
||||||
endif
|
|
||||||
!assert ( p == pp)
|
!assert ( p == pp)
|
||||||
!assert ( q == qq)
|
!assert ( q == qq)
|
||||||
!print *," --- p=",p," q=",q
|
!print *," --- p=",p," q=",q
|
||||||
@ -409,88 +358,35 @@ endif
|
|||||||
!print *,"obt DOMO -> VMO"
|
!print *,"obt DOMO -> VMO"
|
||||||
extyp = 2
|
extyp = 2
|
||||||
if(N_int.eq.1)then
|
if(N_int.eq.1)then
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! p = (popcnt(ieor( IEOR(Idomo,Jdomo),IEOR(Idomo,Jdomo) -1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
p = TRAILZ(IEOR(Idomo,Jdomo)) + 1
|
p = TRAILZ(IEOR(Idomo,Jdomo)) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
Isomo = IEOR(Isomo, Jsomo)
|
Isomo = IEOR(Isomo, Jsomo)
|
||||||
Isomo = IBCLR(Isomo,p-1)
|
Isomo = IBCLR(Isomo,p-1)
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! q = (popcnt(ieor(Isomo,Isomo-1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
q = TRAILZ(Isomo) + 1
|
q = TRAILZ(Isomo) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
else
|
else
|
||||||
exc=0
|
|
||||||
exc(0,1,1) = 0
|
! Find p
|
||||||
exc(0,2,1) = 0
|
do ii=1,N_int
|
||||||
exc(0,1,2) = 0
|
Isomo = Ialpha(ii,1)
|
||||||
exc(0,2,2) = 0
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
do ii = 1,2
|
Idomo = Ialpha(ii,2)
|
||||||
ishift = 1-bit_kind_size
|
Jdomo = psi_configuration(ii,2,i)
|
||||||
do l=1,N_int
|
if(popcnt(IEOR(Idomo,Jdomo)) > 0)then
|
||||||
ishift = ishift + bit_kind_size
|
p = TRAILZ(IEOR(Idomo,Jdomo)) + 1 + ii * bit_kind_size
|
||||||
if (Jcfg(l,ii) == Icfg(l,ii)) then
|
EXIT
|
||||||
cycle
|
endif
|
||||||
|
end do
|
||||||
|
! Find q
|
||||||
|
do ii=1,N_int
|
||||||
|
Isomo = Ialpha(ii,1)
|
||||||
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
|
Isomo = IEOR(Isomo, Jsomo)
|
||||||
|
Isomo = IBCLR(Isomo,p-1)
|
||||||
|
if(popcnt(Isomo) > 0)then
|
||||||
|
q = TRAILZ(Isomo) + 1 + ii * bit_kind_size
|
||||||
|
EXIT
|
||||||
endif
|
endif
|
||||||
tmp = xor( Jcfg(l,ii), Icfg(l,ii) )
|
|
||||||
particle = iand(tmp, Icfg(l,ii))
|
|
||||||
hole = iand(tmp, Jcfg(l,ii))
|
|
||||||
if (particle /= 0_bit_kind) then
|
|
||||||
tz = trailz(particle)
|
|
||||||
exc(0,2,ii) = 1
|
|
||||||
exc(1,2,ii) = tz+ishift
|
|
||||||
!print *,"part ",tz+ishift, " ii=",ii
|
|
||||||
endif
|
|
||||||
if (hole /= 0_bit_kind) then
|
|
||||||
tz = trailz(hole)
|
|
||||||
exc(0,1,ii) = 1
|
|
||||||
exc(1,1,ii) = tz+ishift
|
|
||||||
!print *,"hole ",tz+ishift, " ii=",ii
|
|
||||||
endif
|
|
||||||
|
|
||||||
if ( iand(exc(0,1,ii),exc(0,2,ii)) /= 1) then ! exc(0,1,ii)/=1 and exc(0,2,ii) /= 1
|
|
||||||
cycle
|
|
||||||
endif
|
|
||||||
|
|
||||||
high = max(exc(1,1,ii), exc(1,2,ii))-1
|
|
||||||
low = min(exc(1,1,ii), exc(1,2,ii))
|
|
||||||
|
|
||||||
ASSERT (low >= 0)
|
|
||||||
ASSERT (high > 0)
|
|
||||||
|
|
||||||
k = shiftr(high,bit_kind_shift)+1
|
|
||||||
j = shiftr(low,bit_kind_shift)+1
|
|
||||||
m = iand(high,bit_kind_size-1)
|
|
||||||
n = iand(low,bit_kind_size-1)
|
|
||||||
|
|
||||||
if (j==k) then
|
|
||||||
nperm = nperm + popcnt(iand(Jcfg(j,ii), &
|
|
||||||
iand( shiftl(1_bit_kind,m)-1_bit_kind, &
|
|
||||||
not(shiftl(1_bit_kind,n))+1_bit_kind)) )
|
|
||||||
else
|
|
||||||
nperm = nperm + popcnt( &
|
|
||||||
iand(Jcfg(j,ii), &
|
|
||||||
iand(not(0_bit_kind), &
|
|
||||||
(not(shiftl(1_bit_kind,n)) + 1_bit_kind) ))) &
|
|
||||||
+ popcnt(iand(Jcfg(k,ii), &
|
|
||||||
(shiftl(1_bit_kind,m) - 1_bit_kind ) ))
|
|
||||||
|
|
||||||
do iii=j+1,k-1
|
|
||||||
nperm = nperm + popcnt(Jcfg(iii,ii))
|
|
||||||
end do
|
end do
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
! Set p and q
|
|
||||||
q = max(exc(1,1,1),exc(1,1,2))
|
|
||||||
p = max(exc(1,2,1),exc(1,2,2))
|
|
||||||
exit
|
|
||||||
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
endif
|
|
||||||
!assert ( p == pp)
|
!assert ( p == pp)
|
||||||
!assert ( q == qq)
|
!assert ( q == qq)
|
||||||
else
|
else
|
||||||
@ -498,183 +394,75 @@ endif
|
|||||||
!print *,"obt SOMO -> SOMO"
|
!print *,"obt SOMO -> SOMO"
|
||||||
extyp = 1
|
extyp = 1
|
||||||
if(N_int.eq.1)then
|
if(N_int.eq.1)then
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! q = (popcnt(ieor( IEOR(Idomo,Jdomo), IEOR(Idomo,Jdomo)-1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
q = TRAILZ(IEOR(Idomo,Jdomo)) + 1
|
q = TRAILZ(IEOR(Idomo,Jdomo)) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
Isomo = IEOR(Isomo, Jsomo)
|
Isomo = IEOR(Isomo, Jsomo)
|
||||||
Isomo = IBCLR(Isomo,q-1)
|
Isomo = IBCLR(Isomo,q-1)
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! p = (popcnt(ieor(Isomo,Isomo-1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
p = TRAILZ(Isomo) + 1
|
p = TRAILZ(Isomo) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
! Check for Minimal alpha electrons (MS)
|
! Check for Minimal alpha electrons (MS)
|
||||||
!if(POPCNT(Isomo).lt.MS)then
|
!if(POPCNT(Isomo).lt.MS)then
|
||||||
! cycle
|
! cycle
|
||||||
!endif
|
!endif
|
||||||
else
|
else
|
||||||
exc=0
|
! Find p
|
||||||
exc(0,1,1) = 0
|
do ii=1,N_int
|
||||||
exc(0,2,1) = 0
|
Isomo = Ialpha(ii,1)
|
||||||
exc(0,1,2) = 0
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
exc(0,2,2) = 0
|
Idomo = Ialpha(ii,2)
|
||||||
do ii = 1,2
|
Jdomo = psi_configuration(ii,2,i)
|
||||||
ishift = 1-bit_kind_size
|
if(popcnt(IEOR(Idomo,Jdomo)) > 0)then
|
||||||
do l=1,N_int
|
q = TRAILZ(IEOR(Idomo,Jdomo)) + 1 + ii * bit_kind_size
|
||||||
ishift = ishift + bit_kind_size
|
EXIT
|
||||||
if (Jcfg(l,ii) == Icfg(l,ii)) then
|
|
||||||
cycle
|
|
||||||
endif
|
endif
|
||||||
tmp = xor( Jcfg(l,ii), Icfg(l,ii) )
|
|
||||||
particle = iand(tmp, Icfg(l,ii))
|
|
||||||
hole = iand(tmp, Jcfg(l,ii))
|
|
||||||
if (particle /= 0_bit_kind) then
|
|
||||||
tz = trailz(particle)
|
|
||||||
exc(0,2,ii) = 1
|
|
||||||
exc(1,2,ii) = tz+ishift
|
|
||||||
!print *,"part ",tz+ishift, " ii=",ii
|
|
||||||
endif
|
|
||||||
if (hole /= 0_bit_kind) then
|
|
||||||
tz = trailz(hole)
|
|
||||||
exc(0,1,ii) = 1
|
|
||||||
exc(1,1,ii) = tz+ishift
|
|
||||||
!print *,"hole ",tz+ishift, " ii=",ii
|
|
||||||
endif
|
|
||||||
|
|
||||||
if ( iand(exc(0,1,ii),exc(0,2,ii)) /= 1) then ! exc(0,1,ii)/=1 and exc(0,2,ii) /= 1
|
|
||||||
cycle
|
|
||||||
endif
|
|
||||||
|
|
||||||
high = max(exc(1,1,ii), exc(1,2,ii))-1
|
|
||||||
low = min(exc(1,1,ii), exc(1,2,ii))
|
|
||||||
|
|
||||||
ASSERT (low >= 0)
|
|
||||||
ASSERT (high > 0)
|
|
||||||
|
|
||||||
k = shiftr(high,bit_kind_shift)+1
|
|
||||||
j = shiftr(low,bit_kind_shift)+1
|
|
||||||
m = iand(high,bit_kind_size-1)
|
|
||||||
n = iand(low,bit_kind_size-1)
|
|
||||||
|
|
||||||
if (j==k) then
|
|
||||||
nperm = nperm + popcnt(iand(Jcfg(j,ii), &
|
|
||||||
iand( shiftl(1_bit_kind,m)-1_bit_kind, &
|
|
||||||
not(shiftl(1_bit_kind,n))+1_bit_kind)) )
|
|
||||||
else
|
|
||||||
nperm = nperm + popcnt( &
|
|
||||||
iand(Jcfg(j,ii), &
|
|
||||||
iand(not(0_bit_kind), &
|
|
||||||
(not(shiftl(1_bit_kind,n)) + 1_bit_kind) ))) &
|
|
||||||
+ popcnt(iand(Jcfg(k,ii), &
|
|
||||||
(shiftl(1_bit_kind,m) - 1_bit_kind ) ))
|
|
||||||
|
|
||||||
do iii=j+1,k-1
|
|
||||||
nperm = nperm + popcnt(Jcfg(iii,ii))
|
|
||||||
end do
|
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
! Set p and q
|
|
||||||
q = max(exc(1,1,1),exc(1,1,2))
|
|
||||||
p = max(exc(1,2,1),exc(1,2,2))
|
|
||||||
exit
|
|
||||||
|
|
||||||
enddo
|
enddo
|
||||||
|
! Find q
|
||||||
|
do ii=1,N_int
|
||||||
|
Isomo = Ialpha(ii,1)
|
||||||
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
|
Isomo = IEOR(Isomo, Jsomo)
|
||||||
|
Isomo = IBCLR(Isomo,q-1)
|
||||||
|
if(popcnt(Isomo) > 0)then
|
||||||
|
p = TRAILZ(Isomo) + 1 + ii * bit_kind_size
|
||||||
|
EXIT
|
||||||
|
endif
|
||||||
enddo
|
enddo
|
||||||
endif
|
endif
|
||||||
!assert ( p == pp)
|
!assert ( p == pp)
|
||||||
!assert ( q == qq)
|
!assert ( q == qq)
|
||||||
end if
|
endif
|
||||||
case (2)
|
case (2)
|
||||||
! DOMO -> SOMO
|
! DOMO -> SOMO
|
||||||
!print *,"obt DOMO -> SOMO"
|
!print *,"obt DOMO -> SOMO"
|
||||||
extyp = 4
|
extyp = 4
|
||||||
if(N_int.eq.1)then
|
if(N_int.eq.1)then
|
||||||
IJsomo = IEOR(Isomo, Jsomo)
|
IJsomo = IEOR(Isomo, Jsomo)
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! p = (popcnt(ieor( IAND(Jsomo,IJsomo), IAND(Jsomo,IJsomo)-1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
p = TRAILZ(IAND(Jsomo,IJsomo)) + 1
|
p = TRAILZ(IAND(Jsomo,IJsomo)) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
IJsomo = IBCLR(IJsomo,p-1)
|
IJsomo = IBCLR(IJsomo,p-1)
|
||||||
!IRP_IF WITHOUT_TRAILZ
|
|
||||||
! q = (popcnt(ieor( IJsomo , IJsomo -1))-1) + 1
|
|
||||||
!IRP_ELSE
|
|
||||||
q = TRAILZ(IJsomo) + 1
|
q = TRAILZ(IJsomo) + 1
|
||||||
!IRP_ENDIF
|
|
||||||
|
|
||||||
else
|
else
|
||||||
exc=0
|
! Find p
|
||||||
exc(0,1,1) = 0
|
do ii=1,N_int
|
||||||
exc(0,2,1) = 0
|
Isomo = Ialpha(ii,1)
|
||||||
exc(0,1,2) = 0
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
exc(0,2,2) = 0
|
Idomo = Ialpha(ii,2)
|
||||||
do ii = 1,2
|
Jdomo = psi_configuration(ii,2,i)
|
||||||
ishift = 1-bit_kind_size
|
IJsomo = IEOR(Isomo, Jsomo)
|
||||||
do l=1,N_int
|
if(popcnt(IAND(Jsomo,IJsomo)) > 0)then
|
||||||
ishift = ishift + bit_kind_size
|
p = TRAILZ(IAND(Jsomo,IJsomo)) + 1 + ii * bit_kind_size
|
||||||
if (Jcfg(l,ii) == Icfg(l,ii)) then
|
EXIT
|
||||||
cycle
|
|
||||||
endif
|
endif
|
||||||
tmp = xor( Jcfg(l,ii), Icfg(l,ii) )
|
|
||||||
particle = iand(tmp, Icfg(l,ii))
|
|
||||||
hole = iand(tmp, Jcfg(l,ii))
|
|
||||||
if (particle /= 0_bit_kind) then
|
|
||||||
tz = trailz(particle)
|
|
||||||
exc(0,2,ii) = 1
|
|
||||||
exc(1,2,ii) = tz+ishift
|
|
||||||
!print *,"part ",tz+ishift, " ii=",ii
|
|
||||||
endif
|
|
||||||
if (hole /= 0_bit_kind) then
|
|
||||||
tz = trailz(hole)
|
|
||||||
exc(0,1,ii) = 1
|
|
||||||
exc(1,1,ii) = tz+ishift
|
|
||||||
!print *,"hole ",tz+ishift, " ii=",ii
|
|
||||||
endif
|
|
||||||
|
|
||||||
if ( iand(exc(0,1,ii),exc(0,2,ii)) /= 1) then ! exc(0,1,ii)/=1 and exc(0,2,ii) /= 1
|
|
||||||
cycle
|
|
||||||
endif
|
|
||||||
|
|
||||||
high = max(exc(1,1,ii), exc(1,2,ii))-1
|
|
||||||
low = min(exc(1,1,ii), exc(1,2,ii))
|
|
||||||
|
|
||||||
ASSERT (low >= 0)
|
|
||||||
ASSERT (high > 0)
|
|
||||||
|
|
||||||
k = shiftr(high,bit_kind_shift)+1
|
|
||||||
j = shiftr(low,bit_kind_shift)+1
|
|
||||||
m = iand(high,bit_kind_size-1)
|
|
||||||
n = iand(low,bit_kind_size-1)
|
|
||||||
|
|
||||||
if (j==k) then
|
|
||||||
nperm = nperm + popcnt(iand(Jcfg(j,ii), &
|
|
||||||
iand( shiftl(1_bit_kind,m)-1_bit_kind, &
|
|
||||||
not(shiftl(1_bit_kind,n))+1_bit_kind)) )
|
|
||||||
else
|
|
||||||
nperm = nperm + popcnt( &
|
|
||||||
iand(Jcfg(j,ii), &
|
|
||||||
iand(not(0_bit_kind), &
|
|
||||||
(not(shiftl(1_bit_kind,n)) + 1_bit_kind) ))) &
|
|
||||||
+ popcnt(iand(Jcfg(k,ii), &
|
|
||||||
(shiftl(1_bit_kind,m) - 1_bit_kind ) ))
|
|
||||||
|
|
||||||
do iii=j+1,k-1
|
|
||||||
nperm = nperm + popcnt(Jcfg(iii,ii))
|
|
||||||
end do
|
|
||||||
|
|
||||||
endif
|
|
||||||
|
|
||||||
! Set p and q
|
|
||||||
q = max(exc(1,1,1),exc(1,1,2))
|
|
||||||
p = max(exc(1,2,1),exc(1,2,2))
|
|
||||||
exit
|
|
||||||
|
|
||||||
enddo
|
enddo
|
||||||
|
! Find q
|
||||||
|
do ii=1,N_int
|
||||||
|
Isomo = Ialpha(ii,1)
|
||||||
|
Jsomo = psi_configuration(ii,1,i)
|
||||||
|
IJsomo = IEOR(Isomo, Jsomo)
|
||||||
|
IJsomo = IBCLR(IJsomo,p-1)
|
||||||
|
if(popcnt(IJsomo) > 0)then
|
||||||
|
q = TRAILZ(IJsomo) + 1 + ii * bit_kind_size
|
||||||
|
EXIT
|
||||||
|
endif
|
||||||
enddo
|
enddo
|
||||||
endif
|
endif
|
||||||
!assert ( p == pp)
|
!assert ( p == pp)
|
||||||
!assert ( q == qq)
|
!assert ( q == qq)
|
||||||
case default
|
case default
|
||||||
|
Loading…
Reference in New Issue
Block a user