Reflectometry plots: use bisection get steep minima right
|Status:||New||Start date:||29 Nov 2019|
Currently, plots of log(reflected intensity) vs alpha_i are inaccurate when there are deep and steep minima. Obviously because the reflected intensity is only computed for preset equidistant values of alpha_i.
To solve this problem, we need to detect sudden changes in slope, and insert additional data points. This can be done by bisectioning. We also need to detect when the graph leaves the current plot window (falls below y_min), and when it resurfaces.
All this I have implemented for arbitrary function plotting in Frida; that code could be reused here.