[lammps-users] Making LAMMPS with FFTW & MPICH libraries

Dear all,

Thank you very much again for answering my questions, Steve and Axel.
My simulations are now smoothly running.
I always appreciate you so much.
Now I am thinking to calculate long coulombic force with pppm.
Also, I am planning to run the simulation with more molecules, so I am
wondering that it might be faster with parallel computation.

But actually I have a lot of error when I make LAMMPS with mpich2 and
FFTW...
I got tons of "undifined reference" and error as following.

Would you tell me how to fix it, or which file I should find?
Thank you very much.

Best,
Nanako Takahashi

Dear all,

dear nanako,

[...]

Also, I am planning to run the simulation with more molecules, so I am
wondering that it might be faster with parallel computation.

what kind of network do you have that connects the nodes?

But actually I have a lot of error when I make LAMMPS with mpich2 and
FFTW...
I got tons of "undifined reference" and error as following.

Would you tell me how to fix it, or which file I should find?

your MPICH has obviously been compiled with the PGI compilers
and it looks as if you are using g++.

it is quite possible that aio_write64 is a function from the
runtime library of the PGI compiler (glibc only has aio_write).

you are a bit between a rock and a hard place. to be consistent
with your MPI you would have to compile with the PGI compilers
but they give you bad performance in c++ code, or you would
have to compile your own MPI library to get one that is
consistent with g++.

if you go for the second option, i strongly recommend to go
with OpenMPI, as it - when compiled and configured properly -
can be set up to support multiple compilers _and_ interconnects.
i have been able to use the same binary on 3 different machines
with 3 different networks (gigabit, myrinet, infiniband).

cheers,
   axel.

Hi Nanako,

I recommend you use Openmpi and not mpich. Axel recommended this a while
back and I have built lmp_openmpi and did some test runs on my systems. I
found it to be 50 % faster than MPICH for my case.

I don't know why this is so perhaps the developers can tell my why.

Jan-Michael

Hi Nanako,

I recommend you use Openmpi and not mpich. Axel recommended this a while
back and I have built lmp_openmpi and did some test runs on my systems. I
found it to be 50 % faster than MPICH for my case.

I don't know why this is so perhaps the developers can tell my why.

well, you'll have to ask the developers of both OpenMPI and MPICH
rather than the LAMMPS developers. OpenMPI has some nifty and smart
algorithms that can do collective operations (broadcast, alltoall,
reductions) in a quite aefficient way. that helps the most if you
have SMP/multi-core nodes. another optimization is the use of compiler
flags for the gcc/g++ compiler. when you assume ansi-compliance
the compiler has room for some additional optimizations, so the
.openmpi makefile signals this for all files that are in fact
ansi-compliant and only turns it off for files where pointer
aliasing is actually used.

cheers,
   axel.

Dear Axel and all LAMMPS users,

Thank you very much for telling me about MPICH and OpenMPI.
It helps me a lot!
Now I am trying to make LAMMPS with OpenMPI modifying "Makefile.g++" instead of MPICH.
I added path to opnempi, but again I got tons of "No such file or directory" amd following error.
I am not very familiar with such kind of things, so I don't know how to fix it...
I would be very glad if you tell me anything you know about it.
Thank you very much.

Best,
Nanako Takahashi

Dear Axel and all LAMMPS users,

Thank you very much for telling me about MPICH and OpenMPI.
It helps me a lot!
Now I am trying to make LAMMPS with OpenMPI modifying "Makefile.g++" instead
of MPICH.
I added path to opnempi, but again I got tons of "No such file or directory"
amd following error.

I am not very familiar with such kind of things, so I don't know how to fix
it...
I would be very glad if you tell me anything you know about it.
Thank you very much.

Best,
Nanako Takahashi

--------------------------------------------
Makefile:84: verlet.d: No such file or directory
Makefile:84: write_restart.d: No such file or directory

those are harmless. the makefile will try to produce them.

mpic++ -O2 -funroll-loops -DFFT_FFTW -DLAMMPS_GZIP -fstrict-aliasing -Wall
-W -Wno-uninitialized -M write_restart.cpp > write_restart.d
/bin/sh: mpic++: command not found

this is problematic. the makefile cannot find the g++ wrapper
for openmpi. so whatever you did to install and enable openmpi
you didn't do it correctly.

please test you openmpi installation first (perhaps go over one
of the little MPI tutorials) to see that your MPI installation
works and _then_ you'll know how to fix the compilation/installation
of LAMMPS.

cheers,

  axel.