Partial fraction expansion over ℂ: cpartfrac

### 5.33.10 Partial fraction expansion over ℂ: cpartfrac

cpartfrac takes as argument a rational fraction.
cpartfrac returns the partial fraction expansion of this rational fraction over the complex numbers, whether Xcas is in real or complex mode.

Example :
Find the partial fraction expansion of :

x5−2x3+1
x4−2x3+2x2−2x+1

Input :

cpartfrac((x^5-2*x^3+1)/(x^4-2*x^3+2*x^2-2*x+1))

Output:

x+2+(-1+2*i)/((2-2*i)*((i)*x+1))+1/(2*(-x+1))+
(-1-2*i)/((2-2*i)*(x+i))