tidy up and syntax
added same_point check so that _is_downstream doesnt check if point x is downstream of point x. Also added comments