선정목록으로
Stable anisotropic heat conduction in smoothed particle hydrodynamics
엔지니어링 플라스틱 · (22) POM(폴리아세탈)
기본 정보
- 저자
- DOI
- 10.48550/arxiv.1812.04006
- 저널
- arXiv (Cornell University)
- 발행년도
- 2022
- 발행기관
- Cornell University
- 피인용수
- 0
- 라이선스
- 0
- 논문 유형
- –
- 언어
- –
- 원문 페이지
- https://doi.org/10.48550/arxiv.1812.04006
- 토픽
- Surface Modification and Superhydrophobicity
- OpenAlex ID
- W6891893667
평가 내용
- 관련도
- 사업분야
- 엔지니어링 플라스틱 · (22) POM(폴리아세탈)
- 부 분야
- –
- R&D 측면
- –
- 확신도
- –
- 근거 용어
- –
- 판단 근거
- 임베딩 유사도 기반 평가로 '엔지니어링 플라스틱 > POM(폴리아세탈)' 분야에 선정된 논문입니다.
- R&D 활용 포인트
- –
- 평가 입력
- –
초록
We investigate how to simulate anisotropic heat conduction in a stable manner in Smoothed Particle Hydrodynamics. We show that the requirement for stability is that entropy must increase. From this, we deduce that methods involving direct second derivatives in SPH are unstable, as found by previous authors. We show that the only stable method is to use two first derivatives with alternating differenced and symmetric SPH derivative operators, with the caveat, that one may need to apply smoothing or use an artificial conductivity term if the initial temperature jump is discontinuous. Furthermore, we find that with two first derivatives the stable timestep can be 3--8 times larger even for isotropic diffusion.
본문 52,263자
본문 펼치기
MNRAS 000, 1–9 (2018) Preprint 18 December 2018 Compiled using MNRAS L <sup>A</sup> TEX style file v3.0
## Stable anisotropic heat conduction in smoothed particle hydrodynamics
### Sergei Biriukov ⋆ and Daniel J. Price
_Monash Centre for Astrophysics (MoCA) and School of Physics and Astronomy, Monash University, Vic. 3800, Australia_
Accepted 2018 December 6. Received 2018 November 20; in original form 2018 August 9.
ABSTRACT
We investigate how to simulate anisotropic heat conduction in a stable manner in Smoothed
Particle Hydrodynamics. We show that the requirement for stability is that entropy must increase. From this, we deduce that methods involving direct second derivatives in SPH are
unstable, as found by previous authors. We show that the only stable method is to use two
first derivatives with alternating differenced and symmetric SPH derivative operators, with
the caveat, that one may need to apply smoothing or use an artificial conductivity term if the
initial temperature jump is discontinuous. Furthermore, we find that with two first derivatives
the stable timestep can be 3–8 times larger even for isotropic diffusion.
Key words: methods: numerical — hydrodynamics — conduction — diffusion
1 INTRODUCTION
In this paper, we aim to find stable discretisations of thermal diffusion equations of the form
tives of _Aa_ with respect to the position r _a_ simply involve the gradient of the kernel function, e.g.,
_∇aAa_ =
_<u>mb</u>_
_ρb_ <sup>(</sup> <sup>_Ab −_</sup> <sup>_Aa_</sup> <sup>)</sup> <sup>_∇aWab._</sup> (3)
_b_
<u>d</u> _<u>u</u>_
(1)
_ρ_ <sup><u>1</u></sup> <sup>_∇·_</sup> <sup>(</sup> <sup>_κ_</sup> <sup>_∇T_</sup> <sup>)</sup> <sup>_,_</sup>
<u>dd</u> _<u>ut</u>_ <sup>=</sup> _ρ_ <sup><u>1</u></sup>
Discretisation of the isotropic heat equation in SPH was considered in Lucy (1977), but most modern implementations follow
the method presented by Brookshaw (1985) and Cleary & Monaghan (1999) whereby
where _u_ = _cvT_ is the internal energy per unit mass, _ρ_ is the density,
_T_ is the temperature, and _κ_ _≡_ _κij_ is a heat conduction tensor (with
_κij_ _≡_ _κδij_ when the conduction is isotropic). The heat conduction
tensor must be a symmetric tensor ( _κij_ = _κji_ ) with positive diagonal elements, to ensure that heat flows from hot to cold and not vice
versa.
Such equations arise in astrophysics when considering heat
(Parrish & Stone 2005) or cosmic ray diffusion (Forman & Gleeson
1975; Girichidis et al. 2016) in the presence of magnetic fields, and
the anisotropic diffusion of radiation (Petkova & Springel 2009).
Smoothed particle hydrodynamics (SPH; for reviews see
Monaghan 1992, 2005) is a Lagrangian method for fluid dynamics. The method consists of two main steps. First, discretise matter
onto a set of finite particles. For each particle _a_ we define properties
such as mass _ma_, density _ρa_, and position r _a_ . Second, discretise
the set of equations using the summation interpolant (Gingold &
Monaghan 1977; Lucy 1977)
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup>
_b_
_<u>mb</u>_
_ρaρb_ <sup>_<u>κab</u>_</sup> <sup>(</sup> <sup>_Tb −_</sup> <sup>_Ta_</sup> <sup>)</sup> <sup>_<u>−</u>_</sup> _|r_ <sup><u>2</u></sup> _ab_ <sup>_<u>Fab</u>_</sup> _|_ <sup>_._</sup> (4)
In the above, _Fab_ is the scalar part of the kernel gradient, and _<u>κ</u>_ is
either an arithmetic or harmonic mean of the (scalar) conductivity
between the particle pair e.g. _<u>κab</u>_ = ( _κa_ + _κb_ ) _/_ 2.
Other methods have been proposed to reduce errors in second
derivatives computed with SPH by correcting the gradient operators
(e.g. Korzilius, Schilders & Anthonissen 2017). We do not consider
such methods in this paper because they do not guarantee the conservation of energy. By contrast, all of the schemes we examine
conserve energy to the precision of the timestepping algorithm.
More recently, Espa˜nol & Revenga (2003) generalised the
Brookshaw method to the anisotropic case (i.e. when _κ_ is a tensor).
However, they found that achieving accuracy to within a few percent required at least 50 neighbours in 2D, which would be equivalent to 250 neighbours in 3D. This is costly.
Petkova & Springel (2009) found a more significant problem:
The method proposed by Espa˜nol & Revenga (2003) is unstable
when the diffusion is highly anisotropic. While Petkova & Springel
(2009) proposed an ‘anisotropy limiter’ to fix the stability problem,
Hopkins (2017) showed that this could lead to incorrect results.
The paper is organised as follows: In Section 2 we outline
methods for isotropic and anisotropic heat conduction in SPH,
_<u>mb</u>_
_ρb_ <sup>_AbW_</sup> <sup>(</sup> <sup>_|_</sup> <sup>r</sup> <sup>_a −_</sup> <sup>r</sup> <sup>_b|, h_</sup> <sup>)</sup> <sup>_,_</sup> (2)
_A_ ( r _a_ ) _≡_ _Aa_ =
_b_
where _Aa_ is the interpolated property, and _W_ ( _|_ r _a −_ r _b|, h_ ) _≡_ _Wab_
is the kernel function describing the weight assigned to neighbours.
As the kernel _Wab_ is the only part of (2) that depends on r _a_, deriva
_⋆_ E-mail: sergei.biriukov@monash.edu (SB)
_⃝_ c 2018 The Authors
2 _Biriukov & Price_
and assess their stability. This shows why the Espanol & Revenga
method is unstable - it does not guarantee positive entropy. Table 1 summarises the stability conditions. We test our ideas in Section 3, and show how to remove oscillations in the solution obtained
with two first derivatives when the initial conditions are discontinuous. We summarise and draw conclusions in Section 4 and 5.
2 HEAT CONDUCTION IN SPH
2.1 Methods
_2.1.1_ _Direct second derivatives_
By taking second derivatives of (2), an SPH discretisation of (1) in
the case where _κ_ is isotropic is given by
_ij_ <sup>_~~a~~_</sup> <sup>_bF ij_</sup> _ab_
<sup>_ij_</sup> _ab_ <sup>_._</sup> (14)
_2.1.3_ _Espanol & Revenga: Anisotropic heat conduction_
Espa˜nol & Revenga (2003) generalised the method further to be
applicable to anisotropic diffusion. In this, more general case, they
showed that the correct expression is
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup> <sup>_−_</sup>
_<u>mb</u>_
_ij_
_ρaρb_ <sup>_Tbaκ_</sup> <sup>_~~a~~_</sup> <sup>_b_</sup>
_ab_ <sup>_j_</sup> <sup>_−_</sup> <sup>_δij_</sup> <sup>�</sup> <sup>_<u>Fab</u>_</sup>
_|rab_
_b_
�( _ν_ + 2)ˆ _r_ <sup>_i_</sup>
_rab_ <sup>_i_</sup> <sup>_r_</sup> <sup>ˆ</sup> <sup>_j_</sup>
<sup>_<u>Fab</u>_</sup> (12)
_|rab|_ <sup>_._</sup>
where _Tba_ _≡_ _Tb −_ _Ta_ . Their method is equivalent to defining
_ab_ <sup>_j_</sup> <sup>_−_</sup> <sup>_δij_</sup> <sup>�</sup> <sup>_<u>Fab</u>_</sup>
_|rab_
_Fab_ <sup>_ij_</sup> <sup>=</sup> <sup>_−_</sup>
�( _ν_ + 2)ˆ _r_ <sup>_i_</sup>
_rab_ <sup>_i_</sup> <sup>_r_</sup> <sup>ˆ</sup> <sup>_j_</sup>
<sup>_<u>Fab</u>_</sup> (13)
_|rab|_ <sup>_,_</sup>
such that the anisotropic discretisation of (1) is given by
_b_
_<u>mb</u>_
_ρaρb_ <sup>_Tbaκ_</sup> _ij_ <sup>_~~a~~_</sup> <sup>_b_</sup>
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup>
_b_
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup>
_<u>mb</u>_
_ρaρb_ <sup>_<u>κab</u>_</sup> <sup>(</sup> <sup>_Tb −_</sup> <sup>_Ta_</sup> <sup>)</sup> <sup>_∇_</sup> _a_ <sup>2</sup> <sup>_W_</sup> _ab_ <sup>_._</sup> (5)
For the anisotropic case with a tensor heat conduction coefficient _κij_ we can generalise this to
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup>
_b_
_a_ <sup>_i_</sup> <sup>_∇j_</sup> _a_
<sup>_j_</sup> _a_ <sup>_W_</sup> _ab_
_2.1.4_ _Petkova & Springel: Anisotropy-limited diffusion_
Petkova & Springel (2009) showed that the method proposed by
Espa˜nol & Revenga (2003) is unstable when the diffusion is highly
anisotropic. To stabilise the method, Petkova & Springel (2009)
proposed to modify the operator according to
_<u>mb</u>_
_ρaρb_ <sup>(</sup> <sup>_Tb −_</sup> <sup>_Ta_</sup> <sup>)</sup>
<u>�</u> _<u>κ</u>_ <sup>_~~a~~_</sup> _ij_ <sup>_b_</sup>
<sup>_~~a~~_</sup> _ij_ <sup>_b∇_</sup> _a_ <sup>_i_</sup>
_,_ (6)
where we assume that repeated _i_ or _j_ indices imply summation.
The second derivative of the kernel can be written in terms of the
dimensionless kernel function according to (e.g. Price 2010)
_F_ ˜ _ab_ <sup>_ij_</sup>
_ij_ <sup>_abF ij_</sup> _ab_
_ab_ <sup>_ij_</sup> <sup>=</sup> <sup>_γκ_</sup> _ij_ <sup>_ab_</sup>
<sup>_ij_</sup> _ab_ <sup>+</sup> <sup><u>1</u></sup> <sup>_<u>−</u>_</sup> <sup>_<u>γ</u>_</sup>
3
<sup>_<u>γ</u>_</sup> _δ_ <sup>_ij_</sup> _._ (15)
3
_r_ ˆ <sup>_i_</sup>
_ab_ <sup>_i_</sup> <sup>_r_</sup> <sup>ˆ</sup> <sup>_j_</sup>
_ab_ <sup>_j_</sup> <sup>+</sup> <sup>_f ′q−_</sup> <sup>1</sup> <sup>_δij_</sup> <sup>�</sup>
_._ (7)
_∇_ <sup>_i_</sup> _a_
<sup>_i_</sup> _a_ <sup>_∇j_</sup> _a_
<u>1</u>
<sup>_j_</sup> _a_ <sup>_W_</sup> _ab_ <sup>=</sup>
_Cν_ _h_ <sup>_ν_</sup> <sup>+2</sup>
�� _f_ <sup>_′′_</sup> _−_ _f_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1�</sup>
In order to obtain a stable solution in 3D, one should use at
least _γ_ = 52 <sup>.</sup> <sup>This</sup> <sup>converts</sup> <sup>the</sup> <sup>fully</sup> <sup>anisotropic</sup> <sup>problem</sup> <sup>to</sup> <sup><u>2</u></sup> 5 <sup>of</sup>
anisotropic diffusion plus <sup><u>3</u></sup> 5 <sup>of isotropic diffusion. However limit-</sup>
ing the anisotropy of the diffusion in this way produces incorrect
results, as discussed by Hopkins (2017).
_2.1.5_ _Two first derivatives_
A simple alternative approach is to compute the diffusive flux explicitly before taking the gradient, i.e.
_F_ <sup>_j_</sup> = _∇_ <sup>_j_</sup> _T,_ (16)
We refer to this method as the ‘direct second derivative’ operator
for heat conduction.
_2.1.2_ _Brookshaw method for isotropic heat conduction_
Brookshaw (1985) showed that the direct second derivative operator (5) could be very inaccurate, explaining the errors reported by
Lucy (1977). Instead, Brookshaw proposed to use the first derivative of the kernel function to compute the second derivative. The
method is equivalent to defining a new kernel function _Y_, such that
(e.g. Price 2012)
_∇_ <sup>2</sup> _Yab_ _≡_ <sup>_<u>−</u>_</sup> <sup><u>2</u></sup> <sup>_<u>Fab</u>_</sup> (8)
_|rab|_ <sup>_,_</sup>
where _Fab_, in terms of the dimensionless kernel function _f_ ( _q_ ), is
_<u>Cν</u>_
_Fab_ = _h_ <sup>_ν_</sup> <sup>+1</sup> <sup>_f ′_</sup> <sup>(</sup> <sup>_q_</sup> <sup>)</sup> <sup>_,_</sup> (9)
with _q_ _≡|rab|/h_, _Cν_ is the kernel normalisation constant, _h_ is the
smoothing length and _ν_ is the number of dimensions. The operator
for isotropic diffusion in SPH is therefore
<u>d</u> _<u>u</u>_
<u>dd</u> _<u>ut</u>_ <sup>=</sup> _ρ_ <sup><u>1</u></sup>
(17)
_ρ_ <sup><u>1</u></sup> <sup>_∇i_</sup> <sup>(</sup> <sup>_κijF j_</sup> <sup>)</sup> <sup>_._</sup>
We show in Section 2.2.4 that this method is stable as long as we
choose the derivative operators carefully. In particular, one should
implement this ‘two first derivatives’ method using a combination
of differenced and symmetric derivative operators (Cummins &
Rudman 1999; Tricco & Price 2012). Considering the general case
where the smoothing length on each particle is different, we discretise this using (e.g. Price 2012)
_b_
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup> <sup>_−_</sup>
_b_
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup>
<u>1</u>
_Fa_ <sup>_j_</sup> <sup>=</sup>
Ω _aρa_
_mb_ ( _Tb −_ _Ta_ ) _∇a_ <sup>_j_</sup> <sup>_W_</sup> _ab_ <sup>(</sup> <sup>_h_</sup> _a_ <sup>)</sup> <sup>_,_</sup> (18)
_<u>mb</u>_
_ρaρb_ <sup>(</sup> <sup>_κa_</sup> <sup>+</sup> <sup>_κb_</sup> <sup>)(</sup> <sup>_Tb −_</sup> <sup>_Ta_</sup> <sup>)</sup> _|_ <sup>_<u>F</u>_</sup> _rab_ <sup>_<u>ab</u>_</sup> _|_ <sup>_._</sup> (10)
<sup>_i_</sup> _<u>a</u>_ <sup>_∇j_</sup> _<u>a</u>_
<sup>_∇j_</sup> _<u>a</u>_ <sup>_W_</sup> _ab_ <sup>(</sup> <sup>_h_</sup> _a_ <sup>)</sup>
Ω _aρ_ <sup>2</sup> _a_
<sup>_i_</sup> _<u>b</u>_ <sup>_∇_</sup> _<u>a</u>_ <sup>_j_</sup>
<sup>_∇_</sup> _<u>a</u>_ <sup>_j_</sup> <sup>_W_</sup> _ab_ <sup>(</sup> <sup>_h_</sup> _b_ <sup>)</sup>
Ω _bρ_ <sup>2</sup> _b_
_._
+ <sup>_κ_</sup> _<u>ij</u>_ <sup>_b_</sup>
_<u>ij</u>_ <sup>_b_</sup> <sup>_F i_</sup> _<u>b</u>_
_b_
_b_
- _κ_ <sup>_a_</sup> _<u>ij</u>_
<sup>_a_</sup> _<u>ij</u>_ <sup>_F i_</sup> _<u>a</u>_
Cleary & Monaghan (1999) proposed an alternative form using the harmonic mean for the case where _κ_ is discontinuous, given
by
_mb_
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup> <sup>_−_</sup>
_b_
<u>4</u> _<u>κaκb</u>_
( _κa_ + _κb_ ) <sup>(</sup> <sup>_Tb −_</sup> <sup>_Ta_</sup> <sup>)</sup> _|_ <sup>_<u>F</u>_</sup> _rab_ <sup>_<u>ab</u>_</sup> _|_ <sup>_._</sup> (11)
(19)
In the above, Ω is the term used in the evaluation of the
smoothing length Monaghan (2002); Springel & Hernquist (2002)
Ω _a_ _≡_ 1 + <sup><u>3</u></sup> <sup>_<u>ha</u>_</sup>
_ρa_
_<u>mb</u>_
_ρaρb_
_b_
_mb_ <sup>_<u>∂Wab</u>_</sup> <sup><u>(</u></sup> <sup>_<u>ha</u>_</sup> <sup><u>)</u></sup> _._ (20)
_∂ha_
We do not consider the harmonic mean in this paper since Price &
Laibe (2015) found that it could produce incorrect results in dust
diffusion problems.
For completeness, in Section 3.1.3 we tested the derivative
MNRAS 000, 1–9 (2018)
operators in the reverse order - differenced after symmetric. Although we find no significant difference in the results (see Figures 4 and 5), the order above is necessary to conserve total energy,
_E_, since
<u>d</u> _<u>E</u>_
<u>dd</u> _<u>Et</u>_ <sup>=</sup> d <sup><u>d</u></sup> _t_
_Anisotropic diffusion in SPH_ 3
<u>Method</u> <u>Isotropic stability</u> <u>Anisotropic stability</u>
<u>Brookshaw/Espanol-Revenga</u> <u>Always</u> <u>If Eq. 24 satisfied</u>
Direct second derivatives If Eq. 27 satisfied If Eq. 26 satisfied
<u>Two first derivatives</u> <u>Always</u> <u>Always</u>
Table 1. Summary of stability conditions for anisotropic diffusion in SPH
using different methods.
To satisfy the inequality (24), the ratio of components should be
_ma_ <sup><u>d</u></sup> <sup>_<u>ua</u>_</sup> (21)
d _t_ <sup>= 0</sup> <sup>_._</sup>
_a_
d _t_
_a_
_maua_ =
The last sum is zero when inserting (19) because of the antisymmetry of the kernel gradient producing a double summation which
is antisymmetric in the particle index _a_ and _b_ and therefore equal
to zero. The above version is also efficient because it does not require adding a third loop over the particles between the density and
force evaluations — since evaluating the flux does not require prior
knowledge of the density.
2.2 Stability
As stated by Monaghan (2005), the main advantage of the Brookshaw method over a direct second derivative of the SPH kernel is
the guarantee of increasing entropy. For heat conduction problems,
this means that heat always flows from hot to cold particles (which
guarantees stability but says nothing about accuracy). To show that
this is true, we need to prove that the rate of change of the total
entropy _S_ is positive. For the Espanol-Revenga operator, we have
As in practice this ratio can be arbitrary, anti-diffusive behaviour
is possible. To illustrate this, the grey shading in Figure 1 shows
the regions inside the kernel compact support radius from which
neighbouring particles contribute anti-diffusive terms. The instability grows from these regions resulting in negative temperatures.
_2.2.3_ _Direct second derivatives_
While we found this approach to be more stable than EspanolRevenga method both practically and theoretically, after the same
analysis as in Section 2.2.1 we arrive at a similar condition for stability as for the Espanol-Revenga operator, namely
_._ (25)
_<u>κxx</u>_
_κyy_ <sup>_∈_</sup>
- <u>1</u>
_ν_ + 1 <sup>;</sup> <sup>_ν_</sup> <sup>+ 1</sup>
<u>d</u> _<u>S</u>_
d _t_ <sup>=</sup>
_a_
_ma_ <sup><u>d</u></sup> <sup>_<u>sa</u>_</sup>
d _t_ <sup>=</sup>
_ma_ <sup><u>d</u></sup> <sup>_<u>sa</u>_</sup>
d _t_
_−_ _κ_ <sup>_xx_</sup> [( _f_ <sup>_′′_</sup> _−_ _f_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1</sup> )ˆ _r_ <sup>_x_</sup> _r_ ˆ <sup>_x_</sup> + _f_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1</sup> ]
_−_ _κ_ <sup>_yy_</sup> [( _f_ <sup>_′′_</sup> _−_ _f_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1</sup> )ˆ _r_ <sup>_y_</sup> _r_ ˆ <sup>_y_</sup> + _f_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1</sup> ] _≥_ 0 _,_
or in the isotropic case
(26)
( _Tb −_ _Ta_ <u>)</u> _<u>κ</u>_ <sup>_~~a~~_</sup> _ij_ <sup>_b_</sup>
<sup>_ij_</sup> _ab_ <sup>_._</sup>
(22)
- <u>1</u>
_Ta_ <sup>_−_</sup> _T_ <sup><u>1</u></sup> _b_
_a_
_b_
_<u>mamb</u>_
_ρaρb_
<sup>_~~a~~_</sup> _ij_ <sup>_bF ij_</sup> _ab_
As the terms involving mass, density and temperature are all
positive, positive entropy requires _<u>κ</u>_ <sup>_~~a~~_</sup> _ij_ <sup>_bF ij_</sup> _ab_ <sup>to be positive definite.</sup>
<sup>_~~a~~_</sup> _ij_ <sup>_bF ij_</sup> _ab_
<sup>_ij_</sup> _ab_ <sup>to be positive definite.</sup>
_2.2.1_ _Brookshaw: Isotropic heat conduction_
When heat conduction is isotropic ( _κ_ = _κδ_ <sup>_ij_</sup> ), the Espa˜nol & Revenga (2003) operator reduces to the Brookshaw (1985) operator.
The stability condition becomes
_<u>κ</u>_ <sup>_~~a~~_</sup> _ii_ <sup>_b_</sup>
<sup>_~~a~~_</sup> _ii_ <sup>_bF ii_</sup> _ab_
<sup>_ii_</sup> _ab_ <sup>=</sup> <sup>_κ_</sup> <sup>_<u>−</u>_</sup> <sup><u>2</u></sup> <sup>_<u>Fab</u>_</sup>
<sup><u>2</u></sup> <sup>_<u>Fab</u>_</sup> _≥_ 0 _._ (23)
_|rab|_
_−_ _κ_ [( _f_ <sup>_′′_</sup> _−_ _f_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1</sup> ) + _νf_ <sup>_′_</sup> _q_ <sup>_−_</sup> <sup>1</sup> ] _≥_ 0 _._ (27)
This means that for direct second derivatives with standard
kernels there is always a region in which anti-diffusive behaviour
occurs. These regions are shown for different kernels in grey in
Figure 1 for the test case described in Section 3.2 where _κ_ <sup>_xx_</sup> = 1
and _κ_ <sup>_yy_</sup> = 0.
_2.2.4_ _Two first derivatives_
We compute the entropy evolution using
Because _κ_ is always positive and _Fab_ is negative (assuming SPH
kernels where the weight decreases monotonically with radius), the
kernel part (23) and the total entropy (22) are always positive, and
therefore the method is stable.
_2.2.2_ _Espanol & Revenga: Anisotropic heat conduction_
As the following idea is the same for more than one dimension,
we will discuss the simplest case of 2D anisotropic heat conduction. Knowing that, from the energy argument, the heat conduction
tensor is a real symmetric tensor, it is always possible to find a principal axis and to represent the heat conduction tensor as a diagonal
(orthotropic) tensor using spectral decomposition with respect to
the principal axis. This means that for any anisotropic heat conduction problem we can find a new local coordinate axis in which _κ_ is
a diagonal tensor. Thus, to have positive total entropy (22) in 2D,
we need to satisfy the inequality
_−κxx_ [( _ν_ + 2)ˆ _r_ <sup>_x_</sup> _r_ ˆ <sup>_x_</sup> _−_ 1)] _−_ _κyy_ [( _ν_ + 2)ˆ _r_ <sup>_y_</sup> _r_ ˆ <sup>_y_</sup> _−_ 1] _≥_ 0 _._ (24)
MNRAS 000, 1–9 (2018)
<u>d</u> _<u>S</u>_
d _t_ <sup>=</sup>
_a_
_a_
_ma_ <sup><u>d</u></sup> <sup>_<u>sa</u>_</sup>
d _t_ <sup>=</sup>
_ma_ <sup><u>1</u></sup>
_Ta_
<u>d</u> _<u>ua</u>_
d _t_ <sup>=</sup>
<sup>_i_</sup> _<u>a</u>_ <sup>_∇j_</sup> _<u>a</u>_
<sup>_i_</sup> _<u>b</u>_ <sup>_∇_</sup> _<u>a</u>_ <sup>_j_</sup>
<sup>_∇_</sup> _<u>a</u>_ <sup>_j_</sup> <sup>_W_</sup> _ab_ <sup>(</sup> <sup>_h_</sup> _b_ <sup>)</sup>
Ω _bρ_ <sup>2</sup> _b_
_._
<sup>_∇j_</sup> _<u>a</u>_ <sup>_W_</sup> _ab_ <sup>(</sup> <sup>_h_</sup> _a_ <sup>)</sup>
Ω _aρ_ <sup>2</sup> _a_
+ <sup>_κ_</sup> _<u>ij</u>_ <sup>_b_</sup>
_<u>ij</u>_ <sup>_b_</sup> <sup>_F i_</sup> _<u>b</u>_
_b_
_b_
_a_
_ma_ <sup><u>1</u></sup>
_Ta_
- _κ_ <sup>_a_</sup> _<u>ij</u>_
_mb_
<sup>_a_</sup> _<u>ij</u>_ <sup>_F i_</sup> _<u>a</u>_
(28)
Taking into account that _∇aWab_ = _−∇bWba_ we can rearrange the
double summation to give
_b_
_mb_ ( _Tb −_ _Ta_ ) _∇a_ <sup>_j_</sup> <sup>_W_</sup> _ab_ <sup>(</sup> <sup>_h_</sup> _a_ <sup>)</sup> <sup>_._</sup> (29)
<u>d</u> _<u>S</u>_
d _t_ <sup>=</sup>
_a_
_κ_ <sup>_a_</sup> _<u>ij</u>_
_<u>a</u>_
Ω _aρ_ <sup>2</sup> _a_
<sup>_a_</sup> _<u>ij</u>_ <sup>_F i_</sup> _<u>a</u>_
_<u>ma</u>_
_TaTb_
Hence, as long as the flux is calculated using (18), entropy increase
is guaranteed. Importantly, stability is guaranteed _independent_ _of_
_the_ _choice_ _of_ _SPH_ _kernel_ . This result is similar to the proof given
in Price et al. (2017) for physical viscosity or in Price (2012) for
magnetohydrodynamics.
Table 1 summarises the stability conditions for each of the
methods discussed above.
4 _Biriukov & Price_
ra ra
ra
a) Espanol-Revenga M6 b) Direct 2 <sup>_nd_</sup> Derivative M6 c) Direct 2 <sup>_nd_</sup> Derivative M4
Figure 1. Neighbours within the kernel radius that contribute to anti-diffusive behaviour when simulating anisotropic diffusion. We consider uniformly
distributed particles inside a compact domain for _a, b_ ) quintic spline kernel and _c_ ) cubic spline kernel, both with the smoothing length equal to the particle
spacing. Instability regions are shown in grey for anisotropic diffusion assuming _κxx_ = 1. The first plot _a_ ) shows this region for the Espanol-Revenga method,
while plots _b, c_ ) show it for the direct second derivative method. Grey shading indicates the region from where the neighbours add negative diffusion to a
particle _a_ . With the Espanol-Revenga method (left), the anti-diffusive region is larger, which is why this method becomes unstable faster. The region becomes
smaller relative to the kernel support area with the quintic kernel for the direct 2 <sup>_nd_</sup> derivative method, but better kernels cannot prevent instability altogether.
_<u>M</u>_ <u>4</u> _<u>M</u>_ <u>6</u> _<u>M</u>_ <u>8</u>
<u>Brookshaw/Espanol-Revenga</u> <u>0.15</u> <u>0.18</u> <u>0.2</u>
Direct second derivatives 0.2 0.35 0.4
<u>Two first derivatives</u> <u>0.6</u> <u>1.2</u> <u>1.6</u>
Table 2. The integration constants used in the numerical tests.
2.3 Timestep constraints
For diffusion problems, the timestep requirement is given by (e.g.
Cleary & Monaghan 1999)
∆ _t ≤_ <sup>_<u>Ccvρh</u>_</sup> <sup>2</sup> _,_ (30)
_κij_
where _C_ is a constant. The above is a local constraint. Since we
used the same timestep for all particles, we take the minimum over
all particles.
Table 2 gives the values of _C_ we found to be stable in our 2D
tests. We obtained these values empirically, although they could,
in principle, be determined analytically by a stability analysis. The
constants for Brookshaw and direct second derivative methods apply only to isotropic diffusion, as the methods are unstable for
anisotropic diffusion regardless of the choice of timestep, which
we confirmed down to _C_ = 0 _._ 01.
The change of the stability constant between kernels (left to
right in Table 2) is not surprising. This simply follows the standard
deviation of the kernel, as discussed by Dehnen & Aly (2012). Even
so this effect helps to mitigate the computational cost of smoother
spline kernels.
The surprising aspect is the factor of 3–8 increase in timestep
possible with the two first derivatives method (bottom row of Table 2). We confirmed that this also holds in 3D. We attribute this to
the extra stability provided by the double convolution of the kernel
gradient inherent in the two first derivatives method. This gives us
compelling reason to use this method even for isotropic diffusion.
_3.1.1_ _Diffusion in the direction of the heat gradient_
Figure 2 shows the results of this test at a resolution of 64 particles along the x-direction, placed on a uniform lattice. We compare the two first derivatives method (left) to direct second derivatives (right), finding that both two first derivatives and direct second derivative methods produce stable results. Using noisier kernels (M4 instead of M6) or higher resolution leads to numerical
instability with the direct second derivative.
At this resolution and kernel (M6), a ‘carbuncle mode’ appears in the solution obtained with the two first derivatives method
caused by the initially discontinuous temperature profile, while the
solution obtained with direct 2 <sup>_nd_</sup> derivative is less noisier. This error decreases with resolution, and can be eliminated by smoothing
the initial conditions (see Section 3.1.4).
MNRAS 000, 1–9 (2018)
3 NUMERICAL TESTS
3.1 Diffusion in a slab with constant heat conduction tensor
To test our ideas in practice, we considered diffusion in a 3D
slab: _x_ _∈_ [ _−_ 1 _,_ 1] with Dirichlet boundary condition, and _y, z_ _∈_
[ _−_ 4∆ _r,_ 4∆ _r_ ], where ∆ _r_ is the particle spacing, with periodic
boundary conditions. We set up the problem using 64 _×_ 8 _×_ 8 particles in 3D. Initially, _TL_ = 1 for _x_ _<_ 0, and _TR_ = 2 for _x_ _>_ 0.
In the isotropic case the exact solution is one dimensional and can
be approximated for some time (until diffusion hits the boundary)
by the exact solution for one dimensional heat conduction in an
infinite slab
_._
<sup><u>+</u></sup> <sup>_<u>TL</u>_</sup> + <sup>_<u>TR −</u>_</sup> <sup>_<u>TL</u>_</sup>
2 2
_T_ ( _x, y, z, t_ ) = _T_ ( _x, t_ ) = <sup>_<u>TR</u>_</sup> <sup><u>+</u></sup> <sup>_<u>TL</u>_</sup>
<sup>_<u>TL</u>_</sup> Erf
2
- _<u>x</u>_
_~~√~~_ 4 _κxxt_
(31)
This solution holds for anisotropic diffusion when _κ_ <sup>_xx_</sup> is the only
non-zero component
_<u>∂T∂t</u>_ <sup>=</sup> <sup>_κxx_</sup> <sup>_<u>∂</u>_</sup> _∂x_ <sup>2</sup> <sup>_<u>T</u>_</sup> <sup>2</sup>
_<u>∂T</u>_
(32)
<sup>_<u>∂</u>_</sup> _∂x_ <sup>2</sup> <sup>_<u>T</u>_</sup> <sup>2</sup> <sup>_._</sup>
_Anisotropic diffusion in SPH_ 5
2 _._ 0
1 _._ 8
1 _._ 6
1 _._ 4
1 _._ 2
1 _._ 0
Two 1 <sup>_st_</sup> deriv. t = 0.05
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Differential F
Symmetric <sup><u>du</u></sup> <u>dt</u>
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Direct 2 <sup>_nd_</sup> deriv. t = 0.05
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Differential F
Symmetric <sup><u>du</u></sup> <u>dt</u>
t = 0.025
t = 0.025 Continuous
No artif. term
Discontinuous
Artif. term
t = 0.025
Symmetric F
Differential <sup><u>du</u></sup> <u>dt</u>
t = 0.025
Figure 2. Diffusion along the x-direction in a 3D slab. Black dots show the
SPH particles, red dashed line shows the exact solution. As expected, the
diffusion for anisotropic case with only one non-zero component _κ_ <sup>_xx_</sup> = 1
behaves in the same way as for isotropic diffusion with _κ_ = 1.
2 _._ 0
1 _._ 8
1 _._ 6
1 _._ 4
1 _._ 2
1 _._ 0
2 _._ 0
1 _._ 8
1 _._ 6
1 _._ 4
1 _._ 2
1 _._ 0
Continuous
No artif. term
Discontinuous
Artif. term
Symmetric F
Differential <sup><u>du</u></sup> <u>dt</u>
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
2 _._ 0
1 _._ 8
1 _._ 6
1 _._ 4
1 _._ 2
1 _._ 0
Two 1 <sup>_st_</sup> deriv. t = 0.05
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Direct 2 <sup>_nd_</sup> deriv. t = 0.05
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Figure 3. Anisotropic diffusion in a 3D slab (Section 3.1). Black dots show
the SPH particles, red dashed line shows the exact solution. Here, we assume _κ_ <sup>_yy_</sup> = 1, meaning there should be no heat conduction at all in the
x-direction. The direct second derivatives method is unstable in this case,
showing anti-diffusive behaviour (right panel), while the two first derivatives method remains stable and accurate (left panel).
_3.1.2_ _Diffusion perpendicular to the heat gradient_
When the only non-zero component of heat conduction tensor is
_κ_ <sup>_yy_</sup>, but heat conduction _T_ ( _x, t_ ) depends only on the _x_ component,
there should be no diffusion at all.
Figure 3 shows the results of the diffusion test with conduction
allowed only in the direction perpendicular to the heat gradient. In
contrast to the previous case, two first derivatives give the correct
solution (left), while the direct second derivatives method is unstable (right).
_3.1.3_ _Does the order of derivative operators matter?_
Comparing left and right panels in Figures 4 and 5 shows that the
order of operators (Symmetric after Differential in the left column
or Differential after Symmetric in the right columns) does not affect
the results. However, total energy is only exactly conserved when
the symmetric operator is used in the thermal energy equation.
_3.1.4_ _Eliminating the carbuncle mode_
The reason for the oscillations in Section 3.1.1 is the discontinuity
in the initial conditions. One can adopt smooth initial conditions by
MNRAS 000, 1–9 (2018)
Figure 4. As in Figure 2 but with a glass-like initial setup. First, a ‘carbuncle mode’ originates purely because of a discontinuous initial conditions,
as the mode is eliminated with the continuous initial conditions (top row of
this Figure) or the artificial thermal conduction term (bottom row). Second,
the order of operators (Symmetric after Differential in the left column or
Differential after Symmetric in the right columns) does not affect the final
result of the diffusion operator when it is done on the same set of relaxed
particles.
2 _._ 0
t = 0.025 Continuous
No artif. term
1 _._ 8
1 _._ 6
1 _._ 4
1 _._ 2
1 _._ 0
2 _._ 0
1 _._ 8
1 _._ 6
1 _._ 4
1 _._ 2
1 _._ 0
Differential F
Symmetric <sup><u>du</u></sup> <u>dt</u>
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Continuous
No artif. term
Discontinuous
Artif. term
Differential F
Symmetric <sup><u>du</u></sup> <u>dt</u>
t = 0.025
Discontinuous
Artif. term
t = 0.025
Symmetric F
Differential <sup><u>du</u></sup> <u>dt</u>
t = 0.025
Symmetric F
Differential <sup><u>du</u></sup> <u>dt</u>
_−_ 1 _._ 0 _−_ 0 _._ 5 0 _._ 0 0 _._ 5 1 _._ 0
x
Figure 5. As in Figure 4 but with only _κyy_ = 1. Although, both methods
cause the solution to loose the sharp interface, that can be fixed with higher
resolution (see Section 3.4). The order of operators still does not affect the
final result.
6 _Biriukov & Price_
setting the initial temperature according to
_T_ 0 = 1 _._ 5 + 0 _._ 5Erf( _x/L_ ) _,_ (33)
where _L_ is the length scale over which the initial discontinuity is
smoothed, which we set to twice the initial particle spacing. The top
row of Figure 4 demonstrates that the oscillations indeed vanish in
this case (compare top to bottom row).
Price (2008) showed that, in general, one requires artificial
dissipation terms whenever a discontinuity occurs in SPH. Hence
an alternative solution is to add an artificial conductivity term at the
discontinuity. For shock capturing the usual term is of the form
Exact Isotropic t = 0.05 Exact Anisotropic t = 0.05
_<u>−</u>_ 1 T(x,y) 1 _~~<u>−</u>~~_ 4 T(x,y) 4
Two 1 <sup>_st_</sup> derivatives t = 0.05 Two 1 <sup>_st_</sup> derivatives t = 0.05
_<u>−</u>_ 1 T(x,y) 1 _~~<u>−</u>~~_ 4 T(x,y) 4
- <u>d</u> _<u>u</u>_
d _t_
AC
_,_
0 _._ 75
0 _._ 50
0 _._ 25
0 _._ 00
_−_ 0 _._ 25
_−_ 0 _._ 50
_−_ 0 _._ 75
0 _._ 75
0 _._ 50
0 _._ 25
0 _._ 00
_−_ 0 _._ 25
_−_ 0 _._ 50
_−_ 0 _._ 75
0 _._ 75
0 _._ 50
0 _._ 25
0 _._ 00
_−_ 0 _._ 25
_−_ 0 _._ 50
_−_ 0 _._ 75
sig <sup>u</sup> <sup>(</sup> <sup>_u_</sup> _a_ <sup>_−_</sup> <sup>_u_</sup> _b_ <sup>)</sup> <sup><u>1</u></sup>
2
=
_b_
_mbα_ u _v_ <sup>u</sup>
- _<u>Fab</u>_ <u>(</u> _<u>ha</u>_ <u>)</u> + <sup>_<u>Fab</u>_</sup> <sup><u>(</u></sup> <sup>_<u>hb</u>_</sup> <sup><u>)</u></sup>
Ω _aρa_ Ω _bρb_
(34)
where _αu_ _∈_ [0 _,_ 1] and _v_ sig <sup>_u_</sup> <sup>is the signal speed. For hydrodynamics,</sup>
Price (2008) proposed
_v_ sig <sup>u</sup> <sup>=</sup>
~~�~~
_<u>|Pa −</u>_ _<u>Pb|</u>_
_<u>ρab</u>_
_,_ (35)
Espanol-Revenga t = 0.05
which is designed to smooth artificial pressure blips which can occur at contact discontinuities. For the purpose of this paper — considering the heat equation in isolation — we adopt a simpler signal
speed of the form
Brookshaw t = 0.05
_v_ sig <sup>u</sup> <sup>=</sup>
~~�~~ _|ua −_ _ub|,_ (36)
which could be easily generalised for diffusion of any quantity. Importantly, the addition of this term does not affect the convergence
of the method, since the artificial diffusion with _v_ sig <sup>_u_</sup> <sup>set as above is</sup>
_O_ ( _h_ <sup>2</sup> ). Given this it is safe to simply adopt _αu_ = 1.
Figures 4 and 5 demonstrate that both using the artificial conduction term (34) or starting with the smoothed initial conditions
effectively eliminate the ‘carbuncle mode’ caused by the discontinuity. For this figure we also placed the particles on a more realistic
particle distribution, by initially placing particles randomly in the
domain and relaxing them using the usual SPH equations with a
damping term. We refer to this as a ‘glass-like’ particle arrangement.
3.2 3D diffusion with constant heat conduction tensor
For our next test, we consider a domain _x, y, z_ _∈_ [ _−_ 1 _,_ 1] with
Dirichlet boundary conditions. Assuming an initial heat distribution in the form of a delta function located at the origin and using Green functions, we can find that the solution for the isotropic
equation in 3D is given by
<u>2</u> _<u>π</u>_ <sup>_−_</sup> <sup>3</sup> <sup>_/_</sup> <sup>2</sup>
_T_ ( _r, t_ ) = _ϵ_ <sup>2</sup> ( _ϵ_ <sup>2</sup> + 2 _κt_ ) <sup>1</sup> <sup>_/_</sup> <sup>2</sup> <sup>exp</sup>
- _−_ <sup><u>1</u></sup>
2
_<u>−</u>_ 1 T(x,y) 1 _~~<u>−</u>~~_ 4 T(x,y) 4
_−_ 0 _._ 5 0 _._ 0 0 _._ 5
x
_−_ 0 _._ 5 0 _._ 0 0 _._ 5
x
Figure 6. Anisotropic diffusion in a 3D slab with constant heat conduction
tensor. We use 64 <sup>2</sup> particles placed uniformly and the _M_ 6 kernel. At _t_ = 0
we assume a Gaussian pulse in the middle of the plate with _ϵ_ = 0 _._ 1. The
only non-zero component of heat conduction tensor is _κ_ <sup>_xx_</sup> . Here we compare isotropic (left panels) and anisotropic (right panels) diffusion. In the
isotropic case both methods agree with the exact solution with errors of order _≈_ 10 <sup>_−_</sup> <sup>2</sup> . For the anisotropic heat conduction, the Espanol-Revenga
method becomes unstable as described in Section 2.2.2, while two first
derivatives retain the same convergence rate and accuracy (see Section 3.4).
occurs only in the function corresponding to the nonzero component of the heat conduction tensor. The exact solution is then
��
_._
(39)
- _<u>x</u>_ <sup>2</sup>
_ϵ_ <sup>2</sup> + 2 _<u>x</u>_ <sup>2</sup> _κt_ <sup>+</sup> <sup>_<u>y</u>_</sup> <sup>2 +</sup> _ϵ_ <sup>2</sup> <sup>_<u>z</u>_</sup> <sup>2</sup>
_ϵ_ <sup>2</sup>
<u>2</u> _<u>π</u>_ <sup>_−_</sup> <sup>3</sup> <sup>_/_</sup> <sup>2</sup>
_T_ ( _r, t_ ) = ( _ϵ_ <sup>2</sup> + 2 _κt_ ) <sup>3</sup> <sup>_/_</sup> <sup>2</sup> <sup>exp</sup>
<sup><u>1</u></sup> _<u>r</u>_ <sup>2</sup>
2 _ϵ_ <sup>2</sup> + 2
- _−_ <sup><u>1</u></sup>
_ϵ_ <sup>2</sup> + 2 _κt_
_._ (37)
As it is impossible numerically to start with this solution, we set
the temperature at _t_ = 0 to be zero everywhere except a sphere of
radius _ϵ_ = 0 _._ 1 around the origin where it is
_T_ ( _r,_ 0) = <sup><u>2</u></sup> <sup>_<u>π−</u>_</sup> <sup>3</sup> <sup>_/_</sup> <sup>2</sup>
( _ϵ_ <sup>2</sup> ) <sup>3</sup> <sup>_/_</sup> <sup>2</sup> <sup>exp</sup>
- _−_ <sup>_<u>r</u>_</sup> <sup>2</sup>
2 _ϵ_ <sup>2</sup>
_._ (38)
Figure 6 shows the results for isotropic diffusion using the
Brookshaw method and for anisotropic diffusion using the EspanolRevenga method (bottom row). The corresponding exact solutions
are shown in the top row, respectively. The results highlight the
instability inherent in the Espanol-Revenga method when the diffusion is highly anisotropic. The solutions to the same problem performed with two first derivatives are stable (middle row).
It is possible to obtain accurate results at this resolution (64 <sup>2</sup>
particles) using the direct second derivative method as well, provided one employs the quintic kernel. However, the method does
MNRAS 000, 1–9 (2018)
We also considered an anisotropic case with diffusion acting only
along the _x_ axis with _κxx_ = 1. As the solution is then still the product of Green functions acting in each direction, the time evolution
_Anisotropic diffusion in SPH_ 7
t = 0.05
Direct 2 <sup>_nd_</sup> derivative
M4 256 <sup>2</sup> particles
0 _._ 5
0 _._ 0
_−_ 0 _._ 5
t = 0.05
Two 1 <sup>_st_</sup> derivatives
t = 0.05
0 _._ 5
0 _._ 0
_−_ 0 _._ 5
_<u>−</u>_ 4 T(x,y) 4 _<u>−</u>_ 4 T(x,y) 4
t = 0.05
Direct 2 <sup>_nd_</sup> derivative
M6 64 <sup>2</sup> particles
Exact Anisotropic
_<u>−</u>_ 0 _._ 3 T(x,y) 0 _._ 3 _<u>−</u>_ 0 _._ 3 T(x,y) 0 _._ 3
_−_ 0 _._ 5 0 _._ 0 0 _._ 5
x
_−_ 0 _._ 5 0 _._ 0 0 _._ 5
x
_−_ 0 _._ 5 0 _._ 0 0 _._ 5
x
_−_ 0 _._ 5 0 _._ 0 0 _._ 5
x
Figure 7. As in Figure 6 but solved with the direct 2 <sup>_nd_</sup> derivative method.
Although it is possible to obtain an accurate solution that appears stable (left
panel), the instability reveals itself at higher resolution and for noisier kernels (right panel), as discussed in Section 2.2.3. In this particular case, the
problem becomes unstable after _t ≈_ 0 _._ 025 with the direct second derivative
method when solved with the _M_ 4 kernel on 256 <sup>2</sup> particles.
not guarantee stability and may become unstable, as demonstrated
in Figure 7.
3.3 3D diffusion with variable heat conduction tensor
If we consider the previous problem in cylindrical coordinates
( _ρ, φ, z_ ), as shown by Hopkins (2017), we can define the initial
heat source according to
- <u>(</u> _<u>ρ −</u>_ _<u>ρ</u>_ <u>0)2</u>
_<u>−</u>_ _<u>ρ</u>_ <u>0)2</u> + <sup>_<u>φ</u>_</sup> <sup>2</sup>
_δρ_ <sup>2</sup> _δφ_ <sup>2</sup>
_δφ_ <sup>2</sup>
_T_ ( _ρ, φ,_ 0) = _T_ 0 + _T_ 1 exp
- _−_ <sup><u>1</u></sup>
2
��
_,_ (40)
where _ρ_ 0 = 0 _._ 3 is a radial position of the source, _δρ_ = 0 _._ 05 is a
radial size of the source, and _δφ_ = 0 _._ 5 is a azimuthal size of the
source, _T_ 0 = 0, _T_ 1 = 1.
Then, the solution is given by
- <u>(</u> _<u>ρ −</u>_ _<u>ρ</u>_ <u>0)2</u>
_<u>−</u>_ _<u>ρ</u>_ <u>0)2</u> _<u>φ</u>_ <sup>2</sup>
+
_δρ_ <sup>2</sup> _δφ_ <sup>2</sup> 0 <sup>+ 2</sup> <sup>_κ_</sup>
_δφ_ <sup>2</sup> 0
<sup>2</sup> 0 <sup>+ 2</sup> <sup>_κφφρ−_</sup> <sup>2</sup> <sup>_t_</sup>
Figure 8. Anisotropic diffusion in 3D slab with a spatially variable heat
conduction tensor. At _t_ = 0 the heat is a Gaussian pulse with _ρ_ 0 = 0 _._ 3,
_δρ_ = 0 _._ 05, and _δφ_ = 0 _._ 5. The heat conduction tensor in cylindrical coordinates contains only one non-zero component _κ_ <sup>_φφ_</sup> = 1. Solution was
obtained with 64 <sup>2</sup> particles and the _M_ 6 quintic kernel.
3.4 Convergence and kernels
For each the preceding tests, we performed a convergence study,
shown in Figures 9 and 10. These show that the kernels and initial
particle distribution have a significant influence on the overall accuracy. The kernel bias is the region in which the accuracy cannot
be increased by simply using more particles.
Figure 9 (left panel) compares the convergence properties of
the Brookshaw method and two first derivatives for isotropic heat
conduction with particles on a regular lattice with the Gaussian
pulse as the initial temperature distribution and quintic spline (M6)
as a smoothing kernel. Convergence is quadratic for both methods, even though the Brookshaw method is one order of magnitude
more accurate overall. When the error reaches _≈_ 10 <sup>_−_</sup> <sup>4</sup>, it stops
improving with higher resolution. The error then depends purely
on the smoothing kernel. The central panel of the Figure 9 shows
that the convergence rate and kernel bias stay the same when we
switch to the anisotropic problem (where the Brookshaw method is
no longer applicable). The right panel of Figure 9 shows that the
choice of kernel and the number of neighbours sets the kernel bias.
Using higher kernels in the spline series, we can obtain progressively more accurate results at high spatial resolution.
Figure 10 shows the convergence results for one dimensional
heat diffusion at _t_ = 0 _._ 025 (Section 3.1). We adopted a glass-like
lattice for different kernels and applied different methods to deal
with the discontinuous initial conditions. Importantly, we see that
the carbuncle mode is _not_ an instability, since the introduced noise
decreases with resolution even if left without any treatment (left
panel). The convergence is linear. When we use the artificial thermal conduction term (Eq. 34) similar to the one used in hydrodynamics, the order of convergence increases to _∼_ 1 _._ 5 (central panel).
Finally, from the right panel, the convergence of the same problem
with continuous initial conditions is second order once again.
Comparing Figures 9 and 10 demonstrates that the kernel biases remain similar independent of the initial conditions, particle
placement, whether or not diffusion is anisotropic, and whether
or not a discontinuity is present. For the _M_ 6 spline kernel it is
_∼_ 5 _×_ 10 <sup>_−_</sup> <sup>4</sup> .
4 DISCUSSION
Our main finding is that the second law of thermodynamics is the
most important consideration when assessing the stability of diffu
_T_ ( _ρ, φ, t_ ) = _T_ 0+ _T_ 1( _t_ ) exp
- _−_ <sup><u>1</u></sup>
2
��
_._
(41)
If we set the heat conduction tensor to have only one nonzero component _κφφ_ = 1, it means that there should be the only diffusion in
the angular direction. The corresponding tensors in both cylindrical
and cartesian coordinates are given by
<u>1</u>
; _κ_ _xyz_ =
_x_ <sup>2</sup> + _y_ <sup>2</sup>
(42)
_x_ <sup>2</sup> _−xy_ 0
_−yx_ _y_ <sup>2</sup> 0
0 0 0
_κ_ _ρφz_ =
0 0 0
0 1 0
0 0 0
Another possible approach here would be to transform the formulae
for SPH derivatives into cylindrical coordinates. We found similar
results regardless of the method employed.
Figure 8 shows that two first derivative method can handle
the situation where the direction of the heat flow is not aligned
with the particle distribution. For the same problem, the EspanolRevenga method results in numerical instability. The direct derivative method is an acceptable, but risky, choice, as it may become unstable depending on the particle arrangement, the number of neighbours, or kernel involved (we used the _M_ 6 quintic spline here). By
contrast, the proof of increasing entropy we gave in 2.2.4 for the
two first derivatives method does not depend on any of the above.
MNRAS 000, 1–9 (2018)
8 _Biriukov & Price_
N <sup>_−_</sup> <sup>2</sup> iso uniform
10 <sup>_−_</sup> <sup>1</sup>
N <sup>_−_</sup> <sup>2</sup> k _xx_ uniform
M4
M6
<u>M8</u>
10 <sup>1</sup> 10 <sup>2</sup> 10 <sup>3</sup>
log N
10 <sup>_−_</sup> <sup>2</sup>
10 <sup>_−_</sup> <sup>3</sup>
10 <sup>_−_</sup> <sup>4</sup>
Brookshaw
Two 1 <sup>_st_</sup> derivs.
10 <sup>1</sup> 10 <sup>2</sup> 10 <sup>3</sup>
log N
N <sup>_−_</sup> <sup>2</sup> k _xx_ uniform
Two 1 <sup>_st_</sup> derivs.
10 <sup>1</sup> 10 <sup>2</sup> 10 <sup>3</sup>
log N
10 <sup>_−_</sup> <sup>1</sup>
10 <sup>_−_</sup> <sup>2</sup>
10 <sup>_−_</sup> <sup>3</sup>
10 <sup>_−_</sup> <sup>4</sup>
Figure 9. Convergence of error for isotropic and anisotropic diffusion of a Gaussian pulse (Section 3.2). Red dashed line shows the results for two first
derivatives, while the blue dashed line corresponds to Brookshaw method. On the uniform lattice with continuous initial conditions, both methods converge
quadratically (the black dotted line shows the expected slope) until the effect of kernel bias dominates at a resolution _∼_ 10 <sup>3</sup> particles per direction. The kernel
bias can be further eliminated by using smoother kernels with larger compact support radii (right panel).
Discontinuous
No artificial term
N <sup>_−_</sup> <sup><u>1</u></sup>
N <sup>_−_</sup> <sup>2</sup>
M4
M6
M8
Discontinuous
Artificial term
N <sup>_−_</sup> <sup><u>1</u></sup>
N <sup>_−_</sup> <sup>2</sup>
M4
M6
M8
Continuous
No artificial term
10 <sup>_−_</sup> <sup>2</sup>
10 <sup>_−_</sup> <sup>3</sup>
10 <sup>_−_</sup> <sup>4</sup>
N <sup>_−_</sup> <sup><u>1</u></sup>
N <sup>_−_</sup> <sup>2</sup>
M4
M6
M8
10 <sup>_−_</sup> <sup>2</sup>
10 <sup>_−_</sup> <sup>3</sup>
10 <sup>_−_</sup> <sup>4</sup>
10 <sup>1</sup> 10 <sup>2</sup> 10 <sup>3</sup>
log N
10 <sup>1</sup> 10 <sup>2</sup> 10 <sup>3</sup>
log N
10 <sup>1</sup> 10 <sup>2</sup> 10 <sup>3</sup>
log N
Figure 10. Convergence for anisotropic diffusion with a discontinuity in the initial conditions. We used the glass-like lattice and the two first derivatives
method. Here we compare how the initial discontinuity influences the convergence properties. With no special treatment the convergence is linear (left panel).
Adding artificial thermal conduction term improves this to _∼_ 1 _._ 5 (central panel). With continuous initial conditions, the error converges quadratically (right
panel). The kernel bias remains the same across all methods for treating the discontinuity, and independent of the particle placement (convergence on a uniform
lattice can be found on the right panel of Figure 9).
sion operators in SPH. This consideration leads to the conclusion
that the only stable operator for anisotropic heat conduction in SPH
is the ‘two first derivatives’ method described in Section 2.1.5. In
the same time, we emphasised that it is crucial to alternate between
differential and symmetric operators when constructing a two first
derivatives method, in order to preserve positive increase of entropy. This conclusion was already reached by Price et al. (2017) in
the context of physical viscosity and dust-gas mixtures. Similarly,
the need for conjugate derivative operators to satisfy conservation
laws is common in SPH (e.g. Monaghan 1992; Cummins & Rudman 1999; Tricco & Price 2012).
Likewise, the two first derivatives method has already been
used widely, e.g. for dust-gas mixtures Price & Laibe (2015), physical viscosity (Flebbe et al. 1994; Sijacki & Springel 2006), resistive and ambipolar diffusion (Wurster et al. 2014) and the Hall ef
fect (Wurster et al. 2016). In the above papers, the authors found
the method to be the most reliable.
For the case of anisotropic diffusion, our findings give an alternative to the fix suggested by Petkova & Springel (2009). In
particular, using two first derivatives does not require limiting the
anisotropy of the flow in order to achieve stability. The Espa˜nol &
Revenga (2003) method should not be used for anisotropic diffusion.
The main caveat to using two first derivatives is the appearance of carbuncle modes if the initial conditions are discontinuous. The problem disappears with smooth initial conditions. Another solution is to introduce additional artificial conduction term
that acts only when the solution (e.g. in pressure) is discontinuous,
as proposed by Price (2008). These terms are similar to the diffusion that would arise in a Finite Volume scheme when fluxes are
MNRAS 000, 1–9 (2018)
reconstructed at discontinuous interfaces. The ‘integral Godunov’
methods proposed by Hopkins (2017) indeed require flux limiters
to ensure that the entropy is positive. Hopkins (2017) pointed out
that symmetric operators, in general, can result in low-order convergence if the particles are disordered. We found this can be mitigated by the use of smoother spline kernels. We found the Espa˜nol
& Revenga (2003) method to be significantly less accurate.
An interesting follow-up would be to search for a kernel function that satisfies condition (26). If such a kernel exists, it may be
possible to take direct second derivatives that are both stable and
give non-oscillating solutions. An interesting application beyond
the scope of this paper would be to the Magneto-Thermal Instability (see Hopkins 2017).
5 CONCLUSIONS
We analysed the stability of methods for anisotropic diffusion in
SPH. Our conclusions are:
(i) In case of isotropic diffusion the Brookshaw method is stable
and also the most accurate method.
(ii) Two first derivatives are the only method for anisotropic
diffusion where stability is guaranteed. The only caveat is that
smoothing or an artificial diffusion term is required for accurate
treatment of discontinuities.
(iii) We recommend against the use of the Espanol-Revenga
method for anisotropic diffusion because it is not only unstable under certain circumstances but also inaccurate.
(iv) We find that use of the M6 quintic spline kernel reduces the
kernel bias by approximately one order of magnitude compared to
the cubic spline kernel for both isotropic and anisotropic diffusion.
(v) For the two first derivatives method one can use a timestep
3–8 times larger (depending on the choice of kernel) than for the
Brookshaw method, while remaining stable. This offers a potentially large cost saving.
ACKNOWLEDGEMENTS
We thank the organisers of SPHERIC2018 for a useful and stimulating conference in Galway, Ireland. DP acknowledges funding from the Australian Research Council via FT130100034 and
DP180104235.
REFERENCES
Brookshaw L., 1985, Proceedings of the Astronomical Society of Australia,
[6, 207](http://adsabs.harvard.edu/abs/1985PASAu...6..207B)
[Cleary P. W., Monaghan J. J., 1999, Journal of Computational Physics, 148,](http://dx.doi.org/10.1006/jcph.1998.6118)
[227](http://adsabs.harvard.edu/abs/1999JCoPh.148..227C)
[Cummins S. J., Rudman M., 1999, Journal of Computational Physics, 152,](http://dx.doi.org/10.1006/jcph.1999.6246)
[584](http://adsabs.harvard.edu/abs/1999JCoPh.152..584C)
[Dehnen W., Aly H., 2012, MNRAS, 425, 1068](http://dx.doi.org/10.1111/j.1365-2966.2012.21439.x)
[Espa˜nol P., Revenga M., 2003, Phys. Rev. E, 67, 026705](http://dx.doi.org/10.1103/PhysRevE.67.026705)
Flebbe O., Muenzel S., Herold H., Riffert H., Ruder H., 1994, [ApJ,](http://dx.doi.org/10.1086/174526) [431,](http://adsabs.harvard.edu/abs/1994ApJ...431..754F)
[754](http://adsabs.harvard.edu/abs/1994ApJ...431..754F)
[Forman M. A., Gleeson L. J., 1975, Ap&SS, 32, 77](http://dx.doi.org/10.1007/BF00646218)
[Gingold R. A., Monaghan J. J., 1977, MNRAS, 181, 375](http://dx.doi.org/10.1093/mnras/181.3.375)
[Girichidis P., et al., 2016, ApJ, 816, L19](http://dx.doi.org/10.3847/2041-8205/816/2/L19)
[Hopkins P. F., 2017, MNRAS, 466, 3387](http://dx.doi.org/10.1093/mnras/stw3306)
Korzilius S., Schilders W., Anthonissen M., Jan 2017, Journal of Applied
Mathematics and Physics, pp 168–184
[Lucy L. B., 1977, AJ, 82, 1013](http://dx.doi.org/10.1086/112164)
MNRAS 000, 1–9 (2018)
_Anisotropic diffusion in SPH_ 9
[Monaghan J. J., 1992, ARA&A, 30, 543](http://dx.doi.org/10.1146/annurev.aa.30.090192.002551)
[Monaghan J. J., 2002, MNRAS, 335, 843](http://dx.doi.org/10.1046/j.1365-8711.2002.05678.x)
[Monaghan J. J., 2005, Reports on Progress in Physics, 68, 1703](http://dx.doi.org/10.1088/0034-4885/68/8/R01)
[Parrish I. J., Stone J. M., 2005, ApJ, 633, 334](http://dx.doi.org/10.1086/444589)
[Petkova M., Springel V., 2009, MNRAS, 396, 1383](http://dx.doi.org/10.1111/j.1365-2966.2009.14843.x)
[Price D. J., 2008, Journal of Computational Physics, 227, 10040](http://dx.doi.org/10.1016/j.jcp.2008.08.011)
[Price D. J., 2010, MNRAS, 401, 1475](http://dx.doi.org/10.1111/j.1365-2966.2009.15763.x)
[Price D. J., 2012, Journal of Computational Physics, 231, 759](http://dx.doi.org/10.1016/j.jcp.2010.12.011)
[Price D. J., Laibe G., 2015, MNRAS, 451, 813](http://dx.doi.org/10.1093/mnras/stv996)
Price D. J., et al., 2017, PHANTOM: Smoothed particle hydrodynamics
and magnetohydrodynamics code, Astrophysics Source Code Library
(ascl:1709.002)
[Sijacki D., Springel V., 2006, MNRAS, 371, 1025](http://dx.doi.org/10.1111/j.1365-2966.2006.10752.x)
[Springel V., Hernquist L., 2002, MNRAS, 333, 649](http://dx.doi.org/10.1046/j.1365-8711.2002.05445.x)
[Tricco T. S., Price D. J., 2012, Journal of Computational Physics, 231, 7214](http://dx.doi.org/10.1016/j.jcp.2012.06.039)
[Wurster J., Price D., Ayliffe B., 2014, MNRAS, 444, 1104](http://dx.doi.org/10.1093/mnras/stu1524)
[Wurster J., Price D. J., Bate M. R., 2016, MNRAS, 457, 1037](http://dx.doi.org/10.1093/mnras/stw013)
This paper has been typeset from a TEX/L <sup>A</sup> TEX file prepared by the author.
섹션 본문
섹션 본문이 없습니다.
참고문헌
참고문헌 정보가 없습니다.