Mathematical Induction in binary trees

Click For Summary

Discussion Overview

The discussion revolves around the application of mathematical induction to prove a property of binary trees, specifically that every 2-tree with n internal nodes has n+1 external nodes. The scope includes theoretical reasoning and homework-related exploration of the inductive proof process.

Discussion Character

  • Homework-related
  • Mathematical reasoning
  • Debate/contested

Main Points Raised

  • One participant presents a proof structure using mathematical induction, stating a base case and an inductive hypothesis.
  • Another participant questions the validity of the inductive step, asking for reasoning behind the claim that k+1 internal nodes lead to k+3 external nodes.
  • A participant expresses confusion about the relationship between internal and external nodes, noting that adding an internal node seems to eliminate one external node but struggles to formalize this understanding.
  • Further inquiries are made about the effects on internal and external node counts when modifying external nodes by adding child nodes.
  • Participants discuss the net change in external nodes when an external node is converted into an internal node with two children, with some uncertainty about the correct count of external nodes after the modification.

Areas of Agreement / Disagreement

Participants express differing views on the relationship between internal and external nodes, with some uncertainty about the inductive reasoning and the net changes in node counts. The discussion remains unresolved regarding the correct application of the inductive step.

Contextual Notes

There are missing assumptions regarding the definitions of internal and external nodes, and the discussion does not resolve the mathematical steps needed to clarify the relationships between these nodes.

TheMathNoob
Messages
189
Reaction score
4

Homework Statement


Show that every 2-tree(Definition 3.2) with n internal nodes has n+1 external nodes

Homework Equations


A 2 tree is a tree which nodes have 2 children or no children.
Internal nodes are nodes which have two children
external nodes are leafs.

The Attempt at a Solution


Proof
base case
n=1
Internal nodes=1
external nodes=2

Inductive step

Inductive hypothesis: Let k internal nodes have k+1 external nodes
so k+1 internal nodes will have (k+1)+1 external nodes.
 
Physics news on Phys.org
TheMathNoob said:
so k+1 internal nodes will have (k+1)+1 external nodes.
What is your reason for thinking that that follows?
 
andrewkirk said:
What is your reason for thinking that that follows?
k internal nodes= k+1 external nodes. But I have been thinking and this doesn't make any sense.
1 internal node= 2 external nodes
so k+1 internal nodes= k+3 external nodes.

I know that when you add an internal node, you should eliminate one external node, but I don't know how to show that.
 
What happens to the internal and external node counts when you take an external node and give it two child nodes?
 
andrewkirk said:
What happens to the internal and external node counts when you take an external node and give it two child nodes?
+2 external nodes +1 internal nodes
 
Yes there are two new external nodes, but what is the net change in the number of external nodes?.
 
andrewkirk said:
Yes there are two new external nodes, but what is the net change in the number of external nodes?.
1?
 

Similar threads

Replies
1
Views
2K
  • · Replies 11 ·
Replies
11
Views
2K
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 10 ·
Replies
10
Views
2K
Replies
1
Views
2K
  • · Replies 15 ·
Replies
15
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
Replies
8
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K