retagged by
2,140 views
9 votes
9 votes

How many Topological Orderings possible from A to H?

retagged by

4 Answers

Best answer
12 votes
12 votes

For E, 4 cases are possible

Case 1: A_ _ E _ _ _ H
Here 2 for BC and 2 for DFG and DGF .....that is 2×2 =4 cases will be there

Case 2: A _ _ _ E _ _ H
Here 3! For B/C/D and 2 for FG/GF .....that is 3!×2=12 cases

Case 3:A _ _ _ _ E _ H
Here 4c2×2! For B/C and 2 case for F/G....that is 24 cases

 

How 4C2 * 2 ! * 2 ! ?
There are 4 places, with in that 4 places fix B and C at any two places, it is Permutation ==> 4C2 * 2 !,
now there are three places remaining in whole sequence, D should be first,remaining two places and 2 elements (G and H)
==> leads to permutation = 2!

By Multiplication rule, total = 4C2 * 2 ! * 2 !



Case 4: A _ _ _ _ _ E H
Here 5c2×2! For BC and 2 cases for DFG /DGF....that is 40 cases

Overall.    80 cases are there

edited by
10 votes
10 votes
B,C should come before E

D should come before F,G

so take B,C,E as a one type of objects (for maintaining order) and D,F and G as other type of objects.

Now B and C can come in any order, but before E so there are 2! ways and similar for F and G.

So No of ways B,C,E,D,F and G = $\frac{6!*2!*2!}{3!*3!}$ =80
0 votes
0 votes

Choose A

there will be 3 paths B,C,D but consider individually

----------------------------------------------------------------------------------------------------------------

Choose B first there will be 2 paths C and D but again  check individually

                   ----------------------------------------------------------------

                  Choose C first , there will be 2 path  D and E again check individually

                              -------------------------------------------------------

                                 Choose E first then D then there will be 2 path F and G lastly H ................................(i)

                              --------------------------------------------------------

                                 Choose D first there will be 3 path E,F,G----------------------------------------------(ii)

                --------------------------------------------------------------------------

                   Choose D first then C will be 3 paths---------------------------------------------------------------(iii)

                                                    (F,G) pair and again from last 2 pairs $2\times 2=4$-------------(iv)

                                    -----------------------------------------------------------------------------

               Similarly for $C$     , So, totally  $\left ( 2+3+3+4 \right )\times 2=24$ paths for B and C

                     ------------------------------------------------------------------------------------------

              Take D first

               there will be 4 paths but we need to break it

              ------------------------------------------------------------------------

                          take B or C and  also (B,C) pair first-------------------2 paths

                           Now will get 3 paths (E,F,G)----------------------------$\binom{3}{1}$ ways

                             Total $\binom{3}{1}\times 2=6$ ways

                 --------------------------------------------------------------------------

                           or take F first will get $2\times 2=4$ ways    [take (B,C) as a pair in $\binom{2}{1}$ ways and (E,G) as a pair]

                                                          (or) take $2\times 2=4$     [take (C,G) as a pair or (B,G as a pair)]

                                                     total $8$ ways

                  So, for D there is $6\times 8=48$ ways

Total 24+48=72 ways

edited by
0 votes
0 votes
A______H

In between A and H you can have these 4 orders

1. BCE

2. CBE

3. DFG

4. DGF

You will notice 1 and 2 are independent of 3 and 4 and hence can be executed in parallel.

Let's find concurrent ordering between 1-3,1-4,2-3,2-4

Topological ordering = No. of possible concurrent execution ( 1-3 +1-4 + 2-3 + 2-4 )

= $^6C_3$ + $^6C_3$ + $^6C_3 $ + $^6C_3 $ = $20 + 20 + 20 +20$ = $80$

Related questions

2 votes
2 votes
1 answer
1
Balaji Jegan asked Sep 7, 2018
1,086 views
How many Topological Orderings possible?
1 votes
1 votes
1 answer
2
Balaji Jegan asked Sep 7, 2018
509 views
How many Topological Orderings possible?
0 votes
0 votes
2 answers
3
Balaji Jegan asked Sep 7, 2018
860 views
How many Topological Orderings possible?
0 votes
0 votes
1 answer
4
Hira Thakur asked Nov 29, 2016
716 views
how many topological sort possible for n vetex(except the null graph)???