Introduction

The two-dimensional integral equations and integro-differential equations have a major role the fields of science, mechanics, physics, engineering, and even biology [14], for example it is usually required to solve two dimensional integral equations in the calculation of plasma physics [5], but there are not many simple numerical method with high accuracy for solving these equation.

The subject of the present paper is to apply the two-dimensional triangular function for solving of two-dimensional linear and nonlinear Volterra–Fredholm integro-differential equations. For this proposes we consider the two-dimensional Volterra–Fredholm integro-differential equations of the form

$$\begin{aligned}&a_{1}(s,t)\frac{ \partial ^{n} u(s,t)}{\partial s^{n}}+a_{2}(s,t)\frac{ \partial ^{m} u(s,t)}{\partial t^{m}}+a{3}(s,t)\frac{\partial ^{n+m}u(s,t)}{\partial ^{n}s \partial ^{m}t}+a_{4}(s,t)u(s,t)= f(s,t)\nonumber \\&\quad +\, \lambda _{1} \int _{0}^{t} \int _{0}^{s}G_{1}(s,t,x,y,u(x,y))dxdy\nonumber \\&\quad +\, \lambda _{2} \int _{0}^{T_{1}} \int _{0}^{T_{2}}G_{2}(s,t,x,y,u(x,y))dxdy\quad (x,y)\in D=([0,T_{1})\times [0,T_{2})), \end{aligned}$$
(1)

with given supplementary initial conditions, \(a_1(s,t),\ldots , a_4(s,t)\) are given continuous functions, where u(st) is an unknown function which should be determined, The functions \(G_{1}(s,t,x,y,u)\) and \( G_{2}(s,t,x,y,u)\) are given functions defined on

$$\begin{aligned} W = \{ (s,t,x,y,u):0\le x\le s<T_{1}, 0\le y \le t < T_{2}\}. \end{aligned}$$

For convenience, we put

$$\begin{aligned} G_{1}(s,t,x,y,u)= & {} k_{1}(s,t,x,y)[u(s,t)]^{P_{1}},\\ G_{2}(s,t,x,y,u)= & {} k_{2}(s,t,x,y)[u(s,t)]^{P_{2}}, \end{aligned}$$

where \(p_{1}\) and \(p_{2}\) are positive integers. Moreover f(st) is a known function defined on D. Since any finite interval [ab] can be transformed to [0, 1] by linear maps, it is supposed that \([0,T_{1})=[0,T_{2})=[0,1).\) Without any loss of generality, also \(m, n\in {\mathbb {Z}}^{+}.\)

Until to now, triangular functions have been developed for solving various types of differential and integral equations. For example in [6] Babolian et al. have been approximated by using TFs for solving of nonlinear Volterra–Fredholm integro-differential equations. Maleknejad in [7] have applied a triangular functions (TFs) method for solving the nonlinear Volterra–Fredholm integral equations. Recently, Babolian et al, have applied two dimensional triangular functions for solving nonlinear Volterra–Fredholm integral equations [8]. Also a class of two-dimensional nonlinear Volterra integral equations solved by using Legendre polynomials [9].

On the other hand, there are many numerical methods for solving one-dimensional integral equations of the second kind, but in two-dimensional cases, few works have been done [1013].

In this paper, we use 2D-TFs to approximate solution of the Eq. (1). This paper is organized as follows: In “The Properties of Triangular Function” section, we introduce TFs and their properties. In “Applying the Method” section, introduces application of the method. Some numerical results has been presented in “Numerical Results” section to show accuracy and advantage of the proposed method. Finally, some concluding remarks are given in “Conclusion” section.

The Properties of Triangular Function

In this section, we derive and present some new properties of triangular function that needed in solving nonlinear two-dimensional Volterra Fredholm integro-differential equation of second kind.

One-dimensional Triangular Functions

In a m-set of one-dimensional triangular functions (1D-TFs) over interval [1,0) the ith left hand and right hand functions are defined as

$$\begin{aligned} T_{i}^{1}(s)= & {} \left\{ \begin{array}{rl} 1-\frac{s-ih}{h},&{} \quad ih\le s <(i+1)h,\\ 0,&{} \quad otherwise, \end{array} \right. \\ T_{i}^{2}(s)= & {} \left\{ \begin{array}{rl} \frac{s-ih}{h},&{} \quad ih\le s <(i+1)h,\\ 0 ,&{} \quad otherwise, \end{array} \right. \end{aligned}$$

where \(i=0,\ldots ,m-1, h=\frac{1}{m}.\) It is easy to show that

$$\begin{aligned} T_{i}^{1}(x)+T_{i}^{2}(x)=\phi _{i}(x), \end{aligned}$$
(2)

where \(\phi _{i}\) is the i th block-pulse function defined as

$$\begin{aligned} \phi _{i}(s) = \left\{ \begin{array}{rl} 1,&{} \quad ih\le s<(i+1)h,\\ 0,&{} \quad otherwise. \end{array} \right. \end{aligned}$$

It is obvious that \(\lbrace T_{i}^{1}(s)\rbrace _{i=0}^{m-1}\) and \(\lbrace T_{i}^{2}(s)\rbrace _{i=0}^{m-1} \) are disjoint. So

$$\begin{aligned} T1(s)\cdot T1^{T}(s)\simeq & {} diag(T1(s))=\tilde{T1}(s),\nonumber \\ T1(s)\cdot T2^{T}(s)\simeq & {} 0_{m \times m},\nonumber \\ T2(s)\cdot T1^{T}(s)\simeq & {} 0_{m \times m},\nonumber \\ T2(s)\cdot T2^{T}(s)\simeq & {} diag(T2(s))=\tilde{T1}(s), \end{aligned}$$
(3)

where \(\tilde{T1}(s)\) and \(\tilde{T2}(s)\) are \(m \times m \) diagonal matrices [14]. Orthogonality of 1D-TFs is shown in [15], that is,

$$\begin{aligned} \int _{0}^{1}T_{i}^{p}(s) T_{j}^{q}(s) =\Delta _{p,q}\delta _{i,j}, \end{aligned}$$
(4)

where \(\delta _{ij}\) denotes the Kronecker delta function and

$$\begin{aligned} \Delta _{p,q} = \left\{ \begin{array}{rl} \frac{h}{3},&{} \quad p=q \in \lbrace 1,2\rbrace \\ \frac{h}{6}, &{} \quad p\ne q.\\ \end{array} \right. \end{aligned}$$
(5)

If we define

$$\begin{aligned} T_{1}(s)= & {} \left[ T_{0}^{1}(s),T_{1}^{1}(s),\ldots ,T_{m-1}^{1}(s)\right] ^{T},\\ T_{2}(s)= & {} \left[ T_{0}^{2}(s),T_{1}^{2}(s),\ldots ,T_{m-1}^{2}(s)\right] ^{T}, \end{aligned}$$

and

$$\begin{aligned} T(s)= \begin{bmatrix} T_{1}(s) \\ T_{2}(s) \end{bmatrix}, \end{aligned}$$
(6)

then T(s) is called the 1D-TF vector.

$$\begin{aligned} \int _{0}^{1}T1(t)T1^{T}dt= & {} \int _{0}^{1}T2(t)T2^{T}dt=\frac{h}{3}I_{m\times m}, \end{aligned}$$
(7)
$$\begin{aligned} \int _{0}^{1}T1(t)T2^{T}dt= & {} \int _{0}^{1}T2(t)T1^{T}dt=\frac{h}{6}I_{m\times m}. \end{aligned}$$
(8)

Expressing \(\int _{0}^{s}T1(\tau )d\tau \) and \(\int _{0}^{s}T2(\tau )d\tau \) in terms of 1D-TFs follows

$$\begin{aligned} \int _{0}^{s}T1(\tau )d\tau= & {} P1\cdot T1(s)+P2\cdot T2(s), \end{aligned}$$
(9)
$$\begin{aligned} \int _{0}^{s}T1(\tau )d\tau= & {} P1\cdot T1(s)+P2\cdot T2(s), \end{aligned}$$
(10)

where the matrix \(P1_{m \times m}\) and \(P2_{m \times m}\), the operational matrix of integration in the 1D-TF domain, can be represented as

$$\begin{aligned} P1= & {} \frac{h}{2} \left( \begin{array}{ccccc} 0 &{}\quad 1 &{}\quad 1&{}\quad \ldots &{}\quad 1 \\ 0 &{}\quad 0 &{}\quad 1&{}\quad \ldots &{}\quad 1\\ \vdots &{}\quad \vdots &{}\quad \vdots &{}\quad \ddots &{}\quad \vdots \\ 0&{}\quad 0&{}\quad 0&{}\quad \ldots &{}\quad 0 \end{array} \right) \\ P2= & {} \frac{h}{2} \left( \begin{array}{ccccc} 1 &{}\quad 1 &{}\quad 1&{} \quad \ldots &{}\quad 1 \\ 0 &{}\quad 1 &{}\quad 1&{}\quad \ldots &{}\quad 1\\ \vdots &{}\quad \vdots &{}\quad \vdots &{}\quad \ddots &{}\quad \vdots \\ 0&{}\quad 0&{}\quad 0&{}\quad \ldots &{}\quad 1 \end{array} \right) \end{aligned}$$

Hence,

$$\begin{aligned} \int _{0}^{s}T(\tau )d\tau \simeq P\cdot T(s), \end{aligned}$$
(11)

where matrix P, the operational matrix of integration in the 1D-TF domain, can be represented as

$$\begin{aligned}&P_{ }= \left[ \begin{array}{cc} P_{1} &{} P_{ 2} \\ P_{1} &{}P_{2} \end{array} \right] , \end{aligned}$$
(12)

Now, the integral of function \(f(\tau )\) can be approximated as

$$\begin{aligned} \int _{0}^{s}f(\tau )d\tau \simeq \int _{0}^{s}C^{T}\cdot T(\tau )d \tau \simeq C^{T}\cdot P\cdot T(s). \end{aligned}$$
(13)

More details of 1D-TFs may be found in [15].

Two-dimensional Triangular Functions

An \(m_{1}\times m_{2}\)-set of 2D-TFs on the region \(([0,1)\times [0,1))\) is defined by

$$\begin{aligned} T_{i,j}^{1,1}(s,t)= & {} \left\{ \begin{array}{lll} \left( 1-\frac{s-ih_{1}}{h_{1}}\right) \left( 1-\frac{t-jh_{2}}{h_{2}}\right) ,&{} \quad ih_1 \le s < ( i+1)h_1 \\ &{} \quad jh_2 \le t < (j+1)h_2,\\ 0, &{} \quad \text {otherwise}, \end{array} \right. \end{aligned}$$
(14)
$$\begin{aligned} T_{i,j}^{1,2}(s,t)= & {} \left\{ \begin{array}{lll} \left( 1-\frac{s-ih_{1}}{h_{1}}\right) \left( \frac{t-jh_{2}}{h_{2}}\right) ,&{} \quad ih_1 \le s < ( i+1)h_1 \\ &{} \quad jh_2 \le t < (j+1)h_2,\\ 0, &{} \quad \text {otherwise}, \end{array} \right. \end{aligned}$$
(15)
$$\begin{aligned} T_{i,j}^{2,1}(s,t)= & {} \left\{ \begin{array}{lll} \left( \frac{s-ih_{1}}{h_{1}}\right) \left( 1-\frac{t-jh_{2}}{h_{2}}\right) ,&{} \quad ih_1 \le s < ( i+1)h_1 \\ &{} \quad jh_2 \le t < (j+1)h_2,\\ 0, &{} \quad \text {otherwise}, \end{array} \right. \end{aligned}$$
(16)
$$\begin{aligned} T_{i,j}^{2,2}(s,t)= & {} \left\{ \begin{array}{lll} \left( \frac{s-ih_{1}}{h_{1}}\right) \left( \frac{t-jh_{2}}{h_{2}}\right) ,&{} \quad ih_1 \le s < ( i+1)h_1\\ &{} \quad jh_2 \le t <(j+1)h_2,\\ 0, &{} \quad \text {otherwise}, \end{array} \right. \end{aligned}$$
(17)

where \(i=0,1,2,\ldots ,m_{1}-1\), \(j=0,1,2,\ldots ,m_{2}-1\) and \(h_{1}=\frac{1}{m_{1}}, h_{2}=\frac{1}{m_{2}}\), \( m_{1}\) and \(m_{2}\) are arbitrary positive integers. It is clear that

$$\begin{aligned} T_{i,j}^{1,1}(s,t)= & {} T_{i}^{1}(s)\cdot T_{j}^{1}(t),\\ T_{i,j}^{1,2}(s,t)= & {} T_{i}^{1}(s)\cdot T_{j}^{2}(t),\\ T_{i,j}^{2,1}(s,t)= & {} T_{i}^{2}(s)\cdot T_{j}^{1}(t),\\ T_{i,j}^{2,2}(s,t)= & {} T_{i}^{2}(s)\cdot T_{j}^{2}(t). \end{aligned}$$

Furthermore,

$$\begin{aligned} T_{i,j}^{1,1}(s,t)+T_{i,j}^{1,2}(s,t)+T_{i,j}^{2,1}(s,t)+T_{i,j}^{2,2}(s,t)=\phi _{i,j}(s,t), \end{aligned}$$

where \(\phi _{i,j}(s,t)\) is the (i,j)th block-pulse function defined on \( ih_1 \le s < ( i+1)h_1 \) and \( jh_2 \le t < ( j+1)h_2 \) as

$$\begin{aligned} \phi _{i,j}(s,t) = \left\{ \begin{array}{lll} 1 &{} \quad ih_1 \le s < ( i+1)h_1 \\ &{} \quad jh_2 \le t < (j+1)h_2,\\ 0 &{} \quad \text {otherwise}. \end{array} \right. \end{aligned}$$
(18)

Similar to the 1D case, there are some properties for 2D-TFs, the most important properties are disjointness and orthogonality.

Each set of \(\{T_{ij}^{11}(s,t)\}\), \(\{T_{ij}^{12}(s,t)\}\), \(\{T_{ij}^{21}(s,t)\}\) and \(\{T_{ij}^{22}(s,t)\}\) are obviously:

  1. 1.

    Disjointness The two-dimensional triangular functions are disjoint with each other, i.e.

    $$\begin{aligned} T_{i_{1},j_{1}}^{p_{1}, q_{1}}(s,t) \cdot T_{i_{2},j_{2}}^{p_{2}, q_{2}}(s,t), \simeq \left\{ \begin{array}{lll} T_{i_{1},j_{1}}^{p_{1}, q_{1}}(s,t), &{} \quad p_{1}=p_{2}, q_{1}=q_{2} \\ &{} \quad i_{1}=i_{2}, j_{1}=j_{2},\\ 0, &{} \quad \text {otherwise}, \end{array} \right. \end{aligned}$$
    (19)

    for \(p_{i},q_{i} \in \{1,2 \} ,i_1,i_2 =0,1,2,\ldots ,m_{1}-1,\) and \(j_{1},j_{2}=0,1,2,\ldots ,m_{2}-1.\)

  2. 2.

    Orthogonality The 2D-TFs are orthogonal with each other, i.e.

    $$\begin{aligned} \int _{0}^{1}\int _{0}^{1}T_{i_1,j_1}^{p_1,q_1}(s,t)\cdot T_{i_2,j_2}^{p_2,q_2}(s,t)ds dt =\Delta _{p_{1},p_{2}}\delta _{i_{1},i_{2}}\cdot \Delta _{q_{1},q_{2}}\delta _{j_{1},j_{2}}, \end{aligned}$$
    (20)

    where \(\delta \) denotes the Kronecker delta function, and

    $$\begin{aligned} \Delta _{\alpha , \beta }= \left\{ \begin{array}{ll} \frac{h}{3} &{}\alpha =\beta \in \{1,2 \},\\ \frac{h}{6} &{} \alpha \ne \beta . \end{array} \right. \end{aligned}$$
    (21)

On the other hand if

$$\begin{aligned} T_{11}(s,t)= & {} [T_{0,0}^{1,1}(s,t),T_{0,1}^{1,1}(s,t)\ldots ,T_{m_{1}-1,m_{2}-1}^{1,1}(s,t)]^{T},\\ T_{12}(s,t)= & {} [T_{0,0}^{1,2}(s,t),T_{0,1}^{1,2}(s,t)\ldots ,T_{m_{1}-1,m_{2}-1}^{1,2}(s,t)]^{T},\\ T_{21}(s,t)= & {} [T_{0,0}^{2,1}(s,t),T_{0,1}^{2,1}(s,t)\ldots ,T_{m_{1}-1,m_{2}-1}^{2,1}(s,t)]^{T},\\ T_{22}(s,t)= & {} [T_{0,0}^{2,2}(s,t),T_{0,1}^{2,2}(s,t)\ldots ,T_{m_{1}-1,m_{2}-1}^{2,2}(s,t)]^{T}, \end{aligned}$$

then T(st),  the 2D-TFs vector, can be defined as

$$\begin{aligned}&T(s, t)= \left[ \begin{array}{cccc} T_{11}(s,t) &{} \\ T_{12}(s,t) &{} \\ T_{21}(s,t) &{}\\ T_{22}(s,t) &{} \end{array} \right] _{4m_{1}m_{2}\times 1}. \end{aligned}$$
(22)

It is possible to cancel the (st) term in \(T(s,t), T_{11}(s,t), T_{12}(s,t), T_{21}(s,t)\) and \(T_{22}(s,t),\) for convenience. From the above representation, it follows that

$$\begin{aligned}&T_{11}\cdot T_{11}^{T}\simeq \left[ \begin{array}{cccc} T_{11}^{1,1} &{}\quad 0 &{} \quad \cdots &{}\quad 0 \\ 0 &{} T_{11}^{T} &{}\quad \cdots &{}\quad 0 \\ \vdots &{}\quad \vdots &{}\quad \ddots &{}\quad \vdots \\ 0&{}\quad 0&{} \quad \ldots &{}\quad T_{m_1-1,m_2-1}^{1,1}\\ \end{array} \right] =diag (T_{1,1}),\\&T_{11}\cdot T_{12}^{T}\simeq 0_{m_{1}m_{2} \times m_{1}m_{2}},\\&T_{11}\cdot T_{21}^{T}\simeq 0_{m_{1}m_{2} \times m_{1}m_{2}},\\&T_{11}\cdot T_{22}^{T}\simeq 0_{m_{1}m_{2} \times m_{1}m_{2}}. \end{aligned}$$

These relations are also satisfied for \(T_{12}(s,t)\), \(T_{21}(s,t)\) and \(T_{22}(s,t)\), similarly. Hence

$$\begin{aligned}&T\cdot T^{T}\simeq \left[ \begin{array}{cccc} diag (T_{1,1}) &{} \quad 0_{m_{1}m_{2} \times m_{1}m_{2}} &{} \quad 0_{m_{1}m_{2} \times m_{1}m_{2}} &{}\quad 0_{m_{1}m_{2} \times m_{1}m_{2}} \\ 0_{m_{1}m_{2} \times m_{1}m_{2}} &{} \quad diag (T_{1,2}) &{}\quad 0_{m_{1}m_{2} \times m_{1}m_{2}} &{} \quad 0_{m_{1}m_{2} \times m_{1}m_{2}} \\ 0_{m_{1}m_{2} \times m_{1}m_{2}} &{} \quad 0_{m_{1}m_{2} \times m_{1}m_{2}} &{}\quad diag (T_{2,1})&{} \quad 0_{m_{1}m_{2} \times m_{1}m_{2}}\\ 0_{m_{1}m_{2} \times m_{1}m_{2}} &{}\quad 0_{m_{1}m_{2} \times m_{1}m_{2}} &{}\quad 0_{m_{1}m_{2} \times m_{1}m_{2}}&{} diag (T_{2,2})\\ \end{array} \right] \end{aligned}$$
(23)

or

$$\begin{aligned} T(s,t)\cdot T^{T}(s,t)\simeq diag(T(s,t))=\tilde{T}(s,t). \end{aligned}$$
(24)

Also,

$$\begin{aligned} T(s,t) \cdot T^{T}(s,t) \cdot X\simeq \tilde{X}\cdot T(s,t), \end{aligned}$$
(25)

where X is a \(4m_{1}m_{2}\)-vector and \(\tilde{X}= diag(X)\).

The disjoint property of \(T_{11}(s,t)\) also implies that for every \((m_{1}m_{2}\times m_{1}m_{2})\)-matrix B,

$$\begin{aligned} T_{11}^{T}(s,t)\cdot B \cdot T_{11}(s,t)\simeq \widehat{B}\cdot T_{11}(s,t), \end{aligned}$$
(26)

where \(\widehat{B}\) is an \( m_1m_2\)-vector with elements equal to the diagonal entries of matrix B. Eq. (26) is also satisfied for \(T_{12}(s,t)\), \(T_{21}(s,t)\) and \(T_{22}(s,t)\), similarly.

Thus for every \((4m_{1}m_{2} \times 4m_{1}m_{2})\)-matrix A

$$\begin{aligned} T^{T}(s,t) \cdot A\cdot T(s,t)\simeq \widehat{A}\cdot T(s,t), \end{aligned}$$
(27)

in which \(\widehat{A}\) is a \(4m_1m_2\)-vector with elements equal to the diagonal entries of matrix A.

Finally, by the orthogonality of \(T_{11}(s,t)\),

$$\begin{aligned} \int _{0}^{1}\int _{0}^{1}T_{11}^{T}(s,t)T_{11}(s,t)dtds\simeq & {} \frac{h_{1}}{3}I_{m_{1}\times m_{1}}\otimes \frac{h_{2}}{3}I_{m_{2}\times m_{2}},\\ \int _{0}^{1}\int _{0}^{1}T_{11}^{T}(s,t)T_{12}(s,t)dtds\simeq & {} \frac{h_{1}}{3}I_{m_{1}\times m_{1}}\otimes \frac{h_{2}}{6}I_{m_{2}\times m_{2}},\\ \int _{0}^{1}\int _{0}^{1}T_{11}^{T}(s,t)T_{21}(s,t)dtds\simeq & {} \frac{h_{1}}{6}I_{m_{1}\times m_{1}}\otimes \frac{h_{2}}{3}I_{m_{2}\times m_{2}},\\ \int _{0}^{1}\int _{0}^{1}T_{11}^{T}(s,t)T_{22}(s,t)dtds\simeq & {} \frac{h_{1}}{6}I_{m_{1}\times m_{1}}\otimes \frac{h_{2}}{6}I_{m_{2}\times m_{2}},\\ \end{aligned}$$

where \(\otimes \) denotes the Kronecker product defined for two arbitrary matrices P and Q as

$$\begin{aligned} P \otimes Q=(P_{ij}Q). \end{aligned}$$

The same equations are implied for \(T_{12}(s,t)\), \(T_{21}(s,t)\) and \(T_{22}(s,t)\), by similar computations. Hence, we can carry out double integration of \(T(s,t):\)

$$\begin{aligned} \int _{0}^{1}\int _{0}^{1}T^{T}(s,t)T(s,t)dtds\simeq D \end{aligned}$$
(28)

in which D is the following \((4m1m2 \times 4m1m2)\)-matrix:

$$\begin{aligned}&D= \left[ \begin{array}{cccc} \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{3}I_{2} &{} \quad \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{6}I_{2} &{} \quad \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{3}I_{2} &{} \quad \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{6}I_{2} \\ \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{6}I_{2} &{} \quad \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{3}I_{2} &{} \quad \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{6}I_{2} &{} \quad \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{3}I_{2} \\ \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{3}I_{2} &{} \quad \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{6}I_{2} &{} \quad \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{3}I_{2} &{} \quad \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{6}I_{2} \\ \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{6}I_{2} &{} \quad \frac{h_{1}}{6}I_{1}\otimes \frac{h_{2}}{3}I_{2} &{} \quad \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{6}I_{2} &{} \quad \frac{h_{1}}{3}I_{1}\otimes \frac{h_{2}}{3}I_{2} \end{array} \right] , \end{aligned}$$
(29)

where we put \(I_{1} = I_{m_{1}\times m_{1}}\) and \( I_{2} = I_{m_{2}\times m_2}\) , for convenience.

2D-TFs Expansion

A function u(st) defined over \(([0,1) \times [0,1))\) may be extended using 2D-TFs as

$$\begin{aligned} u(s,t)\simeq & {} \sum _{i=0}^{m_{1}-1} \sum _{i=0}^{m_{2}-1} c_{i,j}T_{i,j}^{1,1}+ \sum _{i=0}^{m_{1}-1} \sum _{i=0}^{m_{2}-1} d_{i,j}T_{i,j}^{1,2} + \sum _{i=0}^{m_{1}-1} \sum _{i=0}^{m_{2}-1} e_{i,j}T_{i,j}^{2,1}+ \sum _{i=0}^{m_{1}-1} \sum _{i=0}^{m_{2}-1}l_{i,j}T_{i,j}^{2,2} \\= & {} C_{1}^{T} \cdot T_{11}(s,t)+C_{2}^{T}\cdot T_{12}(s,t)+C_{3}^{T}\cdot T_{21}(s,t)+C_{4}^{T}\cdot T_{22}(s,t)\\= & {} C^{T}\cdot T(s), \end{aligned}$$

where C is a \( 4m_{1}m_{2}\)-vector given by

$$\begin{aligned} C=\left[ C_{1}^{T} \ C _{2}^{T} \ C _{3}^{T} \ C _{4}^{T} \right] ^{T}, \end{aligned}$$
(30)

and T(st) is defined in Eq. (22).

The coefficients in vectors C1, C2, C3, and C4 can be computed by sampling the function u(st) at grid points \(s_{i}\) and \(t_{j}\) such that \( s_{i}= ih_{1}\) and \(t_{j} = jh_{2}\), for various i and j. Therefore,

$$\begin{aligned} C_{1 k}= & {} c_{i,j}=u(s_{i},t_{j}),\\ C_{2 k}= & {} d_{i,j}=u(s_{i},t_{j+1}),\\ C_{3 k}= & {} e_{i,j}=u(s_{i+1},t_{j}),\\ C_{4 k}= & {} l_{i,j}=u(s_{i+1},t_{j+1}), \end{aligned}$$

in which \(k=im_{2}+j\) and \(i=0,1,\ldots ,m_{1}-1\), \(j=0,1,\ldots ,m_{2}-1\), the \(4m_{1}m_{2}\)-vector C is called the 2D-TF coefficient vector. Also, the positive integer powers of a function u(st) may be approximated using 2D-TFs as

$$\begin{aligned}{}[u(s,t)]^{p}\simeq C_{p}^{T}\cdot T(s,t), \end{aligned}$$
(31)

where \(C_{p}\) is a column vector whose elements are pth powers of the elements of the vector C.

Let k(stxy) be a function of four variables on \(([0, 1)\times [0, 1)\times [0, 1) \times [0, 1))\). It can be approximated with respect to 2D-TFs as follows:

$$\begin{aligned} k(s,t,x,y)\simeq T^{T}(s,t)\cdot K\cdot T(x,y), \end{aligned}$$
(32)

where T(st) and T(xy) are 2D-TFs vectors of dimension \(4m_1m_2\) and \(4m_3m_4\), respectively, and K is a \((4m_1m_2)\times (4m_3m_4)\) 2D-TF coefficients matrix. This matrix can be represented as

$$\begin{aligned}&K= \left[ \begin{array}{cccc} K_{11} &{} \quad K_{12} &{} \quad K_{13} &{} \quad K_{14} \\ K_{21} &{} \quad K_{22} &{} \quad K_{23} &{} \quad K_{24} \\ K_{31} &{} \quad K_{32} &{} \quad K_{33} &{} \quad K_{34} \\ K_{41} &{} \quad K_{42} &{} \quad K_{43} &{} \quad K_{44} \end{array} \right] , \end{aligned}$$
(33)

where each block of K is an \((m_{1}m_{2}\times m_{3}m_{4})\)-matrix that can be computed by sampling the function k(stxy) at grid points \((s_{i_{1}}, t_{j_{1}}, x_{i_{2}}, y_{j_{2}})\) such that

$$\begin{aligned} s_{i_{1}}= & {} i_{1}h_{1} \quad i_{1}=0,1,\ldots , m_{1}-1\quad h_{1}=\frac{1}{m_{1}},\\ t_{j_{1}}= & {} j_{1}h_{2} \quad j_{1}=0,1,\ldots , m_{2}-1 \quad h_{2}=\frac{1}{m_{2}},\\ x_{i_{2}}= & {} i_{2}h_{3} \quad i_{2}=0,1,\ldots , m_{3}-1\quad h_{3}=\frac{1}{m_{3}},\\ y_{j_{2}}= & {} j_{2}h_{4}\quad j_{2}=0,1,\ldots , m_{4}-1\quad h_{4}=\frac{1}{m_{4}}. \end{aligned}$$

Hence, let \(p = i_{1}m_{2} +j_{1}\) and \(q = i_{2}m_{3} + j_{2}\), then

$$\begin{aligned} K_{11_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}},y_{j_{2}}\right) ,\\ K_{12_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}},y_{j_{2}+1}\right) ,\\ K_{13_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{14_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{21_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}+1},x_{i_{2}},y_{j_{2}}\right) ,\\ K_{22_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}+1},x_{i_{2}},y_{j_{2}+1}\right) ,\\ K_{23_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{24_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{31_{p,q}}= & {} k\left( s_{i_{1}}+1,t_{j_{1}},x_{i_{2}},y_{j_{2}}\right) ,\\ K_{32_{p,q}}= & {} k\left( s_{i_{1}+1},t_{j_{1}},x_{i_{2}},y_{j_{2}+1}\right) ,\\ K_{33_{p,q}}= & {} k\left( s_{i_{1}+1},t_{j_{1}},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{34_{p,q}}= & {} k\left( s_{i_{1}},t_{j_{1}},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{41_{p,q}}= & {} k\left( s_{i_{1}+1},t_{j_{1}+1},x_{i_{2}},y_{j_{2}}\right) ,\\ K_{42_{p,q}}= & {} k\left( s_{i_{1}+1},t_{j_{1}+1},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{43_{p,q}}= & {} k\left( s_{i_{1}+1},t_{j_{1}+1},x_{i_{2}+1},y_{j_{2}+1}\right) ,\\ K_{44_{p,q}}= & {} k\left( s_{i_{1}+1},t_{j_{1}+1},x_{i_{2}+1},y_{j_{2}+1}\right) . \end{aligned}$$

More details may be found in [8].

The Operational Matrix of Integration

We now need to compute the double integral of each element of \(T_{11}(s, t)\):

$$\begin{aligned} \int _{0}^{t}\int _{0}^{s}T_{i,j}^{1,1}(\tau ,\zeta )d\tau d\zeta= & {} \int _{jh_{2}}^{t}\int _{ih_{1}}^{s}\left( 1-\frac{\tau - ih_{1}}{h_{1}}\right) \left( 1 -\frac{\zeta - jh_{2}}{h_{2}} \right) d \tau d\zeta ,\\= & {} \left( \tau -\frac{(\tau - ih_{1})^{2}}{2h_{1}}\right) \mid _{ih_{1}}^{s} \cdot \left( \zeta - \frac{(\zeta - jh_{2})^{2}}{2h_{2}}\right) \mid _{jh_{2}}^{t}\\= & {} Q_{1}(s)\cdot Q_{2}(t),\\ Q_{1}(s)= & {} \left( (s-ih_{1})-\frac{(s-ih_{1})^{2}}{2h_{1}} \right) u(s-ih_{1})\\&-\left( (s-ih_{1})-\frac{(s-ih_{1})^{2}}{2h_{1}}-\frac{h_{1}}{2} \right) u(s-(i+1)h_{1}),\\ Q_{2}(t)= & {} \left( (t-jh_{2})-\frac{(t-jh_{2})^{2}}{2h_{2}} \right) u(t-jh_{2})\\&-\left( (t-jh_{2})-\frac{(t-jh_{2})^{2}}{2h_{2}}-\frac{h_{2}}{2} \right) u(t-(j+1)h_{2}), \end{aligned}$$

in which u denotes the unit step function. Now, by approximating \( \left( (s-ih_{1})-\frac{(s-ih_{1})^{2}}{2h_{1}}-\frac{h_{1}}{2} \right) \) and \(\left( (t-jh_{2})-\frac{(t-jh_{2})^{2}}{2h_{2}}-\frac{h_{2}}{2} \right) \) in \(Q_{1}(s)\) and \(Q_{2}(t)\) by \(\frac{h_{1}}{2}T_{i}^{2}(s)\) and \(\frac{h_{2}}{2}T_{j}^{2}(t),\) respectively, we can express the result in terms of \(T_{11}(s,t), T_{12}(s,t), T_{21}(s,t)\) and \(T_{22}(s,t)\) components:

$$\begin{aligned} \int _{0}^{t}\int _{0}^{s}T_{i,j}^{11}(\tau ,\zeta ) d \tau d\zeta= & {} \frac{h_{1}}{2}\frac{h_{2}}{2}\left( \, \sum _{p=i+1}^{m_{1}-1}\sum _{q=i+1}^{m_{2}-1} T_{p,q}^{1,1}(s,t)+\sum _{p=i+1}^{m_{1}-1}\sum _{q=j}^{m_{2}-1} T_{p,q}^{1,2}(s,t)\right. \\&+ \sum _{p=i}^{m_{1}-1}\left. \sum _{q=j+1}^{m_{2}-1} T_{p,q}^{2,1}(s,t)+\sum _{p=i}^{m_{1}-1}\sum _{q=j}^{m_{2}-1} T_{p,q}^{2,2}(s,t)\right) . \end{aligned}$$

Let \(P_{11}, P_{12}, P_{13}\) and \(P_{14}\) be the operational matrix for double integration of \(T_{11}(s,t)\) with respect to 2D-TF vectors. Moreover, suppose that Ps and Pt are the operational matrices for integration with respect to s and t in the 1D-TF domain, respectively. From Eq. (12).

$$\begin{aligned}&P_{s}= \left[ \begin{array}{c@{\quad }c} P_{s1} &{} P_{s2} \\ P_{s1} &{}P_{s2} \end{array} \right] , \ \ \ \ P_{t}= \left[ \begin{array}{c@{\quad }c} P_{t1} &{} P_{t2} \\ P_{t1} &{}P_{t2} \end{array} \right] . \end{aligned}$$
(34)

Therefore

$$\begin{aligned} P_{11}= & {} P_{s1} \otimes P_{t1},\\ P_{12}= & {} P_{s1} \otimes P_{t2},\\ P_{13}= & {} P_{s2} \otimes P_{t1},\\ P_{14}= & {} P_{s2} \otimes P_{t2}, \end{aligned}$$

where \(\otimes \) denotes the Kronecker product defined in Eq. (3).

It is obvious that the double integral of \(T_{12}(s, t), T_{21}(s,t)\) and \(T_{22}(s, t)\) can be computed in the same manner. Thus the operational matrix of integration in the 2D-TF domain, P, is a \((4m_{1}m_{2}\times 4m_{1}m_{2})\)-matrix as follows:

$$\begin{aligned}&P= \left[ \begin{array}{cccc} P_{11} &{}\quad P_{12} &{}\quad P_{13} &{}\quad P_{14} \\ P_{11} &{}\quad P_{12} &{}\quad P_{13} &{}\quad P_{14} \\ P_{11} &{}\quad P_{12} &{}\quad P_{13} &{}\quad P_{14} \\ P_{11} &{}\quad P_{12} &{}\quad P_{13} &{}\quad P_{14} \end{array} \right] \end{aligned}$$
(35)

Finally, the double integral of function \(u(\tau ,\zeta )\) can be approximated as

$$\begin{aligned} \int _{0}^{t}\int _{0}^{s}u(\tau ,\zeta )d\tau d\zeta \simeq \int _{0}^{t}\int _{0}^{s} C^{T}.T(\tau ,\zeta ) d\tau d\zeta \simeq C^{T}. P.T(s,t), \end{aligned}$$
(36)

where C is the 2D-TF coefficient vector of \(u(\tau ,\zeta )\). More details may be found in [8].

Operational Matrix of Differentiation

First, we attempt to compute the operational matrix of differentiation. For this, let

$$\begin{aligned} u(s,t)= & {} U^{T} T(s,t), \nonumber \\ u(s,0)= & {} U_{s0}^T T(s,t), \nonumber \\ u(0,t)= & {} U_{0t}^T T(s,t), \nonumber \\ u_t(s,t)= & {} U_{t}^T T(s,t), \nonumber \\ u_s(s,t)= & {} U_{s}^T T(s,t), \nonumber \\ u_t(s,0)= & {} U_{ts0}^T T(s,t), \nonumber \\ u_{tt}(s,t)= & {} U_{tt}^T T(s,t), \nonumber \\ u_s(0,s)= & {} U_{s0t}^T T(s,t), \nonumber \\ u_{ss}(s,t)= & {} U_{ss}^T T(s,t), \nonumber \\ u_{st}(s,t)= & {} U_{st}^T T(s,t). \end{aligned}$$
(37)

Now, we can write:

$$\begin{aligned} u(s,t)-u(s,0)= & {} \int _{0}^{t}u_{t}(s,\tau )d\tau , \end{aligned}$$
(38)

from (37), we obtain

$$\begin{aligned} U^T T(s,t)- U_{s0}^T T(s,t)= & {} \int _{0}^{t}U_{t}^T T(s,\tau )d\tau \nonumber \\= & {} U_{t}^T \int _{0}^{t} T(s,\tau )d\tau \nonumber \\= & {} U_{t}^T P T(s,t). \end{aligned}$$
(39)

So we get

$$\begin{aligned} U^T - U_{s0}^T = U_{t}^T P, \end{aligned}$$
(40)

then

$$\begin{aligned} U_{t}^T=\left( U^T - U_{s0}^T \right) P^{-1}. \end{aligned}$$
(41)

Similarly, we can write:

$$\begin{aligned} u(s,t)-u(0,t)= & {} \int _{0}^{s}u_{s}(\tau ,t)d\tau , \end{aligned}$$
(42)

then from (37), we have

$$\begin{aligned} U^T T(s,t)- U_{0t}^T T(s,t)= & {} \int _{0}^{s}U_{s}^T T(\tau ,t)d\tau , \nonumber \\= & {} U_{s}^T \int _{0}^{s} T(\tau ,t)d\tau , \nonumber \\= & {} U_{s}^T P T(s,t), \end{aligned}$$
(43)

so we get

$$\begin{aligned} U^T - U_{0t}^T= U_{s}^T P, \end{aligned}$$
(44)

hence

$$\begin{aligned} U_{s}^T=\left( U^T - U_{0t}^T \right) P^{-1}. \end{aligned}$$
(45)

Similarly, for the second-order partial differential equations, the following equation can be written:

$$\begin{aligned} u_t(s,t)-u_t(s,0)= & {} \int _{0}^{t}u_{tt}(s,\tau )d\tau , \end{aligned}$$
(46)

by using (37), we have

$$\begin{aligned} U_t^T T(s,t)- U_{ts0}^T T(s,t)= & {} \int _{0}^{t}U_{tt}^T T(s,\tau )d\tau , \nonumber \\= & {} U_{tt}^T \int _{0}^{t} T(s,\tau )d\tau , \nonumber \\= & {} U_{tt}^T P T(s,t), \end{aligned}$$
(47)

so we get

$$\begin{aligned} U_t^T - U_{ts0}^T= U_{tt}^T P, \end{aligned}$$
(48)

then

$$\begin{aligned} U_{tt}^T=\left( U_t^T - U_{ts0}^T \right) P^{-1}. \end{aligned}$$
(49)

In the similar way, the following equation has been obtained to approximate \(u_{ss}(s,t)\),

$$\begin{aligned} U_{ss}^T= & {} \left( U_{s}^T - U_{s0t}^T \right) P^{-1}. \end{aligned}$$
(50)

And finally, to approximate \(u_{st}(s,t)\), the following procedure can be applied:

$$\begin{aligned} u_s(s,t)-u_s(s,0)= & {} \int _{0}^{t}u_{st}(s,\tau )d\tau , \end{aligned}$$
(51)

hence

$$\begin{aligned} U_{s}^T T(s,t)- U_{s0t}^T T(s,t)= & {} \int _{0}^{t}U_{st}^T T(s,\tau )d\tau , \nonumber \\= & {} U_{st}^T \int _{0}^{t} T(s,\tau )d\tau , \nonumber \\= & {} U_{st}^T P T(s,t), \end{aligned}$$
(52)

so we get

$$\begin{aligned} U_{s}^T - U_{s0t}^T= U_{st}^T P, \end{aligned}$$
(53)

then we have

$$\begin{aligned} U_{st}^T=\left( U_{s}^T - U_{s0t}^T \right) P^{-1}. \end{aligned}$$
(54)

Applying the Method

In this section, we solve nonlinear two-dimensional mixed Volterra–Fredholm integro-differential equations by using 2D-TFs. As we show before, we can write

$$\begin{aligned} u(s,t)= & {} U^{T}T(s,t),\nonumber \\ f(s,t)= & {} F^{T}T(s,t),\nonumber \\ {[}u(s,t)]^{p_{1}}= & {} T^T(s,t) C_{p_{1}},\nonumber \\ {[}u(s,t)]^{p_{2}}= & {} T^T(s,t) C_{p_{2}},\nonumber \\ u_t(s,t)= & {} U_{t}^T T(s,t),\nonumber \\ u_s(s,t)= & {} U_{s}^T T(s,t), \nonumber \\ u_{tt}(s,t)= & {} U_{tt}^T T(s,t),\nonumber \\ u_{ss}(s,t)= & {} U_{ss}^T T(s,t),\nonumber \\ u_{st}(s,t)= & {} U_{st}^T T(s,t), \nonumber \\ k_{1}(s,t,x,y)= & {} T^{T}(s,t)\cdot K_{1}\cdot T(x,y),\nonumber \\ k_{2}(s,t,x,y)= & {} T^{T}(s,t)\cdot K_{2}\cdot T(x,y), \end{aligned}$$
(55)

where the \(m_1m_2\)-vectors \(U, F, C_{p1},C_{p2}, U_{t}, U_{s}, U_{tt}, U_{ss},U_{st}\) and matrix K are the TFs coefficients of \(u(s,t), f(s,t), [u(s,t)]^{p1}, [u(s,t)]^{p2}, u_t(s,t), u_s(s,t), u_{tt}(s,t), u_{ss}(s,t), u_{st}(s,t)\) and K(stxy) respectively. Elements of \(C_{p1}\) and \(C_{p2} \) are a column vector whose elements are pth power of the elements of the vector U. Now, consideer the following equation,

$$\begin{aligned}&u_{ss}(s,t)+u_{st}(s,t)+u_{tt}(s,t)+u(s,t)\nonumber \\&\quad = f(s,t)+\lambda _{1} \int _{0}^{t} \int _{0}^{s}k_{1}(s,t,x,y)[u(x,y)]^{p_{1}}dxdy \nonumber \\&\qquad +\,\lambda _{2} \int _{0}^{1} \int _{0}^{1}k_{1}(s,t,x,y)[u(x,y)]^{p_{2}}dxdy. \end{aligned}$$
(56)

By using the proposed equations, we have

$$\begin{aligned} \int _{0}^{t}\int _{0}^{s}k_{1}(s,t,x,y)[u(x,y)]^{p1}dxdy= & {} \int _{0}^{t} \int _{0}^{s}T^{T}(s,t)\cdot K_{1}\cdot T(x,y)\cdot T^{T}(x,y)\cdot C_{p_{1}} dxdy\\= & {} T^{T}(s,t)\cdot K \cdot \int _{0}^{t}\int _{0}^{s}T(x,y)\cdot T^{T}(x,y)\cdot C_{p1} dxdy\\\simeq & {} T^{T}(s,t)\cdot K_{1}\cdot \tilde{C_{p1}}\int _{0}^{t}\int _{0}^{s}T(x,y) dxdy, \\\simeq & {} T^{T}(s,t)\cdot K_{1}\cdot \tilde{ C_{p1}}\cdot P \cdot T(s,t)\\\simeq & {} \widehat{\left( K_{1}\tilde{C_{p1}}P\right) ^{T}}\cdot T(s,t)\\= & {} T^{T}(s,t)\cdot \widehat{\left( K_{1}\tilde{C_{p1}}P\right) }, \end{aligned}$$

where \( \widehat{(K_{1}\tilde{C_{p1}}P)}\) is a \(4m_{1}m_{2}\)-vector with components equal to the diagonal of the matrix \( (K_{1}\tilde{C_{p1}}P)\). Since \( \tilde{C_{p1}}\) is a diagonal matrix, we get

$$\begin{aligned} \widehat{\left( K_{1}\tilde{C_{p1}}P\right) }=\Pi \cdot C_{p1} \end{aligned}$$
(57)

in which \( \Pi \) is a \((4m_{1}m_{2} \times 4m_{1}m_{2})\)-matrix with components

$$\begin{aligned} \Pi _{i,j}&= (k_{1})_{i,j}\cdot P_{j,i}, \ \ \ i,j=1,2,\ldots ,4m_{1}m_{2} \end{aligned}$$
(58)
$$\begin{aligned} \int _{0}^{1}\int _{0}^{1}k_{2}(s,t,x,y)[u(x,y)]^{p_{2}}dxdy&\simeq \int _{0}^{1}\int _{0}^{1} T^{T}(s,t)\cdot K_{2}\cdot T(x,y)\cdot T^{T}(x,y)\cdot C_{p2}dxdy \nonumber \\&\simeq T^{T}(s,t)\cdot K_{2} \cdot D \cdot C_{p2} \end{aligned}$$
(59)

with D defined in Eq. (29).

Substituting Eqs. (55), (57) and (59) in Eq. (56), and replacing \(\simeq \) with \(=\) leads to

$$\begin{aligned} T^{T}(s,t)(U_{ss}+U_{st}+U_{tt}+U)= & {} T^{T}(s,t)\cdot F +\lambda _{1}T^{T}(s,t)\cdot \Pi \cdot C_{p1}\\&+\,\lambda _{2}T^{T}(s,t)\cdot K_{2} \cdot D \cdot C_{p2}, \end{aligned}$$

hence we have

$$\begin{aligned} U_{ss}+U_{st}+U_{tt}+U=F+\lambda _{1}\cdot \Pi \cdot C_{p1}+\lambda _{2}\cdot K_{2}\cdot D \cdot G_{p2} \end{aligned}$$
(60)

Eq. (60) is a nonlinear system of \(4m_{1}m_{2}\) algebraic equations. \(4m_{1}m_{2}\) components of C are unknown, and can be obtained by solving this system using Newton’s or other iterative methods. Hence, an approximate solution

$$\begin{aligned} u(s,t)\simeq C^{T}\cdot T(s,t) \end{aligned}$$
(61)

can be computed for Eq. (56).

Numerical Results

In this section, three example are given to show the accuracy of the proposed method. For the all examples, we consider the initial condition from the exact solution. The method presented in this paper is used to find numerical solutions of three illustrative examples. Our results are compared with the exact solutions by calculating the following error function:

$$\begin{aligned} e(s,t)=\mid u(s,t)-\bar{u}_{{m_{1},m_{2}}}(s,t)\mid , \end{aligned}$$

where u (st) and \(\bar{u}_{m_{1},m_{2}} (s, t)\) are the exact and approximate solutions of the integral equation, respectively. The values of e(st) over the set

$$\begin{aligned} D_{grids}=\lbrace (0.0, 0.0),(0.1, 0.1),(0.2, 0.2)\ldots ,(0.9, 0.9)\rbrace , \end{aligned}$$
(62)

are computed for different values of \(m_{1}\) and \(m_{2}\), and collected in Tables 1, 2.

Table 1 Numerical results for Example 1
Table 2 Numerical results for Example 2

Example 1

For the first example, consider the following equation,

$$\begin{aligned}&\frac{ \partial ^2 u(s,t)}{ \partial t^{2}}+ u(s,t) -\int _{0}^{t}\int _{0}^{s}(y+\cos (z))u^{2}(y,z)dydz\\&\quad +\int _{0}^{1}\int _{0}^{1}u^{3}(y,z)dydz=g(s,t), \quad s,t \in [0,1], \end{aligned}$$

where

$$\begin{aligned} g(s,t)= & {} \frac{1}{18}s^{4}\cos (t)\sin (t)-\frac{1}{8}s^{4}t-\frac{1}{9}s^{3}\sin (t)\\&+\,\frac{1}{9}s^{3}\sin (t)\cos (t^{2})+\frac{1}{6}-\frac{1}{4}\cos (1)-\frac{1}{12}\cos (1)^{3} \end{aligned}$$

with subject to the initial conditions:

$$\begin{aligned} u(s,0)=0, \ \ \ \frac{\partial u}{\partial t}(s,0)=s. \end{aligned}$$
(63)

The exact solution of this problem is \(u(s,t)=s\sin (t)\). The numerical solution of this problem is shown in Table 1.

Example 2

In this example, we consider a two-dimensional mixed Volterra–Fredholm integro-differential equation as follows:

$$\begin{aligned}&\frac{ \partial ^2 u(s,t)}{ \partial s^{2}}+\frac{ \partial ^2 u(s,t)}{ \partial s \partial t}+u^{3}(s,t) + \int _{0}^{1}\int _{0}^{1} \left( st+yz^{2}\right) u(y,z)dydz\\&\quad +\,\int _{0}^{t}\int _{0}^{s}(s+t+y+z)[u(y,z)]^{2} dx dy=g(s,t), \quad s,t \in [0,1], \end{aligned}$$

where

$$\begin{aligned} g(s,t)= & {} -\frac{1}{2}st-\frac{2}{3}+\frac{1}{2}est+\frac{1}{3}e- \frac{7}{24}s^{4}-\frac{1}{6}s^{3}t+\frac{1}{12}s^{3}\\&+\,\frac{7}{24}s^{4}e^{2t}+\frac{1}{3}s^{3}e^{2t}t-\frac{1}{12}s^{3}e^{2t}+e^{t}+s^{3}e^{3t}. \end{aligned}$$

with subject to the initial conditions:

$$\begin{aligned} u(0,t)=0, \ \ \ \frac{du}{ds}(0,t)=e^{t}. \end{aligned}$$
(64)

The exact solution of this problem is \(u(s,t)=se^{t}\). In Table 2, the numerical solutions are presented.

Example 3

Consider the third example in the form

$$\begin{aligned}&\frac{ \partial ^2 u(s,t)}{ \partial s^{2}}-\frac{ \partial u(s,t)}{ \partial t }+\frac{\partial u(s,t)}{\partial s}+u(s,t) \\&\quad -\,\int _{0}^{t}\int _{0}^{s} (s\cos (y-z))u(y,z)dydz=g(s,t), \quad s,t \in [0,1], \end{aligned}$$

where

$$\begin{aligned} g(s,t)= & {} 2\cos (s+t)-s\cos (s+t)-1+t-\frac{1}{8}s^{3}+s\sin s-s\sin t\\&+\,st\cos t-\frac{1}{8}st\sin (2s)+\frac{1}{4}s^{2}t\cos (2s)+\frac{1}{8}s^{3}\cos (2t)\\&-\,s\sin (s-t)-st\cos (s-t), \quad s,t\in [0,1] \end{aligned}$$

with the supplementary conditions

$$\begin{aligned} u(0,t)=t, \quad \frac{du}{ds}(1,t)=\sin (1+t)+\cos (1+t).\quad \frac{\partial u}{\partial s}(s,0)=s\cos (s)+1 \end{aligned}$$
(65)

The exact solution of this problem is \(u(s,t)=s\sin (s+t)+t\). In Table 3, the numerical solutions are presented.

Table 3 Numerical results for Example 3

Conclusion

In this paper, we have investigated application of triangular function for solving the nonlinear two-dimensional Volterra–Fredholm integro-differential equations. The benefits of this method are the lower costs of setting up the system of equations without applying any projection method such as the Galerkin, collocation, etc, and, the computational cost of operations is very low. This is an advantage of the method which making it very simple and cheap as computational point of view. Its accuracy and applicability were checked on some examples. The numerical results show that the accuracy of the obtained solutions is good. Furthermore, the current method can be run with increasing \(m_1\) and \(m_2\) until the results settle down to an appropriate accuracy.