Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
n-body_methods
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
CodeVault
hpc-kernels
n-body_methods
Commits
8f7b6919
Commit
8f7b6919
authored
8 years ago
by
Thomas Steinreiter
Browse files
Options
Downloads
Patches
Plain Diff
* removed unused Node::parent
parent
1b45157d
Branches
Branches containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
bhtree_mpi/src/datastructures/BarnesHutTree.cpp
+1
-2
1 addition, 2 deletions
bhtree_mpi/src/datastructures/BarnesHutTree.cpp
bhtree_mpi/src/datastructures/Node.cpp
+1
-1
1 addition, 1 deletion
bhtree_mpi/src/datastructures/Node.cpp
with
2 additions
and
3 deletions
bhtree_mpi/src/datastructures/BarnesHutTree.cpp
+
1
−
2
View file @
8f7b6919
...
...
@@ -16,7 +16,7 @@ namespace nbody {
return
8
;
}
//update upper tree n
d
oes according to moved particles
//update upper tree no
d
es according to moved particles
void
BarnesHutTree
::
update
()
{
//iterate for updating representatives
Node
*
current
=
nodes
->
prev
;
...
...
@@ -64,7 +64,6 @@ namespace nbody {
for
(
auto
it
=
std
::
begin
(
subboxes
);
it
!=
std
::
end
(
subboxes
);
it
++
)
{
Node
*
child
=
new
Node
(
current
->
tree
);
child
->
parent
=
current
;
child
->
bb
=
*
it
;
child
->
bodies
=
it
->
copyBodies
(
current
->
bodies
);
child
->
nextSibling
=
nullptr
;
...
...
This diff is collapsed.
Click to expand it.
bhtree_mpi/src/datastructures/Node.cpp
+
1
−
1
View file @
8f7b6919
...
...
@@ -157,7 +157,7 @@ namespace nbody {
for
(
std
::
size_t
i
=
0
;
i
<
3
;
i
++
)
{
distance
+=
(
representative
.
position
[
i
]
-
body
.
position
[
i
])
*
(
representative
.
position
[
i
]
-
body
.
position
[
i
]);
}
return
sqrt
(
distance
)
>
getL
();
return
sqrt
(
distance
)
>
getL
();
// TODO(steinret): do squared comparison
}
//check if node is sufficient for force evaluation for all bodies in box
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
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