From bca1f35efdad68e3bbfc6e883b98cb9291679938 Mon Sep 17 00:00:00 2001 From: Matthieu Schaller <schaller@strw.leidenuniv.nl> Date: Tue, 17 Sep 2019 18:12:15 +0200 Subject: [PATCH] Prevent the code from using the mass-weighted neighbour number definition in the Gizmo cases. --- src/hydro_properties.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/hydro_properties.c b/src/hydro_properties.c index a21530528c..db4c60eb04 100644 --- a/src/hydro_properties.c +++ b/src/hydro_properties.c @@ -102,6 +102,12 @@ void hydro_props_init(struct hydro_props *p, p->use_mass_weighted_num_ngb = parser_get_opt_param_int(params, "SPH:use_mass_weighted_num_ngb", 0); + if (p->use_mass_weighted_num_ngb) { +#if defined(GIZMO_MFV_SPH) || defined(GIZMO_MFM_SPH) || defined(SHADOWFAX_SPH) + error("Can't use alternative neighbour definition with this scheme!"); +#endif + } + /* Time integration properties */ p->CFL_condition = parser_get_param_float(params, "SPH:CFL_condition"); const float max_volume_change = parser_get_opt_param_float( -- GitLab