Made small_tree vectors pointers, and calculated all yields in var_optimization