o
    ˷e                     @   s   d Z ddlmZ dgZi dg ddgdddgd	dd
gdddgddd
gdg ddg ddg ddg ddg ddg ddg ddg ddg dd g d!Zd"d Zd#S )$zZFunctions that generate the triad graphs, that is, the possible
digraphs on three nodes.

    )DiGraphtriad_graph003012ab102ba021Dbc021Ucb021C111D)accar
   111U)r   r   r   030T)r   r   r   030C)r   r   r   201)r   r   r   r   120D)r
   r   r   r   120U)r   r   r   r   120C)r   r
   r   r   210)r   r
   r   r   r   300)r   r   r
   r   r   r   c                 C   s:   | t vrtd|  dt }|d |t |   |S )a  Returns the triad graph with the given name.

    Each string in the following tuple is a valid triad name::

        ('003', '012', '102', '021D', '021U', '021C', '111D', '111U',
         '030T', '030C', '201', '120D', '120U', '120C', '210', '300')

    Each triad name corresponds to one of the possible valid digraph on
    three nodes.

    Parameters
    ----------
    triad_name : string
        The name of a triad, as described above.

    Returns
    -------
    :class:`~networkx.DiGraph`
        The digraph on three nodes with the given name. The nodes of the
        graph are the single-character strings 'a', 'b', and 'c'.

    Raises
    ------
    ValueError
        If `triad_name` is not the name of a triad.

    See also
    --------
    triadic_census

    zunknown triad name "z9"; use one of the triad names in the TRIAD_NAMES constantabc)TRIAD_EDGES
ValueErrorr   add_nodes_fromadd_edges_from)
triad_nameG r!   Q/var/www/ideatree/venv/lib/python3.10/site-packages/networkx/generators/triads.pyr   #   s    

N)__doc__networkx.classesr   __all__r   r   r!   r!   r!   r"   <module>   sJ   	
