New feature request for ELECTRODE package: flexible electrodes

Dear LAMMPS’s developer,
I have recently learned about the development of some CPM methods (Fluctuating charges) and I think there is a great hope that CPM with movable electrodes can be realized, because movable electrodes are closer to the real simulation and make the ELECTRODE package more widely used.
Like the methods in the following 2 papers.

  1. https://doi.org/10.1002/jcc.25865.
  2. Cookie Absent.

In particular, in the first method, the control equations are independent of the matrix A, and the electrons are considered as virtual points that can be moved. Since this is the case, I feel that this method is a feasible solution to achieve movable electrodes, after all, the CPM equations are position independent. More over, polarization can also be considered.
Here, I would like to ask if this kind of function can be realized, developed and released?

Thanks a lot!

Two comments on that

  • the best place to submit feature requests to LAMMPS is our Github Issues page. Posts in a forum get out of sight easily while the GitHub issues will persist until they are closed. Of course, that does not have much of an impact on how soon or if at all a requested feature is implemented. That requires somebody interested, willing, and able to do the work.
  • the best way to have a feature implemented in LAMMPS quickly and the way you would benefit the most is to implement it yourself. You need to understand that a lot of LAMMPS are contributed features developed by people like you that had a specific need and went about to implement it and then also decided to make this feature available to other researchers. Please also note that arguments like “make the ELECTRODE package more widely used” rarely apply. I personally prefer it if people just state that it would help them personally instead of claiming impact to the community for which they cannot provide any proof.

It could work, but not along the lines you’ve proposed. For background, the Salanne group has had the conjugate gradient method in their code for years, and (to my knowledge) they have never published anything with thermal electrodes, let alone anything which shows they make a big difference. (They are at the forefront of the field and are far better funded and recognised than I am – the only reason I’m still in the game is because their choice to develop a separate package has locked them out of all the big user groups.)

I am aware of the two papers you posted and neither are particularly useful. Re: the first paper: plenty of groups are looking into extended Lagrangians for all sorts of similar fast-slow dynamics (especially polarisation). They all face the basic problem that too-small masses give unstable dynamics, and too-large masses give spurious couplings, so that running an EL technique can require a kind of troubleshooting intuition which can be difficult to communicate. Re: the second paper: the Salanne group is pioneering the field but this particular paper isn’t really worthwhile. In the CPM context their result is easily proved in one line, which their idiosyncratic notation here unnecessarily obscures. Besides, what you’ve said here:

is self-contradictory – CPM works well because the fixed electrodes make the math much easier. In all other respects (at least right now) it’s just a glorified QEq implementation.

Lastly, I want to put a sharper point on what Axel said:

I agree with him, and I don’t think it’s just his personal preference. What you are asking for, effectively, is a scientific collaboration, but you have suggested this collaboration without telling me what electrodes and electrolytes you study and why the current ELECTRODE (or USER-CONP2) packages aren’t enough. I couldn’t know if I would get a paper or grant funding out of helping with your request. I don’t even know where you work! If someone approached you or a colleague with a request to collaborate, without telling you what papers you’d coauthor or when you could go visit them and give a talk at their department, you wouldn’t feel very inclined to collaborate with them either.

So, if you have a casual interest in these techniques and are asking casual questions and you are fine with casual answers, what you are currently doing is okay. As a scientist I also bug my colleagues with questions about techniques I will never use and I don’t expect them to give me very serious answers. It’s nice that you’re curious about our work! But if you are hoping to get some serious and innovative science done, you do need to put in the work.

1 Like

Thank you both developers for your very instructive replies.
First of all, I am ashamed of my remarks above.
Wanted to request this feature for movable electrodes because the current CPM in CMD is not yet available for describing chemical reactions or thermodynamic transfer processes of complete SCs (like NEMD, etc.), and I thought it might be very useful to describe SCs or cells more realistically. I don’t mean any offense, and thanks again for your guidance!

Here is another piece of (unsolicted) advice: avoid acronyms and ‘jargon’, especially for items that are not common outside your area of research and especially when discussing with software developers or maintainers (as they may have limited exposure to your research interests).

Yes! I’ll pay attention next time!

Hi!

You should not feel ashamed to speak your mind, but you should also be prepared for honest and straightforward feedback. :slight_smile:

I still don’t know exactly what you are trying to model, or why exactly an improved ELECTRODE package is what you need. Without that information, I don’t know how useful your proposed modifications would be, or how long they would take, and thus whether it would be worth us working on the proposal (and you waiting for it!).

When you linked specific papers in your first post, I was able to give you technical information about why those approaches were not likely to work. I want to keep being useful to you, and for that to happen you should give me specific information or specific suggestions.

In case @musong_mm is interested, we have features for using conjugate gradient minimisation in movable electrodes now in the ELECTRODE package (currently merged in on the develop branch and presumably will be available in the next patch / release)

1 Like

Dear Professor,

Such exciting news just waking up in the morning! I would like to use the new movable electrodes now in the ELECTRODE package if I could.
Thank you again for your selfless contribution.

Best regards!

Dear Professor,

I tested the latest version 22 December 2022 of lammps/examples/PACKAGES/electrode/piston and I am glad that there is already a movable electrode scheme in this version. The manual on the official website also enables beginners to better understand how to maximize the advantages of the electrode package.Thank you for your great contributions! Hats off to you!

And I remember that there is a compute potential/atom in conp2 to compute the potential of each atom. I wonder if it can still be used in the electrode package? I think it would be helpful for moving electrodes to compute electrode potential.

Thanks a lot!