public function converged(array $gradient, array $coefficients) : bool;
/** * @param array $gradient * @param array $coefficients * @return bool */ public function converged(array $gradient, array $coefficients) : bool { $steppedGradient = []; foreach ($gradient as $i => $slope) { $steppedGradient[] = $this->schedule->step($i) * $slope; } return $this->criteria->converged($steppedGradient, $coefficients); }