From 332755d03e9aafbe68af098351d27dfae1d55fab Mon Sep 17 00:00:00 2001 From: Thomas White Date: Fri, 3 Oct 2008 15:58:00 +0100 Subject: Show final deviations after refinement Fix some debugging comments --- src/refine.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/refine.c b/src/refine.c index 08408ac..e1f4939 100644 --- a/src/refine.c +++ b/src/refine.c @@ -413,13 +413,20 @@ double refine_do_cell(ControlContext *ctx) { if ( !(it % 1000) ) { printf("After %5i iterations: mean dev = %13.8f nm^1\n", it, mean_dev/DISPFACTOR); } - #endif /* REFINE_DEBUG_MORE */ + #endif /* REFINE_DEBUG */ } free(devcell_try); free(devcell_try_best); #if REFINE_DEBUG printf("Final mean dev (%5i iterations) = %13.8f nm^1\n", it, mean_dev/DISPFACTOR); - #endif /* REFINE_DEBUG_MORE */ + printf("Final cell deviation:\n"); + printf("a = %+10.8f %+10.8f %+10.8f nm^-1\n", devcell->a.x/DISPFACTOR, devcell->a.y/DISPFACTOR, + devcell->a.z/DISPFACTOR); + printf("b = %+10.8f %+10.8f %+10.8f nm^-1\n", devcell->b.x/DISPFACTOR, devcell->b.y/DISPFACTOR, + devcell->b.z/DISPFACTOR); + printf("c = %+10.8f %+10.8f %+10.8f nm^-1\n", devcell->c.x/DISPFACTOR, devcell->c.y/DISPFACTOR, + devcell->c.z/DISPFACTOR); + #endif /* REFINE_DEBUG */ /* Apply the final values to the cell */ ctx->cell->a.x += devcell->a.x; ctx->cell->b.x += devcell->b.x; ctx->cell->c.x += devcell->c.x; -- cgit v1.2.3