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
61d02e00
Commit
61d02e00
authored
8 years ago
by
James Willis
Browse files
Options
Downloads
Patches
Plain Diff
Comments
parent
200dcdb9
No related branches found
No related tags found
1 merge request
!287
Particle caching
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/hydro/Gadget2/hydro_iact.h
+2
-1
2 additions, 1 deletion
src/hydro/Gadget2/hydro_iact.h
src/kernel_hydro.h
+2
-1
2 additions, 1 deletion
src/kernel_hydro.h
with
4 additions
and
2 deletions
src/hydro/Gadget2/hydro_iact.h
+
2
−
1
View file @
61d02e00
...
@@ -403,7 +403,7 @@ runner_iact_nonsym_2_vec_density(float *R2, float *Dx, float *Dy, float *Dz, vec
...
@@ -403,7 +403,7 @@ runner_iact_nonsym_2_vec_density(float *R2, float *Dx, float *Dy, float *Dz, vec
vector
dvdr2
;
vector
dvdr2
;
vector
curlvrx2
,
curlvry2
,
curlvrz2
;
vector
curlvrx2
,
curlvry2
,
curlvrz2
;
/*
Get
the
masse
s. */
/*
Fill
the
vector
s. */
mj
.
v
=
vec_load
(
Mj
);
mj
.
v
=
vec_load
(
Mj
);
mj2
.
v
=
vec_load
(
&
Mj
[
VEC_SIZE
]);
mj2
.
v
=
vec_load
(
&
Mj
[
VEC_SIZE
]);
vjx
.
v
=
vec_load
(
Vjx
);
vjx
.
v
=
vec_load
(
Vjx
);
...
@@ -430,6 +430,7 @@ runner_iact_nonsym_2_vec_density(float *R2, float *Dx, float *Dy, float *Dz, vec
...
@@ -430,6 +430,7 @@ runner_iact_nonsym_2_vec_density(float *R2, float *Dx, float *Dy, float *Dz, vec
xi
.
v
=
vec_mul
(
r
.
v
,
hi_inv
.
v
);
xi
.
v
=
vec_mul
(
r
.
v
,
hi_inv
.
v
);
xi2
.
v
=
vec_mul
(
r_2
.
v
,
hi_inv
.
v
);
xi2
.
v
=
vec_mul
(
r_2
.
v
,
hi_inv
.
v
);
/* Calculate the kernel for two particles. */
kernel_deval_2_vec
(
&
xi
,
&
wi
,
&
wi_dx
,
&
xi2
,
&
wi2
,
&
wi_dx2
);
kernel_deval_2_vec
(
&
xi
,
&
wi
,
&
wi_dx
,
&
xi2
,
&
wi2
,
&
wi_dx2
);
/* Compute dv. */
/* Compute dv. */
...
...
This diff is collapsed.
Click to expand it.
src/kernel_hydro.h
+
2
−
1
View file @
61d02e00
...
@@ -363,6 +363,7 @@ __attribute__((always_inline)) INLINE static void kernel_deval_vec(
...
@@ -363,6 +363,7 @@ __attribute__((always_inline)) INLINE static void kernel_deval_vec(
dw_dx
->
v
*
kernel_constant_vec
.
v
*
kernel_gamma_inv_dim_plus_one_vec
.
v
;
dw_dx
->
v
*
kernel_constant_vec
.
v
*
kernel_gamma_inv_dim_plus_one_vec
.
v
;
}
}
/* Define constant vectors for the Wendland C2 kernel coefficients. */
#ifdef WENDLAND_C2_KERNEL
#ifdef WENDLAND_C2_KERNEL
static
const
vector
c0
=
FILL_VEC
(
4
.
f
);
static
const
vector
c0
=
FILL_VEC
(
4
.
f
);
static
const
vector
c1
=
FILL_VEC
(
-
15
.
f
);
static
const
vector
c1
=
FILL_VEC
(
-
15
.
f
);
...
@@ -373,7 +374,7 @@ static const vector c5 = FILL_VEC(1.f);
...
@@ -373,7 +374,7 @@ static const vector c5 = FILL_VEC(1.f);
#endif
#endif
/**
/**
* @brief Computes the kernel function and its derivative using
two
interleaved vectors.
* @brief Computes the kernel function and its derivative
for two particles
using interleaved vectors.
*
*
* Return 0 if $u > \\gamma = H/h$
* Return 0 if $u > \\gamma = H/h$
*
*
...
...
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