Tous les livres

Professionnel

Applis À propos Coach Connexion Commencer la lecture

Computer Science · Glossaire

Qu'est-ce que « Monotone predicate, dichotomy on the answer » ?

Aussi appelé : monotone predicate · dichotomy on the answer

Definition 21.7 University Computer Science — Year 1 · Chapitre 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.

Lire dans le chapitre →