GraphHub
gives the set of vertices with maximum vertex degree in the underlying simple graph of 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 allBasic Examples (1)Summary of the most common use cases
Scope (5)Survey of the scope of standard use cases
GraphHub works with undirected graphs:

https://wolfram.com/xid/0tz1rth7-rvhr2v


https://wolfram.com/xid/0tz1rth7-og1ays

Use rules to specify the graph:

https://wolfram.com/xid/0tz1rth7-bndh30

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

https://wolfram.com/xid/0tz1rth7-o535o0


https://wolfram.com/xid/0tz1rth7-8l42tk

GraphHub works with large graphs:

https://wolfram.com/xid/0tz1rth7-pq9ae

https://wolfram.com/xid/0tz1rth7-7r0z3f

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:

https://wolfram.com/xid/0tz1rth7-2rxdfs

https://wolfram.com/xid/0tz1rth7-9lt98a

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

https://wolfram.com/xid/0tz1rth7-xuzztf


https://wolfram.com/xid/0tz1rth7-htatos

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

https://wolfram.com/xid/0tz1rth7-oqzcw5

https://wolfram.com/xid/0tz1rth7-mujly6

With the most references to other publications:

https://wolfram.com/xid/0tz1rth7-yjnfb1

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

https://wolfram.com/xid/0tz1rth7-lbwuve


https://wolfram.com/xid/0tz1rth7-hhyzfu

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

https://wolfram.com/xid/0tz1rth7-wecsv2

https://wolfram.com/xid/0tz1rth7-eilbv4

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

https://wolfram.com/xid/0tz1rth7-282ha1

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

https://wolfram.com/xid/0tz1rth7-ezj0zr

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

https://wolfram.com/xid/0tz1rth7-hrqjma


https://wolfram.com/xid/0tz1rth7-omw8er

The most interesting subject of the month:

https://wolfram.com/xid/0tz1rth7-gcs5ks

Compute the message generating the largest total number of messages:

https://wolfram.com/xid/0tz1rth7-go8k52

https://wolfram.com/xid/0tz1rth7-7r9swl

Properties & Relations (11)Properties of the function, and connections to other functions
GraphHub gives the center of a graph with respect to DegreeCentrality:

https://wolfram.com/xid/0tz1rth7-w8z5rk


https://wolfram.com/xid/0tz1rth7-kwwfkt


https://wolfram.com/xid/0tz1rth7-1xc8bj

https://wolfram.com/xid/0tz1rth7-05d73j

With respect to in-degree centrality:

https://wolfram.com/xid/0tz1rth7-ob1rb9


https://wolfram.com/xid/0tz1rth7-1dflif

https://wolfram.com/xid/0tz1rth7-voaw5j

With respect to out-degree centrality:

https://wolfram.com/xid/0tz1rth7-lqabmr


https://wolfram.com/xid/0tz1rth7-w5ytdl

https://wolfram.com/xid/0tz1rth7-taapji

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

https://wolfram.com/xid/0tz1rth7-uuzwfj


https://wolfram.com/xid/0tz1rth7-ox3wlp


https://wolfram.com/xid/0tz1rth7-lrav6k

https://wolfram.com/xid/0tz1rth7-4yk36e

Or with respect to VertexInDegree:

https://wolfram.com/xid/0tz1rth7-nw2ahc


https://wolfram.com/xid/0tz1rth7-yssxqc

https://wolfram.com/xid/0tz1rth7-c7x57a

Or with respect to VertexOutDegree:

https://wolfram.com/xid/0tz1rth7-b8clsw


https://wolfram.com/xid/0tz1rth7-tcviwp

https://wolfram.com/xid/0tz1rth7-nhfpmw


https://wolfram.com/xid/0tz1rth7-4na5su

https://wolfram.com/xid/0tz1rth7-estqme

For a CompleteGraph, every vertex is a hub:

https://wolfram.com/xid/0tz1rth7-kq6mmo

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

https://wolfram.com/xid/0tz1rth7-w6ws08

For a CycleGraph, every vertex is a hub:

https://wolfram.com/xid/0tz1rth7-wyf682

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

https://wolfram.com/xid/0tz1rth7-6f0pih

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

https://wolfram.com/xid/0tz1rth7-0ieuul

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

https://wolfram.com/xid/0tz1rth7-0qqbr3

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

https://wolfram.com/xid/0tz1rth7-5z6idu

https://wolfram.com/xid/0tz1rth7-7bk3yc

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

https://wolfram.com/xid/0tz1rth7-qu35os

The BetweennessCentrality center of a graph:

https://wolfram.com/xid/0tz1rth7-fp458p

https://wolfram.com/xid/0tz1rth7-tysf0c

https://wolfram.com/xid/0tz1rth7-krdaqx

The ClosenessCentrality center:

https://wolfram.com/xid/0tz1rth7-v8saw5

The EigenvectorCentrality center:

https://wolfram.com/xid/0tz1rth7-p2cyi9

Possible Issues (1)Common pitfalls and unexpected behavior
Self-loops are not accounted for:

https://wolfram.com/xid/0tz1rth7-fadc17

https://wolfram.com/xid/0tz1rth7-j315jg

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

https://wolfram.com/xid/0tz1rth7-dxmdqk

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
]}
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
]}