0
$\begingroup$

I want to find the limit of the following recursive sequence when n tends to :

a[1] = 2;
a[n_] := a[n] = 1/2 (a[n - 1] + 1/a[n - 1])
Limit[a[n], n -> Infinity]

I don't want to use RSolve[{a[n + 1] == 1/2 (a[n] + 1/a[n]), a[1] == 2}, a[n], n] to find its expression and then find the limit, because some nonlinear recursive formulas can't find the general term expression. I want to use a more general method to find the limit of this recursive sequence.

$\endgroup$

3 Answers 3

3
$\begingroup$
AsymptoticRSolveValue[{{a[n] == (a[n - 1] + 1/a[n - 1])/2}, 
  a[1] == 2}, a[n], n -> Infinity]
$\endgroup$
4
$\begingroup$

Convergence occurs when a[n] is equal to a[n-1]. Call the unknown convergent value x, then you are looking for the value x such that x == 1/2 (x + 1/x). This can be found easily:

Solve[x == 1/2 (x + 1/x), x]
{{x -> -1}, {x -> 1}}

So there are two possible convergent values for your sequence. With a[1]=2, the values will all be positive so you can choose the x->1.

$\endgroup$
1
$\begingroup$

Using RSolve

Clear[a, n]

The general solution is

sol = RSolve[{a[1] == 2, a[n] == 1/2 (a[n - 1] + 1/a[n - 1])}, a[n], n][[1]] //
   Quiet

(* {a[n] -> Coth[2^(-1 + n) ArcCoth[2]]} *)

The limit is then

Limit[a[n] /. sol, n -> Infinity]

(* 1 *)

EDIT: Generalizing the problem

Clear[a, n, sol]

sol[x_] = RSolve[{a[1] == 2, a[n] == 1/2 (a[n - 1] + x/a[n - 1])}, a[n], 
    n][[1]] // Quiet

(* {a[n] -> Sqrt[x] Coth[2^(-1 + n) ArcCoth[2/Sqrt[x]]]} *)

lim[x_] = Limit[a[n] /. sol[x], n -> Infinity]

(* ConditionalExpression[Sqrt[x], 
 Sqrt[x] ∈ Reals && ArcCoth[2/Sqrt[x]] > 0] *)

For the original problem

lim[1]

(* 1 *)
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.