Given a Binary Search Tree(BST) I would like to understand can absolute minimum difference between any two nodes of a BST is always between adjacent nodes. If Yes or No can we generalize it ? Assume there are atleast two nodes.
Here is my approach
Case 1 : Assume only positive real numbers
Assume the absolute difference (dMIN) between two adjacent nodes is not the Minimum This means there exists an absolute minimum difference which is smaller than dMIN by d. Say dMIN - d. In a BST, as we traverse left the value of the Node always decreases atleast by a smallest non zero value. Similiarly if we traverse to the right of a given node value of a node always increases atleast by smallest non-zero value This means the absolute min difference is always greater dMIN atleast by smallest non-zero value Which contradicts there exists a smaller absolute dMIN - d. Thus the absolute minimum difference is always absolute difference of two adjacent nodes
Case 2 - Assume the nodes of the BST comprises entire set of real numbers. There exists atleast one negative real number.
Assume there exists a min absolute difference(dMIN) two adjacent nodes. Since the value of the nodes comprises entire set of real numbers As we traverse to the left side of node the value of the node decreases atleast by the largest negative number. This can be continued until we reach leaf nodes from the root node. Thus the absolute min difference increases as we traverse from the root node to the left most leaf node. Thus absolute min difference of a pair of nodes is always between root node and leaf node.