Status: Accepted
Owner: ----
Labels: Type-Defect Priority-Medium
New issue 1280 by ondrej.certik: integrate(1/((a-x)*(b-x)), x) is giving
too complex results (probably correct)
http://code.google.com/p/sympy/issues/detail?id=1280
sage: var("x a b c")
(x, a, b, c)
sage: integrate(1/(a-x), x)
-log(a - x)
sage: integrate(1/((a-x)*(b-x)), x)
log(x - b)/(b - a) - log(x - a)/(b - a)
sage: integrate(1/((a-x)*(b-x)*(c-x)), x)
-log(x - c)/(c^2 + (-b - a)*c + a*b) + log(x - b)/((b - a)*c - b^2 + a*b) -
log(x - a)/((b - a)*c - a*b + a^2)
In [1]: var("a b c")
Out[1]: (a, b, c)
In [2]: integrate(1/(a-x), x)
Out[2]: -log(a - x)
In [3]: integrate(1/((a-x)*(b-x)), x)
Out[3]:
⎛ ⎛ ⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎞⎞
⎜ ⎜ ╱ 2 2 ⎟⎟
⎜ ⎜a b ╲╱ -2⋅a⋅b + a + b ⎟⎟ ⎛
⎽⎽⎽⎽⎽
⎜ 2⋅⎜─ + ─ + ─────────────────────⎟⎟ ⎜ ╱
⎜ a + b ⎝2 2 2 ⎠⎟ ⎜ a b ╲╱
-2⋅a
⎜─────────────── - ─────────────────────────────────⎟⋅log⎜x - ─ - ─ -
────────
⎜ 2 2 2 2 ⎟ ⎝ 2 2
⎝2⋅a⋅b - a - b 2⋅a⋅b - a - b ⎠
⎛ ⎛ ⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎞⎞
⎜ ⎜ ╱ 2 2 ⎟⎟
⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎞ ⎜ ⎜a b ╲╱ -2⋅a⋅b + a + b ⎟⎟ ⎛
2 2 ⎟ ⎜ 2⋅⎜─ + ─ - ─────────────────────⎟⎟ ⎜
⋅b + a + b ⎟ ⎜ a + b ⎝2 2 2 ⎠⎟ ⎜
─────────────⎟ + ⎜─────────────── -
─────────────────────────────────⎟⋅log⎜x -
2 ⎠ ⎜ 2 2 2 2 ⎟ ⎝
⎝2⋅a⋅b - a - b 2⋅a⋅b - a - b ⎠
⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎽⎞
╱ 2 2 ⎟
a b ╲╱ -2⋅a⋅b + a + b ⎟
─ - ─ + ─────────────────────⎟
2 2 2 ⎠
In [4]: integrate(1/((a-x)*(b-x)*(c-x)), x)
[hangs]
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"sympy-issues" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/sympy-issues?hl=en
-~----------~----~----~----~------~----~------~--~---