home *** CD-ROM | disk | FTP | other *** search
/ Crawly Crypt Collection 2 / crawlyvol2.bin / program / misc / mas / mashelp / dipi.def < prev    next >
Encoding:
Modula Definition  |  1989-11-12  |  7.7 KB  |  235 lines

  1.  
  2. (* DIP Integral Definition Module. *)
  3.  
  4. DEFINITION MODULE DIPI;
  5.  
  6.  
  7. FROM MASSTOR IMPORT LIST;
  8.  
  9.  
  10. PROCEDURE DIIFRP(A: LIST): LIST; 
  11. (*Distributive integral polynomial from rational polynomial.
  12. A is a distributive rational polynomial, B is the primitive
  13. positive associate integral polynomial of A. *)
  14.  
  15.  
  16. PROCEDURE DIILFR(A: LIST): LIST; 
  17. (*Distributive integral polynomial list from rational polynomial list.
  18. A is a list of distributive rational polynomial, B is a list of primitive
  19. positive associate integral polynomials of the polynomials of A. *)
  20.  
  21.  
  22. PROCEDURE DIILRD(V: LIST): LIST; 
  23. (*Distributive integral polynomial list read. V is a
  24. variable list. A list of distributive integral polynomials
  25. in r variables, where r=length(V), r ge 0, is read from
  26. the input stream. any blanks preceding A are skipped. *)
  27.  
  28.  
  29. PROCEDURE DIILWR(A,V: LIST); 
  30. (*Distributive integral polynomial list write. V is a
  31. variable list. A list of distributive integral polynomials
  32. in r variables, where r=length(V), r ge 0, is written to
  33. the output stream. *)
  34.  
  35.  
  36. PROCEDURE DIIPAB(A: LIST): LIST; 
  37. (*Distributive integral polynomial absolute value. A is a
  38. distributive integral polynomial. B is the absolute value of A.*)
  39.  
  40.  
  41. PROCEDURE DIIPCP(A: LIST;  VAR CL,AP: LIST); 
  42. (*Distributive integral polynomial content and primitive part.
  43. A is an distributive integral polynomial, c is the integer
  44. content and AP is the positive primitive part of A. *)
  45.  
  46.  
  47. PROCEDURE DIIPDF(A,B: LIST): LIST; 
  48. (*Distributive integral polynomial difference. A and B are
  49. distributive integral polynomials. C=A-B.*)
  50.  
  51.  
  52. PROCEDURE DIIPDM(A: LIST): LIST; 
  53. (*Distributive integral polynomial derivation main variable.
  54. A is a distributive polynomial. B is the derivation of A
  55. with respect to its main variable.*)
  56.  
  57.  
  58. PROCEDURE DIIPDR(A,IL: LIST): LIST; 
  59. (*Distributive integral polynomial derivation. A is a distributive
  60. polynomial. B is the derivation of A with respect to its i-th
  61. variable, 0 le i le DIPNOV(A).*)
  62.  
  63.  
  64. PROCEDURE DIIPEM(A,AL: LIST): LIST; 
  65. (*Distributive integral polynomial evaluation of main variable.
  66. A is a distributive integral polynomial. a is an integer.
  67. B(x1, ...,x(r-1))=A(x1, ...,x(r-1),a). *)
  68.  
  69.  
  70. PROCEDURE DIIPEV(A,IL,AL: LIST): LIST; 
  71. (*Distributive integral polynomial evaluation of the i-th variable.
  72. A is a distributive integral polynomial, 1 le i le DIPNOV(A),
  73. a is an integer. B(x1, ...,x(i-1),x(i+1), ...,xr)=
  74. A(x1, ...,x(i-1),a,x(i+1), ...,xr). *)
  75.  
  76.  
  77. PROCEDURE DIIPEX(A,NL: LIST): LIST; 
  78. (*Distributive integral polynomial exponentiation. A is a
  79. distributive integral polynomial, n is a non-negative beta-
  80. integer. B=A**n. 0**0 is by definition a polynomial in
  81. zero variables. *)
  82.  
  83.  
  84. PROCEDURE DIIPHD(A,IL,NL: LIST): LIST; 
  85. (*Distributive integral polynomial higher derivation. A is a
  86. distributive integral polynomial. B is the n-th derivation
  87. of A with respect to its i-th variable, 0 le i le DIPNOV(A). *)
  88.  
  89.  
  90. PROCEDURE DIIPIP(A,BL: LIST): LIST; 
  91. (*Distributive integral polynomial integer product. A is a
  92. distributive integral polynomial, b is an integer. C=A*b.*)
  93.  
  94.  
  95. PROCEDURE DIIPIQ(A,BL: LIST): LIST; 
  96. (*Distributive integral polynomial integer quotient. A is a
  97. distributive integral polynomial, b is a nonzero integer,
  98. and b divides any coefficient of A. C=A/b.*)
  99.  
  100.  
  101. PROCEDURE DIIPLS(A: LIST): LIST; 
  102. (*Distributive integral polynomial list sum. A is a circular
  103. list of distributive integral polynomials. B is the sum of all
  104. polynomials in A. *)
  105.  
  106.  
  107. PROCEDURE DIIPMN(A: LIST): LIST; 
  108. (*Distributive integral polynomial maximum norm. A is a
  109. distributive integral polynomial. b is the maximum norm of A.*)
  110.  
  111.  
  112. PROCEDURE DIIPNG(A: LIST): LIST; 
  113. (*Distributive integral polynomial negative. B= -A.*)
  114.  
  115.  
  116. PROCEDURE DIIPON(A: LIST): LIST; 
  117. (*Distributive integral polynomial one. A is a distributive
  118. integral polynomial. If A=1 then t=1, otherwise t=0.*)
  119.  
  120.  
  121. PROCEDURE DIIPPR(A,B: LIST): LIST; 
  122. (*Distributive integral polynomial product. A and B are
  123. distributive integral polynomials. C=A*B.*)
  124.  
  125.  
  126. PROCEDURE DIIPPS(A,B: LIST): LIST; 
  127. (*Distributive integral polynomial pseudo-remainder. A and B are
  128. distributive integral polynomials, B ne 0. C is the
  129. pseudo-remainder of A and B. *)
  130.  
  131.  
  132. PROCEDURE DIIPQ(A,B: LIST): LIST; 
  133. (*Distributive integral polynomial quotient. A and B are
  134. distributive integral polynomials. B is a non zero divisor
  135. of A. C=B/A.*)
  136.  
  137.  
  138. PROCEDURE DIIPQR(A,B: LIST;  VAR Q,R: LIST); 
  139. (*Distributive integral polynomial quotient and remainder.
  140. A and B are distributive integral polynomials with B ne 0.
  141. Q and R are unique distributive integral polynomials such
  142. that either B divides A, so Q=A/B and R=0  or B does not
  143. divide A, so A=B*Q+R with DEG(R) minimal.*)
  144.  
  145.  
  146. PROCEDURE DIIPRA(RL,KL,LL,EL: LIST): LIST; 
  147. (*Distributive integral polynomial random.
  148. k, l and e are positive beta-digits. e is the
  149. maximal permitted exponent of A in any variable. A is a
  150. random distributive integral polynomial in r variables
  151. max norm of a lt 2**k and maximal l base coefficients. *)
  152.  
  153.  
  154. PROCEDURE DIIPRD(V: LIST): LIST; 
  155. (*Distributive integral polynomial read. V is a variable list.
  156. A distributive integral polynomial A in r variables, where
  157. r=length(V), r ge 0, is read from the input stream. Any
  158. blanks preceding A are skipped. Modified version, orginal
  159. version by G. E. Collins. *)
  160.  
  161.  
  162. PROCEDURE DIIPSG(A: LIST): LIST; 
  163. (*Distributive integral polynomial sign. A is a distributive
  164. integral polynomial. s is the sign of the leading base
  165. coefficient of A.*)
  166.  
  167.  
  168. PROCEDURE DIIPSM(A,B: LIST): LIST; 
  169. (*Distributive integral polynomial sum. A and B are
  170. distributive integral polynomials. C=A+B. *)
  171.  
  172.  
  173. PROCEDURE DIIPSN(A: LIST): LIST; 
  174. (*Distributive integral polynomial sum norm. A is a distributive
  175. integral polynomial. b is the sum norm of A.*)
  176.  
  177.  
  178. PROCEDURE DIIPSO(A: LIST): LIST; 
  179. (*Distributive integral polynomial sort. A is a
  180. list of integer base coefficients and exponent vectors,
  181. A is sorted with respect to the actual term order,
  182. two terms with equal exponent vectors are added. *)
  183.  
  184.  
  185. PROCEDURE DIIPSU(A,IL,B: LIST): LIST; 
  186. (*Distributive integral polynomial substitution. A and B are
  187. distributive integral polynomials, 1 le i le r=DIPNOV(A).
  188. E(x1, ...,x(i-1),x(i+1), ...,xr)=A(x1, ...,x(i-1),
  189. B(x1, ...,x(i-1),x(i+1), ...,xr),x(i+1), ...,xr). *)
  190.  
  191.  
  192. PROCEDURE DIIPSV(A,B: LIST): LIST; 
  193. (*Distributive integral polynomial substitution for main variable.
  194. A and B are distributive integral polynomials. t=DIPNOV(A)-1.
  195. C(x1, ...,xt)=A(x1, ...,xt,B(x1, ...,xt)). *)
  196.  
  197.  
  198. PROCEDURE DIIPTM(A,HL: LIST): LIST; 
  199. (*Distributive integral polynomial translation main variable.
  200. A is a distributive integral polynomial, h is an integer.
  201. B(x1, ...xr)=A(x1, ...,x(r-1),xr+h). r=DIPNOV(A). *)
  202.  
  203.  
  204. PROCEDURE DIIPTR(A,HL,IL: LIST): LIST; 
  205. (*Distributive integral polynomial translation. A is a
  206. distributive integral polynomial, h is an integer,
  207. the i-th variable is translated. 1 le i le r=DIPNOV(A).
  208. B(x1, ...,xr)=A(x1, ...,xi+h, ...,xr).*)
  209.  
  210.  
  211. PROCEDURE DIIPWR(A,V: LIST); 
  212. (*Distributive integral polynomial write. A is a distributive
  213. integral poynomial in r variables, r ge 0. V is a variable list
  214. for A. A is written in the output stream. Modified version,
  215. original version by G. E. Collins. *)
  216.  
  217.  
  218. PROCEDURE DIIPWV(A: LIST); 
  219. (*Distributive integral polynomial write with standard variable list.
  220. A is a distributive integral poynomial. The standard
  221. variable list is used. A is written in the output stream.*)
  222.  
  223.  
  224. PROCEDURE DIIRAS(RL,KL,LL,EL,QL: LIST): LIST; 
  225. (*Distributive integral polynomial random sparse exponent vector.
  226. k, l and e are positive beta-digits. e is the
  227. maximal permitted exponent of A in any variable. A is a
  228. random distributive integral polynomial in r variables
  229. max norm of a lt 2**k and maximal l base coefficients. *)
  230.  
  231.  
  232. END DIPI.
  233.  
  234.  
  235.