edited by
1,269 views
8 votes
8 votes

For a given $m$-ary tree, the relationship between leaf nodes and internal nodes is represented by the graph given below. What is the value of $'m'$? Take necessary approximations to nearest integer if required (Integer type)
GO2019-FLT1-13

edited by

2 Answers

Best answer
13 votes
13 votes
For an 'm-ary' tree the number of nodes n, internal nodes $i$ and leaf nodes $l$

below equation holds

$n=mi+1$..........(1)

and

$i+l=mi+1$.........(2)

The Y-axis represents the number of leaf nodes and the X-axis represents the number of internal nodes

Slope of line=$tan(75.964)=4$(Rounded to  nearest integer)

Equation of line $y=mx+c$

can be rewritten as

$l=4i+1$

Subsituting this in (2)

$i+4i+1=mi+1$

$5i=mi$

$m=5$

It's a 5-ary tree.
selected by
0 votes
0 votes

Answer :5

formula: L=i(n-1)+1   -----------(1)   // L: no. of leaf node , i: no. of internal node , n: n-ary tree (take n=2 for binary)

y=mx+c find the equation    , m=tan(75.964) = 4 (take integer part)

L=4i+1

solve both equations --- ---------(2)

4i+1 = i(n-1)+1

n-1 = 4

n=5

Answer:

Related questions

2 votes
2 votes
3 answers
1
Arjun asked Oct 10, 2016
590 views
Consider a complete graph on 10 vertices. Minimum no. of edge removals required to make a tree out of it will be ____
2 votes
2 votes
3 answers
2
Arjun asked Oct 10, 2016
1,088 views
A $2-3$ tree is a tree such thatall internal nodes have either 2 or 3 childrenall paths from root to the leaves have the same length.The maximum number of nodes of a 2-3 ...