Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SWIFTsim
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SWIFT
SWIFTsim
Commits
c7960649
Commit
c7960649
authored
7 years ago
by
Josh Borrow
Browse files
Options
Downloads
Patches
Plain Diff
Added basic theory (equations essentially) behind PUSPH here
parent
5779ee54
No related branches found
No related tags found
1 merge request
!540
Add Pressure-Energy (P-U) SPH
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
theory/SPH/Flavours/sph_flavours.tex
+64
-1
64 additions, 1 deletion
theory/SPH/Flavours/sph_flavours.tex
theory/SPH/swift_sph.tex
+1
-1
1 addition, 1 deletion
theory/SPH/swift_sph.tex
with
65 additions
and
2 deletions
theory/SPH/Flavours/sph_flavours.tex
+
64
−
1
View file @
c7960649
...
...
@@ -377,7 +377,70 @@ itself is \emph{not} updated.
\subsection
{
Pressure-Energy SPH
}
\label
{
sec:sph:pu
}
Section 2.2.2 of
\cite
{
Hopkins2013
}
.
\\
\tbd
Section 2.2.2 of
\cite
{
Hopkins2013
}
describes the equations for Pressure-Energy
(P-U) SPH; they are reproduced here with some more details.
P-U SPH depends on the calculation of a smoothed pressure, and follows the
evolution of the internal energy, as opposed to the entropy.
For P-U, the following choice of parameters in the formalism of
\S
\ref
{
sec:derivation
}
provides convenient properties:
\begin{align}
x
_
i =
&
(
\gamma
- 1) m
_
i u
_
i~,
\\
\tilde
{
x
}_
i =
&
1,
\label
{
eq:sph:pu:xichoice
}
\end{align}
leading to the following requirements to ensure correct volume elements:
\begin{align}
y
_
i =
&
\sum
_{
j
}
(
\gamma
- 1) m
_
j u
_
j W
_{
ij
}
=
\bar
{
P
}_
i,
\\
\tilde
{
y
}_
i =
&
\sum
_{
j
}
W
_{
ij
}
=
\bar
{
n
}_
i,
\\
\label
{
eq:sph:pu:yichoice
}
\end{align}
with the resulting variables representing a smoothed pressure and particle
number density. This choice of variables leads to the following equation of
motion:
\begin{align}
\frac
{
\mathrm
{
d
}
\mathbf
{
v
}_
i
}{
\mathrm
{
d
}
t
}
= -
\sum
_
j (
\gamma
- 1)
^
2 m
_
j u
_
j u
_
i
&
\left
[
\frac
{
f
_{
ij
}}{
\bar
{
P
}_
i
}
\nabla
_
i W
_{
ij
}
(h
_
i) ~+
\right
.
\\
&
\frac
{
f
_{
ji
}}{
\bar
{
P
}_
j
}
\nabla
_
i W
_{
ji
}
(h
_
j) ~+
\\
&
\left
.
\nu
_{
ij
}
\bar
{
\nabla
_
i W
_{
ij
}}
\right
]~.
\label
{
eq:sph:pu:eom
}
\end{align}
which includes the Monaghan artificial viscosity term and Balsara switch in
the final term.
The
$
h
$
-terms are given as
\begin{align}
f
_{
ij
}
= 1 -
&
\left
[
\frac
{
h
_
i
}{
n
_
d (
\gamma
- 1)
\bar
{
n
}_
i
\left\{
m
_
j u
_
j
\right\}
}
\frac
{
\partial
\bar
{
P
}_
i
}{
\partial
h
_
i
}
\right
]
\times
\\
&
\left
( 1 +
\frac
{
h
_
i
}{
n
_
d
\bar
{
n
}_
i
}
\frac
{
\partial
\bar
{
n
}_
i
}{
\partial
h
_
i
}
\right
)
^{
-1
}
\label
{
eq:sph:pu:fij
}
\end{align}
with
$
n
_
d
$
the number of dimensions. In practice, the majority of
$
f
_{
ij
}$
is
precomputed in
{
\tt
hydro
\_
prepare
\_
force
}
as only the curly-bracketed term
depends on the
$
j
$
particle. This cuts out on the majority of operations,
including expensive divisions.
In a similar fashion to
\MinimalSPH
, the internal energy must also be
evolved. Following
\cite
{
Hopkins2013
}
, this is calculated as
\begin{align}
\frac
{
\mathrm
{
d
}
u
_
i
}{
\mathrm
{
d
}
t
}
=
\sum
_
j (
\gamma
- 1)
^
2 m
_
j u
_
j u
_
i
\frac
{
f
_{
ij
}}{
\bar
{
P
}_
i
}
(
\mathbf
{
v
}_
i -
\mathbf
{
v
}_
j)
\cdot
\nabla
_
i W
_{
ij
}
(h
_
i)~.
\label
{
eq:sph:pu:dudt
}
\end{align}
\subsubsection
{
Time integration
}
Time integration follows exactly the same scheme as
\MinimalSPH
.
\subsubsection
{
Particle properties prediction
}
The prediciton of particle properties follows exactly the same scheme as
\MinimalSPH
.
\subsection
{
Anarchy SPH
}
Dalla Vecchia (
\textit
{
in prep.
}
), also described in section 2.2.2 of
\cite
{
Schaller2015
}
.
\\
...
...
This diff is collapsed.
Click to expand it.
theory/SPH/swift_sph.tex
+
1
−
1
View file @
c7960649
...
...
@@ -29,7 +29,7 @@
\section
{
Equation of state
}
\input
{
EoS/eos
}
\section
{
Derivation of the Equation of Motion
}
\section
{
Derivation of the Equation of Motion
}
\label
{
sec:derivation
}
\input
{
Derivation/sph
_
derivation.tex
}
\section
{
SPH flavours
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment