Foundations of Phylogenetic Inference