Lines Matching refs:sigfigs
110 $sigfigs = $this->getSigFigs($n);
111 if ($sigfigs < $this->outputPrecision) {
112 $sigfigs = $this->outputPrecision;
178 $n = $this->round($n, $sigfigs);
197 $sigfigs = strlen(rtrim($n, '0'));
199 $sigfigs = strlen(ltrim($n, '0.')); // eliminate extra decimal character
201 $sigfigs--;
204 return $sigfigs;
259 * @param int $sigfigs
262 private function round($n, $sigfigs) argument
265 $rp = $sigfigs - $new_log - 1; // Number of decimal places needed
274 $n = bcadd($n, $neg . '5' . str_repeat('0', $new_log - $sigfigs), 0);
275 … $n = substr($n, 0, $sigfigs + strlen($neg)) . str_repeat('0', $new_log - $sigfigs + 1);
279 return $this->scale(round($n, $sigfigs - $new_log - 1), $rp + 1);