Computer Science Homework Solutions
Problem
#138984

Mathematical Properties of Binary Trees

-----------

Show that if binary tree T is full at level i, then it is full at every level j smaller than i.

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

Show that the depth of the complete binary tree Tn for a general n is given by
D(Tn) = [log2n].

See attached for better format.

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

Using induction, give a direct proof of Proposition 4.2.3 without using the transformation to 2-trees.
Proposition 4.2.3
Suppose T is any 2-tree. Then the number of leaf nodes is 1 greater than the number of internal nodes of T; that is,
I(T) = L(T) – 1.
Equivalently, we have
n(T) = 2L(T) – 1.

----------

Prove Proposition 4.2.5
Proposition 4.2.5
Suppose T is a 2-tree. Then T is full at the second deepest level if and only if all the leaf nodes are contained in two levels (d – 1 and d).

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

Textbook: Algorithms: Sequential, Parallel, and Distributed by Kenneth Berman and Jerome Paul

Attached file(s):
Attachments
Show that the depth of the.doc  View File

Attachment Content Summary (Note: view attachment at the above link before purchasing. Actual attachment content may vary slightly from that shown below.)

Show that the depth of the.doc
Show that the depth of the complete binary tree Tn for a general n is
given by

D(Tn) = [log2n].
Solution
What is this?
By OTA - Overall OTA Rating
Purchase Cost Now
$2.19 CAD (was ~$39.90)
Included in Download
  • Plain text response
  • Attached file(s):
    • Binary Trees Solution.doc
$2.19 Instant Download
Add to Cart
Why you can trust BrainMass.com
  • Your Information is Secure
  • Best Online Academic Help Service
  • Students find real academic Success
Related Solutions
  • Spreadsheets versus Databases - Spreadsheets versus Databases, How do they compare? When would you want to use one over the other?
  • Application Development - Part I. Basic mathematical calculation 1. How are Integer and String data types used in an application? 2. Are Integers and Strings considered objects in VB? Elaborate. 3. Why is it inherited fro ...
  • C and Shell Programming Language - Can anyone help me explain the difference between a C and a SHELL programming language? Thank you so much!
  • Coding format for a real number - What coding format encodes a real number as a mantissa multiplied by a power (exponent) of two?
  • VB Basic Mathematical Calculation - Hello, I need some help on my assignment (I attached the actual assignment at the end of the answers). I did most of the parts but I still have problems writing some codes in Visual Basic. I need answ ...
Browse