Page 1 of 1

old MBD and libMBD give different results

Posted: Sun May 24, 2026 1:25 pm
by guyohad

Hi,

I have a question regarding test calculations I did with the old MBD implementation and the libMBD.

I succesfully compiled libMBD in version 6.6.0, and compared single point calculations, one using pbe and IVDW = 202, and one with pbe and IVDW = 14 (libmbd). To my understanding, both should use mbd-rsscs with the same default parameters and produce the same total energies. In practice, they give different total enegies:

system 1 (ON): -712.3539 eV (IVDW=202) and -712.4998 (IVDW=14)
system 2 (OP): -703.5948 eV (IVDW=202) and -703.6091 (IVDW=14)
system 3 (R): -356.2884 eV (IVDW=202) and -356.3015 (IVDW=14)

I have attached the input files for the 3 systems.

Can you tell me if I am missing something in the comparison? Should these energies be the same, or did something go wrong during my libMBD compilation?

Thanks a lot!


Re: old MBD and libMBD give different results

Posted: Mon Jun 01, 2026 7:39 am
by marie-therese.huebsch

Hi, sorry for the delay. I will look into it. Could you pls share the OUTCAR files and the stdout if you have them?
Best regards,
Marie-Therese


Re: old MBD and libMBD give different results

Posted: Mon Jun 01, 2026 9:30 am
by guyohad

Thanks a lot!

Sure, I've attached all the OUTCAR and stdout files.


Re: old MBD and libMBD give different results

Posted: Thu Jun 18, 2026 3:39 pm
by fabien_tran1

Hi,

I had a look at these differences between the two implementations of MBD@rsSCS, and a sizeable part of these differences originate from two different reasons:

1) There is a bug in the VASP interface to libMBD. The dimensions of the k-mesh passed by default (i.e., without using the LIBMBD_K_GRID tag) to libMBD are not correct. The fix will be in the next VASP release, however this is possible to avoid this bug by using the LIBMBD_K_GRID tag. For instance, for the system "on" you need to specify in INCAR what is in KPOINTS by adding the line "LIBMBD_K_GRID = 4 1 1".

2) The k-mesh constructed in libMBD is shifted by default, while the VASP implementation of MBD@rsSCS uses the k-mesh as specified by KPOINTS. In the case of the system "on", the k-mesh in KPOINTS is GAMMA-centered, which means that the two implementations of MBD@rsSCS use k-meshes with different shifts. The solution is either to specify a shifted k-mesh in KPOINTS (replace "Gamma" by "Monkhorst Pack") or to set the shift to zero for libMBD (LIBMBD_K_GRID_SHIFT = 0).

Taking into account 1) and 2) leads to better agreement between the two implementations (can you please repeat the calculations and post them?), but some discrepancies remain. I will let you know if I have more information.