diff options
author | Thomas White <taw@physics.org> | 2013-03-21 16:24:04 +0100 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2013-04-17 17:33:49 +0200 |
commit | 3baecd0039864ac1e95fbc0b397fd203d02f4188 (patch) | |
tree | ea52e3c74b1a4bf7c4ec71cacd59af1866706dcf /src/hrs-scaling.c | |
parent | 2a7066092cbc547ea416bb5a7e9f8a9e33f750b5 (diff) |
s/osf/G/
Diffstat (limited to 'src/hrs-scaling.c')
-rw-r--r-- | src/hrs-scaling.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/hrs-scaling.c b/src/hrs-scaling.c index fb1466cb..d91a36d9 100644 --- a/src/hrs-scaling.c +++ b/src/hrs-scaling.c @@ -97,8 +97,8 @@ static void run_scale_job(void *vwargs, int cookie) RefListIterator *iter; double num = 0.0; double den = 0.0; - double corr; - const double osf = crystal_get_osf(cr); + double g; + const double G = crystal_get_osf(cr); if ( crystal_get_user_flag(cr) ) { wargs->shift = 0.0; @@ -145,20 +145,19 @@ static void run_scale_job(void *vwargs, int cookie) Ihl = get_intensity(refl) / corr; esd = get_esd_intensity(refl) / corr; - num += Ih * (Ihl/osf) / pow(esd/osf, 2.0); - den += pow(Ih, 2.0)/pow(esd/osf, 2.0); + num += Ih * (Ihl/G) / pow(esd/G, 2.0); + den += pow(Ih, 2.0)/pow(esd/G, 2.0); } //num += image->osf / pow(SCALING_RESTRAINT, 2.0); //den += pow(image->osf, 2.0)/pow(SCALING_RESTRAINT, 2.0); - corr = num / den; - if ( !isnan(corr) && !isinf(corr) ) { - crystal_set_osf(cr, osf*corr); + g = num / den; + if ( !isnan(g) && !isinf(g) ) { + crystal_set_osf(cr, g*G); } - wargs->shift = fabs(corr-1.0); - + wargs->shift = fabs(g-1.0); } |