Confusion on the CELL input by running i-Pi with cp2k client

74 views
Skip to first unread message

李金翰

unread,
Nov 21, 2023, 5:31:04 AM11/21/23
to ipi-users
Hello i-Pi Users and developers:
sorry to bother you,  

I am running a QMMM simulation with i-Pi and cp2k client at once I got the familiar cp2k error :

QM/MM QM atoms must be fully contained in the same image of the QM box - No wrapping of coordinates is allowed!

This error usually occurs in bad definition of the cell, where the atom position is beyond the border. The i-Pi cell input is:

# # CELL(abcABC):     24.7603 21.4430 56.7389      90.00000    90.00000    90.00000  Step:           0  Bead:       0 positions{angstrom}  cell{angstrom}

But before using i-Pi, I tested the same QMMM simulation with the same cell parameter using pure cp2k and it worked well.
The QM input part about the cell is:
  &QMMM
    CENTER NEVER
    &CELL
      ABC [angstrom]   24.7603 21.4430 56.7389
      ALPHA_BETA_GAMMA  90.000000 90.000000 90.000000
      PERIODIC XY
    &END CELL

  &QMMM
and the SUBSYS part about the cell is the same:
  &SUBSYS
     &CELL
      ABC [angstrom]   24.7603 21.4430 56.7389
      ALPHA_BETA_GAMMA  90.000000 90.000000 90.000000
      PERIODIC XY
    &END CELL

  &END SUBSYS

To overcome this, I increased the i-Pi cell input parameter to
 # # CELL(abcABC):   90.7603    90.4430    140.7389    90.00000    90.00000    90.00000  Step:           0  Bead:       0 positions{angstrom}  cell{angstrom}
, thus it worked.

However, It still doesn't make sence, why the same cell parameter of cp2k and i-Pi can't work, I am curious about if the i-Pi send a different cell parameter to cp2K?Or maybe I made a cheap mistake?

Thanks in advance.
Best Regards

Jinhan Li

Michele Ceriotti

unread,
Nov 21, 2023, 6:49:15 PM11/21/23
to ipi-users
i-PI by default "folds" the coordinates of the atom in the unit cell, which does not make sense when the supercell does not actually represent a periodic structure. You can turn this off by using <ffsocket pbc='false'> in the definition of the forcefield socket.
Let us know if this fixes your problem.
Michele

李金翰

unread,
Nov 21, 2023, 10:31:33 PM11/21/23
to ipi-users
Hi Prof. Michele,

Thank you for your advice, the error is fixed when using <ffsocket pbc='false'>.

I just made a mistake to send private conversations and I can‘t find it now.

Thank you very much.

Sincerely

JInhan Li

Reply all
Reply to author
Forward
0 new messages