Function DP_SelectByType

Function Documentation

void DP_SelectByType(const int natoms, const int *atype, const int nghost, const int nsel_type, const int *sel_type, int *fwd_map, int *nreal, int *bkw_map, int *nghost_real)

Get forward and backward map of selected atoms by atom types.

Parameters
  • natoms – [in] The number of atoms.

  • atype – [in] The atom types of all atoms.

  • nghost – [in] The number of ghost atoms.

  • nsel_type – [in] The number of selected atom types.

  • sel_type – [in] The selected atom types.

  • fwd_map – [out] The forward map with size natoms.

  • nreal – [out] The number of selected real atoms.

  • bkw_map – [out] The backward map with size nreal.

  • nghost_real – [out] The number of selected ghost atoms.