Skip to content

Commit 1110306

Browse files
committed
atom type is now also accesed by atom tag and not cluster index fixing domain decomposition bug for multi-species
1 parent ca5bef7 commit 1110306

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/rascal/structure_managers/structure_manager_lammps.hh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ namespace rascal {
152152
int get_atom_type(int atom_tag) const {
153153
// lammps atom types go from 1 to N, so we map it to rascal atom types
154154
// by mapping 0 to N-1 to the corresponding number
155-
return this->atom_types[this->type[this->get_atom_index(atom_tag)]-1];
155+
return this->atom_types[this->type[atom_tag]-1];
156156
}
157157

158158
//! return number of I atoms in the list
@@ -193,7 +193,7 @@ namespace rascal {
193193
}
194194

195195
int get_atom_index(int atom_tag) const {
196-
return this->atom_index_from_atom_tag_list.at(atom_tag);
196+
return this->atom_index_from_atom_tag_list[atom_tag];
197197
}
198198

199199
/**
@@ -270,7 +270,7 @@ namespace rascal {
270270
int ** firstneigh{}; //!< pointer to first neighbour
271271
double ** x{}; //!< atomic positions
272272
double ** f{}; //!< atomic forces
273-
int * type{}; //!< atom types
273+
int * type{}; //!< lammps atom types
274274
double * eatom{}; //!< energy of atoms
275275
double ** vatom{}; //!< virial stress of atoms
276276
int nb_pairs{}; //! number of clusters with cluster_size=2 (pairs)

0 commit comments

Comments
 (0)