Orbit extension method for finding unstable orbits