Approximate the function cos with series Taylor