Question: problem with collect?

i have a problem in using command "collect". 

eq:=a[1]*a[2]^2+a[2]*a[3]*a[1]+a[3]^3;

eq := a[1]*a[2]^2+a[1]*a[2]*a[3]+a[3]^3

(1)

collect(eq1,a[3]);

a[1]*a[2]^2+a[1]*a[2]*a[3]+a[3]^3

(2)

 

as u see, i just want to collect a[3]s,but it gives me all of the coeeficients,what is the problem ?

Download problem.mws

Please Wait...