t0(x) := 1$ t1(x) := x$ t2(x) := 2 * x^2 - 1$ t3(x) := 4 * x^3 - 3 * x$ t4(x) := 8 * x^4 - 8 * x^2 + 1$ t5(x) := 16 * x^5 - 20 * x^3 + 5 * x$ t6(x) := 32 * x^6 - 48 * x^4 + 18 * x^2 - 1$ t7(x) := 64 * x^7 - 112 * x^5 + 56 * x^3 - 7 * x$ /* This is a comment */ /* expand(t1(x)); expand(t2(x)/2 + t0(x)/2); expand(t3(x)/4 + 3*t1(x)/4); expand(t4(x)/8 + t2(x)/2 + 3*t0(x)/8); expand(t5(x)/16 + 5*t3(x)/16 + 5*t1(x)/8); expand(t6(x)/32 + 3*t4(x)/16 + 15*t2(x)/32 + 5*t0(x)/16); expand(t7(x)/64 + 7*t5(x)/64 + 21*t3(x)/64 + 35*t1(x)/64); */ /* diff(t0(x), x, 1); diff(t1(x), x, 1); diff(t2(x), x, 1); diff(t3(x), x, 1); diff(t4(x), x, 1); diff(t5(x), x, 1); diff(t6(x), x, 1); diff(t7(x), x, 1); */ /* diff(t0(x), x, 2); diff(t1(x), x, 2); diff(t2(x), x, 2); diff(t3(x), x, 2); diff(t4(x), x, 2); diff(t5(x), x, 2); diff(t6(x), x, 2); diff(t7(x), x, 2); */ /* test for (x+y)^5 */ factor(expand(100/16 * t0(x) * t1(y) + 100/16 * t1(x) * t0(y) + 25/16 * t0(x) * t3(y) + 25/16 * t3(x) * t0(y) + 1/16 * t0(x) * t5(y) + 1/16 * t5(x) * t0(y) + 100/16 * t1(x) * t2(y) + 100/16 * t2(x) * t1(y) + 10/16 * t1(x) * t4(y) + 10/16 * t4(x) * t1(y) + 20/16 * t2(x) * t3(y) + 20/16 * t3(x) * t2(y)));