home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / sci / math / symbolic / 2314 < prev    next >
Encoding:
Text File  |  1992-09-03  |  2.8 KB  |  76 lines

  1. Newsgroups: sci.math.symbolic
  2. Path: sparky!uunet!mcsun!Germany.EU.net!ira.uka.de!chx400!bernina!neptune!bronstei
  3. From: bronstei@inf.ethz.ch ()
  4. Subject: Re: ode solver, different results from different packages
  5. Message-ID: <1992Sep3.155128.1990@neptune.inf.ethz.ch>
  6. Originator: bronstei@ru3.inf.ethz.ch
  7. Sender: news@neptune.inf.ethz.ch (Mr News)
  8. Nntp-Posting-Host: ru3.inf.ethz.ch
  9. Organization: Dept. Informatik, Swiss Federal Institute of Technology (ETH)
  10. Date: Thu, 3 Sep 1992 15:51:28 GMT
  11. Lines: 63
  12.  
  13.  
  14. In reply to:
  15. >>    Article: 4600 of sci.math.symbolic
  16. >>    From: qhuang@wiliki.eng.hawaii.edu (Qiming Huang)
  17. >>    Date: Thu, 3 Sep 1992 10:20:37 GMT
  18.  
  19. the d.e. in question:
  20. >>    x*dy/dx +a*x*y^2+2*y+b*x=0
  21.  
  22. >>    the solution given by macsyma is
  23. >>                                                 
  24. >>                                                (2 a sqrt(b) x)/sqrt(-a)
  25. >>      y=((2 %c a b x - 2 %c sqrt(-a) sqrt(b)) %e
  26. >>
  27. >>                                                      (2 a sqrt(b) x)/sqrt(-a)
  28. + sqrt(-a) a sqrt(b) x -a)/(2 %c sqrt(-a) a sqrt(b) x %e
  29. >> 
  30. >> 2
  31. + a x)
  32. >>    where %c is the integration constant.
  33.  
  34. This solution is correct with some assumptions on a and b (it wouln't be in
  35. the macsyma manual otherwise).
  36.  
  37. >>    the solution given by mathematica is
  38. >>    In:=DSolve[x*y'[x]+a*x*y^2+2*y+b*x==0, y[x],x]
  39. >>    Out={{y[x]--> -(bx) -axy^2 +C[1] - 2y log[x]}}
  40. >>    What went wrong?
  41.  
  42. Don't blame mathematica too quickly on that one: I think your input line
  43. was wrong. Try the correct input:
  44.  
  45. Dsolve[x y'[x] + a x y[x]^2 + 2 y[x] + b x == 0, y[x], x]
  46.  
  47. and please do post it if you get a correct answer!
  48. I thing the most likely answer to "What went wrong?" with the correct input,
  49. is that this type of d.e. is not supported by mathematica.
  50.  
  51.  
  52. For your information, AXIOM returns the following solution, which is correct
  53. with somewhat weaker assumptions on a and b than macsyma's:
  54.  
  55.                                          +-----+
  56.                 +-----+               2x\|- a b        +-----+
  57.          (- 2%c\|- a b  - 2%c a b x)%e           + a x\|- a b  + a
  58.          ---------------------------------------------------------
  59.                                          +-----+
  60.                              +-----+  2x\|- a b     2
  61.                      2%c a x\|- a b %e           - a x
  62.  
  63.  
  64. where %c is the integration constant (AXIOM actually returns a first
  65. integral, which you equate to any constant you want, e.g. %c, and then
  66. solve for y(x)).
  67.  
  68. -----------------------------------------------------------------------------
  69.     ____________
  70.    /      /    /   /                Manuel Bronstein
  71.   /---   /    /___/                 bronstein@inf.ethz.ch
  72.  /      /    /   /                  Informatik, ETH Zuerich, Switzerland
  73.  ----  /    /   /                   Tel: [41] (1) 254-7474
  74.                                     Fax: [41] (1) 262-3973
  75. -----------------------------------------------------------------------------
  76.