From 4e46d20a86fa1838a3b15786533bc651f7b33267 Mon Sep 17 00:00:00 2001 From: Pedro Gonnet <pedro.gonnet@durham.ac.uk> Date: Mon, 22 Apr 2013 15:19:08 +0000 Subject: [PATCH] fix massive bug. Former-commit-id: ea90cfb6f63c2acff59c2e576f51c22d98a0efd6 --- src/runner.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runner.c b/src/runner.c index e8a4e0170c..b6d82b5de4 100644 --- a/src/runner.c +++ b/src/runner.c @@ -378,7 +378,7 @@ void runner_doghost ( struct runner *r , struct cell *c ) { /* Final operation on the density. */ p->rho = rho = ih * ih2 * ( p->rho + p->mass*kernel_root ); - p->rho_dh = rho_dh = p->rho_dh * ih4; + p->rho_dh = rho_dh = ( p->rho_dh - 3.0f*p->mass*kernel_root ) * ih4; wcount = ( p->density.wcount + kernel_root ) * ( 4.0f / 3.0 * M_PI * kernel_gamma3 ); wcount_dh = p->density.wcount_dh * ih * ( 4.0f / 3.0 * M_PI * kernel_gamma3 ); -- GitLab