ó
    …~iN  ã                   ó~   • S r SSKrSSKJr  SSKJr  S/r\" S5      \" S5      \R                  S	 5       5       5       r	g)
z
Ramsey numbers.
é    N)Únot_implemented_foré   )Úarbitrary_elementÚ	ramsey_R2ÚdirectedÚ
multigraphc                 óä  ^• U (       d  [        5       [        5       4$ [        U 5      mU4S j[        R                  " U T5       5       n[        R                  " U T5      n[        U R                  U5      R                  5       5      u  p4[        U R                  U5      R                  5       5      u  pVUR                  T5        UR                  T5        [        X5[        S9[        XF[        S94$ )a  Compute the largest clique and largest independent set in `G`.

This can be used to estimate bounds for the 2-color
Ramsey number `R(2;s,t)` for `G`.

This is a recursive implementation which could run into trouble
for large recursions. Note that self-loop edges are ignored.

Parameters
----------
G : NetworkX graph
    Undirected graph

Returns
-------
max_pair : (set, set) tuple
    Maximum clique, Maximum independent set.

Raises
------
NetworkXNotImplemented
    If the graph is directed or is a multigraph.
c              3   ó6   >#   • U  H  oT:w  d  M
  Uv •  M     g 7f)N© )Ú.0ÚnbrÚnodes     €Úe/home/mande/repo/quber/.venv/lib/python3.13/site-packages/networkx/algorithms/approximation/ramsey.pyÚ	<genexpr>Úramsey_R2.<locals>.<genexpr>,   s   øé € ÐDÒ4�C¸t¹�C‰CÒ4ùs   ƒ	�	)Úkey)Úsetr   ÚnxÚall_neighborsÚnon_neighborsr   ÚsubgraphÚcopyÚaddÚmaxÚlen)ÚGÚnbrsÚnnbrsÚc_1Úi_1Úc_2Úi_2r   s          @r   r   r      s¶   ø€ ö6 Ü‹u”c“eˆ|Ðä˜QÓ€DÜDœ2×+Ò+¨A¨tÔ4ÓD€DÜ×Ò˜Q Ó%€EÜ˜Ÿ™ DÓ)×.Ñ.Ó0Ó1�H€CÜ˜Ÿ™ EÓ*×/Ñ/Ó1Ó2�H€Cà‡G�GˆD„MØ‡G�GˆD„Mô ˆsœSÑ!¤3 s´SÑ#9Ð9Ð9ó    )
Ú__doc__Únetworkxr   Únetworkx.utilsr   Úutilsr   Ú__all__Ú_dispatchabler   r   r#   r   Ú<module>r*      sP   ðñó Ý .å &àˆ-€ñ �ZÓ Ù�\Ó"Ø×Ññ%:ó ó #ó !ñ%:r#   