splitting algorithm