• 图论-相关概念


    Clique(团)

    团clique(clique)是一个无向图(undirected graph )的子图,该子图中任意两个顶点之间均存在一条边。
    极大团maximal clique是一个团,该团不能被更大的团所包含,换句话说,再也不存在一个点与该团中的任意顶点之间存在一条边。
    团的大小size是指一个团中包含的顶点数,size=k的团,称为k-团。
    最大团maximum clique是指一个图中size最大的maximal clique。
    团数clique number是指一个图的maximum clique的size。
    引自wiki
    上图中有团的总数可以说是很难计算得到的,1-团有23个(点),2团有42个(边),3-团有19个(浅蓝色和深蓝色),4-团有2个(深蓝色),极大团有18个(11个3-团、2个4-团和5个2-团),最大团2个(深蓝色4-团),该图的团数为4

    Euler path(欧拉路径)

    欧拉通路(路径): 如果图G中的一个路径包括每个边恰好一次,则该路径称为欧拉路径
    欧拉回路(Eulerian circuit): 如果一个回路是欧拉路径,则称为欧拉回路
    欧拉图(Eulerian):包含欧拉回路的图
    半欧拉图(semi-Eulerian):包含欧拉路径,但不包含欧拉回路的图
    有向图的基图:忽略有向图所有边的方向,得到的无向图称为该有向图的基图。

    In graph theory, an Eulerian trail (or Eulerian path) is a trail in a finite graph that visits every edge exactly once (allowing for revisiting vertices). Similarly, an Eulerian circuit or Eulerian cycle is an Eulerian trail that starts and ends on the same vertex. They were first discussed by Leonhard Euler while solving the famous Seven Bridges of Königsberg problem in 1736. The problem can be stated mathematically like this:
    Given the graph in the image, is it possible to construct a path (or a cycle, i.e. a path starting and ending on the same vertex) that visits each edge exactly once?
    Euler proved that a necessary condition for the existence of Eulerian circuits is that all vertices in the graph have an even degree, and stated without proof that connected graphs with all vertices of even degree have an Eulerian circuit. The first complete proof of this latter claim was published posthumously in 1873 by Carl Hierholzer.[1] This is known as Euler's Theorem:
    A connected graph has an Euler cycle if and only if every vertex has even degree.
    The term Eulerian graph has two common meanings in graph theory. One meaning is a graph with an Eulerian circuit, and the other is a graph with every vertex of even degree. These definitions coincide for connected graphs.[2]
    For the existence of Eulerian trails it is necessary that zero or two vertices have an odd degree; this means the Königsberg graph is not Eulerian. If there are no vertices of odd degree, all Eulerian trails are circuits. If there are exactly two vertices of odd degree, all Eulerian trails start at one of them and end at the other. A graph that has an Eulerian trail but not an Eulerian circuit is called semi-Eulerian.
    Every vertex of this graph has an even degree. Therefore, this is an Eulerian graph. Following the edges in alphabetical order gives an Eulerian circuit/cycle.

    如何判断一个图是否有欧拉路径?

    • 图必须连通
    • 若是无向图,则这个图的度数为奇数的点的个数必须是0或2(图中如果恰好有两个奇数度的顶点,则所有欧拉路径都从其中一个开始,并在另一个结束)
    • 若是有向图,则要么所有点的入度和出度相等,要么有且只有两个点的入度分别比出度大1和少1

  • 相关阅读:
    转:线程Thread (1)
    jquery 比较全面的API中文版地址
    IE 出现stack overflow 报错的原因归纳
    转:C#常用的集合类型(ArrayList类、Stack类、Queue类、Hashtable类、Sort)
    转:双向链表dblinklist
    转:stack
    转:queue
    解决获取同胞元素空白节点影响的问题
    取10到100的随机数方法
    进度条
  • 原文地址:https://www.cnblogs.com/houzm/p/12384605.html
Copyright © 2020-2023  润新知