Skip to content
Snippets Groups Projects
Commit c108da64 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Correct multipole order guard

parent 8f78bee6
No related branches found
No related tags found
1 merge request!324Gravity multi dt
...@@ -606,7 +606,7 @@ INLINE static int gravity_multipole_equal(const struct gravity_tensors *ga, ...@@ -606,7 +606,7 @@ INLINE static int gravity_multipole_equal(const struct gravity_tensors *ga,
return 0; return 0;
} }
#endif #endif
#if SELF_GRAVITY_MULTIPOLE_ORDER > 2 #if SELF_GRAVITY_MULTIPOLE_ORDER > 3
/* Check 4th order terms */ /* Check 4th order terms */
if (fabsf(ma->M_400 + mb->M_400) > 1e-6 * ma->M_000 && if (fabsf(ma->M_400 + mb->M_400) > 1e-6 * ma->M_000 &&
fabsf(ma->M_400 - mb->M_400) / fabsf(ma->M_400 + mb->M_400) > tolerance) { fabsf(ma->M_400 - mb->M_400) / fabsf(ma->M_400 + mb->M_400) > tolerance) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment