A computer program product for modifying a crankshaft angle of a crankshaft in an internal combustion engine (ICE) of a vehicle, the ICE including (i) the crankshaft, and (ii) a crankshaft angle sensor, the vehicle including (i) an energy converter configured to be connected to the crankshaft of the ICE, and (ii) an energy storage unit configured to deliver energy to the energy converter when the energy converter acts as a motor, and to store energy output from the energy converter when the energy converter acts as a generator, the computer program product comprising a non-transitory computer readable medium tangibly embodying non-transitory computer program instructions thereon, that, when executed, cause one or more computing devices to:
- (a) calculate a current ideal crankshaft angle, wherein the current ideal crankshaft angle changes with respect to time;
- (b) calculate a current slip angle using an output of the crankshaft angle sensor;
- (c) activate the energy converter as a motor to increase the current crankshaft angle when the current slip angle is greater than a predetermined upper threshold value;
- and
- (d) activate the energy converter as a generator to decrease the current crankshaft angle when the current slip angle is less than a predetermined lower threshold value.