Unit 2-Lecture 5: Walks & Paths

1 Vertex Degrees

  • Definition:
    The in-degree of a vertex in a digraph is the number of arrows coming into it, and similarly its out-degree is the number of arrows out of it.
  • Hand shake theory:
  • Lemma:
    vV(G)indeg(v)  =  vV(G)outdeg(v)

2 Walks and Paths

2.1 Definition:

  • A walk, v, is a sequence of the form:
    v:=v0<v0v1>v1<v1v2>...vk1<vk1vk>
  • The walk is a path iff all the vi are different.
  • A closed walk is a walk that begins and ends at the same vertex.
  • A cycle is a positive length closed walk whose vertices are distinct except for the beginning and end vertices.
  • The distance, dist(u,v), in a graph from vertex u to vertex v is the length of a shortest path from u to v.

2.2 Finding a Path

  • The shortest walk from one vertex to another is a path.
  • The Triangle Inequality: dist(u,v) <= dist(u,x)+dist(x,v)
  • the relationship between walks and paths extends to closed walks and cycles:
    The shortest positive length closed walk through a vertex is a cycle through that vertex

3 Adjacency Matrices

  • Definivtion:
  • Theorem: If C is the length-k walk counting matrix for a graph G, and D is the length-m walk counting matrix, then CD is the length k C m walk counting matrix for G.
  • Shortested Path:
    One simple way to find the lengths of all the shortest paths in an n-vertex graph, G, is to compute the successive powers of AG one by one up to the n-1st, watching for the first power at which each entry becomes positive.

4 Walk Relations

  • Walk relation on V(G):
    uGv= there is a walk in G from u to v.
  • Positive walk relation on V(G)
    uG+v= there is a positive length walk in G from u to v.
  • Composition of Relations:
    If we let Gn denote the composition of G with itself n times, then Gn is the length-n walk relation:
    aGnb iff there is a length n walk in G from a to b.

Reference

[1] Lehman E, Leighton F H, Meyer A R. Mathematics for Computer Science[J]. 2015.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值