-
Notifications
You must be signed in to change notification settings - Fork 248
Open
Labels
Description
We have code such as this:
const double t = (this->simulator_is_past_initialization()) ? this->get_time() : 0.0;
This code is used because if we're still initializing the simulator, the current time is not yet available. The line above then simply assumes that the current time is zero -- but that's dangerous, because the start time might in fact be something else than zero, as witnessed by
start_time = prm.get_double ("Start time");
if (convert_to_years == true)
start_time *= year_in_seconds;
The right thing for these places to do is to query this->get_start_time()
. That function doesn't exist yet, but I'm going to add that next.