WOLFRAM

gives the set of vertices with maximum vertex degree in the underlying simple graph of g.

GraphHub[g,"In"]

gives the set of vertices with maximum vertex in-degree.

GraphHub[g,"Out"]

gives the set of vertices with maximum vertex out-degree.

GraphHub[{vw,},]

uses rules vw to specify the graph g.

Details

  • The vertex degree for a vertex v is the number of edges incident to v.
  • For a directed graph, the in-degree is the number of incoming edges and the out-degree is the number of outgoing edges.
  • For an undirected graph, an edge is taken to be both an in-edge and out-edge.
  • GraphHub works with undirected graphs, directed graphs, multigraphs and mixed graphs.

Examples

open allclose all

Basic Examples  (1)Summary of the most common use cases

Find the hub for a graph:

Out[2]=2

Highlight:

Out[3]=3

Scope  (5)Survey of the scope of standard use cases

GraphHub works with undirected graphs:

Out[1]=1

Directed graphs:

Out[1]=1

Use rules to specify the graph:

Out[1]=1

Compute the hubs with respect to vertex in-degree and vertex out-degree:

Out[1]=1
Out[2]=2

GraphHub works with large graphs:

Out[2]=2

Applications  (7)Sample problems that can be solved with this function

The administrator is the hub of the friendship network between members of a karate club:

Out[2]=2

Find the people with the most family members present at the family gathering:

Out[1]=1
Out[2]=2

Find the publications with the most citations in a citation network:

Out[2]=2

With the most references to other publications:

Out[3]=3

The terrorist network linked to the tragic events of September 11, 2001. The ringleader of the conspiracy is the hub of the network:

Out[1]=1
Out[2]=2

The Medici family is the hub of the marriage network of the ruling families of Florence:

Out[2]=2

It is the most powerful family and has the highest betweenness centrality:

Out[3]=3

Find the stations with the largest number of neighboring stations in the London Underground network:

Out[1]=1

Find the messages receiving the largest number of replies in the network of email sent to the MathGroup list in November 2011:

Out[1]=1
Out[2]=2

The most interesting subject of the month:

Out[3]=3

Compute the message generating the largest total number of messages:

Out[5]=5

Properties & Relations  (11)Properties of the function, and connections to other functions

GraphHub gives the center of a graph with respect to DegreeCentrality:

Out[3]=3
Out[4]=4
Out[6]=6

With respect to in-degree centrality:

Out[7]=7
Out[9]=9

With respect to out-degree centrality:

Out[10]=10
Out[12]=12

For simple graphs, GraphHub gives the center with respect to VertexDegree:

Out[1]=1
Out[2]=2
Out[4]=4

Or with respect to VertexInDegree:

Out[5]=5
Out[7]=7

Or with respect to VertexOutDegree:

Out[8]=8
Out[10]=10

Self-loops are ignored:

Out[2]=2

For a CompleteGraph, every vertex is a hub:

Out[1]=1

For a PathGraph, all vertices except for the endpoints are hubs:

Out[1]=1

For a CycleGraph, every vertex is a hub:

Out[1]=1

For a WheelGraph of size 5 or more, the hub of the wheel is the graph hub:

Out[1]=1

For a GridGraph, all vertices that are not at an edge of the grid are hubs:

Out[1]=1

For a CompleteKaryTree, all vertices except for the leaves and the root are hubs:

Out[1]=1

The center of a graph with respect to EccentricityCentrality is obtained with GraphCenter:

Out[2]=2

The set of vertices with maximum VertexEccentricity is obtained with GraphPeriphery:

Out[3]=3

The BetweennessCentrality center of a graph:

Out[3]=3

The ClosenessCentrality center:

Out[4]=4

The EigenvectorCentrality center:

Out[5]=5

Possible Issues  (1)Common pitfalls and unexpected behavior

Self-loops are not accounted for:

Out[2]=2

Use VertexDegree to find the center with self-loops included:

Out[4]=4
Wolfram Research (2012), GraphHub, Wolfram Language function, https://reference.wolfram.com/language/ref/GraphHub.html (updated 2015).
Wolfram Research (2012), GraphHub, Wolfram Language function, https://reference.wolfram.com/language/ref/GraphHub.html (updated 2015).

Text

Wolfram Research (2012), GraphHub, Wolfram Language function, https://reference.wolfram.com/language/ref/GraphHub.html (updated 2015).

Wolfram Research (2012), GraphHub, Wolfram Language function, https://reference.wolfram.com/language/ref/GraphHub.html (updated 2015).

CMS

Wolfram Language. 2012. "GraphHub." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2015. https://reference.wolfram.com/language/ref/GraphHub.html.

Wolfram Language. 2012. "GraphHub." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2015. https://reference.wolfram.com/language/ref/GraphHub.html.

APA

Wolfram Language. (2012). GraphHub. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/GraphHub.html

Wolfram Language. (2012). GraphHub. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/GraphHub.html

BibTeX

@misc{reference.wolfram_2025_graphhub, author="Wolfram Research", title="{GraphHub}", year="2015", howpublished="\url{https://reference.wolfram.com/language/ref/GraphHub.html}", note=[Accessed: 07-July-2025 ]}

@misc{reference.wolfram_2025_graphhub, author="Wolfram Research", title="{GraphHub}", year="2015", howpublished="\url{https://reference.wolfram.com/language/ref/GraphHub.html}", note=[Accessed: 07-July-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_graphhub, organization={Wolfram Research}, title={GraphHub}, year={2015}, url={https://reference.wolfram.com/language/ref/GraphHub.html}, note=[Accessed: 07-July-2025 ]}

@online{reference.wolfram_2025_graphhub, organization={Wolfram Research}, title={GraphHub}, year={2015}, url={https://reference.wolfram.com/language/ref/GraphHub.html}, note=[Accessed: 07-July-2025 ]}