Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
SWIFT
SWIFTsim
Commits
e9566379
Commit
e9566379
authored
Oct 21, 2016
by
Matthieu Schaller
Browse files
Only check 2nd order multipole terms if they exist
parent
15d0e8ca
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/cell.c
View file @
e9566379
...
...
@@ -827,6 +827,7 @@ void cell_check_multipole(struct cell *c, void *data) {
error
(
"Multipole CoM are different (%12.15e vs. %12.15e"
,
ma
.
CoM
[
k
],
mb
.
CoM
[
k
]);
#if const_gravity_multipole_order >= 2
if
(
fabsf
(
ma
.
I_xx
-
mb
.
I_xx
)
/
fabsf
(
ma
.
I_xx
+
mb
.
I_xx
)
>
1e-5
&&
ma
.
I_xx
>
1e-9
)
error
(
"Multipole I_xx are different (%12.15e vs. %12.15e)"
,
ma
.
I_xx
,
...
...
@@ -851,6 +852,7 @@ void cell_check_multipole(struct cell *c, void *data) {
ma
.
I_yz
>
1e-9
)
error
(
"Multipole I_yz are different (%12.15e vs. %12.15e)"
,
ma
.
I_yz
,
mb
.
I_yz
);
#endif
}
}
...
...
Write
Preview
Supports
Markdown
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!
Cancel
Please
register
or
sign in
to comment