Skip to content

[BUG] Incorrect division in k_mask_grid_search #663

Open
@sizmailov

Description

@sizmailov

R-factor of (f_obs/k, f_model) is not equivalent to R-factor of (f_obs, f_model*k) (where k is an array with non-equal elements). Therefore I believe the next snippet contains an error:

bulk_solvent.k_mask_and_k_overall_grid_search(
f_obs.data()/k_total_,
core.f_calc.data(),
core.f_mask().data(),
k_mask_trial_range,
selection_use)

Corrected code should be something like:

        bulk_solvent.k_mask_and_k_overall_grid_search(
          f_obs.data(),
          core.f_calc.data() * k_total_,
          core.f_mask().data() * k_total_,
          k_mask_trial_range,
          selection_use)

@pafonine @olegsobolev

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions