`lex_hensel', `lex_tl', `tolex', `tolex_d', `tolex_tl'
------------------------------------------------------

lex_hensel(PLIST,VLIST1,ORDER,VLIST2,HOMO)
lex_tl(PLIST,VLIST1,ORDER,VLIST2,HOMO)
     : Groebner basis computation with respect to a lex order by change
     of ordering

tolex(PLIST,VLIST1,ORDER,VLIST2)
tolex_d(PLIST,VLIST1,ORDER,VLIST2,PROCS)
tolex_tl(PLIST,VLIST1,ORDER,VLIST2,HOMO)
     :: Groebner basis computation with respect to a lex order by
     change of ordering, starting from a Groebner basis

RETURN
     list

PLIST  VLIST1  VLIST2  PROCS
     list

ORDER
     number, list or matrix

HOMO
     flag

   * These functions are defined in `gr' in the standard library
     directory.

   * `lex_hensel()' and `lex_tl()' first compute a Groebner basis with
     respect to the variable order VLIST1 and the order type ORDER.
     Then the Groebner basis is converted into a lex order Groebner
     basis with respect to the varable order VLIST2.

   * `tolex()' and `tolex_tl()' convert a Groebner basis PLIST with
     respect to the variable order VLIST1 and the order type ORDER into
     a lex order Groebner basis with respect to the varable order
     VLIST2.  `tolex_d()' does computations of basis elements in
     `tolex()' in parallel on the processes in a child process list
     PROCS.

   * In `lex_hensel()' and `tolex_hensel()' a lex order Groebner basis
     is computed as follows.(Refer to `[Noro,Yokoyama]'.)
       1. Compute a Groebner basis G0 with respect to VLIST1 and ORDER.
          (Only in `lex_hensel()'. )

       2. Choose a prime which does not divide head coefficients of
          elements in G0 with respect to VLIST1 and ORDER. Then compute
          a lex order Groebner basis GP over GF(P) with respect to
          VLIST2.

       3. Compute NF, the set of all the normal forms with respect to
          G0 of terms appearing in GP.

       4. For each element F in GP, replace coefficients and terms in F
          with undetermined coefficients and the corresponding
          polynomials in NF respectively, and generate a system of
          liear equation LF by equating the coefficients of terms in
          the replaced polynomial with 0.

       5. Solve LF by Hensel lifting, starting from the unique mod P
          solution.

       6. If all the linear equations generated from the elements in GP
          could be solved, then the set of solutions corresponds to a
          lex order Groebner basis. Otherwise redo the whole process
          with another P.

   * In `lex_tl()' and `tolex_tl()' a lex order Groebner basis is
     computed as follows.(Refer to `[Noro,Yokoyama]'.)

       1. Compute a Groebner basis G0 with respect to VLIST1 and ORDER.
          (Only in `lex_tl()'. )

       2. If G0 is not zero-dimensional, choose a prime which does not
          divide head coefficients of elements in G0 with respect to
          VLIST1 and ORDER. Then compute a candidate of a lex order
          Groebner basis via trace lifting with P. If it succeeds the
          candidate is indeed a lex order Groebner basis without any
          check. Otherwise redo the whole process with another P.

       3.  If G0 is zero-dimensional, starting from G0, compute a
          Groebner basis G1 with respect to an elimination order to
          eliminate variables other than the last varibale in VLIST2.
          Then compute a lex order Groebner basis stating from G1. These
          computations are done by trace lifting and the selection of a
          mudulus P is the same as in non zero-dimensional cases.

   * Computations with rational function coefficients can be done only
     by `lex_tl()' and `tolex_tl()'.

   * If `homo' is not equal to 0, homogenization is used in Buchberger
     algorithm.

   * The CPU time shown after an execution of `tolex_d()' indicates
     that of the master process, and it does not include the time in
     child processes.

     [78] K=katsura(5)$
     30msec + gc : 20msec
     [79] V=[u5,u4,u3,u2,u1,u0]$
     0msec
     [80] G0=hgr(K,V,2)$
     91.558sec + gc : 15.583sec
     [81] G1=lex_hensel(K,V,0,V,0)$
     49.049sec + gc : 9.961sec
     [82] G2=lex_tl(K,V,0,V,1)$
     31.186sec + gc : 3.500sec
     [83] gb_comp(G0,G1);
     1
     10msec
     [84] gb_comp(G0,G2);
     1

References
     *Note `dp_gr_main dp_gr_mod_main dp_gr_f_main dp_weyl_gr_main
     dp_weyl_gr_mod_main dp_weyl_gr_f_main': dp_gr_main dp_gr_mod_main
     dp_gr_f_main dp_weyl_gr_main dp_weyl_gr_mod_main dp_weyl_gr_f_main,
     *Note `dp_ord': dp_ord, *Note `Distributed computation':
     Distributed computation

