Todos os livros

Profissional

Apps Sobre Coach Entrar Começar a ler

Computer Science · Glossário

O que é Monotone predicate, dichotomy on the answer?

Também chamado de: monotone predicate · dichotomy on the answer

Definition 21.7 University Computer Science — Year 1 · Capítulo 21 — Divide and Conquer

A predicate PP on the integers is monotone if P(x)P(x) implies P(x+1)P(x + 1): false up to some point, true after it. A dichotomy on the answer finds the smallest xx in [lo,hi][lo, hi] with P(x)P(x), knowing P(hi)P(hi), by binary search on xx, with ⌈log⁡2(hi−lo+1)⌉\lceil \log_2 (hi - lo + 1) \rceil evaluations of PP.

Ler no capítulo →