Fast power algorithm implemented