multiply a point by an integer.

        :param p: a point
        :param e: an integer
        :returns: the result, equivalent to adding p to itself e times
493677
def multiply(self, p, e):
        

        if self._order:
            e %= self._order
        if p == self._infinity or e == 0:
            return self._infinity

        e3 = 3 * e
        i = _leftmost_bit(e3) >> 1
        result = p
        while i > 1:
            result += result
            if (e3 & i):
                v = [result, result+p]
            else:
                v = [result-p, result]
            result = v[0 if (e & i) else 1]
            i >>= 1

        return result
579159
def crt(self, mp, mq):
        
        u = (mq - mp) * self.p_inverse % self.q
        return mp + (u * self.p)
471485
def multiply(self, other):
        
        res = Matrix()
        cairo.cairo_matrix_multiply(
            res._pointer, self._pointer, other._pointer)
        return res
1067708
def pint_multiply(da, q, out_units=None):
    
    a = 1 * units2pint(da)
    f = a * q.to_base_units()
    if out_units:
        f = f.to(out_units)
    out = da * f.magnitude
    out.attrs['units'] = pint2cfunits(f.units)
    return out
930426
def Plus(self, other):
    
    return Point(self.x + other.x,
                 self.y + other.y,
                 self.z + other.z)
1323159
def example_point(self):
        
        return np.array([([self.n_meas] + [0] * (self.n_elements-1),)], dtype=self.dtype)
1346375
def Sum(input_vertex: vertex_constructor_param_types, label: Optional[str]=None) -> Vertex:
    
    return Double(context.jvm_view().SumVertex, label, cast_to_double_vertex(input_vertex))
1217354
def add_line(self, p1, p2, char_length):
        
        p1_id = self.get_point_id(p1, char_length)
        p2_id = self.get_point_id(p2, char_length)
        self.Lines.append((p1_id, p2_id))
        return len(self.Lines)
424756
def _m_to_e(cls, e, M):
        

        k1 = 3 * np.pi + 2
        k2 = np.pi - 1
        k3 = 6 * np.pi - 1
        A = 3 * k2 ** 2 / k1
        B = k3 ** 2 / (6 * k1)

        m1 = float(M)
        if abs(m1) < 1 / 6:
            E = m1 + e * (6 * m1) ** (1 / 3) - m1
        elif m1 < 0:
            w = np.pi + m1
            E = m1 + e * (A * w / (B - w) - np.pi - m1)
        else:
            w = np.pi - m1
            E = m1 + e * (np.pi - A * w / (B - w) - m1)

        e1 = 1 - e
        risk_disabler = (e1 + E ** 2 / 6) >= 0.1

        for i in range(2):
            fdd = e * sin(E)
            fddd = e * cos(E)

            if risk_disabler:
                f = (E - fdd) - m1
                fd = 1 - fddd
            else:
                f = cls._e_e_sin_e(e, E) - m1
                s = sin(E / 2)
                fd = e1 + 2 * e * s ** 2
            dee = f * fd / (0.5 * f * fdd - fd ** 2)

            w = fd + 0.5 * dee * (fdd + dee * fddd / 3)
            fd += dee * (fdd + 0.5 * dee * fddd)
            E -= (f - dee * (fd - w)) / fd

        E += M - m1

        return E
943410
def raw_mul(self, e):
        
        e %= self._order
        P = self._infinity
        for bit in range(256):
            # add the power of the generator every time to make it more time-deterministic
            a = [P, P + self._powers[bit]]
            # choose the correct result
            P = a[e & 1]
            e >>= 1
        return P
1018545
def Append(self, other):
        
        orig_len = len(self)
        self.Set(orig_len + len(other))
        ipoint = orig_len
        if hasattr(self, 'SetPointError'):
            for point in other:
                self.SetPoint(ipoint, point.x.value, point.y.value)
                self.SetPointError(
                    ipoint,
                    point.x.error_low, point.x.error_hi,
                    point.y.error_low, point.y.error_hi)
                ipoint += 1
        else:
            for point in other:
                self.SetPoint(ipoint, point.x.value, point.y.value)
                ipoint += 1
1155807
function(p, t) {

            var x = this.x;
            var y = this.y;
            return new Point((1 - t) * x + t * p.x, (1 - t) * y + t * p.y);
        }
519119
public static double sumInvLog1p(int s, int e) {
    double sum = 0.;
    // Iterate e + 1 .. s + 1, descending for better precision
    for(int i = e + 1; i > s; i--) {
      sum += 1. / FastMath.log(i);
    }
    return sum;
  }
349714
def add(self, p0, p1):
        
        p = self._p
        infinity = self._infinity

        if p0 == infinity:
            return p1
        if p1 == infinity:
            return p0

        x0, y0 = p0
        x1, y1 = p1
        if (x0 - x1) % p == 0:
            if (y0 + y1) % p == 0:
                return infinity
            else:
                slope = ((3 * x0 * x0 + self._a) * self.inverse_mod(2 * y0, p)) % p
        else:
            slope = ((y1 - y0) * self.inverse_mod(x1 - x0, p)) % p

        x3 = (slope * slope - x0 - x1) % p
        y3 = (slope * (x0 - x3) - y0) % p

        return self.Point(x3, y3)
805196
def increment(self, key, value=1):
        
        raw = self._get_payload(key)

        integer = int(raw['data']) + value

        self.put(key, integer, int(raw['time']))

        return integer
102478
function(p1, p2, pCenter) {
		pCenter.x = (p1.x + p2.x) * 0.5;
		pCenter.y = (p1.y + p2.y) * 0.5;
	}
253541
public static double Manhattan(IntPoint p, IntPoint q) {
        return Manhattan(p.x, p.y, q.x, q.y);
    }