This file is indexed.

/usr/share/axiom-20140801/input/streams.input is in axiom-test 20140801-11.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
)set break resume
)spool streams.output
)set message test on
)set message auto off
)clear all
 
)set streams calculate 5
 
)set streams showall on
 
--S 1 of 26
a := [i for i in 1..]
--R 
--R
--R   (1)  [1,2,3,4,5,...]
--R                                                Type: Stream(PositiveInteger)
--E 1

--S 2 of 26
b := [i+1 for i in a]
--R 
--R
--R   (2)  [2,3,4,5,6,...]
--R                                                Type: Stream(PositiveInteger)
--E 2

--S 3 of 26
b.20
--R 
--R
--R   (3)  21
--R                                                        Type: PositiveInteger
--E 3

--S 4 of 26
b
--R 
--R
--R   (4)  [2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,...]
--R                                                Type: Stream(PositiveInteger)
--E 4

--S 5 of 26
a
--R 
--R
--R   (5)  [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,...]
--R                                                Type: Stream(PositiveInteger)
--E 5

--S 6 of 26
first(a,10)
--R 
--R
--R   (6)  [1,2,3,4,5,...]
--R                                                Type: Stream(PositiveInteger)
--E 6

--S 7 of 26
rest(a,10)
--R 
--R
--R   (7)  [11,12,13,14,15,16,17,18,19,20,...]
--R                                                Type: Stream(PositiveInteger)
--E 7

--S 8 of 26
[i for i in a | odd? i]
--R 
--R
--R   (8)  [1,3,5,7,9,...]
--R                                                Type: Stream(PositiveInteger)
--E 8

--S 9 of 26
c := [[i,j] for i in a for j in b]
--R 
--R
--R   (9)  [[1,2],[2,3],[3,4],[4,5],[5,6],...]
--R                                          Type: Stream(List(PositiveInteger))
--E 9

--S 10 of 26
[first i for i in c]
--R 
--R
--R   (10)  [1,2,3,4,5,...]
--R                                                Type: Stream(PositiveInteger)
--E 10

)set streams calculate 10

--S 11 of 26
concat([i for i in a while i<7],a)
--R 
--R
--R   (11)  [1,2,3,4,5,6,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,...]
--R                                                Type: Stream(PositiveInteger)
--E 11

--S 12 of 26
concat(a,a)
--R 
--R
--R   (12)  [1,2,3,4,5,6,7,8,9,10,...]
--R                                                Type: Stream(PositiveInteger)
--E 12

--S 13 of 26
upto:NNI->STREAM INT
--R 
--R                                                                   Type: Void
--E 13

--S 14 of 26
upto n == first(a,n)
--R 
--R                                                                   Type: Void
--E 14

--S 15 of 26
d := [upto n for n in a]
--R 
--R   Compiling function upto with type NonNegativeInteger -> Stream(
--R      Integer) 
--R
--R   (15)
--R   [[1], [1,2], [1,2,3], [1,2,3,4], [1,2,3,4,5], [1,2,3,4,5,6],
--R    [1,2,3,4,5,6,7], [1,2,3,4,5,6,7,8], [1,2,3,4,5,6,7,8,9],
--R    [1,2,3,4,5,6,7,8,9,10,...], ...]
--R                                                Type: Stream(Stream(Integer))
--E 15

--S 16 of 26
concat d
--R 
--R
--R   (16)  [1,1,2,1,2,3,1,2,3,4,...]
--R                                                        Type: Stream(Integer)
--E 16

--S 17 of 26
reduce(0,_+$INT,first(a,10))
--R 
--R
--R   (17)  55
--R                                                        Type: PositiveInteger
--E 17

--S 18 of 26
scan(0,_+$INT,a)
--R 
--R
--R   (18)  [1,3,6,10,15,21,28,36,45,55,...]
--R                                                        Type: Stream(Integer)
--E 18

--S 19 of 26
scan(0,_+$INT,[2*i-1 for i in a])
--R 
--R
--R   (19)  [1,4,9,16,25,36,49,64,81,100,...]
--R                                                        Type: Stream(Integer)
--E 19

--S 20 of 26
ff:(LIST INT)->(LIST INT)
--R 
--R                                                                   Type: Void
--E 20

--S 21 of 26
ff(x)==[x.1+x.2,x.1]
--R 
--R                                                                   Type: Void
--E 21

--S 22 of 26
fibs := generate(ff,[1,1])
--R 
--R   Compiling function ff with type List(Integer) -> List(Integer) 
--R
--R   (22)
--R   [[1,1],[2,1],[3,2],[5,3],[8,5],[13,8],[21,13],[34,21],[55,34],[89,55],...]
--R                                           Type: InfiniteTuple(List(Integer))
--E 22

--first([first i for i in fibs], 100)

--S 23 of 26
mt:SQMATRIX(2,INT) := matrix [[1,2],[3,4]]
--R 
--R
--R         +1  2+
--R   (23)  |    |
--R         +3  4+
--R                                                Type: SquareMatrix(2,Integer)
--E 23

--S 24 of 26
mplm:SQMATRIX(2,INT)->SQMATRIX(2,INT)
--R 
--R                                                                   Type: Void
--E 24

--S 25 of 26
mplm x == x*mt
--R 
--R                                                                   Type: Void
--E 25

--S 26 of 26
generate(mplm,mt)
--R 
--R   Compiling function mplm with type SquareMatrix(2,Integer) -> 
--R      SquareMatrix(2,Integer) 
--R
--R   (26)
--R    +1  2+  +7   10+  +37  54 +  +199  290+  +1069  1558+  +5743   8370 +
--R   [|    |, |      |, |       |, |        |, |          |, |            |,
--R    +3  4+  +15  22+  +81  118+  +435  634+  +2337  3406+  +12555  18298+
--R    +30853  44966+  +165751  241570+  +890461   1297782+  +4783807   6972050 +
--R    |            |, |              |, |                |, |                  |,
--R    +67449  98302+  +362355  528106+  +1946673  2837134+  +10458075  15241882+
--R    ...]
--R                                 Type: InfiniteTuple(SquareMatrix(2,Integer))
--E 26
)spool 
)lisp (bye)