Changed GpTree Evaluate Function to use helper function isFunction