Abstract
In the present study, we are interested in solving the nonhomogeneous second-order linear difference equation with periodic coefficients of period \( p\ge 2\), by bringing two new approaches enabling us to provide both analytic and combinatorial solutions to this family of equations. First, we get around the problem by converting this kind of equations to an equivalent family of nonhomogeneous linear difference equations of order p with constant coefficients. Second, we propose new expressions of the solutions of this family of equations, using our techniques of calculating the powers of product of companion matrices and some properties of generalized Fibonacci sequences. The study of the special case \( p=2 \) is provided. And to enhance the effectiveness of our approaches, some numerical examples are discussed.
Similar content being viewed by others
Avoid common mistakes on your manuscript.
1 Introduction
The nonhomogeneous linear difference equations are discrete dynamical systems, currently studied in the literature under the form,
where \(a_j: {\mathbb {N}}\rightarrow {\mathbb {R}}\) (\(0\le j\le r-1\)) and \(g: {\mathbb {N}}\rightarrow {\mathbb {R}}\) are given functions defined on \({\mathbb {N}}\). Recently, the homogeneous and nonhomogeneous linear difference equation (1), has attracted a lot of attention because of their wide applications in various fields of mathematics and applied sciences. That is, discrete time systems defined by Eq. (1), have several applications in economics, physics, circuit theory, and other areas. For example in finance, there is an application to the well-known Leontief model, or the Samuelson–Hicks model. For this former model, the nonhomogeneous linear difference equations of the second order plays a central role (see for instance [9, 13, 16], and references therein).
We recall that, when the coefficients \(a_j(n)\) (\(0\le j\le r-1\)) of the linear recurrences equation (1) are constants, namely, \(a_j(n)=a_j\), where \(a_j\) (\(0\le j\le r-1\)) is a constant, it is well known in the literature that the explicit solutions are expressed under a combinatorial form in terms of coefficients \(a_j\) (\(0\le j\le r-1\)) or under an analytic form, using the roots of the associated characteristic polynomial \(P(z)=z^r-a_0z^{r-1}-\cdots -a_{r-1}\) (see, for example, [11, 12], and references therein). However, when the coefficients \(a_j(n)\) (\(0\le j\le r-1\)) are variable, some methods have been elaborated in the literature for exhibiting formulas of the solutions of Eq. (1). That is, Kittapa gave solutions of the homogeneous linear difference equations of higher order with variable coefficients, in terms of a single matrix determinant (see [14]). In [15], the general solution for nonhomogeneous linear difference equations with variable coefficients, has been provided in terms of the determinant of a lower Hessenberg matrix. In [10], the explicit solution of the nonhomogeneous linear difference equation with variable coefficients is presented, in terms of matrix pencil theory. Malik established a closed form the solutions of (1), in terms of coefficients for the homogeneous linear difference equations with variable coefficients (see [17]). In [1], solutions of the homogeneous linear difference equations of the second order are studied in terms of the determinental approach and using the nested sum. Whereas, some explicit expressions of solutions of the homogeneous linear difference equations with periodic coefficients are established in [4].
In this paper, we present an alternative new method for solving the second order nonhomogeneous linear difference equations with periodic coefficients satisfying,
where \(\{g_n\}_{n\in {\mathbb {N}}}\) is a given real sequence and \(a_j: {\mathbb {N}}\rightarrow {\mathbb {R}}\;(j=0,1)\) are periodic functions of period \(p\in {\mathbb {N}}\), with \(p\ge 2\), namely \(a_0(n+p)=a_0(n)\) and \(a_1(n+p)=a_1(n)\), for every \(n\ge 0\). In our investigation, we provide explicit solutions of (2) by making use of some current results established in [8], on the periodic matrix difference equations related to Eq. (2). Moreover, the combinatorial and analytic formulas of linearly recurrence sequences of constants coefficients, will play a central role. More precisely, the matrix equation expression of Equation (2) and the periodicity condition, allow us to obtain an equivalent formulation of Eq. (2), as a family of nonhomogeneous linear difference equations of constant coefficients. This process leads to the resolution of Eq. (2), by applying the method of [12].
The study of this paper is structured as follows. Section 2 is devoted to the matrix formulation of the second-order difference Eq. (2), where the product of periodic companion matrices is considered. In addition, we give an explicit formula for the second member of the equivalent matrix equation. For this purpose, we develop algorithms for computing the finite product of companion matrices and give combinatorial expressions of powers of such class of matrices. In Sect. 3, we present the first approach, where we study the scalar nonhomogeneous matrix equation of order p with constant coefficients, emanated from the second-order Eq. (2). This allows us to provide the solutions of the homogeneous part and the particular solutions, to obtain the combinatorial and the analytic solutions of Eq. (2). Furthermore, an illustrative example is proposed as application of the results obtained. Section 4 concerns the second approach, where we manage to give other combinatorial and analytic expressions of the solutions of Eq. (2). Section 5 is devoted to the special case when the coefficients of Eq. (2) are periodic of period \( p=2 \). Finally, concluding remarks and discussion are considered.
2 Matrix formulation of the second-order difference equation (2)
2.1 General setting
Consider the second-order nonhomogeneous linear difference equation of periodic coefficients (2), namely,
where \(y_0,\;y_1\) are the initial conditions, \( a_j: {\mathbb {N}}\rightarrow {\mathbb {R}}\;(j=0,1)\) are periodic functions of period \(p\in {\mathbb {N}}\) with \(p\ge 2\), namely \(a_j(n+p)=a_j(n)\) and \(\{g_n\}_{n\in {\mathbb {N}}}\) is a given real sequence. For reason of periodicity we set,
for every \( n\ge p \), where A(n) is a companion matrix of order \(p\times p\) and \(U_n\), \(Y_n\) are matrices of order \(p\times 1\). We observe that the periodicity condition of \(a_{0}(n)\), \(a_1(n)\) implies that \(A(n+p)=A(n)\), for every \(n\ge 0\). Meanwhile, we show that Eq. (2) is equivalent to the following nonhomogeneous matrix discrete equation,
Expression (3) implies that, for every m such that \(n-m\ge p\), we have,
More generally, an iterative prove leads to the following formula,
where \(\prod \limits ^{*,k}_{0\le j\le k}A(n-j)=A(n)A(n-1)\ldots A(n-k)\), with \(\prod \limits ^{*,0}_{0\le j\le 0}A(n-j)=A(n)\). Especially, for \(m=n-p\) we get,
When the matrix \(A(n)=A\) is a constant companion matrix, we show that Expression (5) represents a generalization of Expression (6) established in [12]. On the other hand, using the periodicity condition of the coefficients, a straightforward computation allows us to show that Expression (5) takes the following form:
for every \( k\ge 1 \), where
By taking \(n=kp+m+1\), with \(0\le m\le p-2\), in Expression (4) and employing the periodicity conditions, i.e. \(A(kp+i)=A(i)\), we get the following formula:
In summary, we have the following result.
Proposition 2.1
Consider the second-order nonhomogeneous linear difference equation of periodic coefficients (2), namely
where \(a_{0}(n)\) and \(a_1(n)\) are periodic functions of period \(p\ge 2\) and \(\{g_n\}_{n\in {\mathbb {N}}}\) is a given sequence. Then, for every \( k\ge 1 \), Eq. (2) is equivalent to the following system of p matrix equations (6) and (8), namely
where \(0\le m\le p-2\) and the matrices B and C(h) are given by (7), namely,
The matrix equation (3) shows that for solving Eq. (2), it is sufficient to compute only the \(Y_{kp}\), via the related matrix Expression (6). That is, it is not necessary to compute the \(Y_{kp+m+1}\) by solving Eq. (8). More precisely, it ensues from Proposition (2) our needed to compute C(h) and the powers \(B^n\). That is, for reasons of convenience and clarity, we can write the equation (6) under the following matrix equation,
where
Equations (9)–(10) will play an important role in the process of resolution of Eq. (2), presented in the next Sections. That is, for solving Equation (2), we are led to compute the explicit formula of C(h) and the powers \(B^k\) of the constant matrix B.
2.2 Computation of the matrices C(h) and powers \(B^k\) (\(k\ge 1\))
Equation (6) can be written under the following matrix equation:
where \(Z_k=Y_{kp}\) and \( H_k \) is given as in (10). Equation (11) shows that Eq. (2) is reduced to a nonhomogeneous matrix equation of constant matrix B, given as in (7). Thence, solving Equation (11) calls for the following requirements:
-
A process for the calculation of the matrix C(h) for \( 0\le h\le p-1 \),
-
A process for the calculation of the powers \(B^k\) of the matrix B.
Therefore, the main goal of this subsection is to implement a method for calculating the matrix \(C(h)\; (0\le h\le p-1)\) and the powers \(B^k\) of the matrix B.
First, put
It turns from Expression (7) that \(C(h)=C(h-1)A(p-1-h)\). Thus, a straightforward computation allows us to obtain,
where \( \alpha _{j}^{(h)} \) and \( \beta _{j}^{(h)}\;(0\le j\le h) \) are computed by the following algorithm,
with the initial conditions \( \alpha _{-1}^{(h-2)}=1\) and \(\alpha _{-2}^{(h-2)}=0 \), for every \( h\ge 0 \).
Second, let now compute the entries of the powers \(B^k\) of the matrix B, given as in (7). Since \(B=C(p-1)\) we have,
where the \(\alpha _{j}^{(h)}\) and the \(\beta _{j}^{(h)}\) are as in (12). For \( k\ge 1 \), we put
with
And as \( B^k=B^{k-1}.B \), in other terms,
we conclude that, for every \( j=1,2,...,p \), we have the following recursive relations,
Thereafter, we get the following homogeneous matrix equation,
Put \( Q=\begin{pmatrix} \theta _{1}^{(1)}&{} \theta _{2}^{(1)} \\ \gamma _{1}^{(1)} &{} \gamma _{2}^{(1)} \end{pmatrix} \), then by induction, we acquire,
for every \( j=1,2,...,p \). Let us consider the characteristic polynomial of Q, namely, \( P_Q(z)=det(Q-zI_2)=(\theta _{1}^{(1)}-z)(\gamma _{2}^{(1)}-z)-\theta _{2}^{(1)}\gamma _{1}^{(1)}=z^2-c_1z-c_2 \), where
Using the combinatorial formula, on the powers of matrix established in [6], we obtain,
for \( n\ge 2 \), with \( \rho (1,2)=0,\,\rho (2,2)=1 \), and
for all \( n\ge 2\). As a matter of fact, we have the following combinatorial expression for the entries of the matrix \(Q^n\),
Therefore, we get the following lemma,
Lemma 2.2
With the same notation as above, the combinatorial formula of the powers of the matrix B, is given by,
for every \(k\ge 2\), where
such that \(\rho (n,2)=\sum \limits _{h=0}^{[\frac{n-2}{2}]} \left( {\begin{array}{c}n-h-2\\ h\end{array}}\right) c_1^{n-2\,h-2}c_2^h\), for \( n>2 \), with \( \rho (1,2)=0\), \(\rho (2,2)=1 \), and \(\theta _{j}^{(1)} \), \(\gamma _{j}^{(1)} \) are given by (12)–(14).
It follows from the above Lemma 2.2 that the entries of the powers \(B^k\) are expressed in terms of the combinatorial expression \(\rho (n,2)\), namely, Expression (16). Furthermore, we point out that the sequence \(\{v_n\}_{n\ge 0}\) defined by \(v_n=\rho (n+1,2)\), for \(n\ge 0\), satisfies the linear recursive relation of Fibonacci type \(v_{n+2}=c_0v_{n+1}+c_1v_n\), for \(n\ge 0\), with initial data \(v_0=0 \) and \(v_1=1 \) ( For more details see [6]).
Moreover, let \(\lambda _1\) and \(\lambda _2\) be the roots of the characteristic polynomial \(P(z)=z^{2}-c_1z-c_2\), of the sequence \(\left\{ v_n=\rho (n+1,2)\right\} _{n\ge 0}\). Then, we have \( P(z)=(z-\lambda _1)(z-\lambda _2) \). First, suppose that \(\lambda _1\not = \lambda _2\), it ensues from [5, Lemma 2.1, Expression (6)] that,
Thence, we get the analytic expression of the matrix powers \(Q^n\) as follows:
and using the fact that \( \begin{pmatrix} \theta _{j}^{(k)} \\ \gamma _{j}^{(k)} \end{pmatrix}=Q^{k-1}\begin{pmatrix} \theta _{j}^{(1)} \\ \gamma _{j}^{(1)} \end{pmatrix} \), for every \( k\ge 2 \), we can formulate the following lemma.
Lemma 2.3
With the same notation as above, when \(\lambda _1 \ne \lambda _2\) the analytic formula of the powers of the matrix B is given by,
where
and \(\theta _{j}^{(1)} \), \(\gamma _{j}^{(1)} \) are given as in (12)—(14).
Second, suppose that \(\lambda _1= \lambda _2=\lambda \). Then, the analytic expression of \(\{ \rho (n,2)\}_{n\ge 1}\) is given by \(\displaystyle \rho (n,2)=(\alpha _1+\alpha _2n)\lambda ^n\). Since \(\rho (1,2)=0\) and \(\rho (2,2)=1\), we infer that \((\alpha _1+\alpha _2)\lambda =0\) and \((\alpha _1+2\alpha _2)\lambda ^2=1\). Hence, we conclude that \(\alpha _1=-\alpha _2\) and \(\alpha _1+2\alpha _2=\frac{1}{\lambda ^2}\), thereby, \(\alpha _1=-\frac{1}{\lambda ^2}\) and \(\alpha _2=\frac{1}{\lambda ^2}\). Accordingly we obtain,
Summarizing, we get the following lemma.
Lemma 2.4
With the same notation as above, when \(\lambda _1= \lambda _2=\lambda \) the analytic formula of the powers \(B^k\) of the matrix B is given by,
where
and \(\theta _{j}^{(1)} \), \(\gamma _{j}^{(1)} \) are given by (12)—(14).
2.3 Matrix formulation of Eq. (2)
Consider the characteristic polynomial of the matrix B, given as follows:
with
where \(\theta _{j}^{(1)} \) and \(\gamma _{j}^{(1)} ( j=1, 2 \)) are given by (12)—(14). We point out that \(c_1 \) and \(c_2 \) are nothing else but only the coefficients of \( P_Q(x) \), the characteristic polynomial of the matrix Q, given by (15).
Since \( P_B(B)=\Theta \) (the matrix null), the Cayley–Hamilton Theorem implies that \(B^{p}=c_1B^{p-1}+c_2B^{p-2}\). Therefore, we conclude that
or equivalently,
where \( H_{s} \) is given as in (10), namely,
for \(s=p+k,\;p+k-1,\;p+k-2\). Consequently, the sequence \(\{ Y_{(p+k)p}\}_{k\ge 0}\), satisfies the following nonhomogeneous linear recursive relation,
with \( H^{*}_k=H_{p+k}-c_1H_{p-1+k}-c_2H_{p-2+k} \). Equation (20) represents another equivalent expression of Eq. (3). And by a direct computation we obtain,
where \(D_k=U_{(p+k)p}+\sum \limits _{h=0}^{p-2}C(h)U_{(p+k)p-1-h}\). Equations (20)–(21) will play a central role in the resolution of Eq. (2). To this aim, let us compute the explicit formula for each entry of the matrix column \(H^{*}_k\). We first show that
where \( \alpha _{j}^{(h)} \) are given by (12). Thence, for every \( i=0,1,...,p+k-4\), we get \( B^iD_{k-2-i}=\begin{pmatrix} x_1^{(i)}\\ x_2^{(i)}\\ \vdots \\ x_p^{(i)} \end{pmatrix},\) with
Moreover, a straightforward computation allows us to conclude that
where \(c_1\) and \(c_2\) are as in (15). We can show that,
with
Furthermore, we have, \( (B-c_1I_p)D_{k-1}=\begin{pmatrix} v_1^{(k)}\\ v_2^{(k)}\\ \vdots \\ v_p^{(k)} \end{pmatrix},\) such that
By combining Expressions (23), (24) and (25), we obtain the following explicit expression of \(H^{*}_k\).
Lemma 2.5
With the same notation as above, the explicit formula of \( H^{*}_k=\begin{pmatrix} \varphi ^{(k)}_1\\ \varphi ^{(k)}_2 \\ \vdots \\ \varphi ^{(k)}_p \end{pmatrix} \) is given by
where \( \alpha _{j}^{(h)} \), \(z_j^{(k)}\) and \(v_j^{(k)}\) are given by (12), (24), (25), respectively.
In the next sections, Lemmas 2.3, 2.4 and 2.5 will be extensively used for establishing various explicit expressions of the solutions of Eq. (2), namely, the analytic and the combinatorial formulas of the solutions of Eq. (2).
3 Solutions of Eq. (2)—first approach
The main steps of our process for solving Eq. (2), consist of considering the equivalent non-homogeneous matrix equation (3). Thanks to the condition of periodicity of the coefficients \(a_1(n)\), \(a_2(n) \), the matrix form (3) permits us to establish that it is equivalent to a nonhomogeneous matrix equation with constant coefficients, namely, Eq. (20). More precisely, in light of Eq. (20), we observe that the matrix sequence \(\{ Y_{(p+k)p}\}_{k\ge 1}\), satisfies the following recursive relation:
where \(c_1\), \(c_2\) are the coefficients given by (19) and \( H^{*}_k=H_{p+k}-c_1H_{p-1+k}-c_2H_{p-2+k} \) is the matrix column (21).
3.1 Solutions of the homogeneous part of Eq. (20).
Let us consider the homogeneous matrix recurrence relation of order 2, related to Eq. (20), given by,
Hence, by considering the entries of each vector of the former equation, we conclude that Eq. (2) is equivalent, to the following scalar p equations:
for \( k\ge 1\). By setting \( n=k+p-1 \), we get,
for every \(n\ge p\). For reason of clarity, we denote by \( y_{np+j}^{<h>} \) the solutions of the former Eq. (27). For every \(j=0,1,\cdots ,p-1\), we consider the sequence \(\{w_{m}^{(j)}\}_{m\ge 0} \) defined by \( w_m^{(j)}=y_{mp+p(p-2)+j}^{<h>} \). Therefore, the sequence \(\{w_{m}^{(j)}\}_{m\ge 0} \) is a linear recursive sequence of order 2, of Fibonacci type, fulfilled the following the linear recurrence relation:
with initial conditions \( w_{0}^{(j)}=y_{(p-2)p+j} \), \( w_{1}^{(j)}=y_{(p-1)p+j} \), whose related characteristic polynomial is \( P(z)=z^{2}-c_1z-c_2\). Thus, the combinatorial formula of \(\{w_{m}^{(j)}\}_{m\ge 0} \) is given by,
where \( \rho (m,2) \) is given by (16), namely
with \( \rho (1,2)=0\) and \(\rho (2,2)=1 \).
In addition, employing the analytic formulas of \( \rho (m,2) \) given by (17) and (18), we can obtain the analytic expression of the sequence \(\{w_{m}^{(j)}\}_{m\ge 0} \). As a matter of fact, let \(\lambda _1\), \(\lambda _2\) be the roots of the characteristic polynomial \(P(z)=z^{2}-c_1z-c_2\). For \( \lambda _1\ne \lambda _2 \), Expression (17) shows that \(\displaystyle \rho (m,2)=\sum \limits _{i=1}^{2}\dfrac{\lambda _i^{m-1}}{P'(\lambda _i)}=\dfrac{\lambda _1^{m-1}}{P'(\lambda _1)}+\dfrac{\lambda _2^{m-1}}{P'(\lambda _2)}\), for every \(m\ge 2\). So, in this case we get,
Second, for \(\lambda _1= \lambda _2=\lambda \), the analytic expression (18) of \(\{ \rho (m,2)\}_{m\ge 0}\), given by \(\displaystyle \rho (m,2)=(m-1)\lambda ^{m-2}\), for every \(m\ge 2\), allows us to obtain,
Since, for \(j=0,1,\cdots ,p-1\), we have \( w_m^{(j)}=y_{mp+p(p-2)+j}^{<h>} \), for every \(m\ge 2\), we get the following result.
Proposition 3.1
With the same notation as above, for every \( j=0,...,p-1 \), the combinatorial solution of the homogeneous Eq. (27), \( y_{np+j}=c_1y_{(n-1)p+j}+c_2y_{(n-2)p+j} \), is given by,
Furthermore, if \(\lambda _1\) and \(\lambda _2\) are the roots of the characteristic polynomial \(P(z)=z^{2}-c_1z-c_2\), the analytic solution of the homogeneous Eq. (27), is given as follows.
1) If \(\lambda _1\not = \lambda _2\) then, for every \( j=0,...,p-1 \), we have,
2) If \(\lambda _1 = \lambda _2=\lambda \) then, for every \( j=0,...,p-1 \), we have,
3.2 Particular solutions of Eq. (20).
Consider the nonhomogeneous equation (20),
with initial conditions \( Y_{p^2}\) and \(Y_{(p-1)p} \). Then, Eq. (20) implies that the entries of the vector \(Y_{kp}\) satisfy the nonhomogeneous scalar equations, of constant coefficients, given by,
The nonhomogeneous scalar equation of type (30) have been studied in [12]. More precisely, we exploit the formula given in [12, Theorem 3.1], we can obtain the explicit form, for a particular solution of Eq. (30), which we present in the following proposition.
Proposition 3.2
With the same notation as above, the particular solutions of Eq. (30) can be expressed under the combinatorial form as follows:
Furthermore, if \( \lambda _1\) and \(\lambda _2 \) are the roots of the polynomial \( P(z)=z^{2}-c_1z-c_2\). Then, employing (17)–(18), the particular solutions of Eq. (30) can be expressed under an analytic form as follows:
1) If \(\lambda _1\not = \lambda _2\) then, for every \( j=0,...,p-1 \), we have,
2) If \(\lambda _1 = \lambda _2=\lambda \) then, for every \( j=0,...,p-1 \), we have,
It is well known that the general solution of the non-homogeneous equation (30), is written in the following form, \(\displaystyle y_{np+j}=y_{np+j}^{<h>}+y_{np+j}^{<p>}\), (see for instance [12], and references therein). In summary, applying Expressions (32)–(33), we can formulate our main result, concerning the solutions of Eq. (2), as follows.
Theorem 3.3
Let us consider the difference equations (2) and suppose that the coefficients \(a_0(n)\), \(a_1(n)\) are periodic of period \(p\ge 2\). Then, for every \( j=0,...,p-1 \), the combinatorial formulas of the solutions \(\{y_{np+j}\}_{n\ge p}\) of Eq. (2), are given by,
where
Let \( \lambda _1\), \(\lambda _2 \) be the roots of the polynomial \( P(z)=z^{2}-c_1z-c_2\), where the coefficients \(c_1\), \(c_2\) are as in (19). Then, the analytic formulas of the solutions \(\{y_{np+j}\}_{n\ge p}\) of Eq. (2), are given by,
such that, for \(\lambda _1\not = \lambda _2\), we have,
and for \(\lambda _1 = \lambda _2=\lambda \), we have,
where the scalar \(\varphi _{j}^{(k)}\) given by (26), are the entries of \( H^{*}_k=H_{p+k}-c_1H_{p-1+k}-c_2H_{p-2+k} \), the vector column (21).
To better visualize our main result, we will consider the following illustrative numerical example.
Example 3.4
Let us consider the difference equations (2) and suppose that the coefficients \(a_0(n)\), \(a_1(n)\) are periodic of period \(p=3\), with a given sequence \( (g_n)_{n>0} \) and initial conditions \( y_0,\;y_1 \). Suppose that for the related matrix representation (3), we have,
Using the algorithm (12), we can see that the scalars \(\alpha _j^{(h)}\) and \(\beta _j^{(h)}\) satisfy the following relations:
Therefore, we get, \( C(0)=\begin{pmatrix} \alpha _{0}^{(0)} &{} \beta _{0}^{(0)} &{} 0 \\ 1 &{} 0 &{} 0 \\ 0 &{} 1 &{} 0 \end{pmatrix}=\begin{pmatrix} 4 &{} 2 &{} 0 \\ 1 &{} 0 &{} 0 \\ 0 &{} 1 &{} 0 \end{pmatrix},\; C(1)=\begin{pmatrix} \alpha _{1}^{(1)} &{} \beta _{1}^{(1)} &{} 0 \\ \alpha _{0}^{(1)} &{} \beta _{0}^{(1)} &{} 0 \\ 1 &{} 0 &{} 0 \end{pmatrix}=\begin{pmatrix} -2 &{} 12 &{} 0 \\ -1 &{} 3 &{} 0 \\ 1 &{} 0 &{} 0 \end{pmatrix} \) and
We infer that \( c_1,\;c_2 \) are given by \( c_1=\alpha _{2}^{(2)}+\beta _1^{(2)}=12 \) and \( c_2=\alpha _{1}^{(2)}\beta _2^{(2)}-\alpha _{2}^{(2)}\beta _1^{(2)}=-12 \). Thus, we obtain,
where \( \lambda _1=6-3\sqrt{3} \), \( \lambda _2=6+3\sqrt{3} \), \( P^{'}(\lambda _1)=-6\sqrt{3} \) and \( P^{'}(\lambda _2)=6\sqrt{3} \). Moreover, with the aid of Expression (6), we derive that the vectors columns \(Y_6=\begin{pmatrix} y_5 \\ y_4 \\ y_3 \end{pmatrix}\) and \(Y_9=\begin{pmatrix} y_8 \\ y_7 \\ y_6 \end{pmatrix}\) are given by,
\( Y_6=BY_3+U_6+C(0)U_5+C(1)U_4=\begin{pmatrix} 44y_1+20y_0 \\ 10y_1+4y_0 \\ 2y_1+2y_0 \end{pmatrix}+\begin{pmatrix} g_5+4g_4-2g_3+10g_2 \\ g_4-g_3+2g_2 \\ g_3+g_2 \end{pmatrix}, \)
and \( Y_9= B^{2}Y_3+U_9+C(0)U_8+C(1)U_7+BU_6+B[ C(0)U_5+C(1)U_4].\) Then, for \( j=0,1,2 \) and \( n\ge 3 \), the homogeneous solution is
Furthermore, using Expression (32), we get the following particular solution,
where the \( \varphi ^{(k)}_j \) are such that \(H^{*}_k=\begin{pmatrix}\varphi ^{(k)}_1 \\ \varphi ^{(k)}_2 \\ \varphi ^{(k)}_3 \end{pmatrix}\). More precisely, we have,
\(H^{*}_k=\left( B^{2}-c_1B-c_2I_p\right) \left( \sum \limits _{i=0}^{p+k-4}B^{i}D_{k-2-i}\right) +\left( B-c_1I_p\right) D_{k-1}+D_k.\)
Since \( D_k=\begin{pmatrix} g_{3(k+3)-1}+4g_{3(k+3)-2}-2g_{3(k+3)-3} \\ g_{3(k+3)-2}-g_{3(k+3)-3} \\ g_{3(k+3)-3} \end{pmatrix} \), the explicit formula of the \( \varphi ^{(k)}_j \) is as follows:
and \(\alpha _{j}^{(h)}\), \( z_j^{(k)},\;v_j^{(k)} \) are given by (23), (24) and (25).
4 Solutions of Eq. (2)—second approach
In this section we will provide another approach for resolving Eq. (2). We need to use some results established in [8], regarding companion matrices. That is, let us get back to equation (6), namely,
The former equation can be written under the form,
where \(D_k=U_{(p+k)p}+\sum \limits _{h=0}^{p-2}C(h)U_{(p+k)p-1-h}\) is the matrix exhibited by the explicit formula (22). By appealing the expression of \(B^k\) (\(k\ge 1\)), established in Expression (13), we have
where the entries \( \theta _{j}^{(k)}\), \( \gamma _{j}^{(k)}\) of the matrix \(B^k\) are defined as follows. For \(k=1\), we get
where the \(\;\alpha _{j}^{(h)}\), \(\;\beta _{j}^{(h)}\) are computed using Eq. (12). For \(k=2\), we have
For \( k\ge 3 \), we acquire
such that
where \(\rho (n,2)\) is the combinatorial Expression (16). Moreover, for \( 0\le i\le k-2 \), we come by \( B^iD_{k-p-i}=\begin{pmatrix} x_1^{(i)}\\ x_2^{(i)}\\ \vdots \\ x_p^{(i)} \end{pmatrix},\) where
with \(\theta _{j}^{(k)}\), \(\gamma _{j}^{(k)}\) are as in (34)–(35) and the \(\alpha _{k}^{(h)}\) are as in (12). In addition, we consider the entries \(y_{kp-j}\) of the matrix equation \( Y_{kp}=B^{k-1}Y_{p}+\sum \limits _{i=0}^{k-2}B^{i}D_{k-i-p}\). Finally, we can formulate our main result, concerning the solutions of Eq. (2), as follows.
Theorem 4.1
With the same notation as above, for every \( j=1,2,...,p \), the solutions of Eq. (2) are given by,
where \(\theta _{j}^{(k)}\), \(\gamma _{j}^{(k)}\) are given by (34)–(35) and (36), the \(\alpha _{k}^{(h)}\) are as in (12) and \(x_j^{(i)}\) are given by (37).
Following Formulas (35)–(36), we show that Expression (38) of the combinatorial solutions of Eq. (2) are expressed in terms of the \(\rho (n,2)\) given by (16). It was also established that (17) and (18) are the analytic expressions of \(\rho (n,2)\), when the polynomial \(P(z)=z^2-c_1z-c_2\) has simple roots or a unique root, respectively. More precisely, when the two roots of the polynomial \(P(z)=z^2-c_1z-c_2\) are simple, by substituting the analytical expressions of \(\rho (n,2)\) and \(\rho (n+1,2)\), given by (17), in Expression (36), we obtain the analytical form of the solutions of Eq. (2). More precisely, we have the following result.
Proposition 4.2
With the same notation as above, Suppose that the polynomial \(P(z)=z^2-c_1z-c_2\) owns simple roots \(\lambda _1\), \(\lambda _2\). Then, the solutions \(y_{kp-j}\) of Eq. (2) are given by,
for \( j=1,2,...,p \), where \(x_j^{(i)}\) are given by (37), and \(\theta _{j}^{(k)}\), \(\gamma _{j}^{(k)}\) are as in (34)–(35) such that,
Now, suppose that the two roots of the polynomial \(P(z)=z^2-c_1z-c_2\) are equal, then a substitution of the analytic Expression (18) of the \(\rho (n,r)\) in Expressions (36), allows us to obtain the following analytic form for the solution of Eq. (2).
Proposition 4.3
With the same notation as above, Suppose that the polynomial \(P(z)=z^2-c_1z-c_2\) owns simple roots \(\lambda _1\), \(\lambda _2\). Then, the solutions \(y_{kp-j}\) of Eq. (2) are given by,
for \( j=1,2,...,p \), where \(x_j^{(i)}\) are given by (37), and \(\theta _{j}^{(k)}\), \(\gamma _{j}^{(k)}\) are as in (34)–(35) such that,
5 Study of the special case \(p=2\)
In this section, we focus our study to the special case when \(p=2\). The calculation of the powers of B can be exhibited explicitly in this case, which allows us to obtain handled expressions of the solutions of (2). That is, let us consider the equation (2), such that the coefficients \(a_0(n)\), \(a_1(n)\) are periodic of period \(p=2\), viz \(\displaystyle y_n=a_0(n)y_{n-1}+a_1(n)y_{n-2}+g_n,\) where \(a_0(n+2)=a_0(n)\), \(a_1(n+2)=a_1(n)\). Recall that the matrix representation (3) in this case is, \(\displaystyle Y_{n+1}=A(n)Y_n+U_{n+1},\) with \( Y_n=\begin{pmatrix} y_{n-1} \\ y_{n-2} \end{pmatrix} \), \( A(n)=\begin{pmatrix} a_0(n) &{} a_1(n) \\ 1 &{} 0 \end{pmatrix} \) and \( U_{n+1}=\begin{pmatrix} g_n \\ 0 \end{pmatrix} \). Consequently, with the aid of the results of subsection 2.2, notably Expression (12), related to the algorithms for calculating the matrices C(h) and the powers of the matrix \(B =C(p-1 )\), we have \( C(0)=A(1) \), \( B=\begin{pmatrix} \alpha _1^{(1)} &{} \beta _1^{(1)} \\ \alpha _0^{(1)} &{} \beta _0^{(1)} \end{pmatrix}=\begin{pmatrix} a_0(0)a_0(1)+a_1(1) &{} a_1(0)a_0(1) \\ a_0(0) &{} a_1(0) \end{pmatrix} \) and
The characteristic polynomial of the matrix B is \(P_B(z)=z^2-d_1z-d_2\) with
To calculate the powers \( B^n \) for \( n\ge 2 \), we use the Fibonacci–Horner decomposition (for more details, see [6]). Thus, we have,
with \( \rho (1,2)=0 \), \( \rho (2,2)=1 \), and
For all \( n\ge 0 \), we put
where
Then, for every \( n\ge 2 \), we have,
For this special case, Expression (6) takes the form,
where
Summarizing, we get the following result,
Theorem 5.1
Consider the equation (2) of variable coefficients \(a_0(n)\), \(a_1(n)\). Suppose that \(a_0(n)\), \(a_1(n)\) are periodic of period \(p=2\). Then, the solutions of Equation (2) are given by,
To illustrate the above result of Theorem (), we explore the following numerical example.
Example 5.2
Let us consider Eq. (2) given by,
for a fixed real number x, where the initial conditions \( y_{0}(x)\), \(y_{1}(x) \) and the function g(n) are given. We have,
and
The characteristic polynomial associated to B is
Using the Fibonacci-Horner decomposition, we obtain,
with
Then, for \( n\ge 2 \), we have,
where
and the solutions of Eq. (41) are as follows:
where \(\Delta (k,i,\cos (x))= g_{2(k-i)-1}-\cos (x)g_{2(k-i)-2}\).
6 Conclusion and discussion
Thanks to our approaches, we have succeeded in decomposing the nonhomogeneous difference equation (2), which has periodic variable coefficients with period \( p \ge 2 \), into a family of p nonhomogeneous equations with constant coefficients. These equations were resolved using a matrix technique developed in [12]. Moreover, our approaches based on some auxiliary results established in Section 2 allows us to establish combinatorial and analytic expressions of the solutions for Eq. (2), with periodic coefficients.
To the best of our knowledge, our approaches are not common in the literature. The process of linearization of Eq. (2), permits us to get around the problem by studying nonhomogeneous linear difference equations with constant coefficients. More precisely, this process made it possible to reduce the result of nonhomogeneous equations with periodic coefficients (2), to that of nonhomogeneous linear difference equations with constant coefficients. Thereafter, the method of [12] allows us to provide explicit formulas for the solutions of Eq. (2).
We would like to point out that, the nonhomogeneous difference equations of order r, namely, Eq. (1), with periodic coefficients \(a_j(n)\) (\(0\le j\le r-1\)), is under study. The two references [2, 3] seem to be useful for studying the higher order Eq. (1).
References
Abderraman Marrero, J.; Rachidi, M.: A note on representations for the inverses of tridiagonal matrices. Linear Multilinear Algebra 61(9), 1181–1191 (2013). https://doi.org/10.1080/03081087.2012.734304
Agarwal, R.P.: Difference Equations and Inequalities. Revised and Expended, 2nd edn, p. 980. Marcel Dekker, New York (2000)
Agarwal, R.P.; Popenda, J.: Periodic solutions of first order linear difference equations. Math. Comput. Model. 22–1, 11–19 (1995)
Ben Taher, R.; Benkhaldoun, H.: Solving the linear difference equation with periodic coeffcients via Fibonacci sequences. Linear Multilinear Algebra 67(12), 2549–2564 (2019)
Ben Taher, R.; Rachidi, M.: Solving some generalized Vandermonde systems and inverse of their associate matrices via new approaches for the Binet formula. Appl. Math. Comput. 290, 267–280 (2016)
Ben Taher, R.; Mouline, M.; Rachidi, M.: Fibonacci-Horner decomposition of the matrix exponential and the fundamental system of solutions. Electron. Linear Algebra 15, 178–190 (2006)
Ben Taher, R.; Benkhaldoun, H.; Rachidi, M.: On some class of periodic-discrete homogeneous difference equations via Fibonacci sequences. J. Differ. Equ. Appl. 22–9, 1292–1306 (2016)
Benkhaldoun, H.; Ben Taher, R.; Rachidi, M.: Periodic matrix difference equations and companion matrices in blocks: some applications. Arab. J. Math. 10, 555–574 (2021)
Campbell, S. L.: Singular Systems of Differential Equations, vol. 1, (Pitman, San Francisco, 1980), Vol. 2 (1982)
Dassios, I.: On Non-homogeneous Generalized Linear Discrete Time Systems. Circ. Syst. Signal Process 31, 1699–1712 (2012)
Dubeau, F.; Motta, W.; Rachidi, M.; Saeki, O.: On weighted r-generalized Fibonacci sequences. Fibonacci Quart. 35(2), 102–110 (1997)
El Wahbi, B.; Mouline, M.; Rachidi, M.: Solving nonhomogeneous recurrence relations of order r by matrix methods. Fibonacci Quart. 40, 106–108 (2001)
Heijman, W. J. M., van Mouche, P. H. M.: Floquet theory and economic dynamics II. In: WASS Working paper; No. 15-2015. https://doi.org/10.13140/RG.2.1.1067.4009
Kittappa, R.K.: A representation of the solution of the nth order linear difference equation with variable coefficients. Linear Algebra Appl. 193, 211–222 (1993)
Paraskevopoulos, A. G., Karanasos, M.: A closed form to the general solution of linear difference equations with variable coeffcients (2014). arXiv:1412.8521v1 [math.FA]
Popenda, J.: One expression for the solutions of second order difference equations. Proc. Am. Math. Soc. 100(1), 87–93 (1987)
Ranjan, K.: Mallik, solutions of linear difference equations with variable coefficients. J. Math. Anal. Appl. 222, 79–91 (1998)
Acknowledgements
The authors express their sincere gratitude to the reviewers for their careful reading of the text and their relevant valuable suggestions. References [2, 3] are due to him. The second author MR expresses his sincere thanks to INMA and UFMS. With special thanks to Professors M. Turine, C. Itavo, B. Amaro, E. Pereira, Magda J. Godinho-Mongelli and S. Burigato for their support.
Funding
The authors declare that no funds, grants, or other support were received during the preparation of this manuscript.
Author information
Authors and Affiliations
Corresponding author
Ethics declarations
Conflict of interest
The authors have no relevant financial or non-financial interests to disclose.
Additional information
Publisher's Note
Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Taher, R.B., Lassri, M. & Rachidi, M. New method for solving non-homogeneous periodic second-order difference equation and some applications. Arab. J. Math. 12, 647–665 (2023). https://doi.org/10.1007/s40065-023-00422-3
Received:
Accepted:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s40065-023-00422-3