[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference rusure::math

Title:Mathematics at DEC
Moderator:RUSURE::EDP
Created:Mon Feb 03 1986
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2083
Total number of notes:14613

1517.0. "Recurrence Equation for Binary Trees" by BROKE::RAM (Ram Srinivasan @NUO, Nashua) Wed Nov 06 1991 10:45

    Does this recurrence equation have a closed-form solution:

		i = (n-1)
	       ----
	       \
    f(n) =     /    f(n - i) * f(i)      
	       ----  
	       i = 0

    f(1) = 1


    For the first few n, I got these values:

    f(2) = 2
    f(3) = 5 
    f(4) = 14
    f(5) = 42
    f(6) = 122
    f(7) = 419

    By the way, in this equation, f(n) represents the number of
    different binary trees that may be constructed with n nodes.

    
		        	       
T.RTitleUserPersonal
Name
DateLines
1517.1ALLVAX::JROTHI know he moves along the piersWed Nov 06 1991 11:187
    Sure does... look in Knuth for example.

		 (2n)!
	f(n) = ----------
		(n+1)! n!

    - Jim
1517.2Next question... BROKE::RAMRam Srinivasan @NUO, NashuaThu Nov 07 1991 18:0826

    OK, we have

	   f(2n+1) =      (4n+2)!
		       --------------
		       (2n+2)! (2n+1)!

	   s(2n+1) =    (2n)!
		      ----------
		      (n+1)! (n)!	       
     
    Here f(2n+1) represents the number of different binary trees that
    may be constructed with (2n + 1) nodes, and s(2n+1) represents the
    number of different strictly binary trees that may be constructed
    with (2n + 1) nodes.

    (A strictly binary tree is one in which every nonleaf node has
     nonempty left and right subtrees. A strictly binary tree having
     (2n+1) nodes will have (n+1) leaves and n nonleaf nodes.)

     What is	Lim	s(n)/f(n) ?
		n -> inf

     (My hunch is it will be 0) 
		        	       
1517.3Stirling's formula!HERON::BLOMBERGTrapped inside the universeFri Nov 08 1991 03:594
    
    It's a piece of cake using Stirling's formula for approximating n!.
    The quotient seems to converge to zero, but you better check for
    yourself.
1517.4ELIS::GARSONV+F = E+2Mon Nov 11 1991 04:3828
re .2

Let a(n) = s(2n+1)/f(2n+1)

          (2n)! (2n+2)! (2n+1)!
so a(n) = ---------------------
          (n+1)! n! (4n+2)!

Consider a(n+1)/a(n)

This is, after cancelling all the factorials from a(n),

    (2n+2)(2n+1) (2n+4)(2n+3) (2n+3)(2n+2)
    --------------------------------------
    (n+2) (n+1) (4n+6)(4n+5)(4n+4)(4n+3)

It is obvious (EFTR) that this converges to 2^6/4^4 as n->oo i.e. converges
to 1/4

It is a theorem (if memory serves) that

    If lim   a(n+1)/a(n) exists, call it r, and |r| < 1 THEN
       n->oo

    lim   a(n) exists and is 0.
    n->oo

This confirms the result in .-1 (which used Stirling's approximation).