summaryrefslogtreecommitdiff
path: root/omegalib/examples/code_gen.out
blob: 16e1b2192bb6f165ef6034c2efa56590462b579f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# Omega Calculator [v1.1, Nov 96]:
# #
# # Example of code generation from Omega Calculator documentation
# #
# 
# T10:={[i] -> [0,i,0,0]};
# 
# T20:={[i,j] -> [1,j,0,i]};
# 
# T30:={[i] -> [1,i-1,1,0]};
# 
# 
# Symbolic n;
# 
# IS10 := {[i]: 2 <= i <= n};
# 
# IS20 := {[i,j]: 2 <= i <= n && 1 <= j <= i-1};
# 
# IS30 := IS10;
# 
# 
# codegen T10:IS10,T20:IS20,T30:IS30;
for(t2 = 2; t2 <= n; t2++) {
  s1(t2);
}
for(t2 = 1; t2 <= n-1; t2++) {
  for(t4 = t2+1; t4 <= n; t4++) {
    s2(t4,t2);
  }
  s3(t2+1);
}

#