I'm trying to draw an undirected tree graph such that all vertices have the same degree, but it seems that I can't.
Is it possible? I'd love an example. If it's not possible, what am I missing?
I'm trying to draw an undirected tree graph such that all vertices have the same degree, but it seems that I can't.
Is it possible? I'd love an example. If it's not possible, what am I missing?
On
It is a known fact that every tree has at least one leaf, i.e. a vertex of degree 1 (unless of course the tree is trivial, in which case you have only one vertex and its degree is 0). To see this, take a path P of maximum length. If the last vertex of P has degree strictly more than 1, then one its neighbours would have to lie on P (otherwise P would not have maximum length), but that would form a cycle which is not possible.
So in every tree there is a vertex of degree 1. This means that in order to have a tree where all vertices have the same degree, that degree would have to be exactly 1. The only way this would be possible would be if the tree had exactly 2 vertices.
A tree on $n\geq 1$ vertices has $n-1$ edges. Therefore, if all the vertices have the same degree $d\geq 0$ then $$dn=\sum_{v\in V}\text{deg}(v)=2(n-1)$$ that is $(2-d)n=2$ which has two solutions: i) $d=1$ and $n=2$; ii) $d=0$ and $n=1$.
What may we conclude?