From a4305d698c45fb68cd8e9ce2727b4cfdbda90f9e Mon Sep 17 00:00:00 2001 From: Thomas White Date: Sat, 20 Nov 2010 22:42:57 +0100 Subject: Move post refinement stuff to a new file --- src/post-refinement.h | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 src/post-refinement.h (limited to 'src/post-refinement.h') diff --git a/src/post-refinement.h b/src/post-refinement.h new file mode 100644 index 00000000..1ef7a1fd --- /dev/null +++ b/src/post-refinement.h @@ -0,0 +1,50 @@ +/* + * post-refinement.h + * + * Post refinement + * + * (c) 2006-2010 Thomas White + * + * Part of CrystFEL - crystallography with a FEL + * + */ + +#ifndef POST_REFINEMENT_H +#define POST_REFINEMENT_H + + +#ifdef HAVE_CONFIG_H +#include +#endif + + +#include + +#include "image.h" + + +/* Refineable parameters */ +enum { + REF_SCALE, + REF_DIV, + NUM_PARAMS +}; + + +/* Return the gradient of parameter 'k' given the current status of 'image'. */ +double gradient(struct image *image, int k, struct cpeak spot, + double I_partial); + +/* Apply the given shift to the 'k'th parameter of 'image'. */ +void apply_shift(struct image *image, int k, double shift); + + +double mean_partial_dev(struct image *image, struct cpeak *spots, int n, + const char *sym, double *i_full, FILE *graph); + + +double pr_iterate(struct image *image, double *i_full, const char *sym, + struct cpeak **pspots, int *n); + + +#endif /* POST_REFINEMENT_H */ -- cgit v1.2.3