25.06.2013 Views

1 transparent par page - Montefiore

1 transparent par page - Montefiore

1 transparent par page - Montefiore

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Induction et notation asymptotique<br />

Théorème faux : Soit la récurrence :<br />

◮ T (1) = 1,<br />

◮ T (n) = 2T (n/2) + n (pour n > 1).<br />

On a T (n) = O(n).<br />

(la solution correcte est T (n) = Θ(n log(n)))<br />

Démonstration : (<strong>par</strong> induction forte)<br />

◮ Soit P(n) = “T (n) = O(n)”.<br />

◮ Cas de base : P(1) est vrai car T (1) = 1 = O(1).<br />

◮ Cas inductif : Pour n ≥ 2, supposons P(1),P(2),. . . ,P(n − 1). On a :<br />

Où est l’erreur ?<br />

T (n) = 2T (n/2) + n<br />

= 2O(n/2) + n<br />

= O(n)<br />

367

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!