source: git/Tst/Long/factorizeQ_l.tst @ 0bc5ed4

spielwiese
Last change on this file since 0bc5ed4 was 84be83, checked in by Martin Lee <martinlee84@…>, 11 years ago
chg: added more tests to factorizeQ_l
  • Property mode set to 100644
File size: 799 bytes
Line 
1LIB "tst.lib";
2tst_init();
3
4proc testfactors (list l, poly f)
5{
6  poly g= 1;
7  for (int i= 1; i <= size (l[1]); i++)
8  {
9    g= g*(l[1][i]^l[2][i]);
10  }
11  g == f;
12  l;
13}
14
15ring r=0,(x,y,z,s,u,v,w),dp;
16list l;
17poly f= (1+x+y+z)^20+1;
18poly g= f*(f+1);
19
20l= factorize (g); testfactors (l, g);
21tst_status();
22
23f= (1+x2+y2+z2)^20+1;
24g= f*(f+1);
25
26l= factorize (g); testfactors (l, g);
27tst_status();
28
29f= (1+x+y+z)^30+1;
30g= f*(f+1);
31
32l= factorize (g); testfactors (l, g);
33tst_status();
34
35f= (1+x+y+z+s)^20+1;
36g= f*(f+1);
37
38l= factorize (g); testfactors (l, g);
39tst_status();
40
41f=(1+u2+v+w2+x-y)^10+1;
42g=(1+u+v2+w+x2-y)^10+1;
43g=g*f;
44
45l= factorize (g); testfactors (l, g);
46tst_status();
47
48f=(1+x)^20*(1+y)^20*(1+z)^20+1;
49g=(1-x)^20*(1-y)^20*(1-z)^20+1;
50g=g*f;
51
52l= factorize (g); testfactors (l, g);
53
54tst_status(1);$
Note: See TracBrowser for help on using the repository browser.