当前位置: 首页>>代码示例>>Python>>正文


Python CartanType.dynkin_diagram方法代码示例

本文整理汇总了Python中cartan_type.CartanType.dynkin_diagram方法的典型用法代码示例。如果您正苦于以下问题:Python CartanType.dynkin_diagram方法的具体用法?Python CartanType.dynkin_diagram怎么用?Python CartanType.dynkin_diagram使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在cartan_type.CartanType的用法示例。


在下文中一共展示了CartanType.dynkin_diagram方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: DynkinDiagram

# 需要导入模块: from cartan_type import CartanType [as 别名]
# 或者: from cartan_type.CartanType import dynkin_diagram [as 别名]
def DynkinDiagram(*args):
    """
    INPUT:

     -  ``ct`` - a Cartan Type

    Returns a Dynkin diagram for type ct.


    The edge multiplicities are encoded as edge labels. This uses the
    convention in Kac / Fulton Harris, Representation theory / Wikipedia
    (http://en.wikipedia.org/wiki/Dynkin_diagram). That is for i != j::

       j --k--> i <==> a_ij = -k
                  <==> -scalar(coroot[i], root[j]) = k
                  <==> multiple arrows point from the longer root
                       to the shorter one

    EXAMPLES::

        sage: DynkinDiagram(['A', 4])
        O---O---O---O
        1   2   3   4
        A4

        sage: DynkinDiagram(['A',1],['A',1])
        O
        1
        O
        2
        A1xA1

        sage: R = RootSystem("A2xB2xF4")
        sage: DynkinDiagram(R)
        O---O
        1   2
        O=>=O
        3   4
        O---O=>=O---O
        5   6   7   8
        A2xB2xF4

    SEE ALSO: :func:`CartanType` for a general discussion on Cartan
    types and in particular node labeling conventions.
    """
    if len(args) == 0:
       return DynkinDiagram_class()
    ct = CartanType(*args)
    if hasattr(ct, "dynkin_diagram"):
        return ct.dynkin_diagram()
    else:
        raise ValueError, "Dynkin diagram data not yet hardcoded for type %s"%ct
开发者ID:chos9,项目名称:sage,代码行数:54,代码来源:dynkin_diagram.py

示例2: DynkinDiagram

# 需要导入模块: from cartan_type import CartanType [as 别名]
# 或者: from cartan_type.CartanType import dynkin_diagram [as 别名]
def DynkinDiagram(*args):
    r"""
    Return a Dynkin diagram for type ``ct``.

    INPUT:

    -  ``ct`` -- a Cartan Type

    The edge multiplicities are encoded as edge labels. This uses the
    convention in Hong and Kang, Kac, Fulton Harris, and crystals. This is the
    **opposite** convention in Bourbaki and Wikipedia's Dynkin diagram
    (:wikipedia:`Dynkin_diagram`). That is for `i \neq j`::

       i <--k-- j <==> a_ij = -k
                  <==> -scalar(coroot[i], root[j]) = k
                  <==> multiple arrows point from the shorter root
                       to the longer one

    For example, in type `C_2`, we have::

        sage: C2 = DynkinDiagram(['C',2]); C2
        O=<=O
        1   2
        C2
        sage: C2.cartan_matrix()
        [ 2 -2]
        [-1  2]

    However Bourbaki would have the Cartan matrix as:

    .. MATH::

        \begin{bmatrix}
        2 & -1 \\
        -2 & 2
        \end{bmatrix}.

    EXAMPLES::

        sage: DynkinDiagram(['A', 4])
        O---O---O---O
        1   2   3   4
        A4

        sage: DynkinDiagram(['A',1],['A',1])
        O
        1
        O
        2
        A1xA1

        sage: R = RootSystem("A2xB2xF4")
        sage: DynkinDiagram(R)
        O---O
        1   2
        O=>=O
        3   4
        O---O=>=O---O
        5   6   7   8
        A2xB2xF4

    .. SEEALSO::

        :func:`CartanType` for a general discussion on Cartan
        types and in particular node labeling conventions.
    """
    if len(args) == 0:
       return DynkinDiagram_class()
    ct = CartanType(*args)
    if hasattr(ct, "dynkin_diagram"):
        return ct.dynkin_diagram()
    else:
        raise ValueError, "Dynkin diagram data not yet hardcoded for type %s"%ct
开发者ID:odellus,项目名称:sage,代码行数:75,代码来源:dynkin_diagram.py


注:本文中的cartan_type.CartanType.dynkin_diagram方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。