Skip to content
Snippets Groups Projects
Commit 8aef100f authored by Josh Borrow's avatar Josh Borrow
Browse files

Added check to see if a_begin < a_end

parent cee4c633
No related branches found
No related tags found
1 merge request!626Added check to see if a_begin < a_end
......@@ -487,6 +487,11 @@ void cosmology_init(struct swift_params *params, const struct unit_system *us,
c->time_base = (c->log_a_end - c->log_a_begin) / max_nr_timesteps;
c->time_base_inv = 1. / c->time_base;
/* If a_begin == a_end we hang */
if (c->a_begin >= c->a_end)
error("a_begin must be strictly before (and not equal to) a_end");
/* Construct derived quantities */
/* Curvature density (for closure) */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment