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
dd21e14d
Commit
dd21e14d
authored
7 years ago
by
James Willis
Browse files
Options
Downloads
Patches
Plain Diff
Comments.
parent
c145af2f
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!348
Fix pair vec
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/runner_doiact_vec.c
+5
-2
5 additions, 2 deletions
src/runner_doiact_vec.c
with
5 additions
and
2 deletions
src/runner_doiact_vec.c
+
5
−
2
View file @
dd21e14d
...
...
@@ -752,7 +752,7 @@ void runner_dopair1_density_vec(struct runner *r, struct cell *ci,
if
(
cell_is_active
(
ci
,
e
))
{
/* Loop over the parts in ci. */
/* Loop over the parts in ci
until nothing is within range in cj
. */
for
(
int
pid
=
count_i
-
1
;
pid
>=
first_pi_loop
&&
max_ind_j
>=
0
;
pid
--
)
{
/* Get a hold of the ith part in ci. */
...
...
@@ -762,6 +762,7 @@ void runner_dopair1_density_vec(struct runner *r, struct cell *ci,
/* Set the cache index. */
int
ci_cache_idx
=
pid
-
first_pi_align
;
/* Skip this particle if no particle in cj is within range of it. */
const
float
hi
=
ci_cache
->
h
[
ci_cache_idx
];
const
double
di_test
=
sort_i
[
pid
].
d
+
hi
*
kernel_gamma
+
dx_max
-
rshift
;
if
(
di_test
<
dj_min
)
continue
;
...
...
@@ -888,7 +889,8 @@ void runner_dopair1_density_vec(struct runner *r, struct cell *ci,
}
if
(
cell_is_active
(
cj
,
e
))
{
/* Loop over the parts in cj. */
/* Loop over the parts in cj until nothing is within range in ci. */
for
(
int
pjd
=
0
;
pjd
<=
last_pj_loop
&&
max_ind_i
<
count_i
;
pjd
++
)
{
/* Get a hold of the jth part in cj. */
...
...
@@ -899,6 +901,7 @@ void runner_dopair1_density_vec(struct runner *r, struct cell *ci,
int
cj_cache_idx
=
pjd
;
/*TODO: rshift term. */
/* Skip this particle if no particle in ci is within range of it. */
const
float
hj
=
cj_cache
->
h
[
cj_cache_idx
];
const
double
dj_test
=
sort_j
[
pjd
].
d
-
hj
*
kernel_gamma
-
dx_max
-
rshift
;
if
(
dj_test
>
di_max
)
continue
;
...
...
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