git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@3598 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -155,7 +155,7 @@ int DumpXYZ::pack()
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
void DumpXYZ::write_data(int n, double *buf)
|
||||
void DumpXYZ::write_data(int n, double *mybuf)
|
||||
{
|
||||
// for group = all, spread buf atom coords into global arrays
|
||||
// if last chunk of atoms in this snapshot, write global arrays to file
|
||||
@ -165,12 +165,12 @@ void DumpXYZ::write_data(int n, double *buf)
|
||||
|
||||
int m = 0;
|
||||
for (int i = 0; i < n; i++) {
|
||||
tag = static_cast<int> (buf[m]) - 1;
|
||||
types[tag] = static_cast<int> (buf[m+1]);
|
||||
tag = static_cast<int> (mybuf[m]) - 1;
|
||||
types[tag] = static_cast<int> (mybuf[m+1]);
|
||||
j = 3*tag;
|
||||
coords[j++] = buf[m+2];
|
||||
coords[j++] = buf[m+3];
|
||||
coords[j] = buf[m+4];
|
||||
coords[j++] = mybuf[m+2];
|
||||
coords[j++] = mybuf[m+3];
|
||||
coords[j] = mybuf[m+4];
|
||||
m += size_one;
|
||||
}
|
||||
|
||||
@ -186,7 +186,7 @@ void DumpXYZ::write_data(int n, double *buf)
|
||||
int m = 0;
|
||||
for (int i = 0; i < n; i++) {
|
||||
fprintf(fp,format,
|
||||
static_cast<int> (buf[m+1]),buf[m+2],buf[m+3],buf[m+4]);
|
||||
static_cast<int> (mybuf[m+1]),mybuf[m+2],mybuf[m+3],mybuf[m+4]);
|
||||
m += size_one;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user