Combining Simulations

Hi All,
I am interested in equilibrating water vapor and liquid to a constant T separately, saving the positions and trajectories, and then combining into the same domain. As long as I make sure to define the coordinates accordingly in the separate simulations (so the domains are adjacent to one another), can this be achieved by reading in two different restart files into the combined simulation? Or is it not possible to read in 2 separate restart files? If this wouldn’t work, please let me know of the command I should use. The equilbration of the different phases together is taking too long and I believe this approach will make it faster.
Regards,
Peter

Hi All,
I am interested in equilibrating water vapor and liquid to a constant T separately, saving the positions and trajectories, and then combining into the same domain. As long as I make sure to define the coordinates accordingly in the separate simulations (so the domains are adjacent to one another), can this be achieved by reading in two different restart files into the combined simulation? Or is it not possible to read in 2 separate restart files? If this wouldn’t work, please let me know of the command I should use. The equilbration of the different phases together is taking too long and I believe this approach will make it faster.

you cannot read in two restart files, but you can read in two data files.
equilibration of water vapor will not require a long time. so the time spend will be primarily on equilibrating the liquid phase.
because of this discrepancy, it is not worth the effort to do this as a combined simulation. you are just making your life miserable for minimal gain.

axel.

HI Axel,
Thank you for the quick response! So you think doing the equilibration separately and then combining the two is the best approach? I need to combine them after equilibration to constant T in order to run NEMD simulations with coexistent phases to study interfacial dynamics and structure when a temperature gradient is imposed on the domain.
Regards,
Peter

HI Axel,
Thank you for the quick response! So you think doing the equilibration separately and then combining the two is the best approach?

it would be simpler. you can still paralellize the process by launching the two equilibration calculations concurrently. you’ll also save yourself some time by building both systems with p p f boundaries and walls. that will simplify the merging process and shorten the time required for equilibrating the the combined system.

I need to combine them after equilibration to constant T in order to run NEMD simulations with coexistent phases to study interfacial dynamics and structure when a temperature gradient is imposed on the domain.

as a general rule, it is almost always better to take the simpler solution over a more complex solution. with a complex solution, you just end up spending (much) more time debugging it.

axel.

Hi Axel,
Thanks again! I just want to make sure I am interpreting your advice correctly. I am interpreting your advice in two different ways. They are as follows:

Interpretation 1:

  1. In a single lammps file, create two adjacent boxes with p p f boundary conditions and equilibrate with separate NVT ensembles.
  2. Once the phases have both equilbrated, change the box size to encompass the entire domain and change the boundary conditions to p p p for the new box.

Interpretation 2:

  1. In two separate lammps files create boxes with p p f boundaries and equilibrate to constant T and save the trajectories and positions.
  2. Create a new box and use the read_data command to input the molecules into the combined domain and then equilibrate again.

I have some additional questions as well,

  1. Why does having p p f boundaries simplify the merging process? I am going to set the desired densities of the phases with the create atom command and would not like my molecules to be deleted when they move through the “f” face of the domain. How would using p p p boundary conditions for the separate equilbration processes make the merging process more difficult?

  2. Why is the combined equilbration considered a more complex system?

Thanks in advance for your assistance.

Regards,
Peter

sorry, but this turns into a discussion between student and adviser and i don’t have time to be your adviser and explain everything in great detail and teach you the reasons why. this is the job of your real adviser. i can give you some initial pointers, but that is it.

also, you haven’t read my suggestions carefully enough and are missing important points.

axel.

HI Axel,
My advisor does not have knowledge of the intricacies of the LAMMPS software package. That is why I was hoping to gain some of this in depth knowledge from you because I do not have another source. But I understand that you are busy and I appreciate the help you have provided thus far. If you find the time to answer my last email and spread the knowledge base for this platform that would be greatly appreciated. But again, no worries if that is not possible.
Regards,
Peter

your questions are not really about LAMMPS but about the concepts of setting up a simulation like you want to do. those are independent from how you realize those with LAMMPS. if your adviser cannot help you with that, you either need a new adviser or a new project. people often come with the argument that their adviser doesn’t know enough, but to remedy that is not the job of this mailing list. i often am telling people, this is not a classroom.

as i mentioned before, part of the problem is that you are not paying enough attention to detail and are not really trying to understand the concepts yourself but just keep asking questions that you should be able to figure out by yourself or with the help of your adviser.

axel.

I’ll just add that Axel has given you the ideas to make progress.
Intepretation 2 is the simple way to proceed. Run 2 separate simualtions,
write out a data file for each (not a dump file), then write a 3rd script with
two read_data commands, and run your full system.

When you get to that point you can see if you are successful running
a two-phase simulation, or if you have further Qs.

Steve

Hi All,
Thank you for the advice on this problem. It is much appreciated.
Regards,
Peter