[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MEMD (SCAFACOS) interfacing issue

From: Jean-Noël Grad
Subject: Re: MEMD (SCAFACOS) interfacing issue
Date: Sun, 18 Sep 2022 20:06:15 +0200
User-agent: Roundcube Webmail/1.4.13

Hi Kheerti and Florian,

Just a quick note to let you know that an interface to MEMD is now available in my fork of ScaFaCoS. You can find more details here:

I know this new development arrives quite late in this thread. If anyone is still working on this and is willing to invest developer time, feel free to open a MEMD tracking ticket on the ScaFaCoS project, so that other users can join and help out. While I won't be able to donate more developer time to this feature, there was another user interested in the method on GitHub. It's unclear at the moment, for which range of input parameters the MEMD method works, and it is prone to memory errors and integer overflow errors.

Best regards,
Jean-Noël Grad

On 2021-09-25 22:23, Florian Fahrenberger wrote:
Hi Kheerti,

I was the PhD student at the time who implemented the MEMD method in the
ScaFaCoS library. However, I am not in scientific research anymore and
don't think I will be easily able to debug the code, at least not on an
acceptable timeline.

May I ask why you picked the MEMD algorithm out of all the available?
Because it is a very special algorithm that does provide some benefits
in very special and particular cases, mostly a smoothly varying
inhomogenous dielectric background constant. But this feature is not
available in the ScaFaCoS library, since you don't have an interface to
set the local dielectric background anyways.

So honestly, even though I implemented the code and got to like the
algorithm with time, I would probably recommend you to pick a different
algorithm for your Coulomb solver. Most other methods are much more
established, at least as fast, and are more regularly updated. Last I
looked, the P3M method is the most commonly used for coarse grained soft
matter physics applications, and it is the one I would probably use
myself if I plugged the library into any of my codes.

If you desperately need the MEMD method to work, I can take another look
at it, but it has been years since I even compiled this, and I cannot
guarantee that this would be fast.

I hope this answer helps you to some degree and wish you the best of
luck in your research,


Am 25.09.2021 um 16:13 schrieb Keerthi Radhakrishnan 150503 via ESPResSo
developers' discussions:
Dear all,

I am a PhD student currently pursuing research in soft matter physics.
My work mostly deals with charged polymeric systems. Presently, my
project at hand demands the incorporation of dielectric variation 
within the solvent in the  presence of explicit charges. For that I
resort to the MEMD solver included in SCAFACOS library for the
electrostatics. This is the code snippet from my pypresso script where
it incubates MEMD following  the instructions given in the espresso manual.

from espressomd.electrostatics import Scafacos
from espressomd.electrostatics import Scafacos
scafacos = Scafacos(prefactor=1, method_name="memd",
method_params={"timestep": 0.005, "mesh": 1, "temperature":1,
Following this I get an  error regarding the unrecognition of the passed
argument, which I have carefully taken the argument names mentioned in
SCAFACOS manual itself for MEMD Solver-specific parameters. If this is
not the case of how arguments are named, then where in espresso
documentations is anything regarding it given.

The ERROR is follows:
New handle created!
terminate called after throwing an instance of 'std::runtime_error'
  what():  interface (parser): error in parameter string at 'timestep'!
[Langevin:04113] *** Process received signal ***
[Langevin:04113] Signal: Aborted (6)
[Langevin:04113] Signal code:  (-6)
[Langevin:04113] [ 0]
[Langevin:04113] [ 1]
[Langevin:04113] [ 2]
[Langevin:04113] [ 3]
[Langevin:04113] [ 4]
[Langevin:04113] [ 5]
[Langevin:04113] [ 6]
[Langevin:04113] [ 7]
[Langevin:04113] [ 8]
[Langevin:04113] [ 9]
[Langevin:04113] [10]
[Langevin:04113] [11]
[Langevin:04113] [12]
[Langevin:04113] [13]
[Langevin:04113] [14]
[Langevin:04113] [15]
[Langevin:04113] [16]
[Langevin:04113] [17]
[Langevin:04113] [18]
[Langevin:04113] [19]
[Langevin:04113] [20]
[Langevin:04113] [21]
[Langevin:04113] [22]
[Langevin:04113] [23] /usr/bin/python3[0x50a533]
[Langevin:04113] [24]
[Langevin:04113] [25] /usr/bin/python3[0x507cd4]
[Langevin:04113] [26] /usr/bin/python3(PyEval_EvalCode+0x23)[0x50ae13]
[Langevin:04113] [27] /usr/bin/python3[0x635262]
[Langevin:04113] [28] /usr/bin/python3(PyRun_FileExFlags+0x97)[0x635317]
[Langevin:04113] [29]
[Langevin:04113] *** End of error message ***
Aborted (core dumped)

Following, this I also figured that the interface file in scafacos: 
  scafacos-fcs-0.1/src/FCSInterface.c  - line 1633 the part where
arguments for memd is defined is commented. Don't know if this has
anything to do with the existing issue. 
An insight into the root of this problem and a practical resolve to it
would be highly appreciated.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]