How to Use
Select graph:
- Wp: Polarity index
- d=3: Count pairs
- A³: Trace method
Chemical Polarity
Why distance 3? In alkanes, atoms separated by 3 bonds have maximum polarization interaction (1,4-interactions). These drive boiling point differences. Wp elegantly counts exactly these interactions.
Computation
Wp = ½·(A³)_{trace} - correction. Or simply: BFS from each vertex, count those at distance 3, divide by 2. O(nm) time. For trees: Wp = Σ_{edges} n₁(n-n₁-n₂-n₃) with subtree counts.
Step-by-Step Instructions
- 1Select graph.
- 2BFS from each vertex.
- 3Count d=3 pairs.
- 4Divide by 2.
- 5Predict boiling pt.