On Mon, Jan 06, 2020 at 11:26:06PM -0600, Justin Pryzby wrote:
> As Jeff has pointed out, high correlation has two effects in cost_index():
> 1) the number of pages read will be less;
> 2) the pages will be read more sequentially;
>
> cost_index reuses the pages_fetched variable, so (1) isn't particularly clear,
I tried to make this more clear in 0001
> + cost_per_page_corr = spc_random_page_cost -
> + (spc_random_page_cost - spc_seq_page_cost)
> + * (1-correlation*correlation);
And fixed bug: this should be c*c not 1-c*c.