1 Introduction

Since the success of production of the strongly interacting quark–gluon plasma (QGP) at Relativistic Heavy Ion Collider (RHIC) [1], relativistic viscous hydrodynamic model has been one of promising phenomenological models. Now at RHIC as well as at the Large Hadron Collider (LHC) high-energy heavy-ion collisions are carried out. The strong collective dynamics observed in experimental data at RHIC and the LHC provides us with a clue of understanding the QCD matter. A relativistic hydrodynamic model is suitable for description of space-time evolution of strongly interacting QCD matter produced after collisions. Besides, it has a close relation to an equation of state and transport coefficients of the QGP. The QCD phase transition mechanism and the QGP bulk property is elucidated from comparison between hydrodynamic calculation and experimental data.

A relativistic viscous hydrodynamic model plays an important role in the quantitative understanding of the QGP bulk property. However, introducing viscosity effect into the framework of relativistic hydrodynamics is not an easy task, because of the acausality problem. There is not the unique way to extract the second-order relativistic viscous hydrodynamic equation. In high-energy heavy-ion collisions, currently the Israel–Stewart theory [2, 3] and conformal hydrodynamics [4] are often used. Solving them numerically, study of experimental data of high-energy heavy-ion collisions is performed [5,6,7,8,9,10,11,12,13,14].

Now the relativistic viscous hydrodynamic model can explain not only the elliptic flow but also higher harmonics [15]. In particular, analyses of the higher harmonics bring us progress of understanding of the QGP, because it is more sensitive to the QGP bulk property. Furthermore, a lot of experimental data are reported; correlation between flow harmonics [16, 17], event plane correlation [18, 19], non-linearity of higher flow harmonics [20] and three particle correlation [21, 22]. At the same time, we can investigate the QGP property further using information of (3+1)-dimensional space-time evolutions [19, 21, 22]. The rich experimental data realizes investigation of both shear and bulk viscosities and even their temperature dependence.

We need to perform numerical calculations for relativistic viscous hydrodynamics with high accuracy, to achieve the quantitative analyses of the transport coefficients of the QGP from comparison with high statistics and high precision experimental data. For example, the following features in numerical calculations are demanded: A fluctuating initial condition is correctly captured and numerical viscosity which is needed for stability of calculation is much smaller than physical viscosity. Furthermore, time evolution of the viscous stress tensor is sensitive to numerical scheme, because it consists of time and space derivatives of hydrodynamic variables.

Here we present a new relativistic viscous hydrodynamics code optimized in the Milne coordinates. The code is developed based on our algorithm of the ideal fluid in which a Riemann solver with the two-shock approximation [23] is employed [24]. It is stable even with small numerical viscosity [25]. We shall show comparison between numerical calculations and analytic solutions of viscous Bjorken’s flow and the Israel–Stewart theory in Gubser flow regime.

Using the code, we shall discuss possible development of Kelvin–Helmholtz (KH) instability in high-energy heavy-ion collisions. Hydrodynamic instability and turbulent flow are discussed in Refs. [26, 27] and the possibility of KH instability is argued in Ref. [28]. The hydrodynamic instability is affected by a viscosity effect, which suggests that the numerical code with less numerical viscosity is indispensable for study of it.

This paper is organized as follows. We begin in Sect. 2 by showing the relativistic viscous hydrodynamic equations briefly. In Sect. 3 we explain the numerical algorithm; Strang splitting method and numerical implementation. We check the validity of our code comparing analytic solutions of viscous Bjorken flow and the Israel–Stewart theory in the Gubser flow regime in Sect. 4. In Sect. 5, we discuss the possible development of KH instability in high-energy heavy-ion collisions. We end in Sect. 6 with our conclusions.

2 Relativistic viscous hydrodynamic equations

The relativistic hydrodynamics is based on the conservation equations,

$$\begin{aligned}&N^\mu _{\; ;\mu } = 0 , \end{aligned}$$
(1)
$$\begin{aligned}&T^{\mu \nu }_{\;\;\; ;\mu } =0, \end{aligned}$$
(2)

where \(N^\mu \) is the net charge current and \(T^{\mu \nu }\) is the energy-momentum tensor. In the case of ideal fluid, the net charge current and energy-momentum tensor are given by

$$\begin{aligned}&N^\mu = n u^\mu , \end{aligned}$$
(3)
$$\begin{aligned}&T^{\mu \nu } = e u^\mu u^\nu - p \Delta ^{\mu \nu } , \end{aligned}$$
(4)

where n is the net charge density, e is the energy density, p is the pressure and \(u^\mu \) is the fluid four-velocity which satisfies the normalization \(u^\mu u_\mu = 1\). \(\Delta ^{\mu \nu }\) is the orthogonal projection tensor to \(u^\mu \), which is defined by

$$\begin{aligned} \Delta ^{\mu \nu } = g^{\mu \nu } - u^\mu u^\nu , \end{aligned}$$
(5)

with the metric tensor \(g^{\mu \nu }\). Here the \(u^\mu \) is determined uniquely.

On the other hand, in dissipative flow, there are several possible choices to determine \(u^\mu \). For example, one can assign the \(u^\mu \) as net charge flow (Eckart frame [29]) or as energy flow (Landau frame [30]). The decomposition of \(N^\mu \) and \(T^{\mu \nu }\) in viscous fluid depends on the choice of \(u^\mu \). Here we choose the Landau frame for relativistic viscous hydrodynamic equations, because we focus on the high-energy heavy-ion collisions as RHIC and the LHC where the net baryon number is very small [31].

In the Landau frame, the net charge current and the energy-momentum tensor of the viscous fluid are decomposed as

$$\begin{aligned}&N^\mu = n u^\mu + n^\mu , \end{aligned}$$
(6)
$$\begin{aligned}&T^{\mu \nu } = eu^\mu u^\nu - (p+ \Pi ) \Delta ^{\mu \nu } + \pi ^{\mu \nu }, \end{aligned}$$
(7)

where \(n^\mu \) is the charge diffusion current, \(\Pi \) is the bulk pressure, and \(\pi ^{\mu \nu }\) is the shear tensor [30]. The relativistic extension of Navier–Stokes theory in non-relativistic fluid usually has a problem of acausality and instability [32,33,34]. The problem can be resolved by introducing the second-order terms of the viscous tensor and the derivative of fluid variables into the hydrodynamic equations [2, 3]. However, the original Israel–Stewart theory does not reproduce the results of the kinetic equation quantitatively [35,36,37,38,39]. The construction of second-order relativistic viscous hydrodynamic equations is still under investigation. The extension of the Israel–Stewart theory is also proposed [40,41,42,43,44,45]. In addition to the framework of the Israel–Stewart theory, other approaches such as the AdS/CFT correspondence [4, 46,47,48] and renormalization group method are applied to the construction of causal relativistic hydrodynamics [49, 50].

In the second-order viscous hydrodynamics, additional equations for evolution of the viscous tensors are needed. Here, we introduce the convective time derivative D and the spatial gradient operator \(\nabla ^\mu \), which are defined by

$$\begin{aligned}&DA^{\mu _1 \cdots \mu _n} \equiv u^\beta A^{\mu _1\cdots \mu _n}_{; \beta } , \end{aligned}$$
(8)
$$\begin{aligned}&\nabla _\alpha A^{\mu _1 \cdots \mu _n} \equiv \Delta ^\beta _\alpha A^{\mu _1\cdots \mu _n}_{; \beta }, \end{aligned}$$
(9)

respectively. For example, in the second-order Israel–Stewart formalism the constitutive equations of the viscous tensors are given by

$$\begin{aligned}&\Delta ^{\mu }_{\;\;\alpha } D n^\alpha = -\frac{1}{\tau _n} (n^\mu - n^\mu _\mathrm{NS}) - I_n^\mu , \end{aligned}$$
(10)
$$\begin{aligned}&\Delta ^\mu _{\;\;\alpha }\Delta ^\nu _{\;\;\beta }D\pi ^{\alpha \beta } = -\frac{1}{\tau _\pi } (\pi ^{\mu \nu } - \pi ^{\mu \nu }_\mathrm{NS}) - I^{\mu \nu }_{\pi }, \end{aligned}$$
(11)
$$\begin{aligned}&D\Pi = -\frac{1}{\tau _\Pi } (\Pi - \Pi _\mathrm{NS}) - I_\Pi , \end{aligned}$$
(12)

where \(\tau _n, \tau _\pi \), and \(\tau _\Pi \) are relaxation times, \(I^\mu _n, I^{\mu \nu }_\pi ,\) and \(I_\Pi \) represent second-order terms. \(n^\mu _\mathrm{NS}, \pi ^{\mu \nu }_\mathrm{NS}\), and \(\Pi _\mathrm{NS}\) are the Navier–Stokes value of viscous tensors written as

$$\begin{aligned}&n_\mathrm{NS}^\mu = \sigma T\nabla _\mu \left( \frac{\mu }{T}\right) , \end{aligned}$$
(13)
$$\begin{aligned}&\pi ^{\mu \nu }_\mathrm{NS} = \eta \left( \nabla ^\mu u^\nu + \nabla ^\nu u^\mu - \frac{2}{3}\Delta ^{\mu \nu }\theta \right) , \end{aligned}$$
(14)
$$\begin{aligned}&\Pi _{NS} =-\zeta \theta , \end{aligned}$$
(15)

where T is the temperature, \(\mu \) is the chemical potential, \(\theta \equiv u^\mu _{;\mu }\) is the expansion scalar, \( \sigma \) is the charge conductivity, \(\eta \) is the shear viscosity, and \(\Pi \) is the bulk viscosity.

We construct a relativistic viscous hydrodynamics code in the Milne coordinates \((\tau ,x,y,\eta )\), which is optimized for description of the strong longitudinal expansion [51] at RHIC and the LHC. In the Milne coordinates, the metric tensor is given by \(g^{\mu \nu }=\mathrm{diag}(1, -1,-1,-1/\tau ^2)\) and the fluid four-velocity has the form \(u^\mu = \gamma (1, v^x, v^y,v^\eta )\), where \(v^i (i=x,y,\eta )\) and \(\gamma = (1- {v^x}^2 - {v^y}^2 - \tau ^2 {v^\eta }^2)^{-1/2}\) are the three-velocity and the Lorentz factor, respectively. The conservation equations Eqs. (1) and (2) are explicitly written as

$$\begin{aligned}&\partial _\tau N^\tau + \partial _i N^i = -\frac{1}{\tau } N^\tau , \end{aligned}$$
(16)
$$\begin{aligned}&\partial _\tau T^{\tau \nu } + \partial _i T^{i\nu } = S^\nu , \end{aligned}$$
(17)

where \(i=x,y, \eta \) and the right-hand sides of them represent geometric source terms. \(S^\nu \) is given by

$$\begin{aligned} S^\nu =\left( -\frac{1}{\tau }T^{\tau \tau } -\tau T^{\eta \eta }, - \frac{1 }{\tau }T^{\tau x}, - \frac{1}{\tau }T^{\tau y}, -\frac{3}{\tau }T^{\tau \eta } \right) . \end{aligned}$$
(18)

The constitutive equations Eqs. (10), (11), and (12) in Milne coordinates read

$$\begin{aligned}&(\partial _\tau + v^i\partial _i)n^\mu = -\frac{1}{\gamma \tau _n} (n^\mu - n^\mu _\mathrm{NS}) - I_n^\mu - J^\mu _n - K^\mu _n , \end{aligned}$$
(19)
$$\begin{aligned}&(\partial _\tau + v^i\partial _i)\pi ^{\mu \nu } = - \frac{1}{\gamma \tau _{\eta }} (\pi ^{\mu \nu } - \pi ^{\mu \nu }_{NS}) - I^{\mu \nu }_{\pi } -J^{\mu \nu }_\pi - K^{\mu \nu }_\pi , \end{aligned}$$
(20)
$$\begin{aligned}&(\partial _\tau + v^i\partial _i)\Pi = -\frac{1}{\gamma \tau _\Pi } (\Pi - \Pi _\mathrm{NS}) - I_\Pi , \end{aligned}$$
(21)

where \(\tau _n\), \(\tau _\eta \) and \(\tau _\Pi \) are the relaxation times, and the second-order terms are defined by

$$\begin{aligned}&J_n^\tau = \tau v^\eta n^\eta ,\quad J_n^j = 0, \end{aligned}$$
(22)
$$\begin{aligned}&J_n^\eta = \frac{1}{\tau }v^\eta n^\tau + \frac{1}{\tau } n^\eta , \end{aligned}$$
(23)
$$\begin{aligned}&J^{\tau \tau }_\pi = 2\tau v^\eta \pi ^{\tau \eta } , \quad J^{\tau j}_\pi = \tau v^\eta \pi ^{j \eta }, \end{aligned}$$
(24)
$$\begin{aligned}&J_\pi ^{xx} = J^{yy}_\pi = J^{xy}_\pi = 0, \end{aligned}$$
(25)
$$\begin{aligned}&J_\pi ^{i\eta } = \frac{1}{\tau }\pi ^{i\eta } + \frac{1}{\tau } v^\eta \pi ^{i\tau } , \end{aligned}$$
(26)
$$\begin{aligned}&J_\pi ^{\eta \eta } = \frac{2}{\tau }v^\eta \pi ^{\tau \eta } + \frac{2}{\tau } \pi ^{\eta \eta }, \end{aligned}$$
(27)
$$\begin{aligned}&K^{\mu }_n = n^\lambda v^\mu Du_\lambda , \end{aligned}$$
(28)
$$\begin{aligned}&K^{\mu \nu }_\pi = (\pi ^{\lambda \mu } v^\nu + \pi ^{\lambda \nu }v^\mu )Du_\lambda , \end{aligned}$$
(29)

\(j = x, y\) and \(\lambda = \tau ,x,y,\eta \). Here, \(J^\tau _n\) and \(J^{\mu \nu }_\pi \) are the geometric source terms which come from the convective time derivative of \(n^\mu \) and \(\pi ^{\mu \nu }\) respectively. \(K^\mu _n\) and \(K^{\mu \nu }_\pi \) ensures the constraints \(n^\mu u_\mu =0, \pi ^{\mu \nu }u_\mu =0\) and \(\pi ^\mu _\mu =0\).

3 Numerical algorithm

In this section, we present our numerical algorithm for solving the relativistic viscous hydrodynamic equations in the Milne coordinates.

3.1 Strang splitting method

In our algorithm, we split the conservation equations Eqs. (16) and (17) into two parts, an ideal part and a viscous part using the Strang splitting method [52]. Specifically, the net charge current and the energy-momentum tensor are divided as follows: \(N^\mu = N^\mu _\mathrm{id} + N^\mu _\mathrm{vis}\) and \(T^{\mu \nu } = T^{\mu \nu }_\mathrm{id} + T^{\mu \nu }_\mathrm{vis}\), where \(N^\mu _\mathrm{id} \equiv n u^\mu , N^\mu _\mathrm{vis}\equiv n^\mu \), \(T^{\mu \nu }_\mathrm{id} \equiv eu^\mu u^\nu - p \Delta ^{\mu \nu }\) and \(T^{\mu \nu }_\mathrm{vis} \equiv \pi ^{\mu \nu } - \Pi \Delta ^{\mu \nu }\). The subscripts “id” and “vis” mean the ideal part and the viscous part, respectively. The equations of the ideal part are expressed by

$$\begin{aligned}&\partial _\tau N^\tau _\mathrm{id} + \partial _i N^i_\mathrm{id} = -\frac{1}{\tau } N^\tau _\mathrm{id}, \end{aligned}$$
(30)
$$\begin{aligned}&\partial _\tau T^{\tau \nu }_\mathrm{id} + \partial _i T^{i\nu }_\mathrm{id} = S^\nu _\mathrm{id}, \end{aligned}$$
(31)

where \(S^\nu _\mathrm{id} =\left( -T^{\tau \tau }_\mathrm{id}/\tau -\tau T^{\eta \eta }_\mathrm{id} , - T^{\tau x}_\mathrm{id}/\tau , - T^{\tau y}_\mathrm{id}/\tau , -3T^{\tau \eta }_\mathrm{id}/\tau \right) \). They are nothing but the usual ideal hydrodynamic equations in the Milne coordinates. On the other hand, the equations of the viscous part are given by

$$\begin{aligned}&\partial _\tau (N^\tau _\mathrm{id}+N^\tau _\mathrm{vis} )+ \partial _i N^i_\mathrm{vis} = -\frac{1}{\tau } N^\tau _\mathrm{vis} , \end{aligned}$$
(32)
$$\begin{aligned}&\partial _\tau (T^{\tau \nu }_\mathrm{id} + T^{\tau \nu }_\mathrm{vis}) + \partial _i T^{i\nu }_\mathrm{vis} = S^\nu _\mathrm{vis} , \end{aligned}$$
(33)

where \(S^\nu _\mathrm{vis} =\left( -T^{\tau \tau }_\mathrm{vis}/\tau - \tau T^{\eta \eta }_\mathrm{vis} , - T^{\tau x}_\mathrm{vis}/\tau , - T^{\tau y}_\mathrm{vis}/\tau , -3T^{\tau \eta }_\mathrm{vis}/\tau \right) \). They give viscous corrections to the evolution of the ideal fluid.

The Strang splitting technique is also applied to evaluate the constitutive equations of the viscous tensors Eqs. (19)–(21). We decompose the constitutive equations into the following three parts: the convection equations,

$$\begin{aligned}&(\partial _\tau + v^i\partial _i)n^\mu = 0 , \end{aligned}$$
(34)
$$\begin{aligned}&(\partial _\tau + v^i\partial _i)\pi ^{\mu \nu } =0 , \end{aligned}$$
(35)
$$\begin{aligned}&(\partial _\tau + v^i\partial _i)\Pi = 0, \end{aligned}$$
(36)

the relaxation equations,

$$\begin{aligned}&\partial _\tau n^\mu = -\frac{1}{\gamma \tau _n} (n^\mu - n^\mu _\mathrm{NS}) , \end{aligned}$$
(37)
$$\begin{aligned}&\partial _\tau \pi ^{\mu \nu } = - \frac{1}{\gamma \tau _{\eta }} (\pi ^{\mu \nu } - \pi ^{\mu \nu }_{NS}) , \end{aligned}$$
(38)
$$\begin{aligned}&\partial _\tau \Pi = -\frac{1}{\gamma \tau _\Pi } (\Pi - \Pi _\mathrm{NS}), \end{aligned}$$
(39)

and the equations with source terms,

$$\begin{aligned}&\partial _\tau n^\mu = - I_n^\mu - J^\mu _n - K^\mu _n , \end{aligned}$$
(40)
$$\begin{aligned}&\partial _\tau \pi ^{\mu \nu } = - I^{\mu \nu }_{\pi } -J^{\mu \nu }_\pi - K^{\mu \nu }_\pi , \end{aligned}$$
(41)
$$\begin{aligned}&\partial _\tau \Pi = - I_\Pi . \end{aligned}$$
(42)

In numerical simulation of relativistic hydrodynamic equation, a time-step size \(\Delta \tau \) is usually determined by the Courant–Friedrichs–Lewy (CFL) condition. However, in the relativistic dissipative hydrodynamics, one needs to determine the value of \(\Delta \tau \) carefully. The relaxation times \(\tau _n, \tau _\eta \), and \(\tau _\Pi \) in the constitutive equations show the characteristic timescale of the evolutions of the viscous tensors, which means that a small relaxation time gives us a more restrictive condition to \(\Delta \tau \) than the CFL condition does. If the relaxation times \(\tau _n, \tau _\eta \), and \(\tau _\Pi \) are much shorter than the fluid timescale \(\tau _\mathrm{fluid}\), the time-step size \(\Delta \tau \) should be smaller than the relaxation timescale, which makes the computational cost increase. To avoid this problem, we use the Piecewise Exact Solution (PES) method [53], instead of using a simple explicit scheme. In the PES method, formal solutions of Eqs. (37)–(39),

$$\begin{aligned}&n^\mu (\tau ) = (n^\mu _0 - n^\mu _\mathrm{NS})\mathrm{exp} \left[ - \frac{\tau - \tau _0}{\gamma \tau _n}\right] + n^\mu _\mathrm{NS} , \end{aligned}$$
(43)
$$\begin{aligned}&\pi ^{\mu \nu }(\tau ) = (\pi ^{\mu \nu }_0 - \pi ^{\mu \nu }_\mathrm{NS})\mathrm{exp} \left[ - \frac{\tau - \tau _0}{\gamma \tau _\pi }\right] + \pi ^{\mu \nu }_\mathrm{NS} ,\end{aligned}$$
(44)
$$\begin{aligned}&\Pi (\tau ) = (\Pi _0 - \Pi _\mathrm{NS})\mathrm{exp} \left[ - \frac{\tau - \tau _0}{\gamma \tau _\Pi }\right] +\Pi _\mathrm{NS}, \end{aligned}$$
(45)

can be used. On the other hands, if the relaxation times are larger than \(\Delta \tau \) determined by the CFL condition, the PES method is not applied [12].

In our algorithm, we solve the time evolution of \(n^x, n^y, n^\eta , \pi ^{xx}, \pi ^{yy}, \pi ^{\eta \eta },\pi ^{xy},\pi ^{y\eta }, \pi ^{\eta x}\) and \(\Pi \) directly. Other components of viscous tensors \(n^\tau , \pi ^{\tau \tau }, \pi ^{\tau x}, \pi ^{\tau y}\) and \(\pi ^{\tau \eta }\) are derived from the orthogonality conditions \(n^\mu u_\mu =0\) and \(\pi ^{\mu \nu } u_{\nu }=0\).

3.2 Numerical implementation

The decomposed hydrodynamic equations Eqs. (30)–(42) are solved by the following procedure. Here, we represent a conserved variable as \({\varvec{U}} = {\varvec{U}}_\mathrm{id} + {\varvec{U}}_\mathrm{vis}\), where \({\varvec{U}}_\mathrm{id}\equiv (N^\tau _\mathrm{id}, T^{\tau \nu }_\mathrm{id})\) and \({\varvec{U}}_\mathrm{vis} \equiv (N^\tau _\mathrm{vis}, T^{\tau \nu }_\mathrm{vis})(\nu =\tau ,x,y,\eta )\). Fluid and dissipative variables are described by \({\varvec{V}}_\mathrm{id}\equiv (n, p,v^i)\) and \({\varvec{V}}_\mathrm{vis}\equiv (n^i, \pi ^{ij}, \Pi ) (i,j=x,y,\eta )\), respectively.

First, we solve the ideal part of the conservation equations Eqs. (30) and (31) using the Riemann solver [24]. In this step, the conserved variable \({\varvec{U}}_\mathrm{id}(\tau )\) is evolved into \({\varvec{U}}_\mathrm{id}^*(\tau +\Delta \tau )\), where the asterisk indicates a variable evolved only in the ideal part. \({\varvec{V}}_\mathrm{id}(\tau )\) is used to evaluate the numerical flux and the geometric source terms in Eqs. (30) and (31). We calculate the fluid variable \({\varvec{V}}_\mathrm{id}^*(\tau +\Delta \tau )\) from \({\varvec{U}}^*_\mathrm{id}(\tau +\Delta \tau )\) with the algorithm for recovery of the primitive variables \({\varvec{V}}_\mathrm{id}\) from the conserved variables \({\varvec{U}}_\mathrm{id}\) [25].

Second, we solve the constitutive equations of the viscous tensors Eqs. (34)–(42) to obtain \({\varvec{V}}_\mathrm{vis}(\tau +\Delta \tau )\). The convection equations Eqs. (34)–(36), the relaxation equations Eqs. (37)–(39) and Eqs. (40)–(42) are solved by the upwind scheme, the PES method and the predictor corrector method, respectively. The Navier–Stokes terms \(n^\mu _\mathrm{NS}, \pi ^{\mu \nu }_\mathrm{NS}, \Pi _\mathrm{NS}\) and the second-order terms I, K in the right-hand sides of Eqs. (37)–(42) contain not only the spatial derivatives of fluid variables but also the time derivatives of them. The time derivatives in the right-hand sides of Eqs. (37)–(42) are obtained by \(\partial _\tau {\varvec{V}}_\mathrm{id} = ({\varvec{V}}^*_\mathrm{id}(\tau +\Delta \tau ) - {\varvec{V}}_\mathrm{id}(\tau ) )/ \Delta \tau .\) Here we keep the middle time-step value of the viscous tensor \({\varvec{V}}_\mathrm{vis}(\tau +\Delta \tau /2)\) for the next step.

Next, the conserved variables \({\varvec{U}}^*_\mathrm{id}(\tau +\Delta \tau )\) and \({\varvec{U}}_\mathrm{vis}(\tau )\) are evolved into \({\varvec{U}}_\mathrm{id}(\tau +\Delta \tau )\) and \({\varvec{U}}_\mathrm{vis}(\tau +\Delta \tau )\) by the viscous part of conservation equations Eqs. (32) and (33). Then we recover the fluid variables \({\varvec{V}}_\mathrm{id}(\tau + \Delta \tau )\) from conserved variables \({\varvec{U}}_\mathrm{vis}(\tau +\Delta \tau )\) [53]. We keep the middle time-step value \({\varvec{V}}_\mathrm{id}(\tau +\Delta /2)\).

To achieve the second-order accurate in time, we repeat the above whole steps using the middle time-step values \({\varvec{V}}_\mathrm{id}(\tau +\Delta \tau /2)\) and \({\varvec{V}}_\mathrm{vis}(\tau +\Delta \tau /2)\). However, we find that numerical errors arise mainly from the constitutive equations Eqs. (34)–(42). Therefore we carry out numerical calculation in the second-order accurate in time only in constitutive equations Eqs. (34)–(42) and the viscous part of the conservation equations Eqs. (32) and (33).

Throughout all above steps, we evaluate space derivative terms using the MC limiter [54] for the second-order accurate in space or the piecewise parabolic method (PPM) [55,56,57] for the third-order accurate in space. We shall give the explicit expressions of the interpolation procedures, the MC limiter and the PPM in Appendix A.

4 Numerical tests

We check the correctness of our code in the following test problems; the viscous Bjorken flow for one-dimensional expansion and the Israel–Stewart theory in the Gubser flow regime [58] for the three-dimensional calculation. We use the ideal massless gas equation of state, \(p=e/3\) and set the net charge to be vanishing.

4.1 Viscous Bjorken flow

The Bjorken flow is one of the simplest one-dimensional test problems for the code which is optimized in the Milne coordinates. In the ideal fluid, the time evolution of temperature follows \(T=T_0(\tau _0/\tau )^{1/3}\), where \(\tau _0\) and \(T_0\) are the initial proper time and temperature, respectively [51]. In the viscous fluid, the non-vanishing components of viscous tensor \(\pi ^{\mu \nu }\) are \(\pi ^{xx}\), \(\pi ^{yy}\), and \(\pi ^{\eta \eta }\). From the symmetries of the system, the relation \(2\pi ^{xx}=2\pi ^{yy} = - \tau ^2 \pi ^{\eta \eta }\) holds. First, we focus on the shear viscosity effects at the Navier–Stokes limit. In the Navier–Stokes limit, the relativistic viscous hydrodynamic equation with the boost invariance is written as

$$\begin{aligned} \frac{\partial e}{\partial \tau } = - \frac{e+p+\tau ^2\pi ^{\eta \eta }_\mathrm{NS}}{\tau }, \end{aligned}$$
(46)

where \(\pi ^{\eta \eta }_\mathrm{NS}\) is the Navier–Stokes value of shear tensor,

$$\begin{aligned} \pi ^{\eta \eta }_\mathrm{NS} = -\frac{4\eta }{3\tau ^3}. \end{aligned}$$
(47)

If \(\eta /s\) is constant, Eqs. (46) and (47) give the time evolution of the temperature,

$$\begin{aligned} T = \left( \frac{\tau _0}{\tau } \right) ^{1/3} \left[ T_0 + \frac{2}{3\tau _0}\frac{\eta }{s} \left( 1 - \left( \frac{\tau _0}{\tau }\right) ^{2/3} \right) \right] . \end{aligned}$$
(48)

The numerical calculation is carried out on the space-grid size \(\Delta \eta = 0.1\) with the time-step size \(\Delta \tau = 0.1 \tau _0\Delta \eta \). The initial temperature \(T_0\) and the proper time \(\tau _0\) are set to \(T_0=300\) MeV and \(\tau _0 = 1\) fm, respectively. We set the relaxation time to be \(\tau _\eta = 0.0001\) fm as the Navier–Stokes limit. Since \(\tau _\eta \) is smaller than \(\Delta \tau \), the PES method is applied to solve the relaxation equations Eqs. (37)–(39). Figure 1 shows the analytical and numerical results of the Bjorken flow with and without shear viscosity. In the case of finite shear viscosity, the temperature decreases with proper time more slowly, compared to that of the ideal fluid. In both cases, our numerical results show good agreement with the analytical solutions.

Fig. 1
figure 1

The numerical and analytical results of the time evolution of the temperature in the Bjorken flow with and without shear viscosity. The viscosity to entropy density ratio is \(\eta /s=0\) and 0.2

Fig. 2
figure 2

The numerical and analytical results of the time evolution of the Bulk pressure in the Bjorken flow. The bulk viscosity is \(\zeta =1000\) MeV/fm\(^2\)

Next, we check the time evolution of the bulk pressure in the viscous Bjorken’s flow. Ignoring the second-order terms \(I_\Pi \) in Eq. (21), we write the relaxation equation of the bulk pressure,

$$\begin{aligned} \frac{\partial \Pi }{\partial \tau } = -\frac{1}{\tau _\Pi } \left( \Pi - \Pi _\mathrm{NS}\right) , \end{aligned}$$
(49)

with the Navier–Stokes value of the bulk pressure \(\Pi _\mathrm{NS} = \zeta /\tau \). If we assume \(\zeta \) and \(\tau _\Pi \) are constant, we obtain the analytical solution of Eq. (49),

$$\begin{aligned} \Pi = \Pi _0 e^{-(\tau - \tau _0)/\tau _\Pi } + \frac{\zeta }{\tau _\Pi } e^{-\tau /\tau _\Pi } \left[ \mathrm{Ei}(\tau _0/\tau _\Pi ) - \mathrm{Ei}(\tau /\tau _\Pi )\right] , \end{aligned}$$
(50)

where \(\Pi _0\) is the initial value of the bulk pressure and \(\mathrm{Ei}(x)\) is the exponential integral function.

Fig. 3
figure 3

Comparison between the solutions for temperature T (left panel) and the x component of fluid velocity \(v^x\) (right panel) from the Gubser flow and our numerical calculation as a function of x. The solid lines stand for the semi-analytic solutions and the pluses stand for numerical results

In the numerical calculation, we set \(\Pi _0=0\), \(\zeta =1000\) MeV/fm\(^2\), \(\tau _0 = 1\) fm, and \(\tau _\Pi =1\) fm. The space-grid size \(\Delta \eta = 0.1\) and the time-step size \(\Delta \tau = 0.1 \tau _0\Delta \eta \) are utilized. Figure 2 shows the analytical and numerical results of the time evolution of the bulk pressure in the Bjorken flow. Our numerical calculation is consistent with the analytical solution.

4.2 Israel–Stewart theory in the Gubser flow regime

Based on the symmetry arguments developed by Gubser [59, 60], a semi-analytic solution of the Israel–Stewart theory in the Gubser flow regime is obtained [58]. The semi-analytic solution is a useful test problem for the code of relativistic viscous hydrodynamics which is developed for application to the high-energy heavy-ion collisions [13, 14, 58, 61, 62]. The velocity profile of the semi-analytic solution is the same as that of the ideal Gubser flow,

$$\begin{aligned} v^\bot =\frac{u^\bot }{u^\tau }=\frac{2q^2\tau x_\bot }{1+q^2\tau ^2+q^2x_\bot ^2} , \end{aligned}$$
(51)

where q is an arbitrary dimensional constant with unit of inverse length of the system size and set to \(q=1\) in comparison with numerical computation. The solutions of the temperature and the shear tensors are derived by solving a set of two ordinary differential equations numerically [58]. The second-order terms and the relaxation time in Eq. (20) are given by

$$\begin{aligned}&I^{\mu \nu }_\pi = \frac{4}{3} \pi ^{\mu \nu } \theta , \end{aligned}$$
(52)
$$\begin{aligned}&\tau _\eta = c \frac{\eta }{Ts}, \end{aligned}$$
(53)

where c is a constant [58].

We carry out the numerical calculation with the finite shear viscosity \(\eta /s = 0.2\). We set the relaxation time to \(\tau _\eta =5\eta /(Ts)\). The numerical simulation starts at \(\tau _0=1\) fm. The time-step size and the space-grid size in numerical simulation are set to \(\Delta \tau = 0.1\Delta x\) and \((\Delta x, \Delta y, \Delta \eta )=(0.05 \mathrm{ fm}, 0.05 \mathrm{fm}, 0.1)\), respectively.

Fig. 4
figure 4

Comparison between the solutions for shear tensors \(\pi ^{xx}\) (top left), \(\pi ^{yy}\) (top right), \(\tau ^2\pi ^{\eta \eta }\) (bottom left) and \(\pi ^{xy}\) (bottom right) from the Gubser flow and our numerical calculation as a function of x. The solid lines stand for the semi-analytic solutions and the pluses stand for numerical results

Figure 3 shows the numerical results and the semi-analytic solutions of temperature and x component of fluid velocity as a function of x at \(\tau =1.2\), 2 and 3 fm. The numerical results are consistent with the semi-analytic solutions. In our previous test calculation of the ideal Gubser flow the temperature and the fluid velocity follow the analytic solution until \(\tau =7\) fm [24]. On the other hand, in the finite viscosity calculation the difference between the numerical calculation and the semi-analytic solution appears after \(\tau =4\) fm.

In Fig. 4 the numerical results of the shear tensors \(\pi ^{xx}\), \(\pi ^{yy}\), \(\pi ^{\eta \eta }\) and \(\pi ^{xy}\) at \(\tau =1.2\), 2 and 3 fm are presented together with the semi-analytic solutions. Here the profile of \(\pi ^{xy}\) is shown along a line \(x=y\), since the value of \(\pi ^{xy}\) vanishes on the x and y axes. The shear tensors \(\pi ^{xx}\), \(\pi ^{yy}\) and \(\pi ^{\eta \eta }\) in our numerical calculations show good agreement with the semi-analytic solutions. However, in \(\pi ^{xy}\) the deviation from the semi-analytic solution starts to appear at \(\tau =2\) fm and grows at later time.

Fig. 5
figure 5

Numerical results of shear tensors \(\pi ^{xx}\), \(\pi ^{yy}\), \(\tau ^2\pi ^{\eta \eta }\) and \(\pi ^{xy}\) at \(\tau =3\) fm as a function of x, together with the semi-analytic solution (solid line). The solid circles, crosses and pluses denote the solutions obtained with the MC limiter, the CTU and the PPM method, respectively

Since in the Israel–Stewart theory the second-order terms in \(\pi ^{\mu \nu }\) become small compared with the first-order terms, choice of numerical scheme for evaluation of the convection term in Eq. (35) is important. For example, in Ref. [58], they show that adjustment of the flux limiter which controls possible artificial oscillation in a higher order discretization scheme is crucial for good agreement with the semi-analytic solution. Here we employ the PPM for solving the convection part numerically, instead of the MC limiter. In the case of three-dimensional calculation we use the dimensional splitting method [24]. We find that the Corner Transport Upwind (CTU) scheme [63], which is a three-dimensional unsplit method, realizes good agreement of the semi-analytic solution even with the MC limiter.

We discuss the numerical scheme dependence on the shear tensors in solving the convection term in Eq. (35). We compare the three numerical schemes; a dimensional splitting method with the MC limiter, a dimensional splitting method with the PPM and the CTU method [63] with the MC limiter for three-dimensional unsplit method. We shall explain the details of each scheme in Appendices A and B. Figure 5 shows the semi-analytic solutions and numerical results of the shear tensors \(\pi ^{xx}\), \(\pi ^{yy}\), \(\tau ^2\pi ^{\eta \eta }\) and \(\pi ^{xy}\) at \(\tau =3\) fm. In \(\pi ^{xx}\), \(\pi ^{yy}\) and \(\tau ^2\pi ^{\eta \eta }\), the results of all numerical schemes are reasonably consistent with the semi-analytic solutions. In addition, differences among them are small. However, in \(\pi ^{xy}\) we can clearly see the scheme difference. In the solution obtained with the MC limiter, the large deviation from the semi-analytic solution at the peak around \(x=2\) fm appears, whereas the PPM and the CTU methods keep the good agreement with the semi-analytic solution. The CTU method can achieve the high numerical accuracy with the second-order accurate in space, but it needs the more computer memory than the dimensional splitting method with the PPM does. Therefore we employ the dimensional splitting method with the PPM for solving the convection term.

5 Kelvin–Helmholtz instability in Bjorken expansion

We discuss the possible development of the KH instability in relativistic heavy-ion collisions. The KH instability is one of the hydrodynamic instabilities. It occurs on the interface between two horizontal streams which have different velocities [64]. If it takes place, perturbations to the interface between fluids grow and result in vortex formation. In heavy-ion collisions, the color-flux tube structure in initial condition can be the origin of the KH instability; fluctuations in the longitudinal direction are amplified with the KH instability, however, vortex formation is not observed [28]. Recently initial fluctuations and QGP expansion not only in the transverse direction but also in the longitudinal direction have attracted interest [19, 21, 22]. Using the new relativistic viscous hydrodynamics code which has small numerical viscosity, we investigate the KH instability and vortex formation in heavy-ion collisions.

For simplicity, we focus on hydrodynamic expansion in the \((x,\eta )\) plane. The heavy ion accelerated with high-energy still has about 1 fm width in the longitudinal direction (z direction) due to the uncertainty principle. In other words, a thin disk composed of large-x partons is covered by a cloud of small-x partons. As a result, in the high-energy heavy-ion collisions parton–parton interactions may take place in the area within around 1 fm from \(z=0\) fm. Then if we consider the color-flux tube structure in the initial condition, each color-flux tube may evolve from a different interaction point in \(|z| < 1\) fm.

Suppose that two initial flow fluxes are located in \(x>0\) and \(x<0\) which represent two color-flux tubes starting to expand at \(z=\Delta z\) and \(z=-\Delta z\), respectively. Energy density and \(\eta \) component of velocity of the flow flux are assumed to be described by Bjorken’s scaling solution \(e_B= e_0(\tau _0/\tau )^{4/3}\) and \(v^\eta _B = 0\). Shifting the Bjorken scaling solution to \(\pm \Delta z (=0.3 \) fm) in the z direction, we obtain the energy density \(e_\mathrm{U}\) (\(e_\mathrm{D}\)) and the \(\eta \) component of velocity of the flow flux \(v^\eta _\mathrm{U}\) (\(v^\eta _\mathrm{D}\)) in \(x>0\) (\(x<0\)),

$$\begin{aligned} e_\mathrm{U} (\tau ,\eta )&= e_B(t, z+\Delta z) , \nonumber \\&= e_0 \left( \frac{\tau _0}{ \sqrt{\tau ^2 - 2\tau \mathrm{sinh}\eta \Delta z - \Delta z^2}}\right) ^{4/3}, \end{aligned}$$
(54)
$$\begin{aligned} e_\mathrm{D}(\tau ,\eta )&=e_B(t,z-\Delta z) \nonumber \\&= e_0 \left( \frac{\tau _0}{ \sqrt{\tau ^2 + 2\tau \mathrm{sinh}\eta \Delta z - \Delta z^2}}\right) ^{4/3}, \end{aligned}$$
(55)
$$\begin{aligned} v^\eta _\mathrm{U}(\tau ,\eta )&= v^\eta _B(t, z+\Delta z) = \frac{\Delta z}{\tau ^2} \frac{\mathrm{cosh}\eta }{ 1 - \frac{\Delta z}{\tau }\mathrm{sinh}\eta } ,\end{aligned}$$
(56)
$$\begin{aligned} v^\eta _\mathrm{D} (\tau ,\eta )&= v^\eta _B(t, z-\Delta z) = -\frac{\Delta z}{\tau ^2} \frac{\mathrm{cosh}\eta }{ 1 + \frac{\Delta z}{\tau }\mathrm{sinh}\eta } , \end{aligned}$$
(57)

where \(\tau _0\) and \(e_0\) are the initial time and the energy density, respectively. Figure 6 shows the energy densities \( e_\mathrm{U}\) and \(e_\mathrm{D}\), and the \(\eta \) component of velocity of the flow flux \(v^\eta _\mathrm{U}\) and \(v^\eta _\mathrm{D}\) in \(x>0\) and \(x<0\). The energy density and the \(\eta \) components of velocity of the flow flux are dependent on \(\eta \) in \(x>0\) and \(x<0\), because of the translational transformation of Bjorken’s scaling solution in the z direction. Importantly, one can see that the shear flow is created between the two initial flow fluxes.

Fig. 6
figure 6

The energy density (top panel) and the rapidity component of velocity (bottom panel) of the translated Bjorken flow. The results at \(\tau = \tau _0=1\)fm are shown. The red solid lines indicate the profile of Eqs. (54) and (56). The blue dotted lines indicate the profile of Eqs. (55) and (57)

Furthermore, we put the fluctuation \(x_b= 0.01 \mathrm{sin}(2\pi \eta /\lambda )\) with a wavelength \(\lambda \) along the boundary between the flow fluxes. Finally our initial energy density and flow velocity are written by

$$\begin{aligned} e (\tau _0,x,\eta )&= \frac{e_\mathrm{U}(\tau _0,\eta ) + e_\mathrm{D}(\tau _0,\eta ) }{2} \nonumber \\&\quad + \frac{e_\mathrm{U}(\tau _0,\eta )- e_\mathrm{D}(\tau _0,\eta )}{2}\mathrm{tanh}\left( \frac{x-x_b}{\Delta }\right) , \end{aligned}$$
(58)
$$\begin{aligned} v^\eta (\tau _0,x, \eta )&= \frac{v^\eta _\mathrm{U}(\tau _0,\eta ) + v^\eta _\mathrm{D}(\tau _0,\eta )}{2} \nonumber \\&\quad + \frac{v^\eta _\mathrm{U}(\tau _0,\eta ) - v^\eta _\mathrm{D}(\tau _0,\eta )}{2}\mathrm{tanh}\left( \frac{x-x_b}{\Delta }\right) , \end{aligned}$$
(59)

where the energy density and flow velocity around the boundary are connected from \(e_U\) and \(v^\eta _U\) to \(e_D\) and \(v^\eta _D\) smoothly with the parameter \(\Delta \). Here, we set the wavelength of a fluctuation and the width of boundary between two fluid fluxes to \(\lambda =0.4\) and \(\Delta = 0.02\) fm, respectively. Focusing the hot spots in a fluctuating initial condition at the LHC, we fix the initial energy density (temperature) to \(e_0=741\) GeV/fm\(^3\)(\(T_0=800\) MeV). Figure 7 shows the velocity field and profile of the vorticity \(w^y\) of the initial condition Eqs. (58) and (59). Here the definition of the vorticity \(w^y\),

$$\begin{aligned} w^y = \frac{1}{\tau }\left( \frac{\partial u^x}{\partial \eta } - \tau ^2 \frac{\partial u^\eta }{\partial x}\right) . \end{aligned}$$
(60)

The arrows stand for the velocity field in \((\tau v^\eta , v^x)\).

Fig. 7
figure 7

Initial condition for the shear flow with the Bjorken expansion. The color profile show the distribution of vorticity \(-w^y\). The arrows indicate the three-fluid vector \((\tau v^\eta , v^x)\)

We start the numerical calculation on the grid \((\Delta x, \Delta \eta ) =(0.005 \mathrm{ fm}, 0.00625) \) at \(\tau _0=1\) fm with time-step size \(\Delta \tau =0.2\Delta x\). We use the ideal gas equation of state \(e=3p\).

Fig. 8
figure 8

The evolution of KH instability in Bjorken expansion. The results of ideal fluid calculation at \(\tau = 4\)fm (left) and 7fm (right) are shown. The color profile indicates the distribution of vorticity \(-w^y\). The arrows indicate the three-fluid vector \((\tau v^\eta , v^x)\)

Fig. 9
figure 9

The evolution of KH instability in Bjorken expansion. The results of the viscous fluid calculation with \(\eta /s=0.01\) at \(\tau = 4\)fm (left) and 7fm (right) are shown. The color profile indicates the distribution of vorticity \(-w^y\). The arrows indicate the three-fluid vector \((\tau v^\eta , v^x)\)

First we argue on the KH instability in the ideal fluid. We find a starting vortex formed around the boundary at \(\tau \sim 3\) fm. In Fig. 8 the velocity field and the profile of the vorticity \(w^y\) at \(\tau =\)4 and 7 fm are shown. We observe that the boundary with the two vortexes tilt toward negative x. The initial conditions Eqs. (58) and (59) and Fig. 6 suggest that \(e_U\) is larger than \(e_D\) and \(|v^z|\) in \(x>0\) is larger than that in \(x>0\). The \(e_U\) decreases more slowly than \(e_D\) does due to the time dilation from larger \(|v^z|\). The energy density and the flow differences between \(x>0\) and \(x<0\) cause the flow in the negative x direction. The two vortices expand with time and their sizes grow because of the existence of the Bjorken flow. As a result, the intensity of the vortices becomes small. The larger the difference of velocity in the shear flow is, the faster the growth of instability is. That is why the development of vortex at \(\eta \sim 0.6\) is faster than that at \(\eta \sim 0.2\). The fluctuation with a longer wavelength grows slower in the KH instability than that with a shorter wavelength does. If we set the wavelength \(\lambda \) to \(\lambda >0.5\) in the region \(|\eta |<0.8\), the growth of fluctuation is too slow to form the vortex and the fluctuation is smeared with the Bjorken flow. However, at the forward rapidity, a fluctuation with a long wavelength can survive to form a vortex.

Next we discuss the KH instability with finite viscosity. We employ the same values of the second-order term and the relaxation time in Eq. (20) as those in Sect. 4.2. The shear viscosity is set to \(\eta /s=0.01\). Figure 9 shows the numerical results of KH instability at \(\tau =4\) and 7 fm. In contrast to Fig. 8, we cannot find the clear vortex but small and vague enhancement of vorticity around \(\eta \sim 0.2\) and 0.6. Again we can see that the flow in the negative x direction is produced. The width between two fluid fluxes expands and the fluctuation is washed away before it forms a vortex because of the viscosity effect. The KH instability is not developed. In viscous fluid, a small size vortex compared with the Kolmogorov length scale is smeared by the viscosity and cannot exist. The fluctuation with the wavelength \(\lambda = 0.4\) at \(\tau _0=1\) fm may be smaller than the Kolmogorov length scale. In the mid rapidity, \(|\eta |<0.8\), a fluctuation with long wavelength disappears due to the Bjorken flow and a fluctuation with short wavelength is smeared by the viscosity. However, because at forward rapidity a fluctuation with long wavelength grows faster, there may be a chance that the KH instability occurs. Or if the longitudinal flow is smaller than Bjorken’s flow, a fluctuation with long wavelength survives and can form a vortex. The existence of the KH instability depends on the viscosity and the flow distribution.

6 Summary

In this paper we have developed the new relativistic viscous hydrodynamics code. In the code, we employed the Milne coordinates which are suitable for the initial strong longitudinal expansion at high-energy heavy-ion collisions. After the brief explanation of the relativistic viscous hydrodynamic equations, we showed the numerical algorithm of the code which has the ideal part and the viscous part. For the ideal part we employed the Riemann solver with the two-shock approximation which achieves stable calculation even with the small numerical viscosity [25] and for the viscous part we utilized the PES method [53]. Because we found that the order of accurate in space in the convection part of the viscous part is important, we applied the PPM instead of the MC limiter to the convection part. Next we examined the validity of our code using two test calculations; the viscous Bjorken flow for the one-dimensional test and the Israel–Stewart theory in the Gubser flow regime for the three-dimensional test. In both tests, our numerical calculations showed good agreement with analytical solutions. Besides, we pointed out that in the Gubser flow the shear tensors are sensitive to numerical scheme. Finally, we discussed the possible vortex formation through the KH instability in high-energy heavy-ion collisions. We focused on the mid rapidity and started the numerical calculations with the simple initial conditions inspired by the color-flux tube structure of hot spots in fluctuating initial conditions. In the case of the ideal fluid we found the vortex formation after \(\tau \sim 3\) fm, however, we did not observe the vortex formation in the viscous fluid even with very small viscosity. To obtain a more conclusive result for the vortex formation in high-energy heavy-ion collisions, we need to use the more realistic initial conditions. For example, the existence of shear flow is found in the initial condition based on the Color Glass Condensate [65, 66]. In addition, the effect of deviation from the Bjorken flow in a realistic initial condition is also important. Furthermore we shall apply our new code to analyses of experimental data at RHIC and the LHC; correlation between flow harmonics [16, 17], event plane correlation [18, 19], non-linearity of higher flow harmonics [20] and three particle correlation [21, 22]. A comprehensive investigation of experimental data with the accurate numerical method of the relativistic viscous hydrodynamics gives us deep insight of QCD matter.