diff options
author | Thomas White <taw@physics.org> | 2014-03-24 13:15:37 +0100 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2014-03-24 13:20:29 +0100 |
commit | 5d9cd6f40e08f498cc6ff852a6aba9d9b569fd20 (patch) | |
tree | 1ae45c136073907ee1a5d8a582027dba068117b8 /src | |
parent | f50355434a331e1480f30086789fa61a2c1af991 (diff) |
get_ambiguities() should not return the identity operation
Diffstat (limited to 'src')
-rw-r--r-- | src/ambigator.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/ambigator.c b/src/ambigator.c index 7e1726fd..70dcb631 100644 --- a/src/ambigator.c +++ b/src/ambigator.c @@ -130,7 +130,7 @@ static struct flist *asymm_and_merge(RefList *in, const SymOpList *sym, signed int hr, kr, lr; signed int hra, kra, lra; - get_equiv(amb, NULL, 1, ha, ka, la, &hr, &kr, &lr); + get_equiv(amb, NULL, 0, ha, ka, la, &hr, &kr, &lr); get_asymm(sym, hr, kr, lr, &hra, &kra, &lra); /* Skip twin-proof reflections */ @@ -201,7 +201,7 @@ static struct flist *asymm_and_merge(RefList *in, const SymOpList *sym, Reflection *cr; get_indices(refl, &h, &k, &l); - get_equiv(amb, NULL, 1, h, k, l, &hr, &kr, &lr); + get_equiv(amb, NULL, 0, h, k, l, &hr, &kr, &lr); get_asymm(sym, hr, kr, lr, &hra, &kra, &lra); cr = add_refl(reidx, hra, kra, lra); @@ -641,7 +641,9 @@ static void reindex_reflections(FILE *fh, FILE *ofh, int assignment, /* See scanf() manual page about %n to see why <3 is used */ if ( (r < 3) && !first ) return; - get_equiv(amb, NULL, assignment, h, k, l, &h, &k, &l); + if ( assignment ) { + get_equiv(amb, NULL, 0, h, k, l, &h, &k, &l); + } fprintf(ofh, "%4i %4i %4i%s", h, k, l, line+n); @@ -874,7 +876,7 @@ int main(int argc, char *argv[]) } STATUS("Ambiguity operations:\n"); describe_symmetry(amb); - if ( num_equivs(amb, NULL) != 2 ) { + if ( num_equivs(amb, NULL) != 1 ) { ERROR("There must be only one ambiguity operator.\n"); ERROR("Try again with a different value for -w.\n"); return 1; |