home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / ai / 3266 < prev    next >
Encoding:
Internet Message Format  |  1992-08-30  |  6.9 KB

  1. Xref: sparky comp.ai:3266 comp.ai.edu:393 aus.ai:118
  2. Path: sparky!uunet!kithrup!stanford.edu!ames!sgi!mips!mips!munnari.oz.au!deakin.OZ.AU!huang
  3. From: huang@deakin.OZ.AU (Weiguang Huang)
  4. Newsgroups: comp.ai,comp.ai.edu,aus.ai
  5. Subject: SymbMath: a system learning from user
  6. Message-ID: <3993@sol.deakin.OZ.AU>
  7. Date: 30 Aug 92 03:59:50 GMT
  8. Followup-To: comp.ai
  9. Organization: Deakin University, Victoria, Australia
  10. Lines: 210
  11.  
  12.  
  13.             15.17 Learning from Users
  14.  
  15.     The most important feature of SymbMath is that SymbMath can
  16. learn from users to deduce and expand its knowledge. If users provide
  17. the necessary facts, then SymbMath can solve many problems it could 
  18. not do before.
  19.  
  20.  
  21.     15.17.1 Learning indefinite and definite integrals from
  22.         derivatives
  23.  
  24.     If users provide derivatives, SymbMath can deduce indefinite 
  25. and definite integrals from derivatives. 
  26.  
  27.     Example 15.17.1. 
  28. First check SymbMath wether or not it had already known indefinite and 
  29. definite integrals of exp(x)/x^2 or exp(x)/x^3.
  30.     Input:
  31. inte(exp(x)/x^2*d(x))
  32. inte(exp(x)/x^3*d(x))
  33. inte(exp(x)/x^2, x from 1 to 2)
  34.     Output:
  35. inte(exp(x)/x^2*d(x))
  36. inte(exp(x)/x^3*d(x))
  37. inte(exp(x)/x^2, x from 1 to 2)
  38.  
  39. Teach SymbMath derivative of Ei(x) on the first line, and then run again.
  40.     Input:
  41. d(Ei(x)/d(x))=exp(x)/x
  42. inte(exp(x)/x^2*d(x))
  43. inte(exp(x)/x^3*d(x))
  44. inte(exp(x)/x^2, x from 1 to 2)
  45.     Output:
  46. d(Ei(x)/d(x)) = exp(x)/x
  47. constant - exp(x)/x + Ei(x)
  48. constant - 1/2*(x^(-2)*exp(x) + exp(x)/x - Ei(x))
  49. e + Ei(2) - Ei(1) - 1/2*exp(2)
  50.  
  51.     Users only tell SymbMath a derivative of Ei(x), did not say 
  52. anything about indefinite or definite integrals, about the functions 
  53. exp(x)/x^2 or exp(x)/x^3, did not write any code (a function, 
  54. procedure or subroutine), did not load any file, did not call any 
  55. subroutine. Ei(x) is the exponential integral function, instead of 
  56. a standard function nor the built-in function in SymbMath.
  57.     Why does SymbMath become to have these knowledge ? Because
  58. SymbMath logically deduces these integrals from d(Ei(x)/d(x)).
  59. This is learning from users.
  60.  
  61.     Example 15.17.2. 
  62. Users want to do integration on sin(x)/x^3. First check if 
  63. integral of sin(x)/x^3 or derivative of Si(x) had already been stored 
  64. in SymbMath.
  65.     Input:
  66. d(Si(x)/d(x))
  67. inte(sin(x)/x^3*d(x))
  68.     Output:
  69. d(Si(x)/d(x))
  70. inte(sin(x)/x^3*d(x))
  71.  
  72. Users enter a derivative, then ask the integral of sin(x)/x^3.
  73. On this time, only change the first line, and then run again.
  74.     Input:
  75. d(Si(x)/d(x))=sin(x)/x
  76. inte(sin(x)/x^3*d(x))
  77.     Output:
  78. d(Si(x)/d(x)) = sin(x)/x
  79. -1/2*(Si(x) + cos(x)/x + x^(-2)*sin(x)) + constant
  80.  
  81.         
  82.     15.17.2 Learning complicated indefinite integrals from a
  83.         simple indefinite integral
  84.  
  85.     Users supply a simple indefinite integral, and then ask many
  86. complicated indefinite integrals.
  87.  
  88.     Example 15.17.3. 
  89. Check whether SymbMath had already known the following
  90. integrals or not (i.e. to check if these integrals had already been
  91. stored in the data base or knowledge base, these checking would be
  92. omitted if users trust SymbMath without these predefined knowledge).
  93.     Input:
  94. inte(tan(x)^2*d(x))
  95. inte((2*tan(x)^2+x)*d(x))
  96. inte(inte(tan(x)^2+y)*d(x))*d(y))
  97.     Output:
  98. inte(tan(x)^2*d(x))
  99. inte((2*tan(x)^2+x)*d(x))
  100. inte(inte(tan(x)^2+y)*d(x))*d(y))
  101.  
  102. Users show that an indefinite integral of tan(x)^2 is tan(x)-x, then 
  103. ask indefinite integral of 2*tan(x)^2+x, and a double indefinite 
  104. integral of tan(x)^2+y respect with both x and y. On this time, only 
  105. change the first line, and then run again.
  106.  
  107.     Input:
  108. inte(tan(x)^2*d(x)) = tan(x) - x
  109. inte((2*tan(x)^2+x)*d(x))
  110. inte(inte(tan(x)^2+y)*d(x))*d(y))
  111.  
  112. The first input line is to teach SymbMath the indefinite integral of
  113. tan(x)^2. The second and third input lines are to ask the indefinite
  114. integral of 2*tan(x)^2+x and the double indefinite integral of
  115. tan(x)^2+y.
  116.  
  117.     Output:
  118. inte(tan(x)^2*d(x)) = tan(x) - x
  119. 2 (tan(x) - x) + 1/2*x^2
  120. tan(x)*y - x*y + x*y^2
  121.  
  122. Users will ask inte(inte(tan(x)^2+y^2)*d(x))*d(y)),
  123. inte(inte(tan(x)^2*y)*d(x))*d(y)), inte(x*tan(x)^2*d(x)),
  124. triple integral of tan(x)^2-y+z, or others.
  125.  
  126.  
  127.     15.17.3 Learning definite integral from indefinite integral
  128.  
  129.     Users continue to ask definite integrals as well.
  130.  
  131.     Input:
  132. inte(inte(tan(x)^2+y, x from 0 to 1), y from 0 to 2)
  133.     Output:
  134. 2 tan(1)
  135.  
  136.     Notice that SymbMath has not had knowledge of all of these
  137. integrals before. Users did nothing, except for only telling SymbMath
  138. one simple indefinite integral of tan(x)^2, did not tell SymbMath
  139. anything about other indefinite integral (e.g. tan(x)^2+y, tan(x)^2+x,
  140. etc.), any indefinite double integral, definite integral, or definite
  141. double integral.
  142.  
  143.  
  144.     15.17.4 Learning complicated derivative from simple
  145.         derivative
  146.  
  147.     SymbMath can learn complicated derivatives from a simple 
  148. derivative, even thought the function to be differentiated is any 
  149. function, not only a standard function.
  150.  
  151.     Example 15.17.4. 
  152. Users want to differentiate Ci(x)^6, where Ci(x) is a cosine integral 
  153. function instead of a standard function.
  154.     Input:
  155. d(Ci(x)/d(x))
  156. d((Ci(x)^6)/d(x))
  157.     Output:
  158. d(Ci(x)/d(x))
  159. d((Ci(x)^6)/d(x))
  160.  
  161. Now, alter the first line only, and then run again.
  162.     Input:
  163. d(Ci(x)/d(x))=cos(x)/x
  164. d((Ci(x)^6)/d(x))
  165.     Output:
  166. d(Ci(x)/d(x)) = cos(x)/x
  167. 6 Ci(x)^5*cos(x)/x
  168.  
  169.  
  170.         15.17.5 Learning integration from algebra
  171.  
  172.     If users tell SymbMath algebra, SymbMath can learn integrals
  173. from algebra. 
  174.  
  175.     Example 15.17.5. 
  176. Users input sin(x)^2=1/2-1/2*cos(2*x), then ask integral of sin(x)^2.
  177.     Input:
  178. sin(x)^2=1/2-1/2*cos(2*x)
  179. inte(sin(x)^2*d(x))
  180.     Output:
  181. sin(x)^2 = 1/2 - 1/2*cos(2*x)
  182. 1/2*x - 1/4*sin(2*x)
  183.  
  184.     SymbMath have learned to solve these problems, even though 
  185. the types of problems are different, e.g. learning integrals from 
  186. derivatives or algebra.
  187.  
  188.  
  189.     15.17.6 Learning complicated algebra from simple algebra
  190.  
  191.     SymbMath has the ability to learn complicated algebra from
  192. simple algebra.
  193.  
  194.     Example 15.17.6. 
  195. Transform sin(x)/cos(x) into tan(x) in an expression.
  196.     Input:
  197. sin(x)/cos(x)=tan(x)
  198. x+sin(x)/cos(x)+a
  199.     Output:
  200. sin(x)/cos(x) = tan(x)
  201. a + x + tan(x)
  202.  
  203.     Learning is different from programming. On learning, although
  204. users only input one formula, SymbMath will learn many knowledge.
  205. SymbMath is able to learn, as a student does. On programming, users 
  206. have many things to do. First, users define many subroutines for the
  207. individual integrands (e.g. tan(x)^2, tan(x)^2+y^2, 2*tan(x)^2+x, 
  208. x*tan(x)^2, etc.), and for individual integrals (e.g. the indefinite 
  209. integral, definite integral, the indefinite double integrals, 
  210. indefinite triple integrals, definite double integrals, definite 
  211. triple integrals, etc.), second, write many lines of program for the
  212. individual subroutines, (i.e. to tell the computer how to calculate
  213. these integrals), third, load these subroutines, finally, call these
  214. subroutines.
  215.     In one word, programming means that programmers must
  216. provide step-by-step procedures telling the computer how to solve
  217. each problems. By contrast, learning means that users need only supply
  218. the necessary facts, SymbMath will determine how to go about
  219. solutions.
  220.     If the learning is saved into a disk as a disk file or library, 
  221. SymbMath will never forget it. 
  222.