Re: Algebraic reduction
- To: mathgroup at smc.vnet.net
- Subject: [mg108428] Re: Algebraic reduction
- From: "Alexander Elkins" <alexander_elkins at hotmail.com>
- Date: Wed, 17 Mar 2010 04:40:48 -0500 (EST)
- References: <hnnk72$ckb$1@smc.vnet.net>
"Artur" <grafix at csl.pl> wrote in message news:hnnk72$ckb$1 at smc.vnet.net... > Dear Mathematica Gurus. > Who know how force simplification of polynomials (x^n - 1)/(x - 1)] by > Mathematica > Table[FullSimplify[(x^n - 1)/(x - 1)], {n, 1, 10}] > Above eliminate denominator only in first 5 n > Any idea ? > Best wishes > Artur > Here is a general solution to what you appear to be seeking to obtain that does not use FullSimplify: In[1]:= Column[Table[PolynomialQuotient[#1,#2,#3]+PolynomialRemainder[#1,#2,#3]/#2,{ n,1,10}]&[x^n-1,x-1,x]] Out[1]= 1 1+x 1+x+x^2 1+x+x^2+x^3 1+x+x^2+x^3+x^4 1+x+x^2+x^3+x^4+x^5 1+x+x^2+x^3+x^4+x^5+x^6 1+x+x^2+x^3+x^4+x^5+x^6+x^7 1+x+x^2+x^3+x^4+x^5+x^6+x^7+x^8 1+x+x^2+x^3+x^4+x^5+x^6+x^7+x^8+x^9 Of course for x^n-1 with n > 1 && Element[n, Integers] the PolynomialRemainder[x^n-1,x-1,x] is always zero so you can also simplify your particular example just using Factor: In[2]:= Column[Table[Factor[x^n-1]/(x-1),{n,1,10}]] Out[2]= 1 1+x 1+x+x^2 (1+x) (1+x^2) 1+x+x^2+x^3+x^4 (1+x) (1-x+x^2) (1+x+x^2) 1+x+x^2+x^3+x^4+x^5+x^6 (1+x) (1+x^2) (1+x^4) (1+x+x^2) (1+x^3+x^6) (1+x) (1-x+x^2-x^3+x^4) (1+x+x^2+x^3+x^4) Perhaps you will also notice that the factors are the same as the cyclotomic polynomials of all of the factors on n, so that for x^n-1 with n > 1 && Element[n, Integers] the following is true: In[3]:= Table[Factor[x^n-1],{n,1,10}]==Table[Times@@Cyclotomic[Times@@@Tuples[Union[ #1^Range[0,#2]]&@@@FactorInteger[n]],x],{n,1,10}] Out[3]= True Union is used only to handle the special case of 1^Range[0,1] which produces {{1, 1}} instead of the desired {{1}} Note that x - 1 == Cyclotomic[1, x]. Hope this helps...