Added experimental tree merge routine