set tree functions from lecture 2/13/2013