ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/mdtools/md_code/Thermo.cpp
(Generate patch)

Comparing trunk/mdtools/md_code/Thermo.cpp (file contents):
Revision 253 by chuckv, Thu Jan 30 15:20:21 2003 UTC vs.
Revision 254 by chuckv, Thu Jan 30 20:03:37 2003 UTC

# Line 3 | Line 3 | using namespace std;
3   using namespace std;
4  
5   #ifdef IS_MPI
6 + #include <mpi.h>
7   #include <mpi++.h>
8   #endif //is_mpi
9  
# Line 68 | Line 69 | double Thermo::getKinetic(){
69      }
70    }
71   #ifdef IS_MPI
72 <  MPI_COMM_WORLD.Allreduce(&kinetic,&kinetic_global,1,MPI_DOUBLE,MPI_SUM);
72 >  MPI::COMM_WORLD.Allreduce(&kinetic,&kinetic_global,1,MPI_DOUBLE,MPI_SUM);
73    kinetic = kinetic_global;
74   #endif //is_mpi
75  
# Line 99 | Line 100 | double Thermo::getPotential(){
100  
101    // Get total potential for entire system from MPI.
102   #ifdef IS_MPI
103 <  MPI_COMM_WORLD.Allreduce(&potential,&potential_global,1,MPI_DOUBLE,MPI_SUM);
103 >  MPI::COMM_WORLD.Allreduce(&potential,&potential_global,1,MPI_DOUBLE,MPI_SUM);
104    potential = potential_global;
105   #endif // is_mpi
106  
# Line 190 | Line 191 | void Thermo::velocitize() {
191   #ifdef IS_MPI
192   #error "SPRNG random number generator must be used for MPI"
193   #else
194 < #warning "Using drand48 for random number generation"
194 >    // warning "Using drand48 for random number generation"
195   #endif  // is_mpi
196  
197      x = drand48();
# Line 266 | Line 267 | void Thermo::velocitize() {
267   #ifdef IS_MPI
268   #error "SPRNG random number generator must be used for MPI"
269   #else  // is_mpi
270 < #warning "Using drand48 for random number generation"
270 >        //warning "Using drand48 for random number generation"
271   #endif   // is_MPI
272          
273          vbar = sqrt( 2.0 * kebar * dAtom->getIxx() );

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines