lib/ed25519_keccak/ed25519base.rb
def point_add( pa , pb )
      _A = (pa[1]-pa[0]) * (pb[1]-pb[0]) % @@p
      _B = (pa[1]+pa[0]) * (pb[1]+pb[0]) % @@p
      _C = 2 * pa[3] * pb[3] * @@d % @@p
      _D = 2 * pa[2] * pb[2] % @@p
      _E = _B - _A
      _F = _D - _C
      _G = _D + _C
      _H = _B + _A
      return [ _E*_F , _G*_H , _F*_G , _E*_H ]
    end
def point_add( pa , pb )
      _A = (pa[1]-pa[0]) * (pb[1]-pb[0]) % @@p
      _B = (pa[1]+pa[0]) * (pb[1]+pb[0]) % @@p
      _C = 2 * pa[3] * pb[3] * @@d % @@p
      _D = 2 * pa[2] * pb[2] % @@p
      _E = _B - _A
      _F = _D - _C
      _G = _D + _C
      _H = _B + _A
      return [ _E*_F , _G*_H , _F*_G , _E*_H ]
    end
region calculate point of ed25519 curve 
 Points are represented as array [X, Y, Z, T] of extended
 coordinates, with x = X/Z, y = Y/Z, x*y = T/Z

 [arguments]
 pa : point A
 pb : point B