Convergence =========== Consider the following mathematical succession: :math:`x_{0} = ...` :math:`x_{1} = ...` :math:`x_{n+1} = \frac{2*x_n+x_{n-1}}{3}` We know that it converges for some initial values :math:`x_{0}, x_{1}`. For example, for :math:`x_0 = 7.0` and :math:`x_1 = 3.0` it converges to :math:`4.0`. A function is required such that given two initial values and a tolerance, it approximates the convergence value of the sucession. Implement the following Python function in the :mod:`conv_mp21` module (file :file:`conv_mp21.py`): .. py:function:: conv_mp21(x_0, x_1, ne) such that **given** - ``x_0``, ``x_1`` two :class:`float` initial values for which our succession converges - ``ne``, a :class:`int` such that `1 <= ne < 10`. **returns** the convergence value with a :math:`1/10^{ne}` tolerance. To get the convergence value this must be rounded to ``ne`` decimals. Since the exact convergence value is not known, a way to determine that our approximation is good enough would be the :math:`abs(t_{i}-t_{i-1})/2.0 <= 1/10^{ne}`. The following doctests show some examples: .. literalinclude:: conv_mp21-test.txt :language: python3 :lines: 3- Doctests are available at the file :download:`conv_mp21-test.txt `.