693
правки
Изменения
→Псевдокод
'''Edge''' e = <tex>\langle </tex>u, v<tex>\rangle</tex>
i = e.level
'''whilefor''' i <tex>\geqslant</tex> = e.level '''downto''' 0
<tex>G_i</tex> = <tex>G_i\setminus</tex>e<!---delete(<tex>G_i</tex>, e)--->
<tex>F_i</tex> = <tex>F_i\setminus</tex>e<!---delete(<tex>F_i</tex>, e)--->
'''for''' e2 = <tex>\langle </tex>x, y<tex>\rangle</tex> : e2.level == i '''and''' x <tex>\in T_u</tex>
'''if''' y <tex>\in T_v</tex>
'''whilefor''' j = i <tex>\geqslant</tex> '''downto''' 0 <tex>F_iF_j</tex> = <tex>F_iF_j</tex> <tex>\cup</tex> e2<!---insert(<tex>F_i</tex>, e2)--> i--
'''return'''
'''else'''
e2.level++
<tex>G_{i+1}</tex> = <tex>G_{i+1}</tex> <tex>\cup</tex> e2<!---insert(<tex>F_i</tex>, e2)--> i--
== См. также ==