Home Online Manual
Top
Back: exp2pt
Forward: npar
FastBack: jacobson_lib
FastForward: Teaching
Up: findifs_lib
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

D.11.4.5 texcoef

Procedure from library findifs.lib (see findifs_lib).

Usage:
texcoef(n); n a number

Return:
string

Purpose:
converts the number n into TeX format

Note:
if n is a polynomial, texcoef adds extra brackets and performs some space substitutions

Example:
 
LIB "findifs.lib";
" EXAMPLE:"; 
==>  EXAMPLE:
ring r = (0,dh,dt),(Tx,Tt),dp;
number n1,n2,n3 = dt/(4*dh^2-dt),(dt+dh)^2, 1/dh;
n1; texcoef(n1);
==> (dt)/(4*dh^2-dt)
==> \frac{\tri t}{4\tri h^{2}-\tri t}
n2; texcoef(n2);
==> (dh^2+2*dh*dt+dt^2)
==> (\tri h^{2}+2\tri h\tri t+\tri t^{2})
n3; texcoef(n3);
==> 1/(dh)
==> \frac{1}{\tri h}