anchor.diff:      end if
       call timer_end(LOG_OTHER)
   
  -    if (AD_RHO /= 'No' .and. mod(iter,100) == 0 ) then 
  -      call timer_begin(LOG_ALLREDUCE)
  -      call comm_summation(excited_electron_l,excited_electron,NX_m*NY_m,proc_group(1))
  -      call timer_end(LOG_ALLREDUCE)
  -      if(comm_is_root(1))call write_excited_electron(iter)
  -    else if (iter == Nt ) then
  -      call timer_begin(LOG_ALLREDUCE)
  -      call comm_summation(excited_electron_l,excited_electron,NX_m*NY_m,proc_group(1))
  -      call timer_end(LOG_ALLREDUCE)
  -      if(comm_is_root(1))call write_excited_electron(iter)
  -    end if
  +!    if (AD_RHO /= 'No' .and. mod(iter,100) == 0 ) then 
  +!      call timer_begin(LOG_ALLREDUCE)
  +!      call comm_summation(excited_electron_l,excited_electron,NX_m*NY_m,proc_group(1))
  +!      call timer_end(LOG_ALLREDUCE)
  +!      if(comm_is_root(1))call write_excited_electron(iter)
  +!    else if (iter == Nt ) then
  +!      call timer_begin(LOG_ALLREDUCE)
  +!      call comm_summation(excited_electron_l,excited_electron,NX_m*NY_m,proc_group(1))
  +!      call timer_end(LOG_ALLREDUCE)
  +!      if(comm_is_root(1))call write_excited_electron(iter)
  +!    end if
   
       call timer_begin(LOG_OTHER)
       if (reentrance_switch == 1) then 
  
positive.code: 
    deallocate(rho_in,rho_out)
    deallocate(Eall_GS,esp_var_ave,esp_var_max,dns_diff)
  !====GS calculation============================
  
  #ifdef ARTED_LBLK
  
negative.code:       call timer_end(LOG_OTHER)
  
        call timer_begin(LOG_K_SHIFT_WF)
  !!Adiabatic evolution
  !      if (AD_RHO /= 'No' .and. mod(iter,100) == 0) then
  !        call k_shift_wf(Rion_update,2)
  !        if(comm_is_root(2))then ! sato
  !          excited_electron_l(ix_m,iy_m)=sum(occ)-sum(ovlp_occ(1:NBoccmax,:))
  !        end if ! sato
  !      else if (iter == Nt ) then
  !        call k_shift_wf(Rion_update,2)
  !        if(comm_is_root(2))then ! sato
  !          excited_electron_l(ix_m,iy_m)=sum(occ)-sum(ovlp_occ(1:NBoccmax,:))
  !        end if ! sato
  !      end if
        call timer_end(LOG_K_SHIFT_WF)
        
      end do Macro_loop
  