Keywords

1 Introduction

One of the most important current research is related with design of sensor devices. They are considered as cornerstones of Industry 4.0 [2, 20] relying primarily on cyber-physical systems, which include smart sensors with supervision and communication purposes. A lot of modern applications in biology, medicine, ecology, food industry are dealt with biosensors. They are kind of sensors aimed for measurements of biological substances. The design of biosensor devices includes estimation of parameters enabling us their stable functioning.

The most of models describing biosensors uses partial differential equations. However it does not take into account discrete nature of spatial coordinates of the biosensor, which is based on two- or three-dimensional biopixels array. That is why in series of works (see [15, 19]) finite lattice differential equations were offered to describe biosensor devices.

Differential equations which are used in the biosensors modelling are based on population dynamics for describing different biological species interaction. For example, in case of immunosensors, which are kind of biosensors, we use antigens and antibodies, which play roles of preys and predators respectively. In such a way we result in well-known predator-prey differential equations in the biosensor modelling.

A lot of results for the predator-prey models with discrete or distributed time delays has been obtained. As it was mentioned in [13], the problem is that the most of these results are related with the continuous-time systems but discrete-time modeling is more appropriate in cases “when populations have a short life expectancy, nonoverlapping generations in real world”.

Let \(x_{i,j}(t)\) be concentration of antigens, \(y_{i,j}(t)\) be concentration of antibodies in biopixel (ij), \(i,j=\overline{1,N}\).

The model is based on biological assumption for arbitrary biopixel (ij), which are described in [15]. It includes the following constant parameters: birthrate for antigen population, \(\beta >0\); death rate of antigens, \(\delta _x\); probability rate of neutralization of antigens by antibodies, \(\gamma >0\); birthrate of antibodies, \(\mu _y\); death rate of antibodies, \(\delta _y\); probability rate of immune response with respect to antibodies, \(\eta \). Immune response appears with some constant time delay \(\tau >0\). For the sake of simplicity we assume the same delay \(\tau \) for the death rate of antigens. We have some diffusion of antibodies from four neighboring pixels \((i-1,j)\), \((i+1,j)\), \((i,j-1)\), \((i,j+1)\). The complete biological reasoning and description of the model is presented in [15].

So we start from considering a very simple delayed antibody-antigen competition model for biopixels two-dimensional array which was offered and investigated in [15]

$$\begin{aligned} \begin{aligned} \frac{dx_{i,j}(t)}{dt}&= (\beta - \gamma y_{i,j}(t-\tau ) - \delta _x x_{i,j}(t-\tau ))x_{i,j}(t)+\hat{S}\{ x_{i,j} \},\\ \frac{dy_{i,j}(t)}{dt}&=\Bigg ( -\mu _y + \eta \gamma x_{i,j}(t-\tau ) -\delta _y y_{i,j}(t)\Bigg )y_{i,j}(t) \end{aligned} \end{aligned}$$
(1)

with given initial functions

$$\begin{aligned} \begin{aligned}&x_{i,j}(t)=x_{i,j}^0(t)\ge 0,\quad y_{i,j}(t)=y_{i,j}^0(t) \ge 0,\quad t\in [-\tau , 0),\\&x_{i,j}(0),y_{i,j}(0)>0. \end{aligned} \end{aligned}$$
(2)

For a square \(N\times N\) array of traps, we use the following discrete diffusion form of the spatial operator, which was already applied for modelling biosensors (see [19])

$$\begin{aligned} \hat{S}\{ x_{i,j} \} = D\varDelta ^{-2} \Bigg [ x_{i-1,j} + x_{i+1,j} + x_{i,j-1} + x_{i,j+1} - 4x_{i,j} \Bigg ]\quad i,j= \overline{1,N} \end{aligned}$$
(3)

Each colony is affected by the antigen produced in four neighboring colonies, two in each dimension of the array, separated by the equal distance \(\varDelta \).

We use the boundary condition \(x_{i,j}=0\) for the edges of the array \(i,j=0,N+1\).

The techniques, which are used in the work for discretization, permanence and stability investigation are primarily based on the approach developed in [13] for predator-prey system. Here they were extended in case of finite lattice model with diffusion.

The paper is structured in the following way. In the Sect. 2 we employ the discretization technique to derive the discrete version of system (1). The conditions for quasi-permanence are investigated in Sect. 3. Global stability research is presented in Sect. 4. Results of modeling (1) are displayed in Sect. 5. It can be seen that qualitative behavior of the system is determined mostly by the time of immune response \(\tau \) (or time delay) and diffusion rate D.

Within this paper we use the following notation:

  • the symbol \(i=\overline{m,n}\) for some integer i, m, n, \(m<n\) means \(i=m,m+1,...,n\);

  • \(\lfloor x \rfloor \) denotes the greatest integer less than or equal to the real value x;

  • \(a^u = \sup _{n\in \mathbb {N}} a(n)\) and \(a^l = \inf _{n\in \mathbb {N}} a(n)\) for any bounded sequence \(\left\{ a(n)\right\} \);

  • \(\mathbb {R}^+\) denotes the set of nonnegative real numbers;

  • \(\mathbb {N}\) be the sets of nonnegative integers;

  • \(\otimes \) denotes the direct product of matrices.

2 Deriving the Difference Equations Model

The system (1) without diffusion is approximated by the following differential equations with piecewise constant arguments

$$\begin{aligned} \begin{aligned} \frac{dx_{i,j}(t)}{dt}&=\bigg ( \beta - \gamma y_{i,j}(\lfloor t/h\rfloor h-\lfloor \tau /h\rfloor h) - \delta _x x_{i,j}(\lfloor t/h\rfloor h-\lfloor \tau /h\rfloor h) \bigg ) x_{i,j}(t),\\ \frac{dy_{i,j}(t)}{dt}&=\bigg ( -\mu _y + \eta \gamma x_{i,j}(\lfloor t/h\rfloor h-\lfloor \tau /h\rfloor h)-\delta _y y_{i,j}(\lfloor t/h\rfloor h) \bigg )y_{i,j}(t) \end{aligned} \end{aligned}$$
(4)

for \(t\in [nh, (n+1)h)\), \(n\in \mathbb {N}\).

Noting that \(\lfloor t/h\rfloor =n\), \(\lfloor \tau /h\rfloor =r\in \mathbb {N}\), we integrate (4) over [nht), where \(t<(n+1)h\), then (4) can be reformulated as

$$\begin{aligned} \begin{aligned} \frac{dx_{i,j}(t)}{dt}=\bigg ( \beta - \gamma y_{i,j}(nh-rh) - \delta _x x_{i,j}(nh-rh) \bigg ) x_{i,j}(t),\\ \frac{dy_{i,j}(t)}{dt}=\bigg ( -\mu _y + \eta \gamma x_{i,j}(nh-rh)-\delta _y y_{i,j}(nh) \bigg )y_{i,j}(t). \end{aligned} \end{aligned}$$

Denoting \(x_{i,j}(n)=x_{i,j}(nh)\), \(y_{i,j}(n)=y_{i,j}(nh)\), then we have

$$\begin{aligned} \begin{aligned} x_{i,j}(t)&=x_{i,j}(n)\exp \bigg \{\beta - \gamma y_{i,j}(n-r) - \delta _x x_{i,j}(n-r) \bigg \},\\ y_{i,j}(t)&=y_{i,j}(n)\exp \bigg \{-\mu _y + \eta \gamma x_{i,j}(n-r) - \delta _y y_{i,j}(n) \bigg \}. \end{aligned} \end{aligned}$$
(5)

Setting \(t\rightarrow (n+1)h\) in (5) and simplifying, adding diffusion to the first equation,Footnote 1 we get a discrete analogue of continuous time system (1) with the form

$$\begin{aligned} \begin{aligned} x_{i,j}(n+1)&=x_{i,j}(n)\exp \bigg \{\beta - \gamma y_{i,j}(n-r) - \delta _x x_{i,j}(n-r) \bigg \} + \hat{S}\bigg \{ x_{i,j}(n) \bigg \},\\ y_{i,j}(n+1)&=y_{i,j}(n)\exp \bigg \{-\mu _y + \eta \gamma x_{i,j}(n-r) - \delta _y y_{i,j}(n) \bigg \}, \end{aligned} \end{aligned}$$
(6)

We pay attention that behavior of the system (6) may not be the same as for the differential one (1). The equivalence of differential versus difference equations trajectories, which are obtained with help of forward Euler, backward Euler or central difference schemes, may be for “sufficiently small discretization time steps” only [12]. The problems of equivalence of difference and differential Lotka–Volterra equations were firstly studied in [18]. The derivation of the discrete model (6) is the standard connection between Lotka–Volterra continuous time model and discrete time Nicholson–Bailey model [18]. The Nicholson–Bailey model was derived in order to have similar dynamical properties as Lotka–Volterra ones.

In [16] nonstandard Mickens scheme of time-discretization was described, which was further used in order to get dynamical consistency between discrete-time and continuous-time models in a lot of research and applications [17].

With respect to time-discretization of lattice reaction-diffusion equations we have a wide range of research—in the one-dimensional lattice [5, 6], higher dimensional lattices [9], papers dealing with the exact role of the time discretization on the existence of travelling waves [10] or validity of maximum and comparison principles [23] which is the main reason which led authors to the alternative discretization. There are also numerous contributions in the case of delayed lattice differential equations, for example [14, 25].

In Sect. 5 we investigate the problem of qualitative consistency between (6) and (1) numerically.

We introduce the following definitions for finite lattice difference equations (6).

Definition 1

It is said that system (6) is quasi-permanent if there exist positive constants \(m_{x}\), \(M_{x}\), \(m_{y,i,j}\), \(M_{y,i,j}\), \(i,j=\overline{1,N}\) that every positive solution \(\left\{ \bigg ( x_{i,j}(n),y_{i,j}(n) \bigg )\right\} \), \(i,j=\overline{1,N}\) of system (6) satisfies

$$\begin{aligned} \begin{aligned} m_{x}\le \lim \inf _{n\rightarrow \infty }\sum _{i,j=1}^N{x_{i,j}(n)} \le \lim \sup _{n\rightarrow \infty } \sum _{i,j=1}^N{x_{i,j}(n)} \le M_{x},\\ m_{y,i,j}\le \lim \inf _{n\rightarrow \infty } y_{i,j}(n) \le \lim \sup _{n\rightarrow \infty } y_{i,j}(n) \le M_{y,i,j}. \end{aligned} \end{aligned}$$

Definition 2

A positive solution \(\left\{ \bigg ( x_{i,j}^\star (n),y_{i,j}^\star (n) \bigg )\right\} \), \(i,j=\overline{1,N}\) of system (6) is globally attractive if each other positive solution \(\left\{ \bigg ( x_{i,j}(n),y_{i,j}(n) \bigg )\right\} \), \(i,j=\overline{1,N}\) of system (6) satisfies

$$\begin{aligned} \lim _{n\rightarrow \infty } |x_{i,j}(n)-x_{i,j}^\star (n)|=0, \quad \lim _{n\rightarrow \infty } |y_{i,j}(n)-y_{i,j}^\star (n)|=0, \quad i,j=\overline{1,N}. \end{aligned}$$

3 Permanence

In spite of the fact that a series of results were obtained when considering permanence of Nicholson models without diffusion, e.g. recent ones are [7, 13, 26], much more less permanence results were established for discrete reaction-diffusion models. Here we mention work [1] for on one- and two-dimensional lattices. These results were approved numerically in [3].

Here we have already introduced the notion of quasi-permanence of the system (6) which is “weaker” as compared with traditional permanence. The reason is the taking into account diffusion of \(x_{i,j}\) within the finite lattice. In turn, the system is permanent with respect to \(y_{i,j}(n)\) in a traditional sense.

In order to prove quasi-permanence of the system (6), we need the following auxiliary results from [26].

Lemma 1

It holds

$$\begin{aligned} \max _{x\in \mathbb {R}} x\exp {(\beta (1-x))} = \frac{\exp {(\beta -1)}}{\beta } \end{aligned}$$
(7)

for \(\beta >0\).

Lemma 2

Assume that x(n) satisfies \(x(n) > 0\) and

$$\begin{aligned} x(n + 1) \le x(n) \exp \left\{ s(n)(1 - ax(n))\right\} \end{aligned}$$
(8)

for \(n \in [n_1,\infty )\), where a is a positive constant. Then

$$\begin{aligned} \lim _{n\rightarrow \infty }\sup x(n) \le \frac{1}{a s^u} \exp \left\{ s^u - 1\right\} . \end{aligned}$$
(9)

Lemma 3

Assume that \(\left\{ x(n)\right\} \) satisfies

$$\begin{aligned} x(n + 1)\ge x(n) \exp \left\{ s(n)(1 - ax(n))\right\} ,\quad n\ge N_0, \end{aligned}$$
(10)

\(\lim _{n\rightarrow \infty } \sup x(n)\le x^u\) and \(x(N_0) > 0\), where a is a constant such that \(ax^u > 1\) and \(N_0 \in \mathbb {N}\). Then

$$\begin{aligned} \lim _{n\rightarrow \infty } \inf x(n) \ge \frac{1}{a} \exp \left\{ s^u(1 - ax^u)\right\} . \end{aligned}$$
(11)

The next auxiliary result is related to necessary condition to the positive invariance of the positive orthant

$$\begin{aligned} \varOmega = \left\{ \bigg ( x_{i,j}(n), y_{i,j}(n) \bigg ) : i,j =\overline{1,N}, x_{i,j}(n)>0, y_{i,j}(n)>0 \right\} \end{aligned}$$

Lemma 4

Assume that the positive orthant \(\varOmega \) is positive invariant for the system (6), i.e. \(x_{i,j}(0)>0, y_{i,j}(0)>0\) implies \(x_{i,j}(n)>0, y_{i,j}(n)>0\), \(n\in \mathbb {N}\), \(i,j=\overline{1,N}\).

Then

$$\begin{aligned} e^\beta > \frac{4D}{\varDelta ^2} \end{aligned}$$
(12)

holds.

Proof

We assume for purposes of contradiction that \(e^\beta \le \frac{4D}{\varDelta ^2}\). Consider a counterexample, if \(N=1\). Then the first equation (6) together with the boundary conditions \(x_{0,1} = x_{2,1} = x_{1,0} = x_{1,2} = 0 = y_{0,1} = y_{2,1} = y_{1,0} = y_{1,2}\) introduced above, yields

$$\begin{aligned} \begin{aligned} x_{1,1}(n + 1)&= x_{1,1}(n) \exp \left\{ \beta - \gamma y_{1,1}(n-r) - \delta _x x_{1,1}(n-r) \right\} - (4D/\varDelta ^2) x_{1,1}(n)\\&\le x_{1,1}(n) ( e^\beta - 4D/\varDelta ^2) \le 0 \end{aligned} \end{aligned}$$

for any \(x_{1,1}(0) > 0\), \(y_{1,1}(0) > 0\), contradicting the original supposition.

The next result introduces a sufficient condition for the underlying grid size ensuring that the solution of (6) is non-vanishing.

Lemma 5

Let for the system (6) the positive orthant \(\varOmega \) be positive invariant. Besides that, let N be such that \(f_{\text {extnc}}(N)<1\) holds, where

$$\begin{aligned} f_{\text {extnc}}(N) = \max _{k,l=\overline{1,N}} \Bigg | e^\beta - \frac{4D}{\varDelta ^2}\Bigg ( 1+\cos \frac{\pi (k+l)}{2(N+1)} \cos \frac{\pi (k-l)}{2(N+1)} \Bigg ) \Bigg |. \end{aligned}$$
(13)

Then \(\lim _{n\rightarrow \infty } x_{i,j}(n) = 0\), \(i,j=\overline{1,N}\).

Proof

It requires a comparison principle for difference equations (see [24], Theorem 2.1, p. 241).

The following inequalities hold for \(x_{i,j}(n+1)\)

$$\begin{aligned} x_{i,j}(n+1) < x_{i,j}(n) e^\beta + \hat{S}\left\{ x_{i,j}(n) \right\} . \end{aligned}$$

Consider \(N^2\)-vector of the form

$$\begin{aligned} \begin{aligned} X(n)=\Bigg (&x_{1,1}(n),x_{1,2}(n),\dots ,x_{1,N}(n),x_{2,1}(n),\dots ,x_{2,N}(n),\dots ,\\&x_{N,1}(n),\dots ,x_{N,N}(n) \Bigg )^\top . \end{aligned} \end{aligned}$$

We compare \(X(n+1)\le CX(n)\), where \(C=I_N \otimes A + B \otimes I_N\),

$$\begin{aligned} A=\begin{bmatrix} e^\beta - \frac{4D}{\varDelta ^2}&{}\frac{D}{\varDelta ^2}&{} &{} &{} &{} &{}\\ \frac{D}{\varDelta ^2}&{}e^\beta - \frac{4D}{\varDelta ^2}&{}\frac{D}{\varDelta ^2}&{} &{} &{} &{}\\ &{} \frac{D}{\varDelta ^2}&{}\ddots &{} &{} &{} &{}\\ &{} &{} &{} &{}\ddots &{} &{} \\ &{} &{} &{} &{} &{} e^\beta - \frac{4D}{\varDelta ^2} &{} \frac{D}{\varDelta ^2}\\ &{} &{} &{} &{} &{} \frac{D}{\varDelta ^2} &{} e^\beta - \frac{4D}{\varDelta ^2} \end{bmatrix} \in \mathbb {R}^{N\times N}, \end{aligned}$$
$$\begin{aligned} B=\begin{bmatrix} 0&{}\frac{D}{\varDelta ^2}&{} &{} &{} &{} &{}\\ \frac{D}{\varDelta ^2}&{}0&{}\frac{D}{\varDelta ^2}&{} &{} &{} &{}\\ &{} \frac{D}{\varDelta ^2}&{}\ddots &{} &{} &{} &{}\\ &{} &{} &{} &{}\ddots &{} &{} \\ &{} &{} &{} &{} &{} 0 &{} \frac{D}{\varDelta ^2}\\ &{} &{} &{} &{} &{} \frac{D}{\varDelta ^2} &{} 0 \end{bmatrix} \in \mathbb {R}^{N\times N}, \end{aligned}$$

\(I_N\) is \(N\times N\) identity matrix. The \(N^2\) eigenvalues of C are of the form (see [11], Theorem 8.3.1) \(\lambda _{k,l}(C)=\lambda _k(A) + \lambda _l(B)\), \(k,l=\overline{1,N}\), where the eigenvalues of A

$$\begin{aligned} \lambda _k(A)=e^\beta - \frac{4D}{\varDelta ^2}-\frac{2D}{\varDelta ^2}\cos {(\pi k/(N+1))}, \quad k=\overline{1,N}, \end{aligned}$$

the eigenvalues of B

$$\begin{aligned} \lambda _l(B)=-\frac{2D}{\varDelta ^2}\cos {(\pi l/(N+1))}, \quad l=\overline{1,N}. \end{aligned}$$

The comparison system \(Z(n+1)=CZ(n)\) tends asymptotically to zero if \(\bigg | \lambda _{k,l} \bigg | <1\). That is,

$$\begin{aligned} \max _{k,l=\overline{1,N}} \Bigg | e^\beta - \frac{4D}{\varDelta ^2} - \frac{2D}{\varDelta ^2}\Bigg ( \cos \frac{\pi k}{N+1} + \cos \frac{\pi l}{N+1} \Bigg ) \Bigg | <1. \end{aligned}$$

Theorem 1

Consider the system (6) satisfying the positive invariance of the set \(\varOmega \).Footnote 2 Let

$$\begin{aligned} \begin{aligned} \alpha _{1,i,j}&=-\mu _y + \eta \gamma M_{x,i,j} \frac{\exp (\beta - 1)}{\delta _x},\\ \alpha _{2,i,j}&=\beta - \gamma \frac{\exp (\alpha _{1,i,j}-1)}{\delta _y},\\ \alpha _{3,i,j}&=-\mu _y + \frac{\eta \gamma }{\delta _x}\exp (\alpha _{2,i,j}(1-\delta _x \zeta _{i,j})), \end{aligned} \end{aligned}$$
(14)

where \(\zeta _{i,j}\), \(i,j=\overline{1,N}\) are some constants.

If there exist \(M_{x,i,j}(r)>1\), \(i,j=\overline{1,N}\) such that for any \(\zeta _{i,j}>0\), \(i,j=\overline{1,N}\) conditions

$$\begin{aligned} \min \left\{ \alpha _{k,i,j}, k=\overline{1,3},i,j=\overline{1,N} \right\} >0 \end{aligned}$$
(15)

hold, then system (6) is quasi-permanent.

Proof

Since \(\varOmega \) is a positive invariant set of (6), we assume that \(\left\{ \bigg ( x_{i,j}(n), y_{i,j}(n) \bigg ),\right. \left. i,j=\overline{1,N} \right\} \) is its arbitrary positive solution.

Firstly we prove that \(\left\{ \bigg ( x_{i,j}(n), y_{i,j}(n) \bigg ), i,j=\overline{1,N} \right\} \) is uniformly upper bounded. Consider the first equation of (6). We get

$$\begin{aligned} \begin{aligned} x_{i,j}(n+1)\le x_{i,j}(n)\exp \left\{ \beta - \delta _x x_{i,j}(n-r) \right\} + \hat{S}\left\{ x_{i,j}(n) \right\} \\ = x_{i,j}(n)\exp \left\{ \beta \bigg ( 1-\frac{\delta _x}{\beta }x_{i,j}(n-r) \bigg )\right\} + \hat{S}\left\{ x_{i,j}(n) \right\} . \end{aligned} \end{aligned}$$
(16)

Let \(n_{1,i,j}(r)\in \mathbb {N}\) be such that

$$\begin{aligned} \frac{x_{i,j}(n)}{x_{i,j}(n-r)}<M_{x,i,j}, \quad n>n_1. \end{aligned}$$

Applying Lemma 1 it implies for \(n>n_{1,i,j}(r)\)

$$\begin{aligned} \begin{aligned} x_{i,j}(n+1)&\le M_{x,i,j}(r)x_{i,j}(n-r)\exp \left\{ \beta \left( 1-\frac{\delta _x}{\beta }x_{i,j}(n-r)\right) \right\} + \hat{S}\left\{ x_{i,j}(n) \right\} \\&\le M_{x,i,j}(r)\frac{\beta }{\delta _x} \frac{\exp {(\beta -1)}}{\beta } + \hat{S}\left\{ x_{i,j}(n) \right\} \\&=M_{x,i,j}(r) \frac{\exp {(\beta -1)}}{\delta _x} + \hat{S}\left\{ x_{i,j}(n) \right\} . \end{aligned} \end{aligned}$$

Hence, for \(n>n_1(r)=\max _{i,j=\overline{1,N}}n_{1,i,j}(r)\) we have

$$\begin{aligned} \lim _{n\rightarrow \infty } \sup \sum _{i,j=1}^N{x_{i,j}(n)}\le \frac{\exp (\beta -1)}{\delta _x}\sum _{i,j=1}^N{M_{x,i,j}(r)}=: M_x(r). \end{aligned}$$

Moreover, there exists a sufficiently large \(n_2(\epsilon )\in \mathbb {N}\), that for any constant \(\epsilon >0\) it holdsFootnote 3

$$\begin{aligned} x_{i,j}(n)\le M_{x,i,j}(r)\frac{\exp {(\beta - 1)}}{\delta _x}+\epsilon ,\quad n\ge n_2(\epsilon ). \end{aligned}$$
(17)

Consider the second equation of (6). Hence we get

$$\begin{aligned} \begin{aligned} y_{i,j}(n+1)\le&y_{i,j}(n) \exp {\left\{ -\mu _y + \eta \gamma [M_{x,i,j}(r)\frac{\exp (\beta -1)}{\delta _x}+\epsilon ] - \delta _y y_{i,j}(n) \right\} }\\ =&y_{i,j}(n)\exp \left\{ \alpha _{x,i,j}^\epsilon \left( 1-\frac{\delta _y}{\alpha _{x,i,j}^\epsilon }y_{i,j}(n)\right) \right\} . \end{aligned} \end{aligned}$$

Here

$$\begin{aligned} \alpha _{1,i,j}^\epsilon := -\mu _y + \eta \gamma \left[ M_{x,i,j}(r)\frac{\exp (\beta -1)}{\delta _x}+\epsilon \right] \end{aligned}$$

Applying Lemma 2 and letting \(\epsilon \rightarrow 0\), we have

$$\begin{aligned} \lim _{n\rightarrow \infty } \sup y_{i,j} (n)\le \frac{\exp (\alpha _{1,i,j}^0 - 1)}{\delta _y}=:F_{i,j}^u. \end{aligned}$$
(18)

Hence it follows that

$$\begin{aligned} \lim _{n\rightarrow \infty } \sup \sum _{i,j=1}^N{y_{i,j} (n)}\le \sum _{i,j=1}^N\frac{\exp (\alpha _{1,i,j}^0 - 1)}{\delta _y}=:M_y. \end{aligned}$$

Further we prove that \(\left\{ (x_{i,j},y_{i,j}), i,j=\overline{1,N} \right\} \) is uniformly ultimately lower bounded.

According to (18), there exists an \(n_3(\epsilon )>n_2(\epsilon )\) such that

$$\begin{aligned} y_{i,j}(n)\le \frac{\exp (\alpha _{1,i,j}^0 - 1)}{\delta _y} + \epsilon \end{aligned}$$

for \(n>n_3\) and constant \(\epsilon \) determined above.

Due to the first equation of (6) we have

$$\begin{aligned} x_{i,j}(n+1)\ge x_{i,j}(n) \exp \left\{ \beta - \gamma \left( \frac{\exp (\alpha _{1,i,j}^0 -1)}{\delta _y}+\epsilon \right) - \delta _x x_{i,j}(n-r)\right\} . \end{aligned}$$

We have to differ two cases. Case 1. There exists \(n_4(\epsilon )>n_3(\epsilon )\) such that \(x_{i,j}(n)<x_{i,j}(n-r)\), \(n>n_4\). It implies

$$\begin{aligned} x_{i,j}(n+1)\ge x_{i,j}(n) \exp \left\{ \alpha _{2,i,j}^\epsilon (1-\delta _x x_{i,j}(n) \right\} . \end{aligned}$$

Here

$$\begin{aligned} \alpha _{2,i,j}^\epsilon := \beta - \gamma \left( \frac{\exp (\alpha _{1,i,j}^0 -1)}{\delta _y}+\epsilon \right) . \end{aligned}$$

Due to Lemma 3 we get

$$\begin{aligned} x_{i,j}(n)\ge \frac{1}{\delta _x} \exp \left\{ \alpha _{2,i,j}^\epsilon (1-\delta _x \left( M_{x,i,j}(r) \frac{\exp (\beta -1)}{\delta _x} + \epsilon \right) \right\} \end{aligned}$$

Let \(\epsilon \rightarrow 0\). It implies

$$\begin{aligned} \lim _{n\rightarrow \infty } \inf x_{i,j}(n) \ge \frac{1}{\delta _x}\exp \left\{ \alpha _{2,i,j}^0 \left( 1-\delta _x M_{x,i,j}(r) \frac{\exp (\beta -1)}{\delta _x} \right) \right\} \end{aligned}$$

Case 2. For all \(n>n_2(\epsilon )\) we have \(x_{i,j}(n)\ge x_{i,j}(n-r)\). It follows that \(\lim _{n\rightarrow \infty } x_{i,j}(n)=x_{i,j}^u\) exists, where \(x_{i,j}^u:=x_{i,j}(0)\exp {\beta }\). On the other hand \(x_{i,j}^u\ge \frac{1}{\delta _x}\). It follows that

$$\begin{aligned} \lim _{n\rightarrow \infty } \inf x_{i,j}(n) \ge \frac{1}{\delta _x} \exp \left\{ \alpha _{2,i,j}(1-\delta _x x_{i,j}^u) \right\} \end{aligned}$$

Considering the second equation of (6), we get

$$\begin{aligned} y_{i,j}(n+1)\ge y_{i,j}(n) \exp \left\{ \kappa _{i,j}\left( 1-\frac{\delta _y}{\kappa _{i,j}}y_{i,j}(n) \right) \right\} . \end{aligned}$$

Here

$$\begin{aligned} \kappa _{i,j}:= -\mu _y + \frac{\eta \gamma }{\delta _x}\exp \left\{ \alpha _{2,i,j}^0(1-\delta _x x_{i,j}^u) \right\} . \end{aligned}$$

Further we use the following inequalityFootnote 4

$$\begin{aligned} \frac{\delta _y}{\kappa _{i,j}}y_{i,j}^u = \frac{\exp (\alpha _{1,i,j}^0)-1}{\kappa _{i,j}}\ge \frac{\exp (\alpha _{1,i,j}^0)-1}{\alpha _{1,i,j}^0}>1. \end{aligned}$$

Applying Lemma 3, we have

$$\begin{aligned} \lim _{n\rightarrow \infty }\inf y_{i,j}(n)\ge \frac{\kappa _{i,j}}{\delta _y} \exp \left\{ \kappa _{i,j}\left( 1-\frac{\delta _y}{\kappa _{i,j}}y_{i,j}^u \right) \right\} . \end{aligned}$$

4 Stability Investigation for the Finite Lattice Difference Model of Immunosensor

4.1 Steady States

The complex topology of set of endemic steady states for lattice Nagumo reaction-diffusion dynamical systems were studied in [6]. Moreover, when considering Nagumo equation on graphs, in [22] they observed that for sufficiently strong reactions (or sufficiently weak diffusion) there are exponentional growth of the number of endemic steady states.

In general case steady state \(\mathcal {E}_{i,j} \equiv \Bigg ( x_{i,j}, y_{i,j} \Bigg )\), \(i,j=\overline{1,N}\) for difference system (6) can be found as a result of solution of the algebraic system:

$$\begin{aligned} \begin{aligned} x_{i,j}&=x_{i,j}\exp \bigg \{\beta - \gamma y_{i,j} - \delta _x x_{i,j} \bigg \} + \hat{S}\bigg \{ x_{i,j} \bigg \},\\ y_{i,j}&= y_{i,j}\exp \bigg \{-\mu _y + \eta \gamma x_{i,j} - \delta _y y_{i,j}\bigg \}, \end{aligned} \end{aligned}$$
(19)

with respect to \((x_{i,j},y_{i,j})\), \(i,j=\overline{1,N}\). We have to distinguish the following cases.

Antigen and antibody-free steady state \(\mathcal {E}_{i,j}^{0,0}\equiv \mathcal {E}^{0,0} = \Bigg ( 0, 0 \Bigg )\), \(i,j=\overline{1,N}\).

Antibody-free endemicFootnote 5 steady state. The system (6) has so-called antibody-free steady state, namely

$$\begin{aligned} \mathcal {E}_{i,j}^{*,0}\equiv \mathcal {E}^{*,0} = \left( \frac{\beta }{\delta _x}, 0 \right) ,\quad i,j=\overline{1,N} \end{aligned}$$

Identical endemic steady state. In case if \(x_{i,j}\equiv x>0\), \(i,j=\overline{1,N}\) (it yields \(\hat{S}\bigg \{ x_{i,j} \bigg \}\equiv 0\)) we get steady state \(\mathcal {E}_{i,j} \equiv \mathcal {E}^{idnt}=\Bigg ( x^{idnt}, y^{idnt} \Bigg )\), where

$$\begin{aligned} x^{idnt} = \frac{\beta \delta _y + \gamma \mu _y}{\eta \gamma ^2 + \delta _x \delta _y}, \quad y^{idnt} = \frac{-\mu _y \delta _x + \eta \gamma \beta }{\eta \gamma ^2 + \delta _x \delta _y}. \end{aligned}$$

We see that if \(-\mu _y \delta _x + \eta \gamma \beta >0\), then \(\mathcal {E}^{idnt}\) is endemic.

Nonidentical endemic steady state. In general case we need to solve the algebraic system (19) to find endemic steady state, which we call here as nonidentical steady state \(\mathcal {E}^{nonidnt}=\Bigg ( x_{i,j}^{nonidnt}, y_{i,j}^{nonidnt} \Bigg )\), \(i,j=\overline{1,N}\). In case if all \((x_{i,j}^{nonidnt}, y_{i,j}^{nonidnt})>0\), then \(\mathcal {E}^{nonidnt}\) is endemic. We note that the values of \(x^{idnt}\) and \(y^{idnt}\) can be used as initial approximations for numerical methods to solve nonlinear algebraic system (19).

4.2 Global Attractivity

In [21, 28] there were studied the global attractivity of the positive equilibrium of the discrete Nicholsons model. Global attractivity of Nicholson’s differential equation with continuous diffusion was investigated in [27] with help of maximum principle. In case of continuous-time reaction-diffusion model from \(\mathbb {R}^n\) on graphs, it was shown that at some parameters there are \(3^n\) stationary solutions, out of which \(2^n\) are asymptotically stable [22].

It is natural to expect a possible global attractivity of large number of positive solutions for difference model (6). The next result offers the sufficient conditions of global attractivity, which were obtained with help of Lyapunov functions.

Theorem 2

Assume that conditions of the Theorem 1 hold and there exists a positive constant \(\xi \) such that

$$\begin{aligned} \begin{aligned} \exp&\left\{ \gamma m_y + \delta _x m_x - \beta \right\} - \delta _x - \frac{1}{m_x} - \eta \gamma \ge \xi ,\\ \min&\left\{ \delta _y , \frac{2}{M_y}-\delta _y \right\} - \gamma \ge \xi . \end{aligned} \end{aligned}$$
(20)

Then any positive solution \(\left\{ \bigg (x_{i,j}^\star (n) ,y_{i,j}^\star (n) \bigg ), i,j=\overline{1,N} \right\} \) of system (6) is globally attractive.

Proof

Consider \(\left\{ \bigg (x_{i,j}(n) ,y_{i,j}(n) \bigg ), i,j=\overline{1,N} \right\} \) is arbitrary positive solution of system (6). Let

$$\begin{aligned} V_{1,1,i,j}(n)=|\ln \bigg (x_{i,j}(n)-\hat{S}\left\{ x_{i,j}(n-1) \right\} \bigg ) - \ln \bigg (x_{i,j}^\star (n)-\hat{S}\left\{ x_{i,j}^\star (n-1) \right\} \bigg ) | \end{aligned}$$

Then it follows from the first equation of (6) that

$$\begin{aligned} \begin{aligned} V_{1,1,,i,j}\le&|\ln x_{i,j}(n)-\ln x_{i,j}^\star (n) | + \gamma |y_{i,j}(n-r)-y_{i,j}^\star (n-r) |\\&+ \delta _v |x_{i,j}(n-r)-x_{i,j}^\star (n-r) |. \end{aligned} \end{aligned}$$
(21)

By the Mean Value theorem, we get

$$\begin{aligned} \ln x_{i,j}(n) - \ln x_{i,j}^\star (n) = \frac{1}{\theta _1(n)}(x_{i,j}(n) - x_{i,j}^\star (n)), \end{aligned}$$

where \(\theta _1(n)\) lies between \(x_{i,j}(n)\) and \(x_{i,j}^\star (n)\),

$$\begin{aligned} \begin{aligned} \ln (x_{i,j}(n)-\hat{S}\left\{ x_{i,j}(n-1) \right\} ) - \ln (x_{i,j}^\star (n) -\hat{S}\left\{ x_{i,j}^\star (n-1) \right\} )\\ = \frac{1}{\theta _2(n)}((x_{i,j}(n) - x_{i,j}^\star (n)) - (\hat{S}\left\{ x_{i,j}(n-1) \right\} - \hat{S}\left\{ x_{i,j}^\star (n-1) \right\} )), \end{aligned} \end{aligned}$$

where \(\theta _2(n)\) lies between \(x_{i,j}(n)-\hat{S}\left\{ x_{i,j}(n-1) \right\} \) and \(x_{i,j}^\star (n) -\hat{S}\left\{ x_{i,j}^\star (n-1) \right\} \).

We consider

$$\begin{aligned} \begin{aligned}&|\ln x_{i,j}(n) - \ln x_{i,j}^\star (n) | \\&= |\ln (x_{i,j}(n)-\hat{S}\left\{ x_{i,j}(n-1) \right\} ) - \ln (x_{i,j}^\star (n) -\hat{S}\left\{ x_{i,j}^\star (n-1) \right\} ) |\\&-|\ln (x_{i,j}(n)-\hat{S}\left\{ x_{i,j}(n-1) \right\} ) - \ln (x_{i,j}^\star (n) -\hat{S}\left\{ x_{i,j}^\star (n-1) \right\} ) |\\&+ |\ln x_{i,j}(n) - \ln x_{i,j}^\star (n) |\\&\ge V_{1,1,i,j}(n) - \bigg ( \frac{1}{\theta _2(n)}-\frac{1}{\theta _1(n)} \bigg ) |x_{i,j}(n)-x_{i,j}^\star (n) | \\&- \frac{1}{\theta _2(n)}\bigg ( \hat{S}\left\{ x_{i,j}(n-1) \right\} - \hat{S}\left\{ x_{i,j}^\star (n-1) \right\} \bigg ). \end{aligned} \end{aligned}$$
(22)

Combining (21) and (22), we have

$$\begin{aligned} \begin{aligned} \varDelta V_{1,1,i,j}(n)&=V_{1,1,i,j}(n+1)-V_{1,1,i,j}(n) \\&\le - \bigg ( \frac{1}{\theta _2(n)}-\frac{1}{\theta _1(n)} \bigg ) |x_{i,j}(n)-x_{i,j}^\star (n) |\\&+ \gamma |y_{i,j}(n-r)-y_{i,j}^\star (n-r) |\\&+ \delta _x |x_{i,j}(n-r)-x_{i,j}^\star (n-r) | \\&- \frac{1}{\theta _2(n)}\bigg ( \hat{S}\left\{ x_{i,j}(n-1) \right\} - \hat{S}\left\{ x_{i,j}^\star (n-1) \right\} \bigg ). \end{aligned} \end{aligned}$$
(23)

Next, we let

$$\begin{aligned} V_{1,2,i,j}(n)=\sum _{s=n-r}^{n-1}{\delta _v |x_{i,j}(s)-x_{i,j}^\star (s) |} + \sum _{s=n-r}^{n-1}{\gamma |y_{i,j}(s)-y_{i,j}^\star (s) |} \end{aligned}$$

Then we have

$$\begin{aligned} \begin{aligned} \varDelta V_{1,2,i,j}(n)&=V_{1,2,i,j}(n+1)-V_{1,2,i,j}(n) \\&=\sum _{s=n+1-r}^{n}{\delta _x |x_{i,j}(s)-x_{i,j}^\star (s) |} + \sum _{s=n+1-r}^{n}{\gamma |y_{i,j}(s)-y_{i,j}^\star (s) |}\\&-\sum _{s=n-r}^{n-1}{\delta _x |x_{i,j}(s)-x_{i,j}^\star (s) |} - \sum _{s=n-r}^{n-1}{\gamma |y_{i,j}(s)-y_{i,j}^\star (s) |}\\&= \delta _x |x_{i,j}(n)-x_{i,j}^\star (n) | - \delta _x |x_{i,j}(n-r)-x_{i,j}^\star (n-r) |\\&+ \gamma |y_{i,j}(n)-y_{i,j}^\star (n) | - \gamma |y_{i,j}(n-r)-y_{i,j}^\star (n-r) |. \end{aligned} \end{aligned}$$
(24)

We let \(W_{1,i,j}=V_{1,1,i,j}(n)+V_{1,2,i,j}(n)\). Then it follows from (23) and (24) that

$$\begin{aligned} \begin{aligned} \varDelta V_{1,i,j}(n)&= \varDelta V_{1,1,i,j}(n) + \varDelta V_{1,2,i,j}(n)\\&\le \bigg ( \delta _x - \frac{1}{\theta _2(n)} + \frac{1}{\theta _1(n)}\bigg ) |x_{i,j}(n)-x_{i,j}^\star (n) | \\&+ \gamma |y_{i,j}(n)-y_{i,j}^\star (n) |\\&- \frac{1}{\theta _2(n)}\bigg ( \hat{S}\left\{ x_{i,j}(n-1) \right\} - \hat{S}\left\{ x_{i,j}^\star (n-1) \right\} \bigg ) \end{aligned} \end{aligned}$$
(25)

In a similar way we define for the second equation of (6)

$$\begin{aligned} \begin{aligned} V_{2,i,j}(n)=V_{2,1,i,j}(n)+V_{2,2,i,j}(n), \end{aligned} \end{aligned}$$

where

$$\begin{aligned} \begin{aligned} V_{2,1,i,j}(n)&=|\ln y_{i,j}(n)-\ln y_{i,j}^\star (n) |,\\ V_{2,2,i,j}(n)&=\sum _{s=n-r}^{n-1}{\eta \gamma |x_{i,j}(s)-x_{i,j}^\star (s) |}. \end{aligned} \end{aligned}$$

Then we have

$$\begin{aligned} \begin{aligned} \varDelta V_{2,1,i,j}(n)&=V_{2,1,i,j}(n+1)-V_{2,1,i,j}(n)\\&\le -\Bigg ( \frac{1}{\theta _3(n)}-|\frac{1}{\theta _3}-\delta _y |\Bigg )|y_{i,j}(n)-y_{i,j}^\star |\\&+ \eta \gamma |x_{i,j}(n-r)-x_{i,j}^\star (n-r) |, \end{aligned} \end{aligned}$$

where \(\theta _3\) is between \(y_{i,j}(n)\) and \(y_{i,j}^\star (n)\),

$$\begin{aligned} \varDelta V_{2,2,i,j}(n)=\eta \gamma |x_{i,j}(n)-x_{i,j}^\star (n) | - \eta \gamma |x_{i,j}(n-r)-x_{i,j}^\star (n-r) |. \end{aligned}$$

Hence

$$\begin{aligned} \begin{aligned} \varDelta V_{2,i,j}(n)&=\varDelta V_{2,1,i,j}(n)+\varDelta V_{2,2,i,j}(n) \\&\le -\Bigg ( \frac{1}{\theta _3(n)}-|\frac{1}{\theta _3}-\delta _y |\Bigg )|y_{i,j}(n)-y_{i,j}^\star (n) | \\&+ \eta \gamma |x_{i,j}(n)-x_{i,j}^\star (n) |. \end{aligned} \end{aligned}$$
(26)

Now, we introduce for any pixel (ij) Lyapunov function

$$\begin{aligned} V_{i,j}(n)=V_{1,i,j}(n)+V_{2,i,j}(n). \end{aligned}$$
(27)

According to (25)–(27) we have

$$\begin{aligned} \begin{aligned} \varDelta V_{i,j}(n)&=\varDelta V_{1,i,j}(n) +\varDelta V_{2,i,j}(n)\\&\le \Bigg ( \delta _x - \frac{1}{\theta _2(n)}+\frac{1}{\theta _1(n)}+\eta \gamma \Bigg )|x_{i,j}(n)-x_{i,j}^\star (n) |\\&+ \Bigg ( \gamma -\frac{1}{\theta _3(n)}-|\frac{1}{\theta _3}-\delta _y |\Bigg )|y_{i,j}(n)-y_{i,j}^\star (n) |\\&-\frac{1}{\theta _2(n)}\bigg ( \hat{S}\left\{ x_{i,j}(n-1) \right\} - \hat{S}\left\{ x_{i,j}^\star (n-1) \right\} \bigg ). \end{aligned} \end{aligned}$$

We let \(V(n)=\sum _{i,j=1}^N{V_{i,j}(n)}\). When summing \(\varDelta V_{i,j}(n)\) through \(i,j=\overline{1,N}\), and taking into account the diffusion properties of spatial operator, we get

$$\begin{aligned} \begin{aligned} \varDelta V(n)&\le \Bigg ( \delta _x - \frac{1}{\theta _2(n)}+\frac{1}{\theta _1(n)}+\eta \gamma \Bigg )\sum _{i,j=1}^N{|x_{i,j}(n)-x_{i,j}^\star (n) |}\\&+ \Bigg ( \gamma -\frac{1}{\theta _3(n)}-|\frac{1}{\theta _3}-\delta _y |\Bigg )\sum _{i,j=1}^N{|y_{i,j}(n)-y_{i,j}^\star (n) |}\\&\le \Bigg ( \delta _x - \exp {\left\{ \gamma m_y + \delta _x m_x-\beta \right\} }+\frac{1}{m_x}+\eta \gamma \Bigg )\sum _{i,j=1}^N{|x_{i,j}(n)-x_{i,j}^\star (n) |}\\&+ \Bigg ( \gamma -\min \left\{ \delta _y, \frac{2}{M_y}-\delta _y \right\} \Bigg )\sum _{i,j=1}^N{|y_{i,j}(n)-y_{i,j}^\star (n) |}\\&\le -\xi \Bigg ( \sum _{i,j=1}^N{|x_{i,j}(n)-x_{i,j}^\star (n) |} + \sum _{i,j=1}^N{|y_{i,j}(n)-y_{i,j}^\star (n) |} \Bigg ). \end{aligned} \end{aligned}$$

It completes the proof.

5 Numerical Investigation

In work [15] we investigated numerically the continuous-time model of immunosensor (1) at parameters values:

\(\beta = 2\,\text {min}^{-1}\), \(\gamma = 2\,\frac{\text {mL}}{\text {min} \cdot \mu \text {g}}\), \(\mu _y = 1\,\text {min} ^{-1}\), \(\eta = 0.8/\gamma \), \(\delta _x = 0.5\,\frac{\text {mL}}{\text {min} \cdot \mu \text {g}}\), \(\delta _y = 0.5\,\frac{\text {mL}}{\text {min} \cdot \mu \text {g}}\), \(D/\varDelta ^2 = 2.22\,{\text {min}}^{-1}\).

Here we analyze its discrete analogue, which we obtain with help of scaling some of the corresponding parameters due to discretization step \(h=0.01\) and choosing the others experimentallyFootnote 6\(^{,}\)Footnote 7:

\(\beta = 2h\), \(\gamma = 2\,h\), \(\mu _y = h\), \(\eta = 0.01184/\gamma \), \(\delta _x = 0.5\,h\), \(\delta _y = 0.5\,h\), \(D/\varDelta ^2 = 2.22 \sqrt{h}\).

We see that the scaling of the parameters should be studied deeper. But the exact numerical consistency with the continuous-time system is not the objective of this work. We leave it for our future research.

Fig. 1
figure 1

The values of the function \(f_{\text {extnc}}(N)\) for \(N\in \left\{ 1,2,\dots ,100 \right\} \) (black points) as compared with one (blue line)

Table 1 Numerical simulation of the system (6) at \(r = 8\)

We start from investigating of positivity of the solutions. Firstly, we see that the necessary condition (12) of positive invariance of the set \(\varOmega \) holds. Then, in order to check that \(\lim _{n\rightarrow \infty }x_{i,j}(n) \ne 0\), \(i,j=\overline{1,N}\), we analyze the function \(f_{\text {extnc}}(N)\) (Fig. 1). We see that the value \(N=14\) is the threshold below which \(f_{\text {extnc}}(N)<1\), that is \(\lim _{n\rightarrow \infty }x_{i,j}(n) \ne 0\). Moreover, since \(f_{\text {extnc}}(16)>1\), we conclude that \(\lim _{n\rightarrow \infty }x_{i,j}(n) \ne 0\).

After calculating the steady states for pixels (identical and nonidentical ones), we can apply the global stability conditions (20).

Similarly to differential equations in the discrete-time model we can see that when changing the value of time delay r we have changes of qualitative behavior of pixels and entire model. We considered the parameter value set given above and computed the long-time behavior of the system (6) describing two-dimensional \(16\times 16\)-pixels array (\(N=16\)) for \(r = 8\), 12 and 15. The phase diagrams of the antibody vs. antigen populations for the pixel (8, 8) and its neighborhood for these values of r are shown in Tables 1, 2, 3.

For example, at \(r\le 10\) we can see trajectories corresponding to stable node for all pixels (see Tables 1). At values \(r=10\) Hopf bifurcation occurs and further trajectories correspond to stable limit cycles of ellipsoidal form for all pixels (see Table 2). We note that in order that the numerical solutions regarding Hopf bifurcation were in agreement with the theoretical results, we should apply a Hopf bifurcation theorem from the work [8] which proves appearance of small invariant attracting cycles of radius \(O(\sqrt{h})\).

For \(r=12\), the phase diagrams in Table 2 show that the solution is a limit cycle with two local extrema (one local maximum and one local minimum) per cycle. Then for \(r = 14, 15\) the solution is a limit cycle with twelve local extrema per cycle (see Table 3). Finally, for \(r = 16\), the behavior looks like chaotic one. Similarly as in continuous-time model [15], we have regarded behavior as chaotic if no periodic behavior could be found in the long-time behavior of the solutions.

Table 2 The phase planes of the system (6) for antibody populations \(y_{i,j}\) versus antigen populations \(x_{i,j}\), \(i,j=\overline{7,9}\). Numerical simulation of the system (6) at \(r=12\). Here indicates initial state, indicates identical steady state, indicates nonidentical steady state. The solution converges to a stable limit cycle
Table 3 The limit cycles on the phase plane plots of the system (6) for antibody populations \(y_{i,j}\) versus antigen populations \(x_{i,j}\), \(i,j=\overline{7,9}\). Numerical simulation of the system (6) at \(r=15\). Here indicates identical steady state, indicates nonidentical steady state. Limit cycles are obtained as trajectories for \(t\in [4000,5000]\). The solution converges to a stable limit cycle with twelve local extrema per cycle

At \(D=0\) (i.e., without diffusion) a numerical bifurcation diagram showing the maximum and minimum points for the limit cycles for the antigen population \(x_{1,1}\) as a function of time delay is given in Fig. 2. The Hopf bifurcation from the stable equilibrium point to a simple limit cycle can be clearly seen at \(r=18\). Further all dynamical behavior is characterized as limit cycles, which can be evidenced numerically (see Fig. 3).

At \(D/\varDelta ^2=0.02\) a numerical bifurcation diagram showing the maximum and minimum points for the limit cycles for the antigen population \(V_{1,1}\) as a function of time delay is given in Fig. 4. The Hopf bifurcation from the stable equilibrium point to a simple limit cycle and the sharp transitions at critical values of the time delay between limit cycles with increasing numbers of maximum and minimum points per cycle can be clearly seen.

Fig. 2
figure 2

A numerical bifurcation diagram at \(D=0\). The points show the local extreme points for the \(V_{1,1}\) population at \(n\in [3300,5000]\). Hopf-type bifurcation appears at \(r=18\)

Fig. 3
figure 3

The time series of the solutions to the system (6) for the antigen population \(x_{1,1}\) from \(n =0\) to 5000 with \(D/\varDelta ^2=0.0\) and \(r=24\) for initial conditions \(x_{1,1}(n)=1\) and \(x_{1,1}(t)=1.001\) (deviated), \(n\in [-r, 0]\), and identical all the rest ones. The two solutions appear to be the same, supporting the conclusion that the system behavior is not chaotic

Fig. 4
figure 4

A numerical bifurcation diagram at \(D/\varDelta ^2=0.02\) showing the “bifurcation path to chaos” as the time delay r is increased. The points show the local extreme points per cycle for the \(x_{1,1}\) population. Chaotic-type solutions occur at \(r=16\). Note that at \(r=27, 28\) we have unbounded solutions

Fig. 5
figure 5

The time series of the solutions to the system (6) for the antigen population \(x_{1,1}\) from \(n =0\) to 5000 with \(D/\varDelta ^2=0.02\) and \(r=15\) for initial conditions \(x_{1,1}(n)=1\) and \(x_{1,1}(t)=1.001\) (deviated), \(n\in [-r, 0]\), and identical all the rest ones. The two solutions appear to be the same, supporting the conclusion that the system behavior is not chaotic

As a check that the solution is chaotic for \(r\ge 16\), we perturbed the initial conditions to test the sensitivity of the system. Figures 5, 6, 7 show a comparison of the solutions for the antigen population \(x_{1,1}\) with initial conditions \(x_{1,1}(n)=1\) and \(x_{1,1}(n)=1.001\), \(n\in [-r, 0]\), and identical all the rest ones. In Figs. 6, 7 near the initial time the two solutions appear to be the same, but as time increases there is a marked difference between the solutions supporting the conclusion that the system behavior is chaotic at \(r \ge 16\).

Fig. 6
figure 6

The time series of the solutions to the system (6) for the antigen population \(x_{1,1}\) from \(n =0\) to 5000 with \(D/\varDelta ^2=0.02\) and \(r=16\) for initial conditions \(x_{1,1}(n)=1\) and \(x_{1,1}(t)=1.001\) (deviated), \(n\in [-r, 0]\), and identical all the rest ones. At the beginning the two solutions appear to be the same, but as time increases there is a marked difference between the solutions supporting the conclusion that the system behavior is chaotic

Fig. 7
figure 7

The time series of the solutions to the system (6) for the antigen population \(x_{1,1}\) from \(n =0\) to 5000 with \(D/\varDelta ^2=0.02\) and \(r=26\) for initial conditions \(x_{1,1}(n)=1\) and \(x_{1,1}(t)=1.001\) (deviated), \(n\in [-r, 0]\), and identical all the rest ones. At the beginning the two solutions appear to be the same, but as time increases there is a marked difference between the solutions supporting the conclusion that the system behavior is chaotic

When analyzing an influence of diffusion on qualitative behavior of the model we pay attention on one more the way to chaos presented in Fig. 8. We see that increasing the values of \(D/\varDelta ^2\) we transit from steady state to limit cycles and finally to chaotic behavior at values \(D/\varDelta ^2 \approx 0.025\).

Fig. 8
figure 8

A numerical bifurcation diagram at \(r=12\) showing the “bifurcation path to chaos” as the diffusion \(D/\varDelta ^2\) is increased. The points show the local extreme points per cycle for the \(x_{1,1}\) population. Chaotic-type solutions occur at \(\tau \approx 0.025\) with value 0 for the number of extreme points

6 Conclusions

In the work we offered model of immunosensor which is based on the reaction-diffusion system of the finite lattice difference equations with delay. The main results of the work are conditions of permanence and global asymptotic stability for endemic state. Unfortunately, we are not able to say about permanence of the solution in usual sense. So, here we introduced some “weaker” notion of quasi-permanence allowing us to get conditions in a clear form.

It was shown that the dimension of pixels array N should be large enough (sufficient condition) and the diffusion \(D/\varDelta ^2\) should be small enough (necessary condition) to guarantee the positive invariance.

For the purpose of stability investigation we have used method of Lyapunov functions (it is more correct to say “functionals” here). It combines general approach for construction of Lyapunov functions of predator-prey models with finite lattice differential equations.

Numerical examples showed us influence on stability of different parameters. Increasing time delay we transmit from stable node to limit cycles and finally to chaotic behavior. Such behavior is dynamically consistent with the behavior of continuous-time model, which was studied in [15].

We note that difference with continuous-time model is the way to chaos. Namely, in case of differential equations it was period-doubling, which was characterized by the doubling of the number of local extrema. In case of difference equations we have “chaos” as a result of increasing the number of local extrema (not doubling). It is caused by the discrete nature of the delay r in contrary to the continuous-time system.

Another parameter causing changes in dynamic behavior of the system (6) is the diffusion. Namely, it was numerically shown that when increasing D, we transit from periodic solutions to chaotic ones also.