Eccentricity - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


GraphTheory

  

Eccentricity

  

compute graph eccentricity

 

Calling Sequence

Parameters

Options

Description

Definition

Examples

Compatibility

Calling Sequence

Eccentricity(G, opts)

Eccentricity(G, v)

Parameters

G

-

graph

v

-

(optional) vertex of G

opts

-

(optional) one or more options as specified below

Options

  

The options argument can contain one or more of the options shown below.

• 

output=Array, DataSeries, list, or Vector.

  

This option specifies an alternate container type for the return value. When output is one of Array, list, or Vector, a container of the named type containing the eccentricities for each vertex is returned. When output is DataSeries, the return value is a DataSeries object whose labels correspond to the graph vertices and whose values are the computed eccentricities for the associated vertices. The default container type is a list.

  

The output option cannot be used when a particular vertex v is specified.

Description

• 

The Eccentricity(G,v) command computes the eccentricity for the vertex v in the graph G.

• 

The Eccentricity(G) command returns a list of the computed eccentricities for each vertex in the graph G, listed in the order in which the vertices appear in the list returned by Vertices(G).

Definition

• 

The eccentricity of a vertex v in a graph G is a number which represents the maximum graph distance between v and any other vertex in the graph.

• 

If G is disconnected, then the eccentricity for every vertex is infinity.

• 

If G is a complete graph, then the eccentricity for every vertex is 1.

• 

The maximum of the eccentricities in G is the diameter of G. The minimum of the eccentricities in G is the radius of G.

Examples

withGraphTheory:

GGraph6,1,3,1,6,2,4,2,6,3,6,4,5,4,6,5,6

GGraph 1: an undirected graph with 6 vertices and 8 edge(s)

(1)

DrawGraphG

Compute the eccentricity for vertex 6.

EccentricityG,6

1

(2)

Produce a list of eccentricities for all vertices.

EccentricityG

2,2,2,2,2,1

(3)

Produce a DataSeries with labels corresponding to the named vertices.

HGrapha,b,c,d,a,b,a,d,b,c,c,d

HGraph 2: an undirected graph with 4 vertices and 4 edge(s)

(4)

EccentricityH,output=DataSeries

a2b2c2d2

(5)

Compatibility

• 

The GraphTheory[Eccentricity] command was introduced in Maple 2017.

• 

For more information on Maple 2017 changes, see Updates in Maple 2017.

See Also

GraphTheory[Diameter]

GraphTheory[Distance]

GraphTheory[Radius]