, , Binary, , Newton Search, , - , , , , .
split = 0.5;
while(1)
{
point = lower+split*(upper-lower);
if(x>a[point])
{
lower = point;
split*= 1.2
}
else if(x<a[point])
{
upper=point;
split /=1.2
} else break;
}
This supposedly gives better results with sets that have polynomial layouts and unrelated sets. This gives the worst results with random or linear layouts. It can also crash with a split growing above 1 without proper guarantees.
source
share