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

Make the EAGLE chemistry interaction functions only compute W and not also...

Make the EAGLE chemistry interaction functions only compute W and not also dW/dr as it is not required.
parent 646e4906
No related branches found
No related tags found
No related merge requests found
......@@ -44,8 +44,8 @@ __attribute__((always_inline)) INLINE static void runner_iact_chemistry(
struct chemistry_part_data *chi = &pi->chemistry_data;
struct chemistry_part_data *chj = &pj->chemistry_data;
float wi, wi_dx;
float wj, wj_dx;
float wi;
float wj;
/* Get the masses. */
const float mi = pi->mass;
......@@ -56,11 +56,11 @@ __attribute__((always_inline)) INLINE static void runner_iact_chemistry(
/* Compute the kernel function for pi */
const float ui = r / hi;
kernel_deval(ui, &wi, &wi_dx);
kernel_eval(ui, &wi);
/* Compute the kernel function for pj */
const float uj = r / hj;
kernel_deval(uj, &wj, &wj_dx);
kernel_eval(uj, &wj);
/* Compute contribution to the smooth metallicity */
for (int i = 0; i < chemistry_element_count; i++) {
......@@ -103,7 +103,7 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_chemistry(
struct chemistry_part_data *chi = &pi->chemistry_data;
const struct chemistry_part_data *chj = &pj->chemistry_data;
float wi, wi_dx;
float wi;
/* Get the masses. */
const float mj = pj->mass;
......@@ -113,7 +113,7 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_chemistry(
/* Compute the kernel function for pi */
const float ui = r / hi;
kernel_deval(ui, &wi, &wi_dx);
kernel_eval(ui, &wi);
/* Compute contribution to the smooth metallicity */
for (int i = 0; i < chemistry_element_count; i++) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment