@@ -46,25 +46,25 @@ This is the fundamental unit of *SpaceTime*.
46
46
---
47
47
###Pair points a pair of objects
48
48
49
- ![ ] ( http://localhost:18080/contents/img/pairab.png )
49
+ ![ ] ( http://localhost:18080/contents/img/002.svg )
50
50
51
51
Now, a ` Pair ` points objects: ` a ` and ` b ` .
52
52
53
53
---
54
54
###Pair notation
55
- ![ ] ( http://localhost:18080/contents/img/pairabnotation.png )
55
+ ![ ] ( http://localhost:18080/contents/img/003.svg )
56
56
57
57
When a ` Pair ` points objects: ` a ` and ` b ` , it's expressed as ** {a b}** in ` Pair notation ` .
58
58
59
59
---
60
60
###Pair can point itself
61
61
62
- ![ ] ( http://localhost:18080/contents/img/emptypairentity.png )
62
+ ![ ] ( http://localhost:18080/contents/img/004.svg )
63
63
64
64
---
65
65
###Empty Pair
66
66
67
- ![ ] ( http://localhost:18080/contents/img/emptypairnotation.png )
67
+ ![ ] ( http://localhost:18080/contents/img/005.svg )
68
68
69
69
70
70
@@ -75,7 +75,7 @@ Accordingly, the `Pair notaion` is { { {...} {...} } { {...} {...} } }, so we si
75
75
---
76
76
###Push Pair
77
77
78
- ![ ] ( http://localhost:18080/contents/img/push5.png )
78
+ ![ ] ( http://localhost:18080/contents/img/006.svg )
79
79
80
80
A ` Pair ` can point another ` Pair ` so that we can joint ` Pair ` s.
81
81
@@ -90,7 +90,7 @@ The `Pair notation` is **{ {} 5 }**.
90
90
---
91
91
###Push another Pair
92
92
93
- ![ ] ( http://localhost:18080/contents/img/push2.png )
93
+ ![ ] ( http://localhost:18080/contents/img/007.svg )
94
94
95
95
In the same manner, we can ` push ` another ` Pair ` .
96
96
@@ -101,12 +101,12 @@ The `Pair notation` is **{ { {} 5 } 2 }**.
101
101
---
102
102
###Push to any sequence
103
103
104
- ![ ] ( http://localhost:18080/contents/img/push7.png )
104
+ ![ ] ( http://localhost:18080/contents/img/008.svg )
105
105
106
106
---
107
107
###Sequence
108
108
109
- ![ ] ( http://localhost:18080/contents/img/sequence527.png )
109
+ ![ ] ( http://localhost:18080/contents/img/009.svg )
110
110
111
111
Here, * SpaceTime* explicitly defines a term ` Sequence ` for this form.
112
112
Please note this is the same term and meaning of [ Sequence] ( http://en.wikipedia.org/wiki/Sequence ) in Mathematics.
@@ -116,7 +116,7 @@ At the same time, instead of `Pair notation` : { { { {} 5 } 2 } 7 }, it can be s
116
116
---
117
117
###Push function
118
118
119
- ![ ] ( http://localhost:18080/contents/img/function5.png )
119
+ ![ ] ( http://localhost:18080/contents/img/010.svg )
120
120
121
121
A ` Pair ` can point ` function ` .
122
122
@@ -127,36 +127,25 @@ In this case, we `push` a `function` to **(5)**.
127
127
---
128
128
###A case of Push function
129
129
130
- ![ ] ( http://localhost:18080/contents/img/plus52.png )
130
+ ![ ] ( http://localhost:18080/contents/img/011.svg )
131
131
132
132
When we push a ` function ` : ` plus2 ` to ** (5)** , the result is ** (7)** .
133
133
134
134
---
135
135
###Function is Sequence
136
-
137
- ![ ] ( http://localhost:18080/contents/img/functionissequence.png )
138
-
139
136
The ` function ` : ` plus2 ` is fundamentally some ` Sequence ` .
140
137
141
138
` plus2 ` consists of a ` Sequence ` : ** ( plus (2) )** .
142
139
143
140
** (2)** is an ` attribute Sequence ` of the ` function ` .
144
141
145
- ---
146
- ###Evaluation of a Sequence containing a function
147
-
148
- ![ ] ( http://localhost:18080/contents/img/fullsequence527.png )
149
-
150
142
** ( 5 (plus (2)) )** is equivalent to ** (7)** .
151
143
152
144
---
153
- ### Everything is function and Sequence
145
+ ### Everything is a function and Sequence
154
146
155
- ![ ] ( http://localhost:18080/contents/img/think53.png )
147
+ ![ ] ( http://localhost:18080/contents/img/012.svg )
156
148
157
- ![ ] ( http://localhost:18080/contents/img/actually53is.png )
158
- ![ ] ( http://localhost:18080/contents/img/so3isfunction.png )
159
- ![ ] ( http://localhost:18080/contents/img/so3isfunction2.png )
160
149
161
150
Everything is ` function ` in * SpaceTime* .
162
151
@@ -173,12 +162,12 @@ However, `3` is `3`. There is no other way to express than just `3` in *SpaceTim
173
162
---
174
163
###Every Sequence is a result of function to ` Empty Pair `
175
164
176
- ![ ] ( http://localhost:18080/contents/img/so5isalsofunction.png )
165
+ ![ ] ( http://localhost:18080/contents/img/013.svg )
177
166
178
167
---
179
168
###Function composition
180
169
181
- ![ ] ( http://localhost:18080/contents/img/functioncomposition.png )
170
+ ![ ] ( http://localhost:18080/contents/img/014.svg )
182
171
183
172
[ Function composition] ( http://en.wikipedia.org/wiki/Function_composition ) is naturally expressed in a form :
184
173
** ( * source function fucnction )** in * SpaceTime* .
@@ -188,21 +177,21 @@ Please note the `source` = **( 1 )** as a `Sequence`, not 1.
188
177
---
189
178
###1 +2 +3 = 6
190
179
191
- ![ ] ( http://localhost:18080/contents/img/plus123.png )
180
+ ![ ] ( http://localhost:18080/contents/img/015.svg )
192
181
193
182
* SpaceTime* has a short-cut notation : ** +** corresponding to ` plus ` function.
194
183
195
184
---
196
185
###1 +(2 +3) = 6
197
186
198
- ![ ] ( http://localhost:18080/contents/img/plust1and23.png )
187
+ ![ ] ( http://localhost:18080/contents/img/016.svg )
199
188
200
189
( 1 (+ ( 2 (+ ( 3 ) ) ) ) ) = ( 6 )
201
190
202
191
---
203
192
###Indefinite sequence
204
193
205
- ![ ] ( http://localhost:18080/contents/img/naturaltake10.png )
194
+ ![ ] ( http://localhost:18080/contents/img/017.svg )
206
195
207
196
* SpaceTime* employes an [ evaluation strategy] ( http://en.wikipedia.org/wiki/Evaluation_strategy ) : [ lazy evaluation, or call-by-need] ( http://en.wikipedia.org/wiki/Lazy_evaluation ) .
208
197
@@ -211,26 +200,70 @@ Accordingly, *SpaceTime* can deal with Indefinite sequence such as [Natural numb
211
200
---
212
201
###I/O (Input and Output)
213
202
214
- ![ ] ( http://localhost:18080/contents/img/console5.png )
203
+ ![ ] ( http://localhost:18080/contents/img/018.svg )
215
204
216
205
[ I/O] ( http://en.wikipedia.org/wiki/Input/output ) does not affect the evaluation context of * SpaceTime* directly, so that it can preserve [ Functional programming] ( http://en.wikipedia.org/wiki/Functional_programming ) paradigm.
217
206
218
207
* SpaceTime* employes [ FRP] ( http://en.wikipedia.org/wiki/Functional_reactive_programming ) or ` SpaceTime Programming paradigm ` .
219
208
220
209
---
221
- ###Hello world
222
210
223
- ![ ] ( http://localhost:18080/contents/img/helloworld.png )
224
211
212
+ ##Basic
213
+ ---
214
+ ###Hello world
215
+ ` Code `
216
+ ```
217
+ (
218
+ "hello World"
219
+ (map (CONSOLE))
220
+ )
221
+ ```
222
+ ` Evalation `
223
+ ```
224
+ ("hello World")
225
+ ```
226
+ ` Console `
227
+ ```
228
+ hello World
229
+ ```
225
230
---
226
231
###Hello world twice
227
232
228
- ![ ] ( http://localhost:18080/contents/img/helloworld2.png )
233
+ ` Code `
234
+ ```
235
+ (
236
+ "hello World"
237
+ (map (CONSOLE))
238
+ (map (CONSOLE))
239
+ )
240
+ ```
241
+ ` Evalation `
242
+ ```
243
+ ("hello World")
244
+ ```
245
+ ` Console `
246
+ ```
247
+ hello World
248
+ hello World
249
+ ```
229
250
230
251
---
231
- ###Map any Sequence to the console
232
-
233
- ![ ] ( http://localhost:18080/contents/img/fibconsole.png )
252
+ ###Boolean
253
+
254
+
255
+ ` Code `
256
+ ```
257
+ (
258
+ "hello World"
259
+ (map (CONSOLE))
260
+ (map (CONSOLE))
261
+ )
262
+ ```
263
+ ` Evalation `
264
+ ```
265
+ ("hello World")
266
+ ```
234
267
235
268
---
236
269
0 commit comments