Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Problem with binary tree task

Status
Not open for further replies.

wcppcw

Newbie level 1
Joined
Apr 1, 2007
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,294
a problem of binary tree

i have met a problem:
if a binary tree has n leaf nodes, the maximal depth of the tree is n-1 and the minimal is ceil( log2(n) ), what is the mean depth of the binary tree?

i have got a formular conclusion:
avg_k=Σ(k*p_k)
where p_k means the probability of the depth equals to k,
p_k=c(2^k-1-i, n-1-i)/c(2^i, n-1)!

but it seems to be wrong!

who can help me!?
thx!
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top