diff options
author | Thomas White <taw@physics.org> | 2012-05-31 13:48:42 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2012-05-31 13:48:42 +0200 |
commit | 13770d8553f9696c1c4c0c56703717524c028d86 (patch) | |
tree | 23c9f11f0407207ad24a8f7a4f6c72d52d0e7822 /libcrystfel/src/cell.c | |
parent | 6ff1bbbd0deeac54175fc862a6e1b53374ae6306 (diff) | |
parent | b6e0b7972e3dbdace0034d439b992faf3ac8c454 (diff) |
Merge branch 'master' into tom/speed
Conflicts:
.gitignore
Diffstat (limited to 'libcrystfel/src/cell.c')
-rw-r--r-- | libcrystfel/src/cell.c | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/libcrystfel/src/cell.c b/libcrystfel/src/cell.c index 2e87b770..b6ea010b 100644 --- a/libcrystfel/src/cell.c +++ b/libcrystfel/src/cell.c @@ -424,7 +424,7 @@ int cell_get_parameters(UnitCell *cell, double *a, double *b, double *c, switch ( cell->rep ) { - case CELL_REP_CRYST: + case CELL_REP_CRYST: /* Direct response */ *a = cell->a; *b = cell->b; @@ -434,7 +434,7 @@ int cell_get_parameters(UnitCell *cell, double *a, double *b, double *c, *gamma = cell->gamma; return 0; - case CELL_REP_CART: + case CELL_REP_CART: /* Convert cartesian -> crystallographic */ *a = modulus(cell->ax, cell->ay, cell->az); *b = modulus(cell->bx, cell->by, cell->bz); @@ -448,7 +448,7 @@ int cell_get_parameters(UnitCell *cell, double *a, double *b, double *c, cell->bx, cell->by, cell->bz); return 0; - case CELL_REP_RECIP: + case CELL_REP_RECIP: /* Convert reciprocal -> crystallographic. * Start by converting reciprocal -> cartesian */ cell_invert(cell->axs, cell->ays, cell->azs, @@ -480,21 +480,21 @@ int cell_get_cartesian(UnitCell *cell, switch ( cell->rep ) { - case CELL_REP_CRYST: + case CELL_REP_CRYST: /* Convert crystallographic -> cartesian. */ return cell_crystallographic_to_cartesian(cell, ax, ay, az, bx, by, bz, cx, cy, cz); - case CELL_REP_CART: + case CELL_REP_CART: /* Direct response */ *ax = cell->ax; *ay = cell->ay; *az = cell->az; *bx = cell->bx; *by = cell->by; *bz = cell->bz; *cx = cell->cx; *cy = cell->cy; *cz = cell->cz; return 0; - case CELL_REP_RECIP: + case CELL_REP_RECIP: /* Convert reciprocal -> cartesian */ return cell_invert(cell->axs, cell->ays, cell->azs, cell->bxs, cell->bys, cell->bzs, @@ -518,7 +518,7 @@ int cell_get_reciprocal(UnitCell *cell, switch ( cell->rep ) { - case CELL_REP_CRYST: + case CELL_REP_CRYST: /* Convert crystallographic -> reciprocal */ r = cell_crystallographic_to_cartesian(cell, &ax, &ay, &az, @@ -528,7 +528,7 @@ int cell_get_reciprocal(UnitCell *cell, return cell_invert(ax, ay, az,bx, by, bz, cx, cy, cz, asx, asy, asz, bsx, bsy, bsz, csx, csy, csz); - case CELL_REP_CART: + case CELL_REP_CART: /* Convert cartesian -> reciprocal */ cell_invert(cell->ax, cell->ay, cell->az, cell->bx, cell->by, cell->bz, @@ -536,7 +536,7 @@ int cell_get_reciprocal(UnitCell *cell, asx, asy, asz, bsx, bsy, bsz, csx, csy, csz); return 0; - case CELL_REP_RECIP: + case CELL_REP_RECIP: /* Direct response */ *asx = cell->axs; *asy = cell->ays; *asz = cell->azs; *bsx = cell->bxs; *bsy = cell->bys; *bsz = cell->bzs; @@ -569,12 +569,16 @@ const char *cell_get_spacegroup(UnitCell *cell) static const char *cell_rep(UnitCell *cell) { switch ( cell->rep ) { - case CELL_REP_CRYST: + + case CELL_REP_CRYST: return "crystallographic, direct space"; - case CELL_REP_CART: + + case CELL_REP_CART: return "cartesian, direct space"; - case CELL_REP_RECIP: + + case CELL_REP_RECIP: return "cartesian, reciprocal space"; + } return "unknown"; |