[CP2K-user] How to mix DFTB and normal XC calculation?

linfeng gan ganli... at gmail.com
Wed May 15 10:18:52 UTC 2019


 

 

Hi Vladimir,

Thanks for your feedback. But there are still something confusing me. The 
input which I used was simply modified form 
“tests/QS/regtest-embed/H2O_H2_pbe_mp2.inp” in the CP2K test dir. Correct 
me if I understand the input keyword wrong.

 

In the input system, there are a water molecular and a hydrogen molecular.

 

(1)   Question one

The MULTIPLE_FORCE_EVALS section, I set

    FORCE_EVAL_ORDER 2 3 4 5

So, there should be 5 FORCE_EVAL sections in my input file. Am I correct?

 

(2)   Question two

!*******************************

!FORCE_EVA section 1 

!

!mapping the fragments 

!*******************************

 

The first FORCE_EVA section should be descripting how the other 4 
FORCE_EVAL embed and how to mapping the fragments. The Am I correct?

 

(3)   Question three

!*******************************

!FORCE_EVA section 2 

!

!Subsys 1 the H2O molecular

!*******************************

 

The second FORCE_EVA section should be descripting how to calculate the H2O 
molecular energy with DFTB. 

 

(4)   Question 4

!*******************************

!FORCE_EVA section 3 

!

!Subsys 2 the H2 molecular

!*******************************

    

    &DFT

        &QS

            CLUSTER_EMBED_SUBSYS .TRUE.

        &END QS

    &END DFT

    

 

The third FORCE_EVA section should be descripting how to calculate the H2 
molecular energy with DFTB. This is the embedded cluster and the CLUSTER_EMBED_SUBSYS 
.TRUE. is set.

 

(5)   Question five

!*******************************

!FORCE_EVA section 4

!

!Total system including H2O and H2

!*******************************

    &DFT

        &QS

            REF_EMBED_SUBSYS .TRUE.

            

            &OPT_EMBED

               REG_LAMBDA 0.00001

               N_ITER 3

               DENS_CONV_INT 0.5

               DENS_CONV_MAX 0.025

               OPTIMIZER QUASI_NEWTON

               GRID_OPT .FALSE.

            &END OPT_EMBED

        &END QS

    &END DFT

 

The fourth FORCE_EVA section descripting how to calculate the total system, 
including H2O and H2 molecular, energy with DFTB. Because this is the total 
system, the REF_EMBED_SUBSYS .TRUE. is set.

 

(6)   Question six

!*******************************

!FORCE_EVA section 5 

!

!Higher level calculation on subsys 2, the H2O 

!*******************************

    &DFT

        &QS

            HIGH_LEVEL_EMBED_SUBSYS .TRUE.

        &END QS

    &END DFT

 

The fifth FORCE_EVA section descripting how to calculate the higher level 
system, in this case H2, energy with PBE. The HIGH_LEVEL_EMBED_SUBSYS 
.TRUE. should be set in this section.

 

 

To avoid the grid influence I set the same grids for all the subsystem as 
follow,

        &MGRID

          NGRIDS 5

          CUTOFF 600     

          REL_CUTOFF 60   

        &END MGRID

 

 

But I still got the same error,

*******************************************************************************

 *   ___                                                                       
*

 *  /   \                                        
                              *

 * [ABORT]                                                                     
*

 *  \___/               The pointer gto_basis_set is not associated            
*

 *    |                                                       
                 *

 *  O/|                                                                        
*

 * /| |                                                                        
*

 * / \                                           aobasis/basis_set_types.F:791 
*

 
*******************************************************************************

 

 

What should I do next? I post my input file in the end of this,

 

Regards,

Linfeng


&GLOBAL                                                                                           

    PROJECT  h2o_h2_dftb_pbe_DFET
    PRINT_LEVEL HIGH
    RUN_TYPE ENERGY
&END GLOBAL

&MULTIPLE_FORCE_EVALS
    FORCE_EVAL_ORDER 2 3 4 5
    MULTIPLE_SUBSYS T
&END MULTIPLE_FORCE_EVALS


!*******************************
!FORCE_EVA section 1 
!
!mapping the fragments 
!*******************************
&FORCE_EVAL

    METHOD EMBED
    
    !Select DFET or DMFET. Default value: DFET
    &EMBED DFET
       NGROUPS 1
       &MAPPING
          &FORCE_EVAL_EMBED
             &FRAGMENT 1
                1 3  
             &END
             &FRAGMENT 2
                4 5  
             &END
             &FRAGMENT 3
                1 5  
             &END
          &END
          &FORCE_EVAL 1
             &FRAGMENT 1
                1 3
                MAP 1 
              &END
          &END
          &FORCE_EVAL 2
             &FRAGMENT 1
                1 2
                MAP 2 
             &END
          &END
          &FORCE_EVAL 3
             &FRAGMENT 1
                1 5
                MAP 3 
              &END
          &END
          &FORCE_EVAL 4
             &FRAGMENT 1
                1 2
                MAP 2 
             &END
          &END
       &END
    &END EMBED
    
    &SUBSYS
      &CELL
        ABC [angstrom]  5.000   5.000  5.000
      &END CELL
      
      &COORD
          O      1.75  1.5  0.0   
          H      1.0   1.0  0.0   
          H      2.5   1.0  0.0    
          H      1.75  2.75  0.0   
          H      1.75  3.50 0.0    
      &END
      
    &END SUBSYS
    
&END FORCE_EVAL



!*******************************
!FORCE_EVA section 2 
!
!Subsys 1 the H2O molecular
!*******************************
&FORCE_EVAL

    METHOD Quickstep
    
    &SUBSYS
        &CELL
            ABC [angstrom]    5.000   5.000  5.000
        &END CELL
        
        &COORD
            O      1.75  1.5  0.0   
            H      1.0   1.0  0.0   
            H      2.5   1.0  0.0 
        &END COORD
        
    &END SUBSYS

    &DFT
        &QS
        
          METHOD DFTB
          &DFTB
            SELF_CONSISTENT    T
            &PARAMETER
              PARAM_FILE_PATH  DFTB/scc
              PARAM_FILE_NAME  scc_parameter
              UFF_FORCE_FIELD  ../uff_table
            &END PARAMETER
          &END DFTB
          
        &END QS
        
        &POISSON
            &EWALD
               EWALD_TYPE SPME
               GMAX 25
            &END EWALD
            POISSON_SOLVER ANALYTIC
        &END POISSON
        
        &MGRID
          NGRIDS 5
          CUTOFF 600     
          REL_CUTOFF 60   
        &END MGRID
        
        
        &SCF
            MAX_SCF 100           !Maximum number of SCF iteration
            
            &OT
                PRECONDITIONER FULL_SINGLE_INVERSE
                MINIMIZER DIIS
            &END OT
          
        &END SCF
      
    &END DFT
    
    STRESS_TENSOR ANALYTICAL
  
&END FORCE_EVAL




!*******************************
!FORCE_EVA section 3 
!
!Subsys 2 the H2 molecular
!*******************************
&FORCE_EVAL

    METHOD Quickstep
    
    &SUBSYS     
    
      &CELL
          ABC [angstrom]    5.000   5.000  5.000      
      &END CELL
      
        
      &COORD   
          H      1.75  2.75  0.0   
          H      1.75  3.50 0.0 
      &END COORD
    
    &END SUBSYS
    
    &DFT
        &QS
            CLUSTER_EMBED_SUBSYS .TRUE.
            
            METHOD DFTB
            &DFTB
              SELF_CONSISTENT    T
              &PARAMETER
                PARAM_FILE_PATH  DFTB/scc
                PARAM_FILE_NAME  scc_parameter
                UFF_FORCE_FIELD  ../uff_table
              &END PARAMETER
            &END DFTB
            
        &END QS
        
        &POISSON
            &EWALD
                EWALD_TYPE SPME
                GMAX 25
            &END EWALD
            POISSON_SOLVER ANALYTIC
        &END POISSON
        
        &MGRID
          NGRIDS 5
          CUTOFF 600     
          REL_CUTOFF 60   
        &END MGRID
        
        &SCF
            MAX_SCF 100         
            
            &OT
                PRECONDITIONER FULL_SINGLE_INVERSE
                MINIMIZER DIIS
            &END OT
          
        &END SCF
      
    &END DFT
    
    STRESS_TENSOR ANALYTICAL
  
  
&END FORCE_EVAL



!*******************************
!FORCE_EVA section 4
!
!Total system including H2O and H2
!*******************************
&FORCE_EVAL

    METHOD Quickstep
     
    &SUBSYS
        &CELL
           ABC [angstrom]    5.000   5.000  5.000
        &END CELL
        
        
        &COORD
            O      1.75  1.5  0.0   
            H      1.0   1.0  0.0   
            H      2.5   1.0  0.0    
            H      1.75  2.75  0.0   
            H      1.75  3.50 0.0 
        &END COORD
        
    &END SUBSYS
   
    &DFT
        &QS
            REF_EMBED_SUBSYS .TRUE.
            
            &OPT_EMBED
               REG_LAMBDA 0.00001
               N_ITER 3
               DENS_CONV_INT 0.5
               DENS_CONV_MAX 0.025
               OPTIMIZER QUASI_NEWTON
               GRID_OPT .FALSE.
            &END OPT_EMBED
            
            !&OPT_DMFET
            !&END
          
            EPS_DEFAULT 1.0E-10   !Default value: 1.00000000E-010
          
            METHOD DFTB
            &DFTB
              SELF_CONSISTENT    T
              &PARAMETER
                PARAM_FILE_PATH  DFTB/scc
                PARAM_FILE_NAME  scc_parameter
                UFF_FORCE_FIELD  ../uff_table
              &END PARAMETER
            &END DFTB
          
        &END QS
        
        &POISSON
            &EWALD
               EWALD_TYPE SPME
               GMAX 25
            &END EWALD
            POISSON_SOLVER ANALYTIC
        &END POISSON
        
        &MGRID
          NGRIDS 5
          CUTOFF 600     
          REL_CUTOFF 60   
        &END MGRID
        
        &SCF
            MAX_SCF 100           
          
            &OT
                PRECONDITIONER FULL_SINGLE_INVERSE
                MINIMIZER DIIS
            &END OT
            
        &END SCF
    
    &END DFT
  
    STRESS_TENSOR ANALYTICAL
  
&END FORCE_EVAL




!*******************************
!FORCE_EVA section 5 
!
!Higher level calculation on subsys 2, the H2O 
!*******************************

&FORCE_EVAL
    METHOD Quickstep
    
    &DFT
        BASIS_SET_FILE_NAME   BASIS_RI_cc-TZ
        POTENTIAL_FILE_NAME   HF_POTENTIALS
  

        &QS
            HIGH_LEVEL_EMBED_SUBSYS .TRUE.
            
            METHOD GPW
            EPS_DEFAULT 1.0E-15
            EPS_PGF_ORB 1.0E-30
        &END QS
        
        &SCF
          MAX_SCF 100        
        
          &OT
            PRECONDITIONER FULL_SINGLE_INVERSE
            MINIMIZER DIIS
          &END OT
          
        &END SCF
        
        &XC
            &XC_FUNCTIONAL PBE
            &END XC_FUNCTIONAL
        &END XC
        
        &POISSON
            &EWALD
               EWALD_TYPE SPME
               GMAX 25
            &END EWALD
            POISSON_SOLVER ANALYTIC
        &END POISSON
        
        &MGRID
          NGRIDS 5
          CUTOFF 600     
          REL_CUTOFF 60   
        &END MGRID
        
    &END DFT
    
    &SUBSYS
        &CELL
            ABC [angstrom]  5.000   5.000  5.000
        &END CELL
        
        &KIND H
            BASIS_SET  cc-TZ
            BASIS_SET RI_AUX  RI_TZ
            POTENTIAL  GTH-HF-q1
        &END KIND
        &KIND O
            BASIS_SET  cc-TZ
            BASIS_SET RI_AUX  RI_TZ
            POTENTIAL  GTH-HF-q6
        &END KIND
        
        &COORD
            H      1.75  2.75  0.0   
            H      1.75  3.50 0.0    
        &END
    &END SUBSYS
&END FORCE_EVAL


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.cp2k.org/archives/cp2k-user/attachments/20190515/69c7180a/attachment.htm>


More information about the CP2K-user mailing list