bridge/class-master/depend/pari/src/modules/krasner.c
/* Eval P(x, y) assuming P has positive coefficients and the result is a long */
Eval P(x, y) assuming P has positive coefficients and the result is a long
Eval P ( x y ) assuming P has positive coefficients and the result is a long
static ulong
ZXY_z_eval(GEN P, ulong x, ulong y)
{
  long i, l = lg(P);
  ulong z;
  if (l == 2) return 0;
  z = ZX_z_eval(gel(P, l-1), y);
  for (i = l-2; i > 1; i--) z = z*x + ZX_z_eval(gel(P, i), y);
  return z;
}
static ulong ZXY_z_eval ( GEN P , ulong x , ulong y ) { long i , l = lg ( P ) ; ulong z ; if ( l == 2 ) return 0 ; z = ZX_z_eval ( gel ( P , l - 1 ) , y ) ; for ( i = l - 2 ; i > 1 ; i -- ) z = z * x + ZX_z_eval ( gel ( P , i ) , y ) ; return z ; }
Eval P(x, y) assuming P has positive coefficients and the result is a long
Eval P ( x y ) assuming P has positive coefficients and the result is a long