Commit d80ed507 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Added configuration option to change the order of the multipole scheme.

parent 0d2a74ab
......@@ -788,6 +788,15 @@ case "$with_potential" in
;;
esac
# Gravity multipole order
AC_ARG_WITH([multipole-order],
[AS_HELP_STRING([--with-multipole-order=<order>],
[order of the multipole and gravtiational field expansion @<:@ default: 2@:>@]
)],
[with_multipole_order="$withval"],
[with_multipole_order="2"]
)
AC_DEFINE_UNQUOTED([SELF_GRAVITY_MULTIPOLE_ORDER], [$with_multipole_order], [Multipole order])
# Check for git, needed for revision stamps.
......@@ -835,6 +844,7 @@ AC_MSG_RESULT([
Riemann solver : $with_riemann
Cooling function : $with_cooling
External potential : $with_potential
Multipole order : $with_multipole_order
Task debugging : $enable_task_debugging
Debugging checks : $enable_debugging_checks
......
......@@ -110,8 +110,7 @@ INLINE static void gravity_reset(struct gravity_tensors *m) {
* @param m The #multipole.
* @param dt The drift time-step.
*/
INLINE static void gravity_drift(struct gravity_tensors *m,
double dt) {
INLINE static void gravity_drift(struct gravity_tensors *m, double dt) {
/* Move the whole thing according to bulk motion */
m->CoM[0] += m->m_pole.vel[0];
......@@ -119,7 +118,6 @@ INLINE static void gravity_drift(struct gravity_tensors *m,
m->CoM[2] += m->m_pole.vel[2];
}
INLINE static void gravity_field_tensors_init(struct gravity_tensors *m) {
bzero(&m->a_x, sizeof(struct acc_tensor));
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment