Commit ea83c29d authored by Stuart McAlpine's avatar Stuart McAlpine Committed by Matthieu Schaller
Browse files

Updated + to +=

parent 50ef86b9
......@@ -216,27 +216,21 @@ __attribute__((always_inline)) INLINE static void runner_iact_grav_pm_full(
#if SELF_GRAVITY_MULTIPOLE_ORDER > 3
/* 4th order contributions */
*f_x = m->M_004 * d.D_104 + m->M_013 * d.D_113 + m->M_022 * d.D_122
*f_x += m->M_004 * d.D_104 + m->M_013 * d.D_113 + m->M_022 * d.D_122
+ m->M_031 * d.D_131 + m->M_040 * d.D_140 + m->M_103 * d.D_203
+ m->M_112 * d.D_212 + m->M_121 * d.D_221 + m->M_130 * d.D_230
+ m->M_202 * d.D_302 + m->M_211 * d.D_311 + m->M_220 * d.D_320
+ m->M_301 * d.D_401 + m->M_310 * d.D_410 + m->M_400 * d.D_500;
*f_y = m->M_004 * d.D_014 + m->M_013 * d.D_023 + m->M_022 * d.D_032
*f_y += m->M_004 * d.D_014 + m->M_013 * d.D_023 + m->M_022 * d.D_032
+ m->M_031 * d.D_041 + m->M_040 * d.D_050 + m->M_103 * d.D_113
+ m->M_112 * d.D_122 + m->M_121 * d.D_131 + m->M_130 * d.D_140
+ m->M_202 * d.D_212 + m->M_211 * d.D_221 + m->M_220 * d.D_230
+ m->M_301 * d.D_311 + m->M_310 * d.D_320 + m->M_400 * d.D_410;
*f_z = m->M_004 * d.D_005 + m->M_013 * d.D_014 + m->M_022 * d.D_023
*f_z += m->M_004 * d.D_005 + m->M_013 * d.D_014 + m->M_022 * d.D_023
+ m->M_031 * d.D_032 + m->M_040 * d.D_041 + m->M_103 * d.D_104
+ m->M_112 * d.D_113 + m->M_121 * d.D_122 + m->M_130 * d.D_131
+ m->M_202 * d.D_203 + m->M_211 * d.D_212 + m->M_220 * d.D_221
+ m->M_301 * d.D_302 + m->M_310 * d.D_311 + m->M_400 * d.D_401;
*pot = m->M_004 * d.D_004 + m->M_013 * d.D_013 + m->M_022 * d.D_022
+ m->M_031 * d.D_031 + m->M_040 * d.D_040 + m->M_103 * d.D_103
+ m->M_112 * d.D_112 + m->M_121 * d.D_121 + m->M_130 * d.D_130
+ m->M_202 * d.D_202 + m->M_211 * d.D_211 + m->M_220 * d.D_220
+ m->M_301 * d.D_301 + m->M_310 * d.D_310 + m->M_400 * d.D_400;
#endif
/* Take care of the the sign convention */
......@@ -343,27 +337,21 @@ __attribute__((always_inline)) INLINE static void runner_iact_grav_pm_truncated(
#if SELF_GRAVITY_MULTIPOLE_ORDER > 3
/* 4th order contributions */
*f_x = m->M_004 * d.D_104 + m->M_013 * d.D_113 + m->M_022 * d.D_122
*f_x += m->M_004 * d.D_104 + m->M_013 * d.D_113 + m->M_022 * d.D_122
+ m->M_031 * d.D_131 + m->M_040 * d.D_140 + m->M_103 * d.D_203
+ m->M_112 * d.D_212 + m->M_121 * d.D_221 + m->M_130 * d.D_230
+ m->M_202 * d.D_302 + m->M_211 * d.D_311 + m->M_220 * d.D_320
+ m->M_301 * d.D_401 + m->M_310 * d.D_410 + m->M_400 * d.D_500;
*f_y = m->M_004 * d.D_014 + m->M_013 * d.D_023 + m->M_022 * d.D_032
*f_y += m->M_004 * d.D_014 + m->M_013 * d.D_023 + m->M_022 * d.D_032
+ m->M_031 * d.D_041 + m->M_040 * d.D_050 + m->M_103 * d.D_113
+ m->M_112 * d.D_122 + m->M_121 * d.D_131 + m->M_130 * d.D_140
+ m->M_202 * d.D_212 + m->M_211 * d.D_221 + m->M_220 * d.D_230
+ m->M_301 * d.D_311 + m->M_310 * d.D_320 + m->M_400 * d.D_410;
*f_z = m->M_004 * d.D_005 + m->M_013 * d.D_014 + m->M_022 * d.D_023
*f_z += m->M_004 * d.D_005 + m->M_013 * d.D_014 + m->M_022 * d.D_023
+ m->M_031 * d.D_032 + m->M_040 * d.D_041 + m->M_103 * d.D_104
+ m->M_112 * d.D_113 + m->M_121 * d.D_122 + m->M_130 * d.D_131
+ m->M_202 * d.D_203 + m->M_211 * d.D_212 + m->M_220 * d.D_221
+ m->M_301 * d.D_302 + m->M_310 * d.D_311 + m->M_400 * d.D_401;
*pot = m->M_004 * d.D_004 + m->M_013 * d.D_013 + m->M_022 * d.D_022
+ m->M_031 * d.D_031 + m->M_040 * d.D_040 + m->M_103 * d.D_103
+ m->M_112 * d.D_112 + m->M_121 * d.D_121 + m->M_130 * d.D_130
+ m->M_202 * d.D_202 + m->M_211 * d.D_211 + m->M_220 * d.D_220
+ m->M_301 * d.D_301 + m->M_310 * d.D_310 + m->M_400 * d.D_400;
#endif
/* Take care of the the sign convention */
*f_x *= -1.f;
......
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