vincefn / objcryst

Free Objects for Crystallography : Fox / ObjCryst++
Other
23 stars 10 forks source link

Fix double loop in PowderPattern::PrepareIntegratedRfactor #53

Closed zdemat closed 2 years ago

zdemat commented 2 years ago

Fix for a double loop in PowderPattern::PrepareIntegratedRfactor.

vincefn commented 2 years ago

Thanks a lot. That's an embarassing bug. Thankfully it would only have affected cases where there are multiple crystalline phases...

zdemat commented 2 years ago

Thanks to @milandopita for reporting this. He hit an issue with that on a 2 crystalline component case.

Charlaiz commented 1 year ago

Hello, is it possible that there is still an issue with the scale factor? I would like to do a LeBail fit on a pattern with two crystal phases but FOX throws the current error: Warning:FitScaleFactorForIntegratedRw: working around NaN scale factor... Warning:FitScaleFactorForRw working around NaN scale factor...

Thank you very much in advance for clarifying!

vincefn commented 1 year ago

@Charlaiz You'll need to be more specific (example to reproduce). Occasionally the scale factor can diverge, but that's normally only when initialising when there are no atoms in a crystal structure (and so no intensity).

Also, please open a separate issue - this is not related to this PR.