fixed a small bug in eval ehrhart
[polylib.git] / Test / general / convex.test
blobcecd7300ec5810d5f8b39a3f2e217ad6f61427ee
1 c1 = readDom["{i,N,M|1<=M<=N }"]
3 d1 = readDom["{i,N,M|i=1;N=M}|{i,N,M|1<=i<=(N,M+1)}|{i,N,M|1<=i<=N}"]
4 d2 = DomConvex[d1]
5 ashow[d2]
6 d2 = DomConvex[DomIntersection[d1,c1]]
7 ashow[d2]
9 d1 = readDom["{i,N,M|i=1;N=M}|{i,N,M|1<=i<=(N,M+1)}"]
10 d2 = DomConvex[d1]
11 ashow[d2]
12 d2 = DomConvex[DomIntersection[d1,c1]]
13 ashow[d2]
15 d1 = readDom["{i,N,M|i=1;N=M}|{i,N,M|1<=i<=N}"]
16 d2 = DomConvex[d1]
17 ashow[d2]
18 d2 = DomConvex[DomIntersection[d1,c1]]
19 ashow[d2]
21 d1 = readDom["{i,N,M|1<=i<=(N,M+1)}|{i,N,M|1<=i<=N}"]
22 d2 = DomConvex[d1]
23 ashow[d2]
24 d2 = DomConvex[DomIntersection[d1,c1]]
25 ashow[d2]
27 (* simplest case *)
28 d1 = readDom["{i,N|i=1}|{i,N|1<=i<=N}"]
29 d2 = DomConvex[d1]
30 ashow[d2]
31 (* with context included, its OK *)
32 d1 = readDom["{i,N|i=1;1<=N}|{i,N|1<=i<=N}"]
33 d2 = DomConvex[d1]
34 ashow[d2]
36 (* intersection and convex are not interchangeable *)
37 d1 = readDom["{i,N|i=1; 0<=N}|{i,N|1<=i<=N}"]
38 d1 = readDom["{i,N|i=1}|{i,N|1<=i<=N}"]
39 d2 = readDom["{i,N|N=4}"]
40 d3 = DomIntersection[d1,d2]
41 d4 = DomConvex[d3]
42 ashow[d4]
43 d5 = DomConvex[d1]
44 d6 = DomIntersection[d5,d2]
45 ashow[d6]