dynamic binary tree

HI,

I’M working on the mathematic functions
simplifator and I need to create a
dynamic binary tree for it. I need
function like remove(ind Id) or Replace(int Id) etc… anyone know how to do this??

Thnx.