home *** CD-ROM | disk | FTP | other *** search
/ Simtel MSDOS - Coast to Coast / simteldosarchivecoasttocoast2.iso / calculat / sm30a.zip / SYMBMATH.H45 < prev    next >
Text File  |  1993-11-07  |  1KB  |  50 lines

  1.                 4.13    Getting parts of expression
  2.                 4.13.1  Getting type of data
  3.         You can get type of data by
  4.                         type(x)
  5.  
  6. IN:  type(2)
  7. OUT: "integer"
  8.  
  9.                 4.13.2  Getting operators
  10.         You also can get operators by
  11.                         type(x)
  12.  
  13. IN:  type(a>b)
  14. OUT: ">"
  15. IN:  type(sin(x))
  16. OUT: "sin()"
  17.  
  18.                 4.13.3  Getting operatands
  19.     The functions
  20.         left(x=a), left(a > b)
  21.         right(x=a), right(a > b)
  22. pick up the left- and right- side of the equation and inequality.
  23.  
  24. IN:  left(a>b), right(a>b)
  25. OUT: a, b
  26.  
  27.         You can get the j-th term of sum by
  28.                        member(term(a+b), j)
  29.  
  30. IN:  member(term(a+b), 1)
  31. OUT: a
  32.  
  33.         You can get the arguments of a function by
  34.                         argue(f(x))
  35.  
  36. IN:  argue(sin(x))
  37. OUT: x
  38.  
  39.                 4.13.4  Getting coefficients
  40.     A coefficient of x^n in an expression can be picked up by 
  41.         coef(p, x^n)
  42.  
  43. IN:  coef(a + b*x + c*x^2 + d*x^3, x)
  44. OUT: b
  45.  
  46.         You can get a coefficient of x^n (where 0<= n < 4) in polynomials
  47. ordered up to 4 by
  48.                 coef(poly, x,n)
  49. (see Chapter 4.8.4 Polynomials for detail).
  50.