[CP2K:2459] cannot restart with constraint/restraint

Teodoro Laino teodor... at gmail.com
Thu Dec 10 07:03:05 UTC 2009

Basically this issue has many different sources. The two most important:

-) The first problem is that you should seriously think if you want 
help: in this case next time I would recommend to send the entire input 
file and not just pieces of it.

-) The second problem is that CP2K has not a manual: it is difficult to 
learn but we do provide (for extremely motivated people) quite a big 
number of working input files, which cover most of its functionalities.
It would be ideal that before mixing keywords and subsections you would 
train yourself trying first to understand (on your own) what is the 
logic of the code.

Having said that, based on the minimal amount of information you sent 
us, I can try to guess:

1) probably  you ask cp2k to build the topology. At the beginning the 
geometry is reasonable and cp2k is able to build a correct connectivity. 
When you restart (connectivity is not restartable!) cp2k builds a new 
connectivity and very probably your input
file is so well tuned that the system just explodes -> new connectivity 
is a mess -> the intramolecular constraint cannot be applied (your 
restratins is intramolecular!!)

2) with the restraint setup below (the only piece you have sent) you are 
specifying the same restraint for all molecular types 1. if you want to 
apply just 1 restraint (between two atoms not belonging to the same 
molecule) there is a keyword to be specified:

3) if you really want to have the same restraint appled to all molecular 
types 1 then I would recommend you to have a topology file. This will 
guarantee that even if you are trying to simulate the "big bang" the 
specification of molecular connectivity will not depend on how far are 
the atoms.

4) if you don't need the connectivity (because your goal is to model 
some explosion [for example..]) then just disable the generation of the 

Since the possible sources are many (because mainly we cannot understand 
what you really want to do!) I would suggest you : take your time, think 
what you want to do with cp2k and your present run.


Liu wrote:
> Hi all,
> I used the following COLVAR and CONSTRAINT to do a MD run and it goes
> well.
>      &COLVAR
>       &DISTANCE
>        ATOMS 13 1
>      &END COLVAR
>        TARGET   1.89
>        MOLECULE 1
>        COLVAR 1
>        &RESTRAINT
>         k 0.1
> When I added this:
>  RESTART_FILE_NAME A-1.restart
> the error happened:
>     |  Error in constraints setup!
>     |  A constraint has been defined for a molecule type
>     |   but the atoms specified in the constraint and the a    |
> Error in constraints setup!
>     |  A constraint has been defined for a molecule type
>     |   but the atoms specified in the constraint and the atoms
> defined for
>     |   the molecule DO NOT match!
> Any suggestion is appreciated !
> cheers,
> Liu
> --
> You received this message because you are subscribed to the Google Groups "cp2k" group.
> To post to this group, send email to cp... at googlegroups.com.
> To unsubscribe from this group, send email to cp2k+uns... at googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/cp2k?hl=en.

More information about the CP2K-user mailing list