Lines Matching refs:p

67     protected $p;  variable in phpseclib3\\Crypt\\EC\\BaseCurves\\Prime
163 $this->p = [
184 return $this->p;
192 protected function jacobianAddPointMixedXY(array $p, array $q) argument
194 list($u1, $s1) = $p;
200 return $this->doublePoint($p);
224 protected function jacobianAddPointMixedX(array $p, array $q) argument
226 list($u1, $s1, $z1) = $p;
237 return $this->doublePoint($p);
260 protected function jacobianAddPoint(array $p, array $q) argument
262 list($x1, $y1, $z1) = $p;
276 return $this->doublePoint($p);
299 public function addPoint(array $p, array $q) argument
305 if (!count($p) || !count($q)) {
309 if (count($p)) {
310 return $p;
316 if (isset($p[2]) && isset($q[2])) {
317 if (isset($p['fresh']) && isset($q['fresh'])) {
318 return $this->jacobianAddPointMixedXY($p, $q);
320 if (isset($p['fresh'])) {
321 return $this->jacobianAddPointMixedX($q, $p);
324 return $this->jacobianAddPointMixedX($p, $q);
326 return $this->jacobianAddPoint($p, $q);
329 if (isset($p[2]) || isset($q[2])) {
333 if ($p[0]->equals($q[0])) {
334 if (!$p[1]->equals($q[1])) {
337 list($numerator, $denominator) = $this->doublePointHelper($p);
340 $numerator = $q[1]->subtract($p[1]);
341 $denominator = $q[0]->subtract($p[0]);
344 $x = $slope->multiply($slope)->subtract($p[0])->subtract($q[0]);
345 $y = $slope->multiply($p[0]->subtract($x))->subtract($p[1]);
355 protected function doublePointHelper(array $p) argument
357 $numerator = $this->three->multiply($p[0])->multiply($p[0])->add($this->a);
358 $denominator = $this->two->multiply($p[1]);
367 protected function jacobianDoublePoint(array $p) argument
369 list($x, $y, $z) = $p;
390 protected function jacobianDoublePointMixed(array $p) argument
392 list($x, $y) = $p;
411 public function doublePoint(array $p) argument
417 if (!count($p)) {
422 if (isset($p[2])) {
423 if (isset($p['fresh'])) {
424 return $this->jacobianDoublePointMixed($p);
426 return $this->jacobianDoublePoint($p);
429 list($numerator, $denominator) = $this->doublePointHelper($p);
433 $x = $slope->multiply($slope)->subtract($p[0])->subtract($p[0]);
434 $y = $slope->multiply($p[0]->subtract($x))->subtract($p[1]);
476 public function verifyPoint(array $p) argument
478 list($x, $y) = $p;
629 $p = null;
633 $p = $z > 0 ?
636 $acc = $this->addPoint($acc, $p);
757 public function convertToAffine(array $p) argument
759 if (!isset($p[2])) {
760 return $p;
762 list($x, $y, $z) = $p;
776 public function convertToInternal(array $p) argument
778 if (isset($p[2])) {
779 return $p;
782 $p[2] = clone $this->one;
783 $p['fresh'] = true;
784 return $p;