Hi Clemens,

On Wed, Aug 20, 2014 at 5:15 AM, clemens novak <[email protected]> wrote:
> I have a question regarding the apart function. I want to obtain the partial
> fractions for eq = z / (z**2-z-1) .
>
> The denominator has real roots solve(denom(eq)) yields [1/2 + sqrt(5)/2 ,
> 1/2- sqrt(5)/2], but apart does not return the partial fractions; i,e.
> apart(eq, z) = z/(z**2 - z - 1) .
>
> Using apart(eq, z, full=True) yields RootSum(_w**2 - _w - 1, Lambda(_a,
> (_a/5 + 2/5)/(-_a + z))) which doesn't seem to be of much help (at least for
> me).
>
> Using apart with a fraction with "simpler" roots produces the desired
> partial fractions; e.g. apart (z / (z**2+z-2), z) yields 2/(3*(z + 2)) +
> 1/(3*(z - 1))
>
> Are there any additional options I can provide to apart to obtain the
> desired result?

Good point. I checked Mathematica and it produces the same result as SymPy.
However, clearly this can be decomposed, so I don't quite understand
if this is a bug in Mathematica as well,
or whether perhaps there is some reason not to do the decomposition
for this case.

Ondrej

>
> Thanks & regards - Clemens
>
> --
> You received this message because you are subscribed to the Google Groups
> "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/sympy.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/sympy/97ec7958-e6c8-4871-90fa-d53c06b0a2b6%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sympy.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sympy/CADDwiVA8P6izbs%2Ba2QtGm9ntFNzxO%2ByVMSROmuvuG5iqetvLMg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to