📜  图的基本属性

📅  最后修改于: 2022-05-13 01:57:54.132000             🧑  作者: Mango

图的基本属性

图是由节点和边组成的非线性数据结构。节点有时也称为顶点,边是连接图中任意两个节点的线或弧。

图的属性基本上用于根据图的结构来表征图。我们用与图论领域相关的特定术语定义了这些属性。在本文中,我们将讨论图的一些属性,如下所示:

  1. 两个顶点之间的距离
    它基本上是顶点 A 和顶点 B 之间的最短路径中可用的边数。如果使用多个边连接两个顶点,那么我们基本上将最短路径视为这两个顶点之间的距离。
    Notation used :
    d(A, B)
    here function d is basically showing the distance between vertex A and vertex B.
    

    让我们通过一个例子来理解这一点:

    在上图中,让我们尝试找出顶点 b 和 d 之间的距离。

    d(b, c)
    We can go from vertex b to vertex d in different ways such as
    1.ba, af, fe, ed here the d(b, c) will be 4.
    2.ba, af, fc, cd here the d(b, c) will be 4.
    3.bc, cf, fe, ed here the d(b, c) will be 4.
    4.bc, cd here the d(b, c) will be 2.
    hence the minimum distance between vertex b and vertex d is 2.
    
  2. 顶点的偏心率
    从一个顶点到所有其他顶点的最大距离被认为是该顶点的离心率。
    Notation used:
    e(V)
    here e(v) determines the eccentricity of vertex V.
    

    让我们尝试使用以下示例来理解这一点。

    From the above diagram lets try to find the eccentricity of vertex b.
    e(b)
    d(b, a)=1
    d(b, c)=1
    d(b, d)=2
    d(b, e)=3
    d(b, f)=2
    d(b, g)=2
    Hence the eccentricity of vertex b is 3
    
  3. 连通图的半径
    所有顶点的离心率的最小值基本上被认为是连通图的半径。
    Notation used:
    r(G)
    here G is the connected graph.
    

    让我们尝试使用以下示例来理解这一点。

    From the above diagram:
    r(G) is 2.
    Because the minimum value of eccentricity from all vertices is 2.
    
  4. 连通图的直径
    与这里的连通图的半径不同,我们基本上使用所有顶点的偏心率的最大值来确定图的直径。
    Notation used:
    d(G)
    where G is the connected graph.
    

    让我们尝试使用以下示例来理解这一点。

    From the above diagram:
    d(G) is 3.
    Because the maximum value of eccentricity from all vertices is 3.
    
  5. 中心点和中心
    具有最小偏心率的顶点被认为是图的中心点。所有中心点的集合被认为是图的中心。
    if
    e(V)=r(G)
    then v is the central point.
    

    让我们尝试使用以下示例来理解这一点。

    In the above diagram the central point will be f.
    because 
    e(f)=r(G)=2
    hence f is considered as the central point of graph.
    Hence f is also the centre of the graph.