Ë
    D^(h(	  ã                   óx   — d Z ddlZddlmZmZ dgZ ed«       ed«      ej                  dd„«       «       «       Zy)	z=
Algorithm to find a maximal (not maximum) independent set.

é    N)Únot_implemented_forÚpy_random_stateÚmaximal_independent_setÚdirectedé   c           	      ó¶  — |s|j                  t        | «      «      h}nt        |«      }|j                  | «      st	        j
                  |› d�«      ‚t        j                  |D �cg c]  }t        | j                  |   «      ‘Œ c}Ž }t        j                  ||«      rt	        j
                  |› d�«      ‚t        |«      }t        | j                  «       «      j                  |j                  |«      «      }|rY|j                  t        |«      «      }|j                  |«       |j                  t        | j                  |   «      |gz   «       |rŒY|S c c}w )a'  Returns a random maximal independent set guaranteed to contain
    a given set of nodes.

    An independent set is a set of nodes such that the subgraph
    of G induced by these nodes contains no edges. A maximal
    independent set is an independent set such that it is not possible
    to add a new node and still get an independent set.

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

    nodes : list or iterable
       Nodes that must be part of the independent set. This set of nodes
       must be independent.

    seed : integer, random_state, or None (default)
        Indicator of random number generation state.
        See :ref:`Randomness<randomness>`.

    Returns
    -------
    indep_nodes : list
       List of nodes that are part of a maximal independent set.

    Raises
    ------
    NetworkXUnfeasible
       If the nodes in the provided list are not part of the graph or
       do not form an independent set, an exception is raised.

    NetworkXNotImplemented
        If `G` is directed.

    Examples
    --------
    >>> G = nx.path_graph(5)
    >>> nx.maximal_independent_set(G)  # doctest: +SKIP
    [4, 0, 2]
    >>> nx.maximal_independent_set(G, [1])  # doctest: +SKIP
    [1, 3]

    Notes
    -----
    This algorithm does not solve the maximum independent set problem.

    z" is not a subset of the nodes of Gz is not an independent set of G)ÚchoiceÚlistÚsetÚissubsetÚnxÚNetworkXUnfeasibleÚunionÚadjÚintersectionÚnodesÚ
differenceÚappendÚdifference_update)ÚGr   ÚseedÚvÚ	neighborsÚindep_nodesÚavailable_nodesÚnodes           úU/var/www/skyplay_api_hub/venv/lib/python3.12/site-packages/networkx/algorithms/mis.pyr   r      s  € ñf Ø—‘œT !›WÓ%Ð&‰ä�E“
ˆØ�>‰>˜!ÔÜ×#Ñ# u gÐ-OÐ$PÓQÐQÜ—	‘	°5Ö9¨aœC §¡ a¡�MÒ9Ð:€IÜ
×Ñ˜	 5Ô)Ü×#Ñ# u gÐ-LÐ$MÓNÐNÜ�u“+€KÜ˜!Ÿ'™'›)“n×/Ñ/°	·±ÀÓ0FÓG€OÙ
Ø�{‰{œ4 Ó0Ó1ˆØ×Ñ˜4Ô Ø×)Ñ)¬$¨q¯u©u°T©{Ó*;¸t¸fÑ*DÔEò ð Ðùò :s   Á&E)NN)	Ú__doc__Únetworkxr   Únetworkx.utilsr   r   Ú__all__Ú_dispatchabler   © ó    r   ú<module>r%      sN   ðñó
 ß ?à$Ð
%€ñ �ZÓ Ù�ÓØ×Ñò?ó ó ó !ñ?r$   