Theory and Modern Applications

# Solvability of a one-parameter class of nonlinear second-order difference equations by invariants

## Abstract

By using an invariant we show in an original and quite unexpected way that a one-parameter class of nonlinear second-order difference equations is solvable in closed form, improving and theoretically explaining a recent result in the literature. As a motivation for this and also for general use of invariants for difference equations in solvability, we also demonstrate an application of the method of invariants on a very basic example of linear first-order difference equation with constant coefficients explaining a frequently confused detail. We also give a general hint how the method can be applied for the case of difference equations of any order.

## 1 Introduction

First, recall that $${\mathbb{N}}$$, $${\mathbb{N}}_{0}$$, $${\mathbb{Z}}$$, $${\mathbb{R}}$$, $${\mathbb{C}}$$ stand for natural, nonnegative integer, integer, real and complex numbers, respectively. If $$k_{1},k_{2} \in {\mathbb{Z}}$$, $$k_{1}\le k_{2}$$, the notation $$j=\overline{k_{1},k _{2}}$$ is the same as the following one: $$\{j\in {\mathbb{Z}}: k_{1} \le j\le k_{2}\}$$.

Solvability of difference equations is an old area. Many important eighteenth century results can be found in [1,2,3,4,5,6,7], where first serious results of analytic sort on solvability of difference equations were obtained.

First nontrivial difference equation which was solved in closed form was the following:

$$x_{n}+ax_{n-1}+bx_{n-2}=0$$

with $$a, b\in {\mathbb{R}}$$ [1,2,3].

For some influential nineteenth century presentations of the theory of difference equations, see, for example, [8,9,10]. Books of the twentieth century usually put aside the solvability of the equations and paid more attention to some other topics; nevertheless, they contain quite a lot information on solvability (see, for example, [11,12,13,14,15,16,17,18]). For some interesting historical details and comments, see our recent paper .

Use of computers, among other things, enhanced some interest in solvable difference equations, as well as in systems of difference equations. However, a sheer use of them without use of any serious mathematical theory causes some problems (some of the problems were explained, for example, in [20,21,22,23,24]). Knowing explicit formulas for solutions to difference equations and systems has a great applicable potential (see, for example, [11,12,13,14, 25,26,27,28,29,30,31,32,33,34,35] and the related references therein).

Many recent papers on solvability of difference equations and systems use various changes of variables which transform them to well-known solvable ones, usually linear, which are the basic classes of practically or theoretically solvable difference equations. For example, in [20, 21, 36,37,38,39,40] some changes of variables, which in a way can be characterized as standard, were used, whereas some more complex changes of variables, as well as more complex methods, can be found, for example, in [41,42,43,44,45] where some product-type systems of difference equations were considered (see also the related references therein).

One of the most frequent linear difference equations appearing in solvability is the linear first-order one, that is,

\begin{aligned} x_{n}=a_{n}x_{n-1}+b_{n}, \quad n\in { \mathbb{N}}_{0}, \end{aligned}
(1)

where $$(a_{n})_{n\in {\mathbb{N}}_{0}}$$, $$(b_{n})_{n\in {\mathbb{N}} _{0}}$$, and $$x_{-1}$$ are real or complex. Some methods for solving equation (1) can be found, for example, in [11, 12, 15, 16]. Our investigations so far show that equation (1) essentially occupies the central position in the theory of solvability of difference equations.

A closely related topic to the solvability of difference equations and systems is finding invariants for the equations and systems, which is not so popular as the former one. Nevertheless, the topic is no doubt useful in studying of the equations and is also interesting.

For a function $$I:{\mathbb{R}}^{l}\ (\text{or } {\mathbb{C}}^{l}) \to {\mathbb{R}}\ (\text{or } {\mathbb{C}})$$, it is said that it is an invariant for a difference equation if

\begin{aligned} I(x_{n},x_{n+1},\ldots ,x_{n+l-1})=c, \end{aligned}
(2)

for some constant c and every solution to the equation, on its domain.

Invariants are usually used in establishing some properties of solutions to an equation. Frequently they are useful in establishing the boundedness of solutions to a difference equation or a system of difference equations. Many interesting results on the topic can be found in the following papers by Papaschinopoulos and Schinas: [46,47,48,49,50,51] (see also the references therein). However, in some cases they can lead to finding solutions to some difference equations. Some basic examples of such equations will be given in the next section.

In  the following nonlinear second-order difference equation has been recently investigated:

\begin{aligned} x_{n+1}=x_{n}+\frac{x_{n}}{x_{n}-x_{n-1}} \end{aligned}
(3)

for $$n\in {\mathbb{N}}_{0}$$, where by a simple inductive argument some formulas for solutions to the difference equation are verified. However, no theory or explanations how the formulas are obtained appear there.

Our main aim is to explain formulas obtained in . We will also extend them for the case of the following equation:

\begin{aligned} x_{n+1}=x_{n}\frac{x_{n}-x_{n-1}+d}{x_{n}-x_{n-1}},\quad n\in {\mathbb{N}} _{0}, \end{aligned}
(4)

where $$d, x_{-1}, x_{0}\in {\mathbb{C}}$$. This will be done in a bit unexpected way, by using an invariant of equation (4).

For a solution $$(x_{n})$$ to a difference equation, we say that it is well-defined if it has defined finite value for each n which belongs to the domain of the difference equation.

## 2 An example of using invariants and a hint how to use them

Before we present a proof of our main result, in this section we present, as a motivation and for benefit of the reader, an application of the method of invariants on a very basic example of linear first-order difference equation with constant coefficients explaining a frequently confusing detail. We also give a general hint how to use the method of invariants for the case of difference equations of any order.

### 2.1 Linear first-order difference equation with constant coefficients

Here we consider difference equation (1) when the sequences $$(a_{n})_{n\in {\mathbb{N}}_{0}}$$ and $$(b_{n})_{n\in {\mathbb{N}}_{0}}$$ are constant, that is, the linear first-order difference equation with constant coefficients

\begin{aligned} x_{n}=ax_{n-1}+b, \quad n\in {\mathbb{N}}_{0}, \end{aligned}
(5)

where $$a, b, x_{-1}\in {\mathbb{C}}$$, $$a\ne 0$$.

Besides the three standard methods for solving difference equation (1) which correspond to the three methods for solving the linear first-order differential equation (see, e.g., ), the special choice of sequences $$(a_{n})_{n\in {\mathbb{N}}_{0}}$$ and $$(b_{n})_{n \in {\mathbb{N}}_{0}}$$ enables finding general solution to the equation also in some other ways. One of the ways is by use of an invariant. General solution to difference equation (5) in the nontrivial case when $$a\ne 1$$ (formula (16)) was found for the first time by Lagrange in  (see also ).

Now we demonstrate how the method of invariants can be used for solving equation (5) in very detail, which will help to understand the method better. The method is essentially known, but usually scientist are not aware that they use an invariant and do not pay attention to some details.

Let

\begin{aligned} I_{1}(x_{n-1},x_{n}):=x_{n}-ax_{n-1} \end{aligned}
(6)

for $$n\in {\mathbb{N}}_{0}$$.

Since the following obviously holds

\begin{aligned} I_{1}(x_{n-1},x_{n})=b, \quad n\in { \mathbb{N}}_{0}, \end{aligned}
(7)

(6) is an invariant for equation (5).

An obvious consequence of relation (7) is

\begin{aligned} I_{1}(x_{n},x_{n+1})=I_{1}(x_{n-1},x_{n}) \end{aligned}
(8)

for $$n\in {\mathbb{N}}_{0}$$.

Now note that (8) can be written in the following form:

\begin{aligned} x_{n}-(a+1)x_{n-1}+ax_{n-2}=0, \quad n\in { \mathbb{N}}, \end{aligned}
(9)

which is a homogeneous linear second-order difference equation with constant coefficients, so solvable.

Since in the case $$a=1$$ equation (5) is easily solved, from now on we will assume that $$a\ne 1$$.

The characteristic polynomial associated with equation (9) is

$$p_{2}(\lambda )=\lambda ^{2}-(a+1)\lambda +a,$$

from which it follows that

$$\lambda _{1}=1 \quad\text{and} \quad \lambda _{2}=a$$

are the characteristic zeros.

Hence, general solution to equation (9) is

\begin{aligned} x_{n}=c_{1}+c_{2}a^{n}, \quad n\ge -1, \end{aligned}
(10)

where $$c_{1}$$ and $$c_{2}$$ are arbitrary constants.

To find $$c_{1}$$ and $$c_{2}$$, it is necessary to solve the linear system

\begin{aligned} &c_{1}+\frac{c_{2}}{a}=x_{-1}, \end{aligned}
(11)
\begin{aligned} &c_{1}+c_{2}=x_{0}, \end{aligned}
(12)

from which it follows that

\begin{aligned} c_{1}=\frac{ax_{-1}-x_{0}}{a-1} \quad \text{and}\quad c_{2}=a \frac{x _{0}-x_{-1}}{a-1}. \end{aligned}
(13)

Using (13) in (10), we have

\begin{aligned} x_{n}=\frac{ax_{-1}-x_{0}+(x_{0}-x_{-1})a^{n+1}}{a-1}, \end{aligned}
(14)

which is general solution to equation (9) in terms of parameter a and the initial values $$x_{-1}$$ and $$x_{0}$$.

Now note that from (5) we have

\begin{aligned} x_{0}=ax_{-1}+b. \end{aligned}
(15)

By using (15) in (14), we obtain

\begin{aligned} x_{n}=\frac{((a-1)x_{-1}+b)a^{n+1}-b}{a-1}, \quad n\in {\mathbb{N}} _{0}. \end{aligned}
(16)

The above procedure, although very simple, has many steps. So, at first sight, it is not quite clear what formula (16) represents, although it is expected that it is general solution to difference equation (5), which is easily verified by a simple inductive argument.

The confusion is found in the fact that a relation of the form (8) is a consequence of any relation of the form (7). However, from (8), in general, we cannot conclude that relation of the form (7) holds. Namely, from (8) we have

\begin{aligned} I_{1}(x_{n-1},x_{n})=I_{1}(x_{-1},x_{0}) \end{aligned}
(17)

for $$n\in {\mathbb{N}}_{0}$$.

However, the catch is that in this case $$I_{1}(x_{-1},x_{0})$$ is not only equal to b, but the value of $$x_{0}$$ is not arbitrary (it is specified, see relation (15)).

So, the above procedure is not one-directional, but, in fact, all the steps are equivalent. More precisely, the initial value problem consisting of equation (5) and initial value $$x_{-1}$$ is equivalent to the initial value problem consisting of equation (9) and initial values $$x_{-1}$$ and the one given in (15).

### Remark 1

The above detailed analysis shows that during applications of the method of invariants for difference equations and systems, it should be tried to transfer a problem to equivalent one, if possible, or, at least, as long as it is possible. Nevertheless, it is suggested that the final formulas are always checked by the method of induction for the case (if a difference equation is complicated, its general solution can be very complicated as it was the case in several recent papers of ours [20, 40, 41, 43, 44]; we have also found several papers with wrong formulas for general solutions to difference equations; see, for example, our comment in ).

### Remark 2

Obvious consequence of relation (7) appearing in (8) is usually used for the corresponding invariants for difference equations of any order. Namely, if (2) holds, then the following relation

\begin{aligned} I(x_{n},x_{n+1},\ldots ,x_{n+l-1})=I(x_{n-1},x_{n}, \ldots ,x_{n+l-2}) \end{aligned}
(18)

also holds on the domain of the corresponding difference equation, where l is a fixed natural number.

Of course, if we know invariants for a difference equation or for a system of difference equations, then compositions of the invariants with any other function are also invariants, but the catch is to choose the operative ones, that is, the ones from which we can conclude something on solutions of the difference equation, which in our case refers to finding a closed-form formula for general solution to the difference equation or system.

### Remark 3

The above argument can be used to any linear difference equation of the following form

\begin{aligned} x_{n}=a_{k}x_{n-1}+\cdots +a_{1}x_{n-k}+b, \quad n\in {\mathbb{N}}_{0}, \end{aligned}
(19)

where coefficients $$a_{j}$$, $$j=\overline{1,k}$$, and b are complex numbers such that $$a_{1}\ne 0$$, that is, to nonhomogeneous linear difference equations with constant coefficients whose nonhomogeneous part is constant.

Namely, let

\begin{aligned} I_{2}(x_{n-k},x_{n-k+1},\ldots ,x_{n})=x_{n}-a_{k}x_{n-1}- \cdots -a _{1}x_{n-k} \end{aligned}
(20)

for $$n\in {\mathbb{N}}_{0}$$.

Since it obviously holds

\begin{aligned} I_{2}(x_{n-k},x_{n-k+1},\ldots ,x_{n})=b, \quad n\in {\mathbb{N}}_{0}, \end{aligned}
(21)

(20) is an invariant for equation (19).

An obvious consequence of relation (21) is

\begin{aligned} I_{2}(x_{n-k},x_{n-k+1},\ldots ,x_{n})=I_{2}(x_{n-k+1},x_{n-k+2}, \ldots ,x_{n+1}) \end{aligned}
(22)

for $$n\in {\mathbb{N}}_{0}$$, which can be written in the following form:

\begin{aligned} x_{n+1}-(a_{k}+1)x_{n}-(a_{k-1}-a_{k})x_{n-1}- \cdots -(a_{1}-a_{2})x _{n-k+1}+a_{1}x_{n}=0 \end{aligned}
(23)

for $$n\in {\mathbb{N}}_{0}$$.

Now note that difference equation (23) is homogeneous linear with constant coefficients, but of order $$k+1$$, which is solvable, at least theoretically (equations of order five and more need not be practically solvable due to the Abel–Ruffini theorem which says that polynomials of order five or more need not be solvable by radicals ).

### Remark 4

Let us also note that there is a custom to show solvability of linear second-order difference equation with constant coefficients prior to showing the solvability of equation (5). It is also interesting to note that de Moivre essentially knew to solve equation (9) already at the beginning of the eighteenth century, but the solvability of equation (5) was discovered several decades later by Lagrange.

## 3 Main result

Here we show that general solution to difference equation (4) can be found by using the method of invariants, which, at first sight, is a bit unexpected result. The real background for the fact has not been thoroughly investigated yet, but let us say that the idea of getting solution in this way essentially stems from the fact that some difference equations containing quadratic terms have invariants of the form in (20) for fixed $$k\in {\mathbb{N}}$$.

Before we start with our analysis of solvability of equation (4) by using the method of invariants, note that if $$(x_{n})_{n\ge -1}$$ is an arbitrary well-defined solution to the equation, then it must be

\begin{aligned} x_{n}-x_{n-1}\ne 0 \end{aligned}
(24)

for every $$n\in {\mathbb{N}}_{0}$$, since otherwise if, for some $$n_{0}\in {\mathbb{N}}_{0}$$, relation (24) does not hold, then the term $$x_{n_{0}+1}$$ is not defined.

Note also that if $$d=0$$, then equation (4) is reduced to the following difference equation:

\begin{aligned} x_{n+1}=x_{n}\frac{x_{n}-x_{n-1}}{x_{n}-x_{n-1}} \end{aligned}
(25)

for $$n\in {\mathbb{N}}_{0}$$.

From (25) it follows that, if $$x_{0}\ne x_{-1}$$, then $$x_{1}=x_{0}$$, from which we have that $$x_{2}$$ is not defined. This implies that none solution to equation (25) is well-defined.

Hence, from now on we will assume that $$d\ne 0$$.

### 3.1 Solving equation (4) by using an invariant

Equation (4) can be written in the following form:

\begin{aligned} x_{n+1}=x_{n}+\frac{dx_{n}}{x_{n}-x_{n-1}}, \quad n\in {\mathbb{N}} _{0}, \end{aligned}
(26)

from which it follows that for every well-defined solution $$(x_{n})_{n \ge -1}$$ to equation (4) we have

\begin{aligned} (x_{n+1}-x_{n}) (x_{n}-x_{n-1})=dx_{n} \end{aligned}
(27)

for every $$n\in {\mathbb{N}}_{0}$$.

At this point it should be noted that equations (26) and (27) are not equivalent, since, for example, $$x_{n}=0$$, $$n\ge -1$$, is a solution to equation (27), while it is not a solution to equation (26).

Let

\begin{aligned} I(x_{n-1},x_{n},x_{n+1}):=(x_{n+1}-x_{n}) (x_{n}-x_{n-1})-dx_{n},\quad n\in { \mathbb{N}}_{0}. \end{aligned}
(28)

Then from (27) we see that

\begin{aligned} I(x_{n-1},x_{n},x_{n+1})=0,\quad n\in { \mathbb{N}}_{0}, \end{aligned}
(29)

that is, it is an invariant for equation (4).

Now we use the idea which is explained in detail in the previous section (see also Remark 2).

Namely, from (29), we have

\begin{aligned} I(x_{n-1},x_{n},x_{n+1})=I(x_{n-2},x_{n-1},x_{n}), \quad n\in {\mathbb{N}}, \end{aligned}
(30)

that is,

\begin{aligned} (x_{n+1}-x_{n}) (x_{n}-x_{n-1})-dx_{n}=(x_{n}-x_{n-1}) (x_{n-1}-x_{n-2})-dx _{n-1} \end{aligned}
(31)

for every $$n\in {\mathbb{N}}$$.

From (31) it easily follows that

\begin{aligned} (x_{n}-x_{n-1}) (x_{n+1}-x_{n}-x_{n-1}+x_{n-2}-d) \end{aligned}
(32)

for $$n\in {\mathbb{N}}$$.

From (24) and (32), it follows that every well-defined solution to equation (4) satisfies the following difference equation:

\begin{aligned} x_{n+1}-x_{n}-x_{n-1}+x_{n-2}=d \end{aligned}
(33)

for $$n\in {\mathbb{N}}$$.

The characteristic polynomial associated with equation (33) is

\begin{aligned} p_{3}(\lambda )=\lambda ^{3}-\lambda ^{2}-\lambda +1=(\lambda -1) \bigl( \lambda ^{2}-1\bigr), \end{aligned}
(34)

from which it follows that the characteristic roots are

\begin{aligned} \lambda _{1}=\lambda _{2}=1, \qquad \lambda _{3}=-1. \end{aligned}
(35)

Hence, the general solution to the corresponding linear homogeneous difference equation

$$x_{n+1}-x_{n}-x_{n-1}+x_{n-2}=0$$

is given by

\begin{aligned} x_{n}^{h}=c_{1}n+c_{2}+c_{3}(-1)^{n} \end{aligned}
(36)

for $$n\ge -1$$.

Bearing in mind that 1 is a double zero of the characteristic polynomial (34), a particular solution to equation (33) is searched for in the following form:

\begin{aligned} x_{n}^{p}=cn^{2} \end{aligned}
(37)

for $$n\ge -1$$.

Substituting (37) in equation (33) we have that it must be

$$c\bigl((n+1)^{2}-n^{2}-(n-1)^{2}+(n-2)^{2} \bigr)=d,$$

so that

\begin{aligned} c=\frac{d}{4}. \end{aligned}
(38)

From (37) and (38) it follows that

\begin{aligned} x_{n}^{p}=\frac{d}{4}n^{2} \end{aligned}
(39)

for $$n\ge -1$$.

From (36), (39) and by a well-known theorem on the structure of solutions to nonhomogeneous linear difference equations (see, e.g., [12, 14,15,16]), we have that the general solution to equation (33) is given by

\begin{aligned} x_{n}=c_{1}n+c_{2}+c_{3}(-1)^{n}+ \frac{d}{4}n^{2} \end{aligned}
(40)

for $$n\ge -1$$.

Now we find constants $$c_{1}$$, $$c_{2}$$, and $$c_{3}$$ in terms of the initial values $$x_{-1}$$ and $$x_{0}$$. Before this, note that from (4) with $$n=0$$ it follows that

\begin{aligned} x_{1}=x_{0}\frac{x_{0}-x_{-1}+d}{x_{0}-x_{-1}}. \end{aligned}
(41)

Using (40) for $$n=-1,0,1$$, respectively, we get

\begin{aligned} &{-} c_{1}+c_{2}-c_{3}=x_{-1}- \frac{d}{4}, \\ & c_{2}+c_{3}=x_{0}, \\ &c_{1}+c_{2}-c_{3}=x_{1}- \frac{d}{4}. \end{aligned}
(42)

By adding the first and third equation of system (42) and dividing such obtained equality by 2, we get

\begin{aligned} c_{2}-c_{3}=\frac{x_{-1}+x_{1}}{2}-\frac{d}{4}. \end{aligned}
(43)

From the second equation in (42) and (43), we similarly get

\begin{aligned} &c_{2} =\frac{1}{2} \biggl(x_{0}+\frac{x_{-1}+x_{1}}{2}- \frac{d}{4} \biggr), \end{aligned}
(44)
\begin{aligned} &c_{3} =\frac{1}{2} \biggl(x_{0}-\frac{x_{-1}+x_{1}}{2}+ \frac{d}{4} \biggr), \end{aligned}
(45)

whereas from the first equation in (42) and (43), we obtain

\begin{aligned} c_{1}=\frac{x_{-1}+x_{1}}{2}-\frac{d}{4}-x_{-1}+ \frac{d}{4}=\frac{x _{1}-x_{-1}}{2}. \end{aligned}
(46)

Using (44)–(46) in (40), we have

\begin{aligned} x_{n}=\frac{x_{1}-x_{-1}}{2}n+\frac{4x_{0}+2x_{-1}+2x_{1}-d}{8}+\frac{4x _{0}-2x_{-1}-2x_{1}+d}{8}(-1)^{n}+ \frac{d}{4}n^{2} \end{aligned}
(47)

for $$n\ge -1$$.

Finally, using (41) in (47), after some calculation we obtain

\begin{aligned} x_{n}={} & \biggl(x_{0}-x_{-1}+\frac{dx_{0}}{x_{0}-x_{-1}} \biggr) \frac{n}{2}+\frac{1}{8} \biggl(6x_{0}+2x_{-1}+ \frac{2\,dx_{0}}{x_{0}-x _{-1}}-d \biggr) \\ &{}+ \biggl(2x_{0}-2x_{-1}-\frac{2\,dx_{0}}{x_{0}-x_{-1}}+d \biggr) \frac{(-1)^{n}}{8}+\frac{d}{4}n^{2} \end{aligned}
(48)

for $$n\ge -1$$.

The sequence defined in (48) is a candidate for general solution to equation (4). However, since relations (29) and (30), in general, need not be equivalent, and as we have already noticed equations (26) and (27) are not equivalent, we have to check that the sequence is a solution to equation (4).

Let

\begin{aligned} \widetilde{x}_{n}:={}& \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x_{0}-x_{-1}} \biggr) \frac{n}{2}+\frac{1}{8} \biggl(6x_{0}+2x_{-1}+\frac{2\,dx_{0}}{x_{0}-x _{-1}}-d \biggr) \\ &{}+ \biggl(2x_{0}-2x_{-1}-\frac{2\,dx_{0}}{x_{0}-x_{-1}}+d \biggr) \frac{(-1)^{n}}{8}+\frac{d}{4}n^{2} \end{aligned}
(49)

for $$n\ge -1$$.

A simple calculation shows that, for $$n=-1$$ and $$n=0$$, we have

\begin{aligned} \widetilde{x}_{-1}= {}&{-}\frac{1}{2} \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x _{0}-x_{-1}} \biggr)+\frac{1}{8} \biggl(6x_{0}+2x_{-1}+ \frac{2\,dx_{0}}{x _{0}-x_{-1}}-d \biggr) \\ &{}-\frac{1}{8} \biggl(2x_{0}-2x_{-1}- \frac{2\,dx_{0}}{x_{0}-x_{-1}}+d \biggr)+ \frac{d}{4}=x_{-1} \end{aligned}
(50)

and

\begin{aligned} \widetilde{x}_{0}={}& \frac{1}{8} \biggl(6x_{0}+2x_{-1}+ \frac{2\,dx_{0}}{x _{0}-x_{-1}}-d \biggr) \\ &{}+\frac{1}{8} \biggl(2x_{0}-2x_{-1}- \frac{2\,dx_{0}}{x _{0}-x_{-1}}+d \biggr)=x_{0}. \end{aligned}
(51)

From (49) we have

\begin{aligned} \widetilde{x}_{2n-1}:={} & \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x_{0}-x_{-1}} \biggr) \biggl(n-\frac{1}{2} \biggr)+ \frac{1}{8} \biggl(6x_{0}+2x_{-1}+\frac{2\,dx_{0}}{x_{0}-x_{-1}}-d \biggr) \\ &{}-\frac{1}{8} \biggl(2x_{0}-2x_{-1}- \frac{2\,dx_{0}}{x_{0}-x_{-1}}+d \biggr)+d \biggl(n-\frac{1}{2} \biggr)^{2} \\ = {}&x_{-1}+n \biggl(x_{0}-x_{-1}+ \frac{dx_{-1}}{x_{0}-x_{-1}} \biggr)+dn ^{2} \end{aligned}
(52)

and

\begin{aligned} \widetilde{x}_{2n}:= {}& \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x_{0}-x_{-1}} \biggr)n+ \frac{1}{8} \biggl(6x_{0}+2x_{-1}+ \frac{2\,dx_{0}}{x_{0}-x_{-1}}-d \biggr) \\ &{}+\frac{1}{8} \biggl(2x_{0}-2x_{-1}- \frac{2\,dx_{0}}{x_{0}-x_{-1}}+d \biggr)+dn ^{2} \\ = {}&x_{0}+n \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x_{0}-x_{-1}} \biggr)+dn ^{2} \end{aligned}
(53)

for $$n\ge -1$$.

Using (52) and (53), we have

\begin{aligned} &\widetilde{x}_{2n} \biggl(1+\frac{d}{\widetilde{x}_{2n}-\widetilde{x} _{2n-1}} \biggr) \\ &\quad = \biggl(x_{0}+n \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x_{0}-x_{-1}} \biggr)+dn ^{2} \biggr) \biggl(1+\frac{d}{x_{0}-x_{-1}+nd} \biggr) \\ &\quad = (x_{0}-x_{-1}+nd) \biggl(\frac{x_{0}}{x_{0}-x_{-1}}+n \biggr) \biggl(\frac{x _{0}-x_{-1}+(n+1)\,d}{x_{0}-x_{-1}+nd} \biggr) \\ &\quad = \biggl(\frac{x_{0}}{x_{0}-x_{-1}}+n \biggr) \bigl(x_{0}-x_{-1}+(n+1)d \bigr) \\ &\quad= x_{-1}+(n+1) \biggl(x_{0}-x_{-1}+ \frac{dx_{-1}}{x_{0}-x_{-1}} \biggr)+d(n+1)^{2} \\ &\quad = \widetilde{x}_{2n+1}. \end{aligned}
(54)

Using (53) and (54), we have

\begin{aligned} &\widetilde{x}_{2n+1} \biggl(1+\frac{d}{\widetilde{x}_{2n+1}- \widetilde{x}_{2n}} \biggr) \\ &\quad = \biggl(x_{-1}+(n+1) \biggl(x_{0}-x_{-1}+ \frac{dx_{-1}}{x_{0}-x_{-1}} \biggr)+d(n+1)^{2} \biggr) \biggl(1+ \frac{d}{\frac{dx _{-1}}{x_{0}-x_{-1}}+(n+1)d} \biggr) \\ &\quad = \biggl(\frac{x_{-1}}{x_{0}-x_{-1}}+n+1 \biggr) \bigl(x_{0}-x_{-1}+d(n+1) \bigr) \biggl(\frac{\frac{x_{-1}}{x_{0}-x_{-1}}+n+2}{\frac{x_{-1}}{x_{0}-x _{-1}}+n+1} \biggr) \\ &\quad = \bigl(x_{0}-x_{-1}+d(n+1)\bigr) \biggl( \frac{x_{-1}}{x_{0}-x_{-1}}+n+2 \biggr) \\ &\quad = x_{0}+(n+1) \biggl(x_{0}-x_{-1}+ \frac{dx_{0}}{x_{0}-x_{-1}} \biggr)+d(n+1)^{2} \\ &\quad = \widetilde{x}_{2n+2}. \end{aligned}
(55)

From (54) and (55) it follows that the sequence $$(\widetilde{x}_{n})_{n\ge -1}$$ is a solution to equation (4), which by (50) matches with the solution with initial values $$x_{-1}$$ and $$x_{0}$$. Hence, formula (48) really presents general solution to equation (4).

From all the above mentioned results it is easy to see that the following result holds.

### Theorem 1

Consider difference equation (4). Then the following statements hold.

1. (a)

A solution $$(x_{n})_{n\ge -1}$$ of difference equation (4) is well-defined if and only if $$x_{-1}\ne x_{0}$$.

2. (b)

If $$d=0$$, then none solution to difference equation (4) is well-defined.

3. (c)

If $$d\ne 0$$, then the general solution to equation (4) is given by the following formula:

\begin{aligned} x_{n}= {}& \biggl(x_{0}-x_{-1}+\frac{dx_{0}}{x_{0}-x_{-1}} \biggr) \frac{n}{2}+\frac{1}{8} \biggl(6x_{0}+2x_{-1}+ \frac{2\,dx_{0}}{x_{0}-x _{-1}}-d \biggr) \\ &{}+ \biggl(2x_{0}-2x_{-1}-\frac{2\,dx_{0}}{x_{0}-x_{-1}}+d \biggr) \frac{(-1)^{n}}{8}+\frac{d}{4}n^{2}\quad \textit{for }n\ge -1. \end{aligned}

## References

1. de Moivre, A.: The Doctrine of Chances. London (1718)

2. de Moivre, A.: Miscellanea analytica de seriebus et quadraturis. Londini (1730) (in Latin)

3. de Moivre, A.: The Doctrine of Chances, 3rd edn. London (1756)

4. Eulero, L.: Introductio in Analysin Infinitorum, Tomus Primus. Lausannae (1748) (in Latin)

5. Lagrange, J.-L.: Sur l’intégration d’une équation différentielle à différences finies, qui contient la théorie des suites récurrentes, Miscellanea Taurinensia, t. I, (1759) 33–42 (Lagrange OEuvres, I, 23–36, 1867) (in French)

6. Lagrange, J.-L.: OEuvres, t. II. Gauthier-Villars, Paris (1868) (in French)

7. Laplace, P.S.: Recherches sur l’intégration des équations différentielles aux différences finies et sur leur usage dans la théorie des hasards, Mémoires de l’ Académie Royale des Sciences de Paris 1773, t. VII (1776) (Laplace OEuvres, VIII, 69–197, 1891) (in French)

8. Boole, G.: A Treatsie on the Calculus of Finite Differences, 3rd edn. Macmillan & Co., London (1880)

9. Markoff, A.A.: Differenzenrechnung. Teubner, Leipzig (1896) (in German)

10. Markov, A.A.: Ischislenie Konechnykh Raznostey, 2nd edn. Matezis, Odessa (1910) (in Russian)

11. Agarwal, R.P.: Difference Equations and Inequalities: Theory, Methods, and Applications, 2nd edn. Dekker, New York (2000)

12. Fort, T.: Finite Differences and Difference Equations in the Real Domain. Oxford Univ. Press, London (1948)

13. Jordan, C.: Calculus of Finite Differences. Chelsea, New York (1956)

14. Levy, H., Lessman, F.: Finite Difference Equations. Dover, New York (1992)

15. Milne-Thomson, L.M.: The Calculus of Finite Differences. Macmillan & Co., London (1933)

16. Mitrinović, D.S., Kečkić, J.D.: Methods for Calculating Finite Sums. Naučna Knjiga, Beograd (1984) (in Serbian)

17. Nörlund, N.E.: Vorlesungen Über Differenzenrechnung. Springer, Berlin (1924) (in German)

18. Richardson, C.H.: An Introduction to the Calculus of Finite Differences. Van Nostrand, Toronto (1954)

19. Stević, S.: Representations of solutions to linear and bilinear difference equations and systems of bilinear difference equations. Adv. Differ. Equ. 2018, Article ID 474 (2018)

20. Stević, S., Diblik, J., Iričanin, B., Šmarda, Z.: On some solvable difference equations and systems of difference equations. Abstr. Appl. Anal. 2012, Article ID 541761 (2012)

21. Stević, S., Diblik, J., Iričanin, B., Šmarda, Z.: Solvability of nonlinear difference equations of fourth order. Electron. J. Differ. Equ. 2014, Article ID 264 (2014)

22. Stević, S., Iričanin, B., Kosmala, W., Šmarda, Z.: Note on the bilinear difference equation with a delay. Math. Methods Appl. Sci. 41, 9349–9360 (2018)

23. Stević, S., Iričanin, B., Kosmala, W., Šmarda, Z.: Representation of solutions of a solvable nonlinear difference equation of second order. Electron. J. Qual. Theory Differ. Equ. 2018, Article ID 95 (2018)

24. Stević, S., Iričanin, B., Šmarda, Z.: On a symmetric bilinear system of difference equations. Appl. Math. Lett. 89, 15–21 (2019)

25. Agarwal, R.P., Popenda, J.: Periodic solutions of first order linear difference equations. Math. Comput. Model. 22(1), 11–19 (1995)

26. Berezansky, L., Braverman, E.: On impulsive Beverton–Holt difference equations and their applications. J. Differ. Equ. Appl. 10(9), 851–868 (2004)

27. Iričanin, B., Stević, S.: Eventually constant solutions of a rational difference equation. Appl. Math. Comput. 215, 854–856 (2009)

28. Mitrinović, D.S.: Mathematical Induction, Binomial Formula, Combinatorics. Nostrand Knjiga, Beograd (1980) (in Serbian)

29. Mitrinović, D.S.: Matrices and Determinants. Naučna Knjiga, Beograd (1989) (in Serbian)

30. Mitrinović, D.S., Adamović, D.D.: Sequences and Series. Naučna Knjiga, Beograd (1980) (in Serbian)

31. Proskuryakov, I.V.: Problems in Linear Algebra. Nauka, Moscow (1984) (in Russian)

32. Riordan, J.: Combinatorial Identities. Wiley, New York (1968)

33. Stević, S.: Bounded and periodic solutions to the linear first-order difference equation on the integer domain. Adv. Differ. Equ. 2017, Article ID 283 (2017)

34. Stević, S.: Bounded solutions to nonhomogeneous linear second-order difference equations. Symmetry 9, Article ID 227 (2017)

35. Stević, S.: Existence of a unique bounded solution to a linear second order difference equation and the linear first order difference equation. Adv. Differ. Equ. 2017, Article ID 169 (2017)

36. Berg, L., Stević, S.: On some systems of difference equations. Appl. Math. Comput. 218, 1713–1718 (2011)

37. Papaschinopoulos, G., Stefanidou, G.: Asymptotic behavior of the solutions of a class of rational difference equations. Int. J. Difference Equ. 5(2), 233–249 (2010)

38. Stević, S.: On the difference equation $$x_{n}=x_{n-2}/(b_{n}+c_{n}x _{n-1}x_{n-2})$$. Appl. Math. Comput. 218, 4507–4513 (2011)

39. Stević, S.: On the difference equation $$x_{n}=x_{n-k}/(b+cx_{n-1} \cdots x_{n-k})$$. Appl. Math. Comput. 218, 6291–6296 (2012)

40. Stević, S.: On the system of difference equations $$x_{n}=c_{n}y _{n-3}/(a_{n}+b_{n}y_{n-1}x_{n-2}y_{n-3})$$, $$y_{n}=\gamma _{n} x_{n-3}/( \alpha _{n}+\beta _{n} x_{n-1}y_{n-2}x_{n-3})$$. Appl. Math. Comput. 219, 4755–4764 (2013)

41. Stević, S.: First-order product-type systems of difference equations solvable in closed form. Electron. J. Differ. Equ. 2015, Article ID 308 (2015)

42. Stević, S.: Product-type system of difference equations of second-order solvable in closed form. Electron. J. Qual. Theory Differ. Equ. 2015, Article ID 56 (2015)

43. Stević, S., Iričanin, B., Šmarda, Z.: On a product-type system of difference equations of second order solvable in closed form. J. Inequal. Appl. 2015, Article ID 327 (2015)

44. Stević, S., Iričanin, B., Šmarda, Z.: Solvability of a close to symmetric system of difference equations. Electron. J. Differ. Equ. 2016, Article ID 159 (2016)

45. Stević, S., Alghamdi, M. A., Alotaibi, A., Elsayed, E. M.: Solvable product-type system of difference equations of second order. Electron. J. Differ. Equ. 2015, Article ID 169 (2015)

46. Papaschinopoulos, G., Schinas, C.J.: On the behavior of the solutions of a system of two nonlinear difference equations. Commun. Appl. Nonlinear Anal. 5(2), 47–59 (1998)

47. Papaschinopoulos, G., Schinas, C.J.: Invariants for systems of two nonlinear difference equations. Differ. Equ. Dyn. Syst. 7, 181–196 (1999)

48. Papaschinopoulos, G., Schinas, C.J.: Invariants and oscillation for systems of two nonlinear difference equations. Nonlinear Anal., Theory Methods Appl. 46, 967–978 (2001)

49. Papaschinopoulos, G., Schinas, C.J., Stefanidou, G.: On a k-order system of Lyness-type difference equations. Adv. Differ. Equ. 2007, Article ID 31272 (2007)

50. Schinas, C.: Invariants for difference equations and systems of difference equations of rational form. J. Math. Anal. Appl. 216, 164–179 (1997)

51. Schinas, C.: Invariants for some difference equations. J. Math. Anal. Appl. 212, 281–291 (1997)

52. Elsayed, E.M.: Dynamics of recursive sequence of order two. Kyungpook Math. J. 50(4), 483–497 (2010)

53. Krechmar, V.A.: A Problem Book in Algebra. Mir, Moscow (1974)

54. Stević, S.: Solutions of a max-type system of difference equations. Appl. Math. Comput. 218, 9825–9830 (2012)

55. Abel, N.H.: Mémoire sur les équations algébriques, où on démontre l’impossibilité de la résolution de l’équation générale du cinquième dégré. In: Sylow, Ludwig; Lie, Sophus, Oeuvres Complètes de Niels Henrik Abel (in French), I (2nd ed.). Grondahl & Son, 28–33 (1881) 

### Acknowledgements

The study in the paper is a part of the investigation under the projects III 41025 and III 44006 by the Serbian Ministry of Education and Science.

Not applicable.

Not applicable.

## Author information

Authors

### Contributions

The author has contributed solely to the writing of this paper. He read and approved the manuscript.

### Corresponding author

Correspondence to Stevo Stević.

## Ethics declarations

### Competing interests

The author declares that he has no competing interests. 