Introduction

The study of incompressible homogeneous fluid of grade two is of remarkable importance because of its recognition as a special subclass among fluids of differential type and its significance in industries and applications in technology. Therefore, the flow characteristics of second order fluids has been an area of interest for researchers like Ariel [1, 2], Rajagopal et al. [3], C.L Roux [16] who deliberated the existence and uniqueness of the flow of second grade fluids with slip boundary conditions, Teipel [21] studied the flow behaviour of second order fluid, the authors in [6, 7, 20] studied some properties of unsteady unidirectional flows of a fluid of second grade. Hayat et al [10] pondered the steady flow of a second grade fluid in a porous channel.

VeeraKrishna and Reddy [23] derived a solution using Laplace transform technique to the hydromagnetic convective flow of second grade fluid through a porous medium in a rotating parallel plate channel with temperature dependent source. A similar study was performed in [25] where they deduced that the hydromagnetic flow and heat transfer is majorly influenced by four different factors. Veerakrishna et al. [24] adopted the pertubation technique to study the heat and mass transfer on oscillatory flow of MHD second grade fluid via a porous medium bounded by a pair of vertical plates taking into account the influence of two vital factors. A similar flow model was examined in [22] to study the effects of radiation and hall current.

Parida et al. [13] reviewed the magnetohydrodynamic flow of a second grade fluid with porous channel, solved numerically using Runge Kutta fourth order method in association with quasi linear shooting technique. Sahoo and Labropulu [17] analysed the steady Homann flow and heat transfer of an electrically conducting second grade fluid and deduced from the graphs that non-Newtonian parameter and magnetic parameter have opposite effects on momentum and thermal boundary layers. Raftari et al. [14] made an analysis of different fluid parameters of second grade like magnetic strength, viscosity, viscoelasticity on velocity and temperature profiles by obtaining numerical solution through Homotopy analysis method.

Das and Sahoo [5] studied the flow and heat transfer of a second grade fluid between two strechable coaxially rotating disks. They have used Homotopy Analysis Method to obtain a solution. Ghadikolaei [9] discussed the analytical and numerical solutions of non-Newtonian second grade fluid flow on a stretching sheet. The homotopy perturbation method was employed to solve the differential equations and the comparisons made validated its high precision in solving non linear differential equation. Effects of changes in the viscoelastic parameter on velocity profile and Prandtl number on temperature profile was analysed . Khan et al. [12] implemented the shooting method to study the effects of both activation energy and thermal radiation in modified second grade fluid flow with the aid of nanoparticles and deduced important results. Waqas et al. [26] also examined the effects of the two important factors as [12] for a second grade nanofluid over a moving Riga plate.

The main aim of this study is to present a convergent, simple and yet more general numerical solution to the considered flow problem which finds its application in general in MHD generators, in designing the liquid metal cooling system, flow meters and petroleum industries mainly for the tapping and purification of underground oil which flows through porous rocks, where there is natural magnetic field and also in blood flow through arteries where the boundaries are porous. The porous channel flow, structurally, is quite similar to unsteady squeeze film flow having a separable extensional effect which has immense application in lubrication, viscometry and polymer technology. The used scheme in the present work is flexible for solving strong non linear complex problem without transforming it to simpler form. A strong point of the implemented scheme is that its well founded for small as well as large non dimensional parametric values plus the monotonous calculation for slightest to considerable change of boundary conditions can be avoided and hence the implementation of this method is beneficial and worthwhile.

A recapitulation of the work is presented as follows. Section 2 recounts our concerned problem. A solution to the momentum and energy equation is obtained in Sect. 3. Section 4 comprises of the graphical results. Section 5 highlights some noteworthy findings of the study.

Description of the Problem

The constituents of velocity \(u^{'}\) and \(v^{'}\) in the domain of flow is denoted as

$$\begin{aligned} u^{'} = u^{'}(y^{'},t^{'}) \ , \ v^{'} = V. \end{aligned}$$
(1)

Following the stress strain rate relation the stress component is given as

$$\begin{aligned} P_{x^{'}y^{'}} = -p +\mu _{1}\Bigg ( \frac{\partial u^{'}}{\partial y^{'}}\Bigg )+\mu _{2}\Bigg [ V\frac{\partial ^{2} u^{'}}{\partial y^{'2}} + \frac{\partial ^{2} u^{'}}{\partial y^{'}\partial t^{'}}\Bigg ] \end{aligned}$$
(2)

Since the motion is due to shearing action of the fluid layers

$$\begin{aligned} \frac{\partial p}{\partial y{'}} = 0 \end{aligned}$$
(3)

Based on the information provided in [8, 15], we directly write the governing momentum and energy equations including viscous dissipation \(\phi \) using the above identities

$$\begin{aligned} \rho \Bigg (\frac{\partial u^{'}}{\partial t^{'}} + V\frac{\partial u^{'}}{\partial y^{'}}\Bigg )= & {} \mu _{1}\frac{\partial ^{2} u^{'}}{\partial y^{'2}}+ \mu _{2}\Bigg [V \frac{\partial ^{3} u^{'}}{\partial y^{'3}} + \frac{\partial ^{3} u^{'}}{\partial y^{'2}\partial t^{'}}\Bigg ]-\sigma {\beta _{0}^{2}}u^{'}. \end{aligned}$$
(4)
$$\begin{aligned} \rho c \Bigg ( \frac{\partial \theta ^{'}}{\partial t^{'}} + V\frac{\partial \theta ^{'}}{\partial y^{'}}\Bigg )= & {} k\frac{\partial ^2 \theta ^{'}}{\partial y^{'2}} + \mu _{1}\Big (\frac{\partial u^{'}}{\partial y^{'}}\Big )^{2}\nonumber \\&+ \mu _{2}\Bigg ( V\frac{\partial ^{2}u^{'}}{\partial y^{'2}}\frac{\partial u^{'}}{\partial y^{'}} + \frac{\partial ^{2}u^{'}}{\partial y^{'}\partial t^{'}}\frac{\partial u^{'}}{\partial y^{'}} \Bigg )- \sigma {\beta _{0}^{2}}u^{'2}.\nonumber \\ \end{aligned}$$
(5)

The boundary condition associated with equation (4) are

$$\begin{aligned} \begin{aligned} {\left\{ \begin{array}{ll} t^{'} = 0 : \ \ \ \ \ u^{'} = 0, \ \ \ \ \ \forall \ y^{'} \\ {\left\{ \begin{array}{ll} t^{'}> 0:\ \ \ u^{'} =At^{n}\ \ for \ y^{'} = 0 \\ t^{'} > 0:\ \ \ u^{'} = 0, \ \ \ \ for \ y^{'} = L \end{array}\right. } \end{array}\right. } \end{aligned} \end{aligned}$$
(6)

The boundary condition to which equation (5) is subjected to are

$$\begin{aligned} \begin{aligned} {\left\{ \begin{array}{ll} t^{'} = 0 : \ \ \ \ \ \theta ^{'} = 0, \ \ \ \ \ \forall \ y^{'} \\ {\left\{ \begin{array}{ll} t^{'}> 0:\ \ \frac{\partial \theta ^{'}}{\partial y^{'}} = 0\ \ \ \ for \ y^{'} = 0 \\ t^{'} > 0:\ \ \ \theta ^{'} = \theta _{L}, \ \ for \ y^{'} = L \end{array}\right. } \end{array}\right. } \end{aligned} \end{aligned}$$
(7)

The fact \(\frac{\partial \theta ^{'}}{\partial y^{'}} = 0\) when \(y^{'} = 0 \) implies that the lower wall is a non conducting one (Fig. 1). The magnetic Reynolds number is assumed to be very small as a result of which the induced magnetic field is negligible in comparison to the intensity of the imposed magnetic field and hence its impact is neglected [19].

Fig. 1
figure 1

Geometry of the flow problem

Introducing the dimensionless variables and parameters as shown below

$$\begin{aligned} y= & {} \frac{y^{'}}{\sqrt{\nu _{1}T}} \,\ t = \frac{t^{'}}{T}, \ Re = \frac{V\sqrt{T}}{\sqrt{\nu _{1}}}, = \ \alpha = -\frac{\mu _{2}}{\mu _{1}T} \ , \ m^{2} = \frac{\sigma \beta _{0}^{2}T}{\rho },\\ u= & {} \frac{u^{'}}{A}, \ \Pr = \frac{\nu _{1}\rho c}{k},\\ Ec= & {} \frac{A^{2}}{c\theta _{L}} , \theta = \frac{\theta ^{'} - \theta _{L}}{\theta _{L}}. \end{aligned}$$

The elastic coefficient \(\mu _{2}\) is assumed to be negative. The value of L is considered as 1. Employing the above notations in equation (4) and (5), we get

$$\begin{aligned} \frac{\partial u}{\partial t} + Re\frac{\partial u}{\partial y} - \frac{\partial ^{2} u}{\partial y^{2}} + Re \ \alpha \frac{\partial ^{3}u}{\partial y^{3}} +\alpha \frac{\partial ^{3}u}{\partial y^{2} \partial t} +m^{2}u= 0. \end{aligned}$$
(8)

with the following stated condition

$$\begin{aligned}&{\left\{ \begin{array}{ll} t = 0 : \ \ \ \ \ u = 0, \ \ \ \ \forall \ y \\ {\left\{ \begin{array}{ll} t> 0:\ \ \ u = t^{n}\ \ \ \ for \ y = 0 \\ t > 0:\ \ \ u = 0, \ \ \ \ for \ y = 1 \end{array}\right. } \end{array}\right. } \end{aligned}$$
(9)
$$\begin{aligned}&Pr\frac{\partial \theta }{\partial t} + Pr \ Re \frac{\partial \theta }{\partial y} - \frac{\partial ^{2}\theta }{\partial y^{2}} +\alpha \ Ec \ Pr \Bigg (Re\frac{\partial ^{2}u}{\partial y^{2}}\frac{\partial u}{\partial y} + \frac{\partial u}{\partial y} \frac{\partial ^{2}u}{\partial y \partial t}\Bigg )\nonumber \\&\quad - Pr\ Ec \Bigg (\frac{\partial u}{\partial y}\Bigg )^{2}+ m^{2}\ Ec \ Pr \ u^{2} = 0 \end{aligned}$$
(10)
$$\begin{aligned}&{\left\{ \begin{array}{ll} t = 0 : \ \ \ \ \ \theta = 0, \ \ \ \ \ \forall \ y \\ {\left\{ \begin{array}{ll} t> 0:\ \ \ \frac{\partial \theta }{\partial y} = 0\ \ \ \ for \ y = 0 \\ t > 0:\ \ \ \theta = 0, \ \ \ \ for \ y = 1 \end{array}\right. } \end{array}\right. } \end{aligned}$$
(11)

The dimensionless shear stress \(\tau _{xy}\) can be expressed as

$$\begin{aligned} \tau _{xy} = \frac{\partial u}{\partial y}-\alpha \Bigg (Re\frac{\partial ^{2}u}{\partial y^{2}}+\frac{\partial ^{2}u}{\partial y \partial t} \Bigg ) \end{aligned}$$
(12)

Solution Strategy

We choose to take up the following solution strategy to solve the above equation (8). We implement the implicit finite difference scheme of crank-Nickolson type for discretisation in space as well as in time with a uniform mesh of space step h and time step k. The used scheme is unconditionally stable and suffices the second order convergence in time as well as in space.

The derivatives at the nodes \((ih,j\triangle t)\), \(i = 0,1,\ldots ,N+1 \ and \ j = 0,1,\ldots ,M-1\) are reckoned as

$$\begin{aligned} \begin{aligned} \frac{\partial u}{\partial t}&\approx \frac{u_{i}^{j+1} - u_{i}^{j}}{\triangle t}.\\ \frac{\partial u}{\partial y}&\approx \frac{1}{4h}((u_{i+1}^{j+1} - u_{i-1}^{j+1}) + (u_{i+1}^{j} - u_{i-1}^{j})).\\ \frac{\partial ^{2} u}{\partial y^{2}}&\approx \frac{1}{2h^{2}}((u_{i+1}^{j+1} - 2u_{i}^{j+1} + u_{i-1}^{j+1}) + (u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j}))\\ \frac{\partial ^{3}u}{\partial y^{2} \partial t}&\approx \frac{1}{h^{2}\triangle t}((u_{i+1}^{j+1} - 2u_{i}^{j+1} + u_{i-1}^{j+1}) - (u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j}))\\ \frac{\partial ^{2}u}{\partial y \partial t}&\approx \frac{1}{2h\triangle t}((u_{i+1}^{j+1} - u_{i}^{j+1}) - (u_{i+1}^{j} - u_{i}^{j}))\\ \frac{\partial ^{3}u}{\partial y^{3}}&\approx \frac{1}{2h^{3}}\Bigg ((-u_{i-2}^{j+1} + 2u_{i-1}^{j+1}- 2u_{i+1}^{j+1} + u_{i+2}^{j+1})\\&\quad +(-u_{i-2}^{j} + 2u_{i-1}^{j }-2u_{i+1}^{j} + u_{i+2}^{j})\Bigg ) \ , i \ne 1,N.\\&\quad At \ point \ (1,j\triangle t),\frac{\partial ^{3}u}{\partial y^{3}} \approx \frac{1}{2h^{3}}\Bigg ((-3u_{i-1}^{j+1} + 10u_{i}^{j+1} - 12u_{i+1}^{j+1} + 6u_{i+2}^{j+1} - u_{i+3}^{j+1})\\&\qquad +(-3u_{i-1}^{j} + 10u_{i}^{j} - 12u_{i+1}^{j} +6u_{i+2}^{j} - u_{i+3}^{j})\Bigg )\\&\quad At \ point \ (N,j\triangle t),\ \frac{\partial ^{3}u}{\partial y^{3}} \approx \frac{1}{2h^{3}}\Bigg ((u_{i-3}^{j+1} - 6u_{i-2}^{j+1} + 12u_{i-1}^{j+1} - 10u_{i}^{j+1} + 3u_{i+1}^{j+1})\\&\qquad +(u_{i-3}^{j} - 6u_{i-2}^{j} + 12u_{i-1}^{j} -10u_{i}^{j} + 3u_{i+1}^{j})\Bigg ) \end{aligned} \end{aligned}$$
(13)

Solution for Velocity Field

Using the above differences, we frame the governing velocity equation and its boundary condition as

$$\begin{aligned}&\frac{u_{i}^{j+1} - u_{i}^{j}}{\triangle t}+\frac{R}{4h}((u_{i+1}^{j+1} - u_{i-1}^{j+1}) + (u_{i+1}^{j} - u_{i-1}^{j}))\nonumber \\&\quad -\frac{1}{2h^{2}}((u_{i+1}^{j+1} - 2u_{i}^{j+1} + u_{i-1}^{j+1}) + (u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j}))\nonumber \\&\quad +\frac{R\alpha }{2h^{3}}((-u_{i-2}^{j+1} + 2u_{i-1}^{j+1}- 2u_{i+1}^{j+1} + u_{i+2}^{j+1}) +(-u_{i-2}^{j} + 2u_{i-1}^{j }- 2u_{i+1}^{j} + u_{i+2}^{j}))\nonumber \\&\quad +\frac{\alpha }{h^{2}\triangle t}((u_{i+1}^{j+1} - 2u_{i}^{j+1} + u_{i-1}^{j+1}) - (u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j}))+m^{2}u = 0 \end{aligned}$$
(14)
$$\begin{aligned}&{\left\{ \begin{array}{ll} u_{i}^{0} = 0,\ \ \ \ \ \ \ \ \ \ \ for \ i = 0, 1, 2,\ldots ,N+1 \\ {\left\{ \begin{array}{ll} u_{0}^{j} = (j\triangle t)^{n} \ \ \ and \\ u_{N+1}^{j} = 0,\ \ \ \ \ for \ j = 1, 2,\ldots ,M \end{array}\right. } \end{array}\right. } \end{aligned}$$
(15)

Using the above system of equations we compute the residues(x)

$$\begin{aligned} R_{1}&\equiv {} (u_{1}^{j+1}-u_{1}^{j})+\frac{Re\triangle t}{4h}((u_{2}^{j+1} - u_{0}^{j+1}) + (u_{2}^{j} - u_{0}^{j}))\nonumber \\&\quad -\frac{\triangle t}{2h^{2}}((u_{2}^{j+1} - 2u_{1}^{j+1} + u_{0}^{j+1}) + (u_{2}^{j} - 2u_{1}^{j} + u_{0}^{j}))\nonumber \\&\quad +\frac{\alpha }{h^2}((u_{2}^{j+1} - 2u_{1}^{j+1} + u_{0}^{j+1}) - (u_{2}^{j} - 2u_{1}^{j} + u_{0}^{j}))\nonumber \\&\quad +\frac{Re \ \alpha \triangle t}{2h^{3}}((-3u_{0}^{j+1} + 10u_{1}^{j+1} - 12u_{2}^{j+1} + 6u_{3}^{j+1} - u_{4}^{j+1}) \nonumber \\&\quad +(-3u_{0}^{j} + 10u_{1}^{j} - 12u_{2}^{j} + 6u_{3}^{j} - u_{4}^{j}))+m^2\Big (\frac{u_{1}^{j+1}+u_{1}^{j}}{2}\Big )\triangle t. \end{aligned}$$
(A1)
$$\begin{aligned} R_{2}&\equiv {} (u_{2}^{j+1}-u_{2}^{j})+\frac{Re\triangle t}{4h}((u_{3}^{j+1} - u_{1}^{j+1}) + (u_{3}^{j} - u_{1}^{j}))\nonumber \\&\quad -\frac{\triangle t}{2h^{2}}((u_{3}^{j+1} - 2u_{2}^{j+1} + u_{1}^{j+1}) + (u_{3}^{j} - 2u_{2}^{j} + u_{1}^{j}))\nonumber \\&\quad +\frac{\alpha }{h^2}((u_{3}^{j+1} - 2u_{2}^{j+1} + u_{1}^{j+1}) - (u_{3}^{j} - 2u_{2}^{j} + u_{1}^{j}))\nonumber \\&\quad +\frac{Re \ \alpha \triangle t}{2h^{3}}((-3u_{1}^{j+1} + 10u_{0}^{j+1} - 12u_{1}^{j+1} + 6u_{2}^{j+1} - u_{3}^{j+1}) \nonumber \\&\quad +(-3u_{1}^{j} + 10u_{0}^{j} - 12u_{1}^{j} + 6u_{2}^{j} - u_{3}^{j}))+m^2\Big (\frac{u_{2}^{j+1}+u_{2}^{j}}{2}\Big )\triangle t. \end{aligned}$$
(A2)
$$\begin{aligned} R_{i}&\equiv {} (u_{i}^{j+1}-u_{i}^{j})+\frac{Re\triangle t}{4h}((u_{i+1}^{j+1} - u_{i-1}^{j+1}) + (u_{i+1}^{j} - u_{i-1}^{j}))\nonumber \\&\quad -\frac{\triangle t}{2h^{2}}((u_{i+1}^{j+1} - 2u_{i}^{j+1} + u_{i-1}^{j+1}) + (u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j}))\nonumber \\&\quad +\frac{\alpha }{h^2}((u_{i+11}^{j+1} - 2u_{i}^{j+1} + u_{i-1}^{j+1}) - (u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j}))\nonumber \\&\quad +\frac{Re \ \alpha \triangle t}{2h^{3}}((-u_{i-2}^{j+1} + 2u_{i-1}^{j+1}- 2u_{i+1}^{j+1} + u_{i+2}^{j+1}) \nonumber \\&\quad +(-u_{i-2}^{j} + 2u_{i-1}^{j }- 2u_{i+1}^{j} + u_{i+2}^{j})) \nonumber \\&\quad +m^2 \Big (\frac{u_{i}^{j+1}+u_{i}^{j}}{2}\Big )\triangle t. \end{aligned}$$
(A3)
$$\begin{aligned} R_{N}&\equiv {} (u_{N}^{j+1}-u_{N}^{j})+\frac{Re\triangle t}{4h}(-u_{N-1}^{j+1}-u_{N-1}^{j})-\frac{\triangle t}{2h^{2}}(-2u_{N}^{j+1}+u_{N-1}^{j+1}-2u_{N}^{j}+u_{N-1}^{j})\nonumber \\&\quad +\frac{\alpha }{h^2}(-2u_{N}^{j+1}+u_{N-1}^{j+1}+2u_{N}^{j}-u_{N-1}^{j})\nonumber \\&\quad +\frac{Re \ \alpha \triangle t}{2h^3}((u_{N-3}^{j+1} - 6u_{N-2}^{j+1} + 12u_{N-1}^{j+1} - 10u_{N}^{j+1} + 3u_{N+1}^{j+1}) \nonumber \\&\quad +(u_{N-3}^{j} - 6u_{N-2}^{j} + 12u_{N-1}^{j} - 10u_{N}^{j} + 3u_{N+1}^{j}))+m^2\Big (\frac{u_{N}^{j+1}+u_{N}^{j}}{2}\Big )\triangle t. \end{aligned}$$
(A4)

The elements constituting the Jacobian matrix for \(i,j = 1,2,\ldots N\) is represented as

Knowing the velocity field in the discretised form (accurate to the order \(O(h^{2}+(\triangle t)^{2}))\) the shearing stress \(\tau _{0}\) and \(\tau _{1}\) at \(y = 0\) and \(y = 1\) i.e at the lower wall and upper wall respectively are

$$\begin{aligned} \tau _{0}= & {} \tau _{xy}]_{y=0} = \frac{-3u_{0}^{j}+4u_{1}^{j}-u_{2}^{j}}{2h}-\alpha \Bigg [\frac{Re}{h^2}(2u_{0}^{j}-5u_{1}^{j}+4u_{2}^{j}-u_{3}^{j})\nonumber \\&+\frac{1}{2h \triangle t}(-3u_{0}^{j+1}+4u_{1}^{j+1}-u_{2}^{j+1}+3u_{0}^{j}-4u_{1}^{j}+u_{2}^{j}\Bigg ] \end{aligned}$$
(16)
$$\begin{aligned} \tau _{1}= & {} \tau _{xy}]_{y=1} = \frac{u_{N-1}^{j}-4u_{N}^{j}+3u_{N+1}^{j}}{2h}-\alpha \Bigg [\frac{Re}{h^2}(2u_{N+1}^{j}-5u_{N}^{j}+4u_{N-1}^{j}-u_{N-2}^{j})\nonumber \\&+\frac{1}{2h \triangle t}(u_{N-1}^{j+1}-4u_{1}^{j+1}+3u_{N+1}^{j+1}-u_{N-1}^{j}+4u_{N}^{j}-3u_{N+1}^{j}\Bigg ] \end{aligned}$$
(17)

Solution for Temperature Field

Using the above differences, we frame the governing energy equation and its boundary condition as

$$\begin{aligned} \begin{aligned}&\theta _{i}^{j+1} - \theta _{i}^{j} + \frac{Re\triangle t}{4h}\Big ( (\theta _{i+1}^{j+1} - \theta _{i-1}^{j+1}) + (\theta _{i+1}^{j}-\theta _{i-1}^{j})\Big )\\&\quad - \frac{\triangle t}{2h^{2} Pr}\Big ( (\theta _{i+1}^{j+1}-2\theta _{i}^{j+1}+\theta _{i-1}^{j+1})\\&\quad +(\theta _{i+1}^{j}-2\theta _{i}^{j}+\theta _{i-1}^{j})\Big )+\alpha \ Ec\Big (\frac{Re\triangle t}{8h^{3}}[(u_{i+1}^{j+1} - 2u_{i}^{j+1} \\&\quad + u_{i-1}^{j+1})+(u_{i+1}^{j} - 2u_{i}^{j} + u_{i-1}^{j})][(u_{i+1}^{j+1} - u_{i-1}^{j+1})\\&\quad +(u_{i+1}^{j} - u_{i-1}^{j})]+\frac{1}{8h^{2}}[((u_{i+1}^{j+1} - u_{i-1}^{j+1})\\&\quad +(u_{i+1}^{j} - u_{i-1}^{j})][(u_{i+1}^{j+1} - u_{i}^{j+1})-(u_{i+1}^{j} - u_{i}^{j})]\Big )\\&\quad -\frac{Ec\triangle t}{16h^{2}}\Big ( (u_{i+1}^{j+1} - u_{i-1}^{j+1})+(u_{i+1}^{j} -u_{i-1}^{j})\Big )^{2}+m^{2}\ Ec \ \triangle t \Big (\frac{u_{i}^{j+1} + u_{i}^{j}}{2}\Big )^{2} = A (say). \end{aligned} \end{aligned}$$
(18)

Arranging in tridiagonal form, we get

$$\begin{aligned}&\Big (\frac{Re\triangle t}{4h} -\frac{\triangle t}{2h^{2}}\Big )\theta _{i+1}^{j+1} + \Big ( 1+ \frac{\triangle t}{h^{2} Pr}\Big )\theta _{i}^{j+1}+\Big (\frac{-Re\triangle t}{4h}-\frac{\triangle t}{2h^{2}Pr}\Big )\theta _{i-1}^{j+1}\nonumber \\&\quad =A + \Big (-\frac{Re\triangle t}{4h}+\frac{\triangle t}{2h^{2}Pr}\Big )\theta _{i+1}^{j}\nonumber \\&\qquad +\Big (1-\frac{\triangle t}{Pr h^{2}}\Big )\theta _{i}^{j}+\Big (\frac{Re\triangle t}{4h Pr}+\frac{\triangle t}{2h^{2}Pr}\Big )\theta _{i-1}^{j} = b \end{aligned}$$
(19)
$$\begin{aligned}&{\left\{ \begin{array}{ll} \theta _{i}^{0} = 0,\ \ \ \ \ \ \ \ \ \ \ for \ i=0,1,2,\ldots N+1 \\ {\left\{ \begin{array}{ll} \theta _{0}^{j} = \frac{4\theta _{1}^{j} - \theta _{2}^{j}}{3}\ \ \ for \ j = 1,2,\ldots ,M \\ \theta _{N+1}^{j} = 0 \end{array}\right. } \end{array}\right. } \end{aligned}$$
(20)

The system of equations (14) along with (15) is solved by using damped-Newton method which converges quadratically .

An approximate value of M is chosen in accordance with the algorithm stated in [11]. The iterations are repeated till the absolute difference of the successive solutions obtained at nodes \(((N+1)h, j\triangle t)\) and \(((N+2)h, j\triangle t)\) becomes less than \(\varepsilon \).

A suitable value of initial velocity is preferred and (14) is framed in a tridiagonal manner. The parameters \(\alpha \) and \(m^2\) are equated to zero to obtain a solution with the help of gaussian elimination.

The residuals\((R_{i}, i = 0,1,\ldots ,N)\) and jacobians \(\Big (\Big (\frac{\partial R_{i}}{\partial u_{j}}\Big ) \ne 0\), \(i = 1,\ldots ,N\) and \(j = 1,\ldots ,M\Big )\) are computed to carry through the damped-Newton method. We consider our next approximation to be \( x^{k+1} = \Big (x^{k}+\frac{h}{2^{i}}\Big )\). The value of i is considered in a manner such that

$$\begin{aligned} i = min \Bigg (j : 0 \le j \le j_{max} \mid {\parallel residue \Big (x^{k}+\frac{h}{2^{j}}\Big )\parallel }_{2} < {\parallel residue(x^{k}) \parallel }_{2}\Bigg ) \end{aligned}$$

thus validating the error reduction in every iteration and convergence of the method as given in [4] precisely to five decimal places.

\(\alpha \)

t

Re

\(n=1(\tau _0)\)

\(\alpha \)

t

Re

\(n=1(\tau _{1})\)

0.5

0.05

0.00

\(-0.08128\)

0.5

0.05

0.00

\(-0.03486\)

0.05

\(-0.05702\)

  

0.05

\(-0.05702\)

0.10

\(-0.03642\)

  

0.10

\(-0.07468\)

0.10

0.00

\(-0.17231\)

 

0.10

0.00

\(-0.07947\)

0.05

\(-0.14566\)

  

0.05

\(-0.10414\)

0.10

\(-0.12264\)

  

0.10

\(-0.12261\)

0.15

0.00

\(-0.26900\)

 

0.15

0.00

\(-0.12974\)

0.05

\(-0.24132\)

  

0.05

\(-0.15827\)

0.10

\(-0.21664\)

  

0.10

\(-0.17839\)

5.0

0.05

0.00

\(-0.02288\)

5.0

0.05

0.00

\(-0.09327\)

0.05

\(-0.05848\)

  

0.05

\(-0.05848\)

0.10

\(-0.08007\)

  

0.10

\(-0.02319\)

0.10

0.00

\(-0.05550\)

 

0.10

0.00

\(-0.29628\)

0.05

\(-0.13283\)

  

0.05

\(-0.23040\)

0.10

\(-0.18725\)

  

0.10

\(-0.18725\)

0.15

0.00

\(-0.09379\)

 

0.15

0.00

\(-0.50496\)

0.05

\(-0.26798\)

  

0.05

\(-0.46310\)

0.10

\(-0.37638\)

  

0.10

\(-0.40863\)

The tables represents value of shear stress \(\tau _{0}\) at the lower plate and the value of shear stress \(\tau _{1}\) at the upper plate.

Results and Discussion

The unsteady MHD flow characteristic of the reckoned fluid advancing through unbounded porous channel is investigated and depicted using the subsequent figures.

Fig. 2
figure 2

Influence of varying values of \(\alpha \) on velocity when n = 1

Fig. 2 and 3 depicts second grade fluid velocity profile when \(m^2 = 3, Re = 4, Pr = 0.3, Ec = 0.5\), for increasing values of second grade elastic parameters with \(0< \alpha < 6\). An increasing behaviour is noticed for both constant acceleration (\(n = 1\)) and variable acceleration (\(n=0.5\)).

Keeping other parameters fixed, the Reynolds number is increased to 8 and a crossover phenomena for velocity is observed for the case of constant acceleration where the velocity initially increases until the point of crossover after which it decreases as in Fig. 4. A decreasing behaviour in velocity can be noticed for the case of variable acceleration which is insignificant near the plate but becomes more prominent towards the middle region of plate depicted in Fig. 5.

The value of Re is further increased to 10 keeping other parameters constant, and it is noticed that the velocity profile decreases for constant acceleration as well as variable acceleration as portrayed in Figs. 6 and 7.

Figures 8, 9, 10 and 11 shows effect of increasing \(\alpha \) values (\(\alpha \ge 6\)) on velocity as well as temperature profile. An opposite behaviour between velocity and temperature is observed for the parametric values \(m^2=11, Re=9, Pr=0.3, Ec=0.5\), where the former increases and the latter decreases.

Figures 12, 13, 14 and 15 depicts the behaviour of increasing \(m^2\) on both velocity and temperature of the fluid for \(n=1\) and \(n=0.5\). The velocity decreases due to increase in the resistive forces as a consequence of increase in the lorentz forces. As a result of increasing friction a good amount of heat is generated which results in rise in temperature.

Influence of varying values of Re on both velocity and temperature of the fluid is shown in Figs. 16, 17, 18 and 19. The velocity profile increases and temperature profile decreases for both constant and variable acceleration for \(\alpha =6\), \(m^2=9\), \(Ec=0.5\), \(Pr=0.3\).

Figures 20 and 21 portrays the fall and rise in temperature profiles for Re values 5 and 1 respectively with increasing value of Pr.

The influence of increasing Eckert number is shown in Fig. 22 for balanced inertial forces and viscous forces. An increasing behaviour in temperature is observed when the Reynolds number is increased for \(Ec = 1, 1.5, 2\) as shown in Fig. 23.

Fig. 3
figure 3

Influence of varying values of \(\alpha \) on velocity when n = 0.5

Fig. 4
figure 4

Influence of varying values of \(\alpha \) on velocity when n = 1

Fig. 5
figure 5

Influence of varying values of \(\alpha \) on velocity when n = 0.5

Fig. 6
figure 6

Influence of varying values of \(\alpha \) on velocity when n = 1

Fig. 7
figure 7

Influence of varying values of \(\alpha \) on velocity when n = 0.5

Fig. 8
figure 8

Influence of varying values of \(\alpha \) on velocity when n = 1

Fig. 9
figure 9

Influence of varying values of \(\alpha \) on velocity when n = 0.5

Fig. 10
figure 10

Influence of varying values of \(\alpha \) on temperature when n = 1

Fig. 11
figure 11

Influence of varying values of \(\alpha \) on temperature when n = 0.5

Fig. 12
figure 12

Influence of varying values of \(m^2\) on velocity when n = 1

Fig. 13
figure 13

Influence of varying values of \(m^2\) on velocity when n = 0.5

Fig. 24 depicts a transient increase in velocity profile of the second grade fluid. In the absence of the second grade viscoelastic parameter, the behaviour of flow velocity is similar to the solution of viscous fluid obtained by [18] as depicted in Fig. 25 and 26. The precedent tables 1 and 2 represents skin friction values \(\tau _{0}\) ( for lower plate) and \(\tau _{1}\) (for upper plate) for various parametric values of Re, \(\alpha \), and t when the bottom plate suddenly starts moving with velocity \(At^{n}\) and constant acceleration(n=1). It can be noticed that \(\tau _0\) increases with increase in the the value of Re at any instant of time for particular value of \(\alpha \) i.e 0.5. A decreasing behaviour is perceived when \(\alpha = 5\)

An opposite behaviour is observed from Table 2. The shear stress \(\tau _1\) at the upper wall decreases with increase in the the value of Re when the values of t are taken as 0.05, 0.10, 0.15 for particular value of \(\alpha \) i.e 0.5, contrary to the behaviour observed for that particular values of t when \(\alpha = 5\).

Fig. 14
figure 14

Influence of varying values of \(m^2\) on temperature when n = 1

Fig. 15
figure 15

Influence of varying values of \(m^2\) on temperature when n = 0.5

Fig. 16
figure 16

Influence of varying values of Re on velocity when n = 1

Fig. 17
figure 17

Influence of varying values of Re on velocity when n = 0.5

Fig. 18
figure 18

Influence of varying values of Re on temperature when n =1

Fig. 19
figure 19

Influence of varying values of Re on temperature when n = 0.5

Fig. 20
figure 20

Influence of varying values of Pr on temperature when n = 1

Fig. 21
figure 21

Influence of varying values of Pr on temperature when n = 1

Fig. 22
figure 22

Influence of varying values of Ec on temperature when n = 1

Fig. 23
figure 23

Influence of varying values of Ec on temperature when n = 1

Fig. 24
figure 24

Transient velocity profile

Fig. 25
figure 25

Influence of varying values of \(m^2\) on velocity as compared to [18]

Fig. 26
figure 26

Influence of varying values of time on velocity as compared to [18]

Conclusion

The principal aim of this paper is to investigate the influence of dimensionless parameters on velocity as well as temperature field by solving the momentum equation by using suitable finite difference approximations followed by damped-Newton method and solving the energy equation by arranging in tridiagonal form. The noteworthy findings is stated as below.

  • For \(\alpha < 6\), velocity decreases with increasing Re, for other parameters kept constant.

  • For comparatively larger values of \(m^2\), when \(Re > 8\) and \(\alpha \ge 6\), an inverse relation holds between velocity and temperature profiles.

  • The magnetic parameter and Reynolds number have significantly opposite effect on the temperature and velocity profiles of a second grade fluid for both constant and variable acceleration.

  • For balanced inertial and viscous forces the temperature increases for increasing values of Pr and Ec.

  • With increasing values of Pr, the temperature profile decreases and increases respectively for decreasing values of reynolds number.

  • The variations in Re also has a prominent effect on the shear stress in lower and upper plate. The shear stress in the lower plate increases with increase in Re whereas the shear stress in the upper plate decreases with increase in Re for \(\alpha = 0.5\) but a contrasting effect is observed for \(\alpha = 5\) at any instant of time.

  • Increase in the value of Ec encourages entropy generation rate as a consequence of excess heat production within the channel due to increased viscous heating.

  • Increasing values of Ec and \(m^2\) plays a key role in enhancing the temperature at any point of the fluid.

  • Larger values of Re and \(\alpha \) have a pronounced effect on the velocity profile of the fluid. The considered flow problem finds its application generally in MHD generators, in designing the liquid metal cooling system, flow meters and petroleum industries, viscometry and polymer technology.