Home Online Manual
Top
Back: invertLeftFraction
Forward: isOneFraction
FastBack:
FastForward:
Up: olga_lib
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

D.15.30.15 isZeroFraction

Procedure from library olga.lib (see olga_lib).

Usage:
isZeroFraction(frac), vector frac

Purpose:
determine if the vector frac represents zero

Assume:
frac is a valid fraction

Return:
int

Note:
returns 1, if frac == 0; 0 otherwise

Example:
 
LIB "olga.lib";
ring R = 0,(x,y,Dx,Dy),dp;
def S = Weyl();
setring S; S;
==> // coefficients: QQ
==> // number of vars : 4
==> //        block   1 : ordering dp
==> //                  : names    x y Dx Dy
==> //        block   2 : ordering C
==> // noncommutative relations:
==> //    Dxx=x*Dx+1
==> //    Dyy=y*Dy+1
isZeroFraction([42,0,0,0]);
==> 1
isZeroFraction([0,0,Dx,3]);
==> 0
isZeroFraction([1,1,1,1]);
==> 0