1 Introduction

The study of non-Newtonian fluids is a very interesting topic for many researchers due to its wide application in modern technologies and many industrial sectors. The non-Newtonian fluids deal with the problems related to the chemical engineering, polymers, petroleum, paints, pharmaceutical, plastics, and food-processing industries. Furthermore, these type of models also deal with fluids such as biological materials, ketchup, polymeric liquids, motor oils, personal care items (shampoo, creams, toothpastes) and complex mixtures, etc. However, in the literature, different types of fluid models exist included rate type, differential and integral models. Many researchers have addressed the rate-type fluid model, because from the research point of view it is more applicable, having both elastic effects and memory. Hence, in the present work, rate-type models are recognized as a Maxwell model. Furthermore, this type of model was first developed by Maxwell to estimate the air viscoelastic characteristics [1]. Also, Jordan et al. [2] studied solutions that are exact for the Stokes problem of the first type, including the Maxwell model also. Moreover, Fetecau et al. [3] explored the Stokes problem of the second type by assuming flow of a fluid placed on the surface of an infinite plate that is vacillating in the plane. Furthermore, the model generated by Maxwell is known as an uncomplicated model operated to assess the rheological performance of fluids and have features of both viscosity and elasticity. Fetecau [4] investigated the exact solution for an infinite vertical surface. The effects of thermophoresis and chemically reactive impacts on the flow of Maxwell fluids were studied by Noor [5]. It is the case that when heat is extracted from a high-temperature wall through a fluid having a certain movement such a mechanism is termed heat convection (advection). This mechanism interacts by molecular diffusion and the motion of the fluid on the basis of natural as well as forced convection. This is due to convective-heat transfer that transpires when the surface temperature varies from that of the encompassing fluid [6]. Solangi et al. [7] investigated the unique heat-conduction properties for the enhancement of concentration. The focus in this work was to discuss the particle-size control for heat exchange and mass-concentration behavior on fluids. Soomro et al. [8] carried out a typical analysis of stretching a surface to develop the heat transfer for the flow of a non-Newtonian nanofluid. To study the physical aspects, numerical computation was used on the governing equations based on finite-difference schemes to describe heat-transfer phenomena. Shafiq et al. [9] conducted an interesting study on the magnetohydrodynamic convective flow to explore the transfer rate of heat, motile microorganisms and mass. They emphasized the parametric study of the problem for Brownian motion, buoyancy forces, thermophoretic, magnetic field and Newtonian heating for temperature and concentration. Kashif et al. [10] carried out a dual thermal analysis to determine the role of temperature dissimilarity versus the temperature or time by using a suspension of nanoparticles. The core objective of this study was to highlight the problem through fractional operators and special functions. Heat transmission over a stretched sheet based on the magnetohydrodynamic two-dimensional Casson fluid flow was observed by Hamid et al. [11]. They examined the linear convected heat effects on two-fold solutions in which numerical stability was discussed for the dual results from the governing equation of the problem. Abro et al. [12] suggested a fractional study for thermal radiation of a Jeffery fluid and educed the subsolutions from fluid motion of the second grade with and without a magnetic field. The thermal properties of the governing equations were treated by an integral-transform approach. Sheikholeslami et al. [13] observed a magnetizable hybrid fluid in the core of a circular cavity with two heaters in circular form subjected to the carbon nanotubes. Their focus was to create the magnetic fields by wires via an electrical current. Abdelmalek et al. [14] applied a hybrid technique known as the Control Volume Finite Element Scheme to the curved circular heater with nanosized particles on convective-heat transmission. They suggested the finding and concluded that the conformation of the curved heater played an essential role to manage the heat-transfer rate and control the convectional flow within the enclosure. Kashif [15] applied surface-modification technology to analyze the thermodissipation effects on the time-dependent natural-convection flow of fluid. A finite Fourier sine transform, Laplace and fractional techniques were applied to the governing equations to show the typical and rheological properties of the problem. Although the studies on heat and transfer analysis will be continued the relevant studies can be observed therein in categorical format as: heat transfer via analytical approaches [16, 17, 2932], heat transfer via numerical approaches [18, 19, 3336], heat transfer via fractional calculus approaches [20, 21, 37, 38] and heat transfer via multidimensional approaches [22, 23, 25, 26, 39, 40]. Motivated by the above consideration, the main theme of this paper is to assess the significance of convective heating and variable heat source on the azimuthal oscilatroy MHD convective flows developed in a cylindrical Darcy–Forchheimer porous medium filled by a radiating second-grade fluid.

Talha Anwar et al. [24] recently, discussed the same problem for a different fluid model without analyzing the diffusion equation, and determined the approximate result for the proposed problem by using the Laplace transformation technique and Durbin’s numerical algorithm. The work introduced in this paper is new. In this model, we added a concentration equation and analyzed its effects on the velocity profile. Based on the aforesaid literature, the object of this exploration is to establish the exact expressions for velocity, concentration and energy equations, in terms of a generalized Lorenzo–Hartley function known as the G-function, of the considered problem and accomplish a comparison with the results obtained by Talha Anwar et al. [24]. In solving the differential equations (DEs) with the help of the Laplace transform method (LT), the inverse integral transform is not trivial. In this regard we have to introduce some special functions. For example, a Mittag–Leffler function, a Robotnov and Hartley function, a Lorenzo and Hartley generalized R function, a generalized G function, etc. Such functions produce a direct solution and give important interpretations for the fundamental linear integer-order DEs and corresponding IVPs. These functions are helpful in the solution of the problems and more notably in the solution of differential equations. Furthermore, the consequences of different related physical parameters, such as relaxation time parameter λ, grashof number Gr, magnetic field M, dimensionless time τ, Schmidt number Sc, mass Grashof number Gm and Prandtl number Pr, on nondimensional velocity, concentration and temperature are discussed in detail and demonstrated graphically using appropriate software.

2 Mathematical model

Let us assume that the unsteady MHD, natural convection, incompressible, time-dependent, viscous motion of a Maxwell fluid is near an infinite upright plate embedded in a permeable medium with constant concentration and ramped conditions on temperature. In this case, consider the cartesian coordinates system \((x,y)\), the plate is placed in the plane such that the x-axis is vertically oriented and the y-axis is in the normal direction. At the end of the wall, temperature, velocity and concentration are assumed to be time dependent within certain limits of time, identified as the characteristic time; velocity, temperature and concentration after that time attain constant values of velocity \(u_{0}\), temperature \(T_{\infty }\) and concentration \(C_{\infty }\). The physical quantities of the model’s flow that is under consideration is described in Fig. 1. The principal governing partial differential equations with small Reynolds number and the usual Boussinesq’s approximation are given as [25, 26]:

$$\begin{aligned}& \biggl(1+\lambda _{1}\frac{\partial }{\partial t} \biggr) \frac{\partial {u}^{*}(\eta ,t)}{\partial t} \\& \quad =\upsilon \frac{\partial ^{2}{{u}^{*}(\eta ,t)}}{\partial {\eta }^{2}}- \biggl( \lambda _{1}\frac{\partial }{\partial {t}} +1 \biggr) \frac{{\sigma }B_{0}^{2} {{u}^{*}(\eta ,t)}}{\rho } \\& \qquad {}+ \biggl(1+\lambda _{1}\frac{\partial }{\partial {t}} \biggr)g\beta _{ \grave{T}} \bigl(\grave{T}(\eta ,t)-\grave{T}_{\infty } \bigr) - \biggl(1+\lambda _{1}\frac{\partial }{\partial {t}} \biggr)g\beta _{ \grave{C}} \bigl(\grave{C}_{\infty }-\grave{C}(\eta ,t) \bigr), \end{aligned}$$
(1)
$$\begin{aligned}& \frac{\partial {\grave{T}(\eta ,t)}}{\partial {t}}= \frac{k}{{\rho }{\grave{C}_{p}}} \frac{\partial ^{2}{\grave{T}(\eta ,t)}}{\partial {\eta }^{2}}, \end{aligned}$$
(2)
$$\begin{aligned}& \biggl(1+\lambda _{1}\frac{\partial }{\partial t} \biggr)S_{0}= \upsilon \frac{\partial {{u}^{*}(\eta ,t)}}{\partial {\eta }}, \end{aligned}$$
(3)
$$\begin{aligned}& \frac{\partial {\grave{C}(\eta ,t)}}{\partial {t}}=\delta _{m} \frac{\partial ^{2}{\grave{C}(\eta ,t)}}{\partial {\eta }^{2}}-\delta _{m} \bigl(\grave{C}(\eta ,t)- \grave{C}_{\infty } \bigr). \end{aligned}$$
(4)

with initial and boundary conditions of:

$$\begin{aligned} & {u}^{*}(\eta ,0)=0,\qquad \grave{T}(\eta ,0)= \grave{T}_{\infty },\qquad \grave{C}(\eta ,0)=\grave{C}_{\infty },\qquad \frac{\partial {u(\eta ,0)}}{\partial {t}}=0, \quad \eta \geq 0, \end{aligned}$$
(5)
$$\begin{aligned} &\grave{C}(0,t)=\grave{C}_{w},\qquad {u}^{*}(0,t)={g_{1}(t)},\qquad \grave{T}(0,t)={g_{2}(t)}, \end{aligned}$$
(6)

where

$$\begin{aligned} {g_{1}(t)}= \textstyle\begin{cases} u_{0}\frac{\grave{t}}{t_{0}},&0< \grave{t}\leq {t_{0}}; \\ u_{0},&\grave{t}>t_{0}, \end{cases}\displaystyle \qquad {g_{2}(t)}= \textstyle\begin{cases} {(T_{w}-T_{\infty })}\frac{t}{t_{0}} + T_{\infty },&0< t\leq {t_{0}}; \\ \grave{T}(0,\grave{t})=T_{w},&t>t_{0}. \end{cases}\displaystyle \end{aligned}$$
(7)

and

$$\begin{aligned} {u}^{*}(\eta ,t)\rightarrow 0,\qquad \grave{T}(\eta ,t) \rightarrow \infty ,\qquad \grave{C}(\eta ,t)\rightarrow \infty \quad \text{as } \eta \rightarrow \infty . \end{aligned}$$
(8)

Introducing the set of dimensionless quantities:

$$\begin{aligned} &\psi=\frac{u_{0}}{\upsilon }\eta ,\qquad \lambda = \frac{\lambda _{1} {u_{0}}^{2}}{\upsilon },\qquad \tau = \frac{u_{0}^{2}}{\upsilon }t, \qquad \theta = \frac{\grave{T}-T_{\infty }}{T_{w}-T_{\infty }}, \qquad S= \frac{S_{0}}{\rho {u_{0}}}, \\ &\begin{aligned} & Sc= \frac{\upsilon }{\delta _{m}},\qquad G_{m}=\frac{g\beta _{\grave{C}}t_{0}(\grave{C}-C_{\infty })}{u_{0}}, \qquad u=\frac{{u}^{*}}{u_{0}},\qquad M= \frac{{\sigma _{0}}B_{0}^{2}\upsilon }{{\rho }u_{0}^{2}}, \\ &\Pr = \frac{{\mu }{C_{p}}}{k},\qquad \upsilon ={t_{0}} {u_{0}}^{2},\qquad C^{\ast }=\frac{\grave{C}-C_{\infty }}{C_{w}-C_{\infty }},\qquad G_{r}= \frac{g\beta _{\grave{T}}t_{0}(\grave{T}-T_{\infty })}{u_{0}},\end{aligned} \\ & a=M, \qquad b=1+\lambda M,\qquad \lambda _{0} = \frac{\upsilon ^{2}}{u_{0}^{2}}. \end{aligned}$$
(9)

After employing the dimensionless quantities, and ignoring the asterisk ∗ notation, the following partial differential equations in dimensionless form are derived as:

$$\begin{aligned}& \begin{aligned}[b] \biggl( 1+\lambda \frac{\partial }{\partial {\tau }} \biggr) \frac{\partial {u(\psi ,\tau )}}{\partial {\tau }}={}& \frac{\partial ^{2}{u(\psi ,\tau )}}{\partial {\psi }^{2}}- \biggl(1+ \lambda \frac{\partial }{\partial {\tau }} \biggr)Mu(\psi ,\tau ) \\ &{}+ \biggl(1+\lambda \frac{\partial }{\partial {\tau }} \biggr)G_{r} \theta (\psi ,\tau )+ \biggl(1+\lambda \frac{\partial }{\partial {\tau }} \biggr)G_{m}C(\psi , \tau ), \end{aligned} \end{aligned}$$
(10)
$$\begin{aligned}& \frac{\partial {\theta (\psi ,\tau )}}{\partial {\tau }}=\frac{1}{\Pr } \frac{\partial ^{2}{\theta (\psi ,\tau )}}{\partial {\psi }^{2}}, \end{aligned}$$
(11)
$$\begin{aligned}& \biggl(1+\lambda \frac{\partial }{\partial \tau } \biggr)S= \frac{\partial {u(\psi ,\tau )}}{\partial {\psi }}, \end{aligned}$$
(12)
$$\begin{aligned}& \frac{\partial {C(\psi ,\tau )}}{\partial {\tau }}=\frac{1}{Sc} \frac{\partial ^{2}{C(\psi ,\tau )}}{\partial {\psi }^{2}}- \frac{\lambda _{0}}{Sc}C(\psi ,\tau ). \end{aligned}$$
(13)

with conditions in dimensionless form:

$$\begin{aligned}& u(\psi ,0)=0,\qquad C(\psi ,0)=0,\qquad \theta (\psi ,0)=0, \end{aligned}$$
(14)
$$\begin{aligned}& u(0,\tau )=d(\tau ),\qquad \theta (0,\tau )=d(\tau ),\qquad C(0,\tau )=1. \end{aligned}$$
(15)

where

$$\begin{aligned} d(\tau )= \textstyle\begin{cases} \tau ,& 0< \tau \leq 1 \\ 1,& \tau >1, \end{cases}\displaystyle \end{aligned}$$

and

$$\begin{aligned} u(\psi ,\tau ) \rightarrow 0,\qquad C(\psi ,\tau ) \rightarrow 0, \qquad \theta (\psi ,\tau ) \rightarrow 0 \quad \text{as } \psi \rightarrow {\infty }. \end{aligned}$$
(16)
Figure 1
figure 1

Geometrical formation of the flow model

3 Solution of the problem

To obtain the solution of the considered problem, the Laplace transformation technique was employed.

3.1 Exact solution of heat profile

Applying the Laplace transformation technique to write the solution of Eq. (11) with conditions as Eqs. (14), (15), (16), we have

$$\begin{aligned} \frac{d^{2}{\bar{ \theta }(\psi ,s)}}{d{\psi }^{2}}-P_{r} s{ \bar{\theta }(\psi ,s)}=0. \end{aligned}$$
(17)

with

$$\begin{aligned} {\bar{\theta }(0,s)}=\frac{1-e^{-s}}{s^{2}} \quad \text{and} \quad { \bar{\theta }(\psi ,s)}\rightarrow 0 \quad \text{as }\psi \rightarrow \infty . \end{aligned}$$
(18)

and its solution is given by

$$\begin{aligned} \bar{\theta }(\psi ,s)= c_{1} e^{\psi \sqrt{P_{r}s}} + c_{2} e^{- \psi \sqrt{P_{r}s}}. \end{aligned}$$
(19)

we applied boundary conditions for temperature given by Eq. (18) to determine the unknown constants and obtain:

$$\begin{aligned} \bar{\theta }(\psi ,s)= \frac{1}{s^{2}} \bigl(1-e^{-s} \bigr) e^{- \psi \sqrt{P_{r}s}}. \end{aligned}$$
(20)

which can be written as

$$\begin{aligned} \bar{\theta }(\psi ,s)&= \biggl(\frac{e^{-\psi \sqrt{P_{r}s}}}{s^{2}} \biggr)-{e^{-s}} \biggl(\frac{e^{-\psi \sqrt{P_{r}s}}}{s^{2}} \biggr), \\ &= \bar{\theta }_{r}(\psi ,s)-e^{-s}\bar{\theta }_{r}(\psi ,s). \end{aligned}$$
(21)

To obtain the required solution of Eq. (21), the Laplace inverse transformation was used, which is written as:

$$\begin{aligned} {\theta }(\psi ,\tau )= {\theta }_{r}(\psi ,\tau )-{\theta }_{r}(\psi , \Phi )g(\Phi ). \end{aligned}$$
(22)

with

$$\begin{aligned} {\theta }_{r}(\psi ,\tau )= \biggl( \frac{P_{r}}{2}{\psi }^{2}+\tau \biggr)\operatorname{erfc} \biggl( \sqrt{\frac{P_{r}}{4\tau }} {\psi }\biggr)-\biggl(\sqrt{ \frac{P_{r}\tau }{\pi }} {\psi }\biggr)e^{ \frac{-P_{r}{\psi }^{2}}{4\tau }}. \end{aligned}$$
(23)

where \(g(\Phi )\) represents a standard Heaviside function and \(\Phi =\tau -1\).

3.1.1 Nusselt number

An expression for the Nusselt number to efficiently forecast the generalized rate of heat transfer corresponding to ramped conditions is evaluated as:

$$\begin{aligned} N_{u}&=-\frac{\partial \theta (\psi ,\tau )}{\partial \psi }\biggm|_{\psi =0} \\ &=-\frac{\partial }{\partial \psi }\mathscr{L}^{-1} \bigl\lbrace \bar{\theta }( \psi ,s) \bigr\rbrace \biggm|_{\psi =0} \\ &=-\mathscr{L}^{-1} \biggl\lbrace \frac{\partial \bar{\theta }(\psi ,s)}{\partial \psi } \biggm|_{\psi =0} \biggr\rbrace \\ &=\mathscr{L}^{-1} \biggl\lbrace \frac{(1-e^{-s})\sqrt{Prs}}{s^{2}} \biggr\rbrace \\ &= \sqrt{\Pr } \biggl[\frac{2\sqrt{\tau }}{\sqrt{\pi }}- \frac{2\sqrt{\tau -1}}{\sqrt{\pi }}H(\tau -1) \biggr], \end{aligned}$$
(24)

where \(H(\tau -1)\) represents a standard Heaviside function.

3.2 Exact solution of mass profile

Solving Eq. (13) using Eqs. (14), (15) and (16), and employing the Laplace transformation technique, the resulting equations are written as:

$$\begin{aligned} \frac{d^{2}{\bar{C}(\psi ,s)}}{d{\psi }^{2}}- ({S_{c}}s+\lambda _{0} ) {\bar{C}(\psi ,s)}=0. \end{aligned}$$
(25)

with

$$\begin{aligned} {\bar{C}(0,s)}=\frac{1}{s} \quad \text{and} \quad {\bar{C}(\psi ,s)} \rightarrow 0 \quad \text{as }\psi \rightarrow \infty . \end{aligned}$$
(26)

the solution in general form is

$$\begin{aligned} \bar{C}(\psi ,s)= c_{1} e^{{\psi }\sqrt{{S_{c}}s+\lambda _{0}}} + c_{2} e^{-{ \psi }\sqrt{{S_{c}}s+\lambda _{0}}}. \end{aligned}$$
(27)

the values of constants \(c_{1}\) and \(c_{2}\), conditions are implemented as given in Eq. (26) for concentration, so

$$\begin{aligned} \bar{C}(\psi ,s)= \frac{1}{s}e^{-{\psi }\sqrt{{S_{c}}s+\lambda _{0}}}. \end{aligned}$$
(28)

To obtain the solution, taking the inverse Laplace transformation, we have:

$$\begin{aligned} C(\psi ,\tau )={}&\mathscr{L}^{-1} \biggl\lbrace \frac{1}{s}e^{-{\psi } \sqrt{Sc}\sqrt{s+\frac{\lambda _{0}}{Sc}}} \biggr\rbrace \\ ={}&\frac{1}{2} \biggl(e^{-{\psi }\sqrt{Sc}\sqrt{\frac{\lambda _{0}}{Sc}}}\operatorname{erfc} \biggl( \frac{\psi \sqrt{Sc}}{2\sqrt{\tau }}-\sqrt{ \frac{\lambda _{0}}{Sc}\tau } \biggr) \biggr) \\ &{}+ \frac{1}{2} \biggl(e^{{ \psi }\sqrt{Sc}\sqrt{\frac{\lambda _{0}}{Sc}}}\operatorname{erfc} \biggl( \frac{\psi \sqrt{Sc}}{2\sqrt{\tau }}+\sqrt{\frac{\lambda _{0}}{Sc}\tau } \biggr) \biggr). \end{aligned}$$
(29)

The following result, which exists in the literature, is used:

$$\begin{aligned} \mathscr{L}^{-1} \biggl\lbrace \frac{e^{-{\psi }\sqrt{c_{1}}\sqrt{s+b_{1}}}}{s-a_{1}} \biggr\rbrace ={}& \frac{e^{a_{1}\tau }}{2} \biggl(e^{-{\psi }\sqrt{c_{1}}\sqrt{a_{1}+b_{1}}} \operatorname{erfc} \biggl(\frac{\psi \sqrt{c_{1}}}{2\sqrt{\tau }}-\sqrt{(a_{1}+b_{1}) \tau } \biggr) \biggr) \\ &{}+\frac{e^{a_{1}\tau }}{2} \biggl(e^{{\psi }\sqrt{c_{1}}\sqrt{a_{1}+b_{1}}}\operatorname{erfc} \biggl( \frac{\psi \sqrt{c_{1}}}{2\sqrt{\tau }}+\sqrt{(a_{1}+b_{1})\tau } \biggr) \biggr). \end{aligned}$$
(30)

3.3 Exact solution of velocity profile

The solution of Eq. (10) by using a Laplace transform, is:

$$\begin{aligned}& \begin{aligned}[b] (1+\lambda s )\bar{u}(\psi ,s)= {}&\frac{d^{2}\bar{u}(\psi ,s)}{d{\psi }^{2}} + (1+ \lambda s )G_{r}{ \bar{\theta } (\psi ,s )}\\ &{}+ (1+\lambda s )G_{m}{ \bar{C} (\psi ,s )} - (1+\lambda s )M\bar{u}( \psi ,s), \end{aligned} \end{aligned}$$
(31)
$$\begin{aligned}& \frac{d^{2}\bar{u}(\psi ,s)}{d{\psi }^{2}}- \bigl( a + \lambda s^{2} + bs \bigr) \bar{u}(\psi ,s)= - (1+\lambda s ) ( G_{r} \bar{\theta }+G_{m}{\bar{C}} ). \end{aligned}$$
(32)

by using Eqs. (21), (28) to determine the values \({\bar{\theta } (\psi ,s )}\) and \({\bar{C} (\psi ,s )}\), then Eq. (32) has the general form of the solution, which is represented as:

$$\begin{aligned} \bar{u} (\psi ,s )={}&c_{3}e^{\psi \sqrt{ ( a + \lambda s^{2} + bs )}}+c_{4}e^{-\psi \sqrt{ ( a + \lambda s^{2} + bs )}}- \biggl( \frac{G_{r} (1+\lambda s ) (1-e^{-s} )e^{-\psi \sqrt{P_{r}s}}}{s^{2} ( P_{r}s- ( a + \lambda s^{2} + bs ) ) } \biggr) \\ &{} - \biggl( \frac{G_{m} (1+\lambda s )e^{-\psi \sqrt{S_{c}s+{\lambda _{0}}}}}{s ( S_{c}s+{\lambda _{0}}- ( a + \lambda s^{2} + bs ) ) } \biggr) \end{aligned}$$
(33)

Applying \({\bar{u}(\psi ,s)}\rightarrow 0\), as \(\psi \rightarrow \infty \) and \({\bar{u}(0,s)}=\frac{1-e^{-s}}{s^{2}}\), to determine the values of unknowns \(c_{3}\) and \(c_{4}\), we obtain:

$$\begin{aligned} \bar{u} (\psi ,s )={}& \biggl( \frac{1-e^{-s}}{s^{2}} \biggr)e^{- \psi \sqrt{ ( a + \lambda s^{2} + bs )}}+ \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \biggl( \frac{G_{r} (1+\lambda s ) (e^{-\psi \sqrt{ ( a + \lambda s^{2} + bs )}}-{e^{-\psi \sqrt{P_{r}s}}} ) }{P_{r}s- ( a + \lambda s^{2} + bs )} \biggr) \\ &{}+ \biggl( \frac{G_{m} (1+\lambda s ) (e^{-\psi \sqrt{ ( a + \lambda s^{2} + bs )}}-e^{-\psi \sqrt{S_{c}s+{\lambda _{0}}}} ) }{s ( S_{c}s+{\lambda _{0}}- ( a + \lambda s^{2} + bs ) ) } \biggr). \end{aligned}$$
(34)

To find the Laplace inverse of Eq. (34), we rearrange the above equation as:

$$\begin{aligned} \bar{u} (\psi ,s )=\bar{F} (\psi ,s )+ Gr \bar{\chi } (\psi ,s ) \bigl[\bar{\theta } (\psi ,s ) - \bar{F} (\psi ,s ) \bigr] +Gm \bar{\xi } ( \psi ,s ) \bigl[\bar{C} (\psi ,s )-\bar{H} ( \psi ,s ) \bigr]. \end{aligned}$$
(35)

Employing an inverse Laplace transformation on Eq. (35), the obtained solution is written as:

$$\begin{aligned} {u} (\psi ,\tau )={F} (\psi ,\tau )+ Gr \bigl[(\chi \ast \theta ) (\tau ) - (\chi \ast F) (\tau ) \bigr] +Gm \bigl[(\xi \ast C) (\tau )-(\xi \ast H) (\tau ) \bigr]. \end{aligned}$$
(36)

with

$$\begin{aligned} {F} (\psi ,\tau )={F_{1}} (\psi ,\tau ) - {F_{1}} (\psi ,\Phi )g(\Phi ). \end{aligned}$$
(37)

where \(g(\Phi )\) represents a standard Heaviside function and \(\Phi =\tau -1\), also

$$\begin{aligned} \bar{F_{1}} (\psi ,s )&=\frac{1}{s^{2}}e^{-\psi \sqrt{a + \lambda s^{2} + bs}} \end{aligned}$$
(38)
$$\begin{aligned} &=\sum_{\alpha =0}^{\infty }\sum _{\beta =0}^{\infty }\sum_{\gamma =0}^{ \infty } \frac{(-\psi )^{\alpha }(a)^{\frac{\alpha }{2}-\beta }(b)^{\beta -\gamma }(\lambda )^{\gamma }\Gamma (\frac{\alpha }{2}+1)}{\alpha ! \gamma ! \Gamma (\beta - \gamma +1)} \frac{1}{s^{2- \beta -\gamma }}, \end{aligned}$$
(39)
$$\begin{aligned} {F_{1}} (\psi ,\tau )&=\sum_{\alpha =0}^{\infty } \sum_{ \beta =0}^{\infty }\sum _{\gamma =0}^{\infty } \frac{(-\psi )^{\alpha }(a)^{\frac{\alpha }{2}-\beta }(b)^{\beta -\gamma }(\lambda )^{\gamma }\Gamma (\frac{\alpha }{2}+1)}{\alpha ! \gamma ! \Gamma (\beta - \gamma +1)} \frac{t^{1- \beta -\gamma }}{\Gamma (2- \beta -\gamma )}, \end{aligned}$$
(40)
$$\begin{aligned} \bar{H} (\psi ,s )&=\frac{1}{s}e^{-\psi \sqrt{a + \lambda s^{2} + bs}}, \end{aligned}$$
(41)
$$\begin{aligned} &=\sum_{\alpha =0}^{\infty }\sum _{\beta =0}^{\infty }\sum_{\gamma =0}^{ \infty } \frac{(-\psi )^{\alpha }(a)^{\frac{\alpha }{2}-\beta }(b)^{\beta -\gamma }(\lambda )^{\gamma }\Gamma (\frac{\alpha }{2}+1)}{\alpha ! \gamma ! \Gamma (\beta - \gamma +1)} \frac{1}{s^{1- \beta -\gamma }}, \end{aligned}$$
(42)
$$\begin{aligned} {H} (\psi ,\tau )&=\sum_{\alpha =0}^{\infty }\sum _{ \beta =0}^{\infty }\sum _{\gamma =0}^{\infty } \frac{(-\psi )^{\alpha }(a)^{\frac{\alpha }{2}-\beta }(b)^{\beta -\gamma }(\lambda )^{\gamma }\Gamma (\frac{\alpha }{2}+1)}{\alpha ! \gamma ! \Gamma (\beta - \gamma +1)} \frac{t^{- \beta -\gamma }}{\Gamma (1- \beta -\gamma )}, \end{aligned}$$
(43)
$$\begin{aligned} \bar{\chi } (\psi ,s )&=(1 + \lambda s) \frac{1}{\lambda s^{2}- (\Pr -b)s+a}, \end{aligned}$$
(44)
$$\begin{aligned} &=\sum_{n=0}^{\infty }\frac{(-1)^{n}(a)^{n}}{(\lambda )^{n+1}} \frac{(s)^{-n-1}}{(s - \epsilon )^{n+1}} + \lambda \sum_{n=0}^{ \infty } \frac{(-1)^{n}(a)^{n}}{(\lambda )^{n+1}} \frac{(s)^{-n}}{(s - \epsilon )^{n+1}}, \end{aligned}$$
(45)
$$\begin{aligned} {\chi } (\psi ,\tau )&=\sum_{n=0}^{\infty } \frac{(-1)^{n}(a)^{n}}{(\lambda )^{n+1}} \bigl[G_{1,-n-1, n + 1}( \epsilon ,\tau ) + G_{1,-n, n + 1}(\epsilon ,\tau ) \bigr], \end{aligned}$$
(46)
$$\begin{aligned} \bar{\xi } (\psi ,s )&=(1 + \lambda s) \frac{1}{\lambda s^{2}- (Sc-b)s+(a-\lambda _{0})}, \end{aligned}$$
(47)
$$\begin{aligned} &=\sum_{m=0}^{\infty } \frac{(-1)^{m}(a-\lambda _{0})^{m}}{(\lambda )^{m+1}} \frac{(s)^{-m-1}}{(s - \delta )^{m+1}} + \lambda \sum_{m=0}^{\infty } \frac{(-1)^{m}(a-\lambda _{0})^{m}}{(\lambda )^{m+1}} \frac{(s)^{-m}}{(s - \delta )^{m+1}}, \end{aligned}$$
(48)
$$\begin{aligned} {\xi } (\psi ,\tau )&=\sum_{m=0}^{\infty } \frac{(-1)^{m}(a-\lambda _{0})^{m}}{(\lambda )^{m+1}} \bigl[G_{1,-m-1, m + 1}(\delta ,\tau ) + G_{1,-m, m + 1}(\delta ,\tau ) \bigr]. \end{aligned}$$
(49)

with \(\epsilon = \frac{\Pr - b}{\lambda }\) and \(\delta = \frac{Sc - b}{\lambda }\), the function \(G_{h,b,l}(.,\tau )\) used in the above expressions is known as the generalized Lorenzo–Hartley function and is defined as \(\mathscr{L}^{-1} \lbrace \frac{s^{b}}{(s^{h}-j)^{l}} \rbrace =G_{h,b,l}(j,\tau )\); \(\operatorname{Re}(hl-b)>0\), \(\operatorname{Re}(s)>0\), \(\vert \frac{j}{s^{h}} \vert <1 \).

3.4 Solution of shear stress

In the industrial and mechanical fields, wall shear stress is of indispensable significance and increasing shear stress is considered as a disadvantage. To estimate the wall shear stress and skin-friction coefficient for a Maxwell fluid we employ a Laplace transform on Eq. (12), and we have:

$$\begin{aligned} (1+\lambda s )\bar{S} (\psi ,s ) = \frac{d\bar{u} (\psi ,s )}{d{\psi }}. \end{aligned}$$
(50)

To determine the value of \(\frac{d\bar{u} (\psi ,s )}{d{\psi }}\), differentiating Eq. (34) with respect to ψ yields:

$$\begin{aligned} \frac{d\bar{u} (\psi ,s )}{d{\psi }}={}& \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \bigl( -\sqrt{\S }e^{-\psi \sqrt{\S }} \bigr) \\ &{} + \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \biggl( \frac{G_{r} (1+\lambda s ) (-\sqrt{\S }e^{-\psi \sqrt{\S }}+{\sqrt{P_{r}s}e^{-\psi \sqrt{P_{r}s}}} ) }{P_{r}s-\S } \biggr) \\ &{}+ \biggl( \frac{G_{m} (1+\lambda s ) (-\sqrt{\S }e^{-\psi \sqrt{\S }}+\sqrt{S_{c}s+{\lambda _{0}}}e^{-\psi \sqrt{S_{c}s+{\lambda _{0}}}} ) }{s ( S_{c}s+{\lambda _{0}}-\S ) } \biggr), \end{aligned}$$
(51)

where \(\S = a + \lambda s^{2} + bs\).

Inserting Eq. (51) into Eq. (50), gives the expression for shear stress:

$$\begin{aligned} \bar{S} (\psi ,s )={}& \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \biggl(\frac{ -\sqrt{\S }e^{-\psi \sqrt{\S }}}{1+\lambda s } \biggr) \\ &{} + \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \biggl( \frac{G_{r} (1+\lambda s ) (-\sqrt{\S }e^{-\psi \sqrt{\S }}+{\sqrt{P_{r}s}e^{-\psi \sqrt{P_{r}s}}} ) }{ (1+\lambda s ) ( P_{r}s-\S ) } \biggr) \\ &{}+ \biggl( \frac{G_{m} (1+\lambda s ) (-\sqrt{\S }e^{-\psi \sqrt{\S }}+\sqrt{S_{c}s+{\lambda _{0}}}e^{-\psi \sqrt{S_{c}s+{\lambda _{0}}}} ) }{s (1+\lambda s ) ( S_{c}s+{\lambda _{0}}-\S ) } \biggr). \end{aligned}$$
(52)

The skin-friction coefficient is estimated as

$$\begin{aligned} \bar{C_{f}} ={}&\frac{1}{ (1+\lambda s )} \frac{d\bar{u} (\psi ,s )}{d{\psi }}\biggm|_{\psi =0}, \\ ={}& \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \biggl( \frac{ -\sqrt{\S }}{1+\lambda s } \biggr) + \biggl( \frac{1-e^{-s}}{s^{2}} \biggr) \biggl( \frac{G_{r} (1+\lambda s ) (-\sqrt{\S }+{\sqrt{P_{r}s}} ) }{ (1+\lambda s ) ( P_{r}s-\S ) } \biggr) \\ &{}+ \biggl( \frac{G_{m} (1+\lambda s ) (-\sqrt{\S }+\sqrt{S_{c}s+{\lambda _{0}}} ) }{s (1+\lambda s ) ( S_{c}s+{\lambda _{0}}-\S ) } \biggr). \end{aligned}$$
(53)

Since the solution given in Eq. (52) and Eq. (53) contains complex terms of the Laplace parameter s, to derive the solution in real time τ, we applied the numerical inversion method known as the Durbin Method [27].

4 Limiting cases

We obtain the same expression for the velocity profile with ramped temperature, without considering the effect of the mass Grashof number, i.e., \(Gm=0\), as obtained by Talha Anwar et al. [24]. Also, we derive the same result for the velocity profile and temperature distribution of a viscous fluid when \(\lambda = 0\) and \(Gm=0\), etc. [28]. This proves the authenticity of our work compared with the existing literature.

5 Results and discussion

In this work, we investigated the effects of constant concentration, ramped temperature and velocity, on the unsteady MHD convective flow of a Maxwell fluid. The exact expressions for nondimensional velocity, concentration and energy equations, in terms of the generalized Lorenzo–Hartley function known as the G-function, are established for the considered problem. The results are demonstrated graphically, for better understanding of the physical significance of the proposed problem, by considering several values of different parameters involved in the problem, like Prandtl number ‘Pr’, the relaxation time ‘λ’, dimensionless time ‘τ’, Schmidt number ‘Sc’, mass Grashof number ‘Gm’ and Grashof number ‘Gr’. For various values of t the behavior of temperature, concentration and velocity are portrayed in Figs. 2 to 11.

Figure 2
figure 2

Temperature and concentration profiles of a Maxwell fluid for various values of τ

Figure 2 represents the influence of τ on concentration and the energy equation. It is noted that increases in time enhanced the temperature and concentration profile of the moving fluid. Concentration and energy are both rising functions of time.

Figure 3 describes the temperature variation for various values of Pr; it is shown that when the value of Pr increases the result is a decrease in the temperature. Generally, the thermal outline layer thickness decreases rapidly, corresponding to high values of Pr. Hence, increasing the value of Pr improves the boundary thickness, which causes the energy profile to slow down linearly.

Figure 3
figure 3

Temperature profiles of a Maxwell fluid for various values of Pr at two different times

Figure 4 illustrates the behavior of concentration for various values of Schmidt number Sc; it is deceptive that for maximum values of Sc, a decay in concentration profile is noted. This is due to the reduction in the outline layer of concentration that occurs corresponding to the increase in the value of the Schmidt number. The involvement of the concentration factor of fluid velocity on the fluid flow is very important and it cannot be overlooked.

Figure 4
figure 4

Concentration profiles of a Maxwell fluid for various values of Sc at two different times

Figure 5 describes the effects of Gm. The mass Grashof number is generally defined as the ratio of mass buoyancy force to viscous force, which causes unrestricted convection. It is noted that the velocity is enhanced in the case of increasing Gm.

Figure 5
figure 5

Velocity profiles of a Maxwell fluid for various values of Gm at two different times

Figure 6 shows the impacts of Gr. It is noted that the velocity is elevated due to the higher value of Gr. Thermal Grashof number is the proportion of thermal buoyancy force to viscous force, which causes free convection.

Figure 6
figure 6

Velocity profiles of a Maxwell fluid for various values of Gr at two different times

Figure 7 illustrates the variation in the velocity field for different values of M; it can be observed that the fluid velocity declines when M is maximum, which causes an increase in the Lorentz force that acts as a dragging force along with allied forces that leads to a fall in the fluid velocity. Also, this force becomes weaker when this is far from the plate surface and eventually fluid flow stops.

Figure 7
figure 7

Velocity profiles of a Maxwell fluid for various values of M at two different times

Figure 8 represents the influence of Pr on the momentum equation. It is noted that increases in Prandtl number reduce the velocity of the moving fluid. The outline layer of the velocity profile becomes thicker due to the small rate of thermal diffusion, Pr dominates the relative thickness of the boundary layers of momentum in heat-transfer problems.

Figure 8
figure 8

Velocity profiles of a Maxwell fluid for various values of Pr at two different times

In Fig. 9 the action of Sc on the velocity profile is displayed and shows that the flow will decrease as Sc increases. Physically, the Schmidt number Sc is mathematically defined as the ratio of momentum to mass diffusivity. This layer of momentum diffusivity of the fluid is more viscous, and as a result velocity decreases.

Figure 9
figure 9

Velocity profiles of a Maxwell fluid for various values of Sc at two different times

Figure 10 shows the behavior of the Maxwell parameter in that the velocity decreases as the value of λ increases. This is due to a low Maxwell shear stress impact, parameter value variation of the term λ is not too significant because of the low effect of activation energy.

Figure 10
figure 10

Velocity profiles of a Maxwell fluid for various values of λ at two different times

Figure 11 shows the momentum field to analyze the effect of τ. A rise in the velocity profile appears on increasing the value of τ. It has been observed that velocity increases as a function of time.

Figure 11
figure 11

Velocity profile of a Maxwell fluid for various values of τ

6 Conclusions

In this paper, we analyze the effects of ramped temperature and velocity with constant concentration on unsteady MHD convective flow on Maxwell fluids. The governing partial differential equation is inscribed into a dimensionless form and the technique of Laplace transformation is used to establish the analytical solution for the velocity profile, concentration and energy equations, in terms of the generalized Lorenzo–Hartley function known as the G-function, for the proposed problem. The mathematical expressions for skin-friction coefficient and Nusselt number are also given. Also, for various parameters, i.e., Prandtl number Pr, Maxwell parameter λ, dimensionless time τ, Schmidt number Sc, magnetic field M, mass and thermal Grashof numbers Gm and Gr, respectively, the impacts of all these parameters on fluid velocity field, constant concentration and ramped wall temperature with the help of graphical illustrations are analyzed. Some noteworthy remarks and concluding results from this work are:

  • It is shown that the temperature field declines with larger values of Pr. It is also noted that the concentration reduces for increasing values of Sc.

  • It is determined that concentration, temperature and velocity profiles are increased as τ increases.

  • It is shown that for higher values of M and λ the fluid velocity is decreased.

  • Increasing values of the Grashof numbers Gr and Gm stimulate the velocity distribution.

  • The accumulative values of the parameters Sc and Pr decrease in the velocity distribution noted.

  • The involvement of the concentration factor of fluid velocity in the fluid movement is significant and cannot be overlooked.