improve vector direction management