• edited by
3,409 views
10 10 votes

Consider directed graphs on $n$ labelled vertices $\{1,2, \dots ,n\}$, where each vertex has exactly one edge coming in  and exactly one edge going out. We allow self-loops. How many graphs have exactly two cycles ?

  1. $\displaystyle \sum_{k=1}^{n-1} k!(n-k)!$
  2. $\frac{n!}{2}\bigg[\displaystyle \sum_{k=1}^{n-1} \frac{1}{k(n-k)}\bigg]$
  3. $n!\bigg[\displaystyle \sum_{k=1}^{n-1} \frac{1}{k}\bigg]$
  4. $\frac{n!(n-1)}{2}$
  5. None of the above

2 Answers

Best answer
16 16 votes

We need to find from $\{1,2,\ldots,n\}$ vertices how many graphs exist which are having exactly two cycles when self loops are allowed.

When $n=1$ there is no such graph with two cycles.

0 graph.

When $n=2$

1 graph exists.

When $n=3$

3 graphs exist.

When $n=4$

11 graphs exist.

For $n=4$

(A) $\sum_{k=1}^{n-1}k!(n-k)! = 16$

(B) $\frac{n!}{2}[\sum_{k=1}^{n-1}\frac{1}{k(n-k)}] = 11$

(C) $n![\sum_{k=1}^{n-1}\frac{1}{k}] = 44$

(D) $\frac{n!(n-1)}{2} = 36$

Option B is answer.

• edited by
14 14 votes

Answer : Option B

Let the first cycle contain k vertices and the second cycle contain n-k vertices. Now we can choose k vertices in nCk ways. The k vertices in the first cycle can be arranged in (k-1)! to give different cycles (here, directed graph is mentioned. So clockwise and anticlockwise ordering will be counted as different and hence, no need to divide it by 2). Similarly, the remaining n-k vertices in the second cycle can be arranged in (n-k-1)! ways to give different cycles. Thus, the total number of cycles, will be given as

 

f(k)   = $\binom{n}{k}.(k-1)!.(n-k-1)!$

        = $\tfrac{n!}{(k.(k-1)! . (n-k).(n-k-1)!)} . (k-1)! . (n-k-1)!$

        = $\tfrac{n!}{k(n-k)}$

The value of k can range from 1 to n-1, and summing up all the cases will give us the total number of graphs that will have exactly two cycles. However, here we are distinguishing between first and second cycles. So we will need to divide by 2 because each graph will be counted twice. (Consider two graphs G1 and G2 such that first cycle of G1 is same as second cycle of G2 and vice versa. We have counted these graphs twice but essentially they are the same and so we need to divide the total number by 2). Therefore, the total number of graphs will be:-

$T =\tfrac{1}{2} \sum_{k=1}^{n-1} \tfrac{n!}{k(n-k)} = \tfrac{n!}{2} \sum_{k=1}^{n-1} \tfrac{1}{k(n-k)}$

 

 

• edited by
Answer:
Position:
Show:

Related questions

6 6 votes
1 1 answer
3.8k
3.8k views
Arjun asked Dec 18, 2018
3,837 views
Let $G=(V,E)$ be a directed graph with $n(\geq 2)$ vertices, including a special vertex $r$. Each edge $e \in E$ has a strictly positive edge weight $w(e)$. An arborescen...
7 7 votes
2 answers 2 answers
2.3k
2.3k views
Arjun asked Dec 18, 2018
2,325 views
A graph is $d$ – regular if every vertex has degree $d$. For a $d$ – regular graph on $n$ vertices, which of the following must be TRUE?$d$ divides $n$Both $d$ and $n$ ar...
3 3 votes
1 1 answer
1.3k
1.3k views
go_editor asked Dec 29, 2016
1,293 views
Let $G$ be an undirected graph. For a pair $(x, y)$ of distinct vertices of $G$, let $\mathsf{mincut}(x, y)$ be the least number of edges that should be delted from $G$ s...
8 8 votes
5 5 answers
5.2k
5.2k views
Arjun asked Dec 18, 2018
5,243 views
Consider the matrix$$A = \begin{bmatrix} \frac{1}{2} &\frac{1}{2} & 0\\ 0& \frac{3}{4} & \frac{1}{4}\\ 0& \frac{1}{4} & \frac{3}{4} \end{bmatrix}$$What is $\displaystyle ...