Wiener Index Calculator

Σ d(u,v)

CalculatorsFreeNo Signup
4.8(429 reviews)
All Tools

Loading tool...

About Wiener Index Calculator

A Wiener index calculator computing W(G) = Σ d(u,v) over all unordered pairs {u,v}. Introduced by chemist Harry Wiener (1947) for molecular graphs. W(K_n)=C(n,2), W(P_n)=C(n+1,3). Important in mathematical chemistry. Client-side.

Wiener Index Calculator Features

  • W(G) value
  • Average distance
  • Common graphs
  • Tree formula
  • Chemical use
Wiener index W(G) = Σ_{u

How to Use

Select graph:

  • W(G): Wiener index
  • Average: Mean distance
  • Compare: Different topologies

Chemical Applications

Wiener showed W correlates with boiling points, density, and surface tension of alkanes. Higher W → more 'stretched out' molecule → higher boiling point. This launched the field of chemical graph theory (topological indices).

Trees

For trees: W = Σ_{edges e} n₁(e)·n₂(e), where n₁,n₂ are the sizes of the two subtrees when edge e is removed. This gives an O(n) algorithm. Stars minimize W among trees; paths maximize it.

Step-by-Step Instructions

  1. 1Select graph.
  2. 2Compute W(G).
  3. 3Find average distance.
  4. 4Compare topologies.
  5. 5Check extremes.

Wiener Index Calculator — Frequently Asked Questions

Why is Wiener index useful in chemistry?+

Molecular structure affects physical properties. The Wiener index captures how 'compact' vs 'elongated' a molecule is. Linear alkanes (high W) have higher boiling points than branched isomers (low W). This was one of the first quantitative structure-property relationships.

Which graphs minimize/maximize W?+

Among n-vertex trees: star K_{1,n-1} minimizes W=(n-1)², path P_n maximizes W=n(n²-1)/6. Among all n-vertex connected graphs: K_n minimizes W=C(n,2). The path is always the worst case.

What's the average distance?+

d̄ = W(G)/C(n,2) = 2W/(n(n-1)). For random graphs: d̄ ≈ log n/log d̄. For small-world networks: d̄ is small despite large n. Social networks typically have d̄ ≈ 4-6.

Share this tool: