Skip to content

Commit 1ddf111

Browse files
committed
update
1 parent f8a0a79 commit 1ddf111

8 files changed

Lines changed: 66 additions & 36 deletions

File tree

_site/0-book/unit-6/section-1/0-null.md

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ These examples illustrate that "absence," "emptiness," or "nullity" is not merel
2424

2525
## 2. The Theoretical Pillar: From Function Pipelines to Algebraic Structures (A Revisit)
2626

27-
Before diving into the core of the "absence" debate, we must return to the theoretical pillar of this book. This is the deliberate, logical flow, established in Unit 2, of how the definition of an **"algebraic structure"** is naturally derived from the idea of a **"function pipeline."
27+
Before diving into the core of the "absence" debate, we must return to the theoretical pillar of this book. This is the deliberate, logical flow, established in Unit 2, of how the definition of an **"algebraic structure"** is naturally derived from the idea of a **"function pipeline."**
2828

2929
First, our starting point is the fundamental concept in functional programming: the "pipeline," where data flows through a series of functions.
3030

@@ -202,13 +202,22 @@ We position this approach as a **theoretically valid path** that consciously div
202202

203203
## 2. 理論的支柱:関数パイプラインから代数構造へ (再訪)
204204

205-
この「不在」を巡る議論の核心に迫る前に、我々は本書の理論的支柱となっている基本原則に立ち返る必要があります。それは、Unit 2で確立した、**「関数パイプライン」**の考え方から、いかにして**「代数構造」**の定義が自然に導かれるか、という丁寧な論理の流れです。
205+
この「不在」を巡る議論の核心に迫る前に、我々は本書の理論的支柱となっている基本原則に立ち返る必要があります。それは、Unit 2で確立した、**「関数パイプライン」** の考え方から、いかにして **「代数構造」** の定義が自然に導かれるか、という丁寧な論理の流れです。
206206

207207
まず、我々の出発点は、データが関数の連なりを流れていく「パイプライン」という、関数型プログラミングの基本的な考え方です。
208208

209209
![Pipeline Flow](https://raw.githubusercontent.com/ken-okabe/web-images5/main/img_1744449185892.png)
210210

211-
1. **パイプラインの構成要素**: * すべてのパイプラインは、特定の**型 (Type)** を持つデータを扱います。 * **関数 (Function)** が、このデータを明確に定義された方法で変換します。 * これにより、我々は自然と `(Type, Function)` というペアを扱うことになります。2. **二項演算子は関数である**: * `1 + 2`のような一般的な二項演算も、一種の**関数**である、という視点を取り入れます。例えば、`+` という演算子は、`(int, int) -> int` という型を持つ関数と見なせます。(カリー化)3. **型と集合の対応**: * プログラミングにおける **型 (Type)**は、数学における**集合 (Set)** と深く対応します。`int`型は整数の集合、`bool`型は`{true, false}`という集合、`string`型はあらゆる文字列の集合と考えることができます。
211+
1. **パイプラインの構成要素**:
212+
* すべてのパイプラインは、特定の**型 (Type)** を持つデータを扱います。
213+
* **関数 (Function)** が、このデータを明確に定義された方法で変換します。
214+
* これにより、我々は自然と `(Type, Function)` というペアを扱うことになります。
215+
216+
2. **二項演算子は関数である**:
217+
* `1 + 2`のような一般的な二項演算も、一種の**関数**である、という視点を取り入れます。例えば、`+` という演算子は、`(int, int) -> int` という型を持つ関数と見なせます。(カリー化)
218+
219+
3. **型と集合の対応**:
220+
* プログラミングにおける **型 (Type)**は、数学における**集合 (Set)** と深く対応します。`int`型は整数の集合、`bool`型は`{true, false}`という集合、`string`型はあらゆる文字列の集合と考えることができます。
212221

213222
これらの洞察を統合すると、我々の目の前に明確な対応関係が浮かび上がります。
214223

@@ -219,7 +228,7 @@ We position this approach as a **theoretically valid path** that consciously div
219228

220229
パイプラインで扱っていた `(Type, Function)` のペアは、数学の世界で**代数構造**と呼ばれる `(Set, Operation)` のペアと、概念的に全く同じものだったのです。
221230

222-
結論として、代数構造とは、小難しい数学の話ではなく、**「あるデータ型(集合)と、そのデータ型上での構造を維持する一連の操作(関数)の組み合わせ」**という、我々にとって極めて身近な設計パターンのことに他なりません。
231+
結論として、代数構造とは、小難しい数学の話ではなく、**「あるデータ型(集合)と、そのデータ型上での構造を維持する一連の操作(関数)の組み合わせ」** という、我々にとって極めて身近な設計パターンのことに他なりません。
223232

224233
この後の議論は、すべてこの単純かつ強力な原則の上に成り立っています。
225234

_site/0-book/unit-6/section-2/0-bind-chain.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,16 @@ step0.define(Now, "Hello!");
5858
This `Timeline` `bind` chain is similar to `Promise.then` in many ways.
5959

6060
* **Sequential Execution**: The next operation starts after the previous one is complete.
61-
* **Value Passing**: The result of the previous step is passed to the next step.
61+
62+
* **Value Passing**: The result of the previous step is passed to the next step.
6263

6364
However, there are also important differences in the fundamental approach.
6465

6566
* **Reactive**: `Timeline` is a reactive system that automatically triggers subsequent operations in response to value changes.
66-
* **Explicit Receiving Timeline**: You need to pre-define a dedicated `Timeline` to receive the result of each step.
67-
* **Synchronous Return Value**: The `bind` function itself must **synchronously** return the `Timeline` to wait for next, without waiting for the asynchronous operation to complete.
67+
68+
* **Explicit Receiving Timeline**: You need to pre-define a dedicated `Timeline` to receive the result of each step.
69+
70+
* **Synchronous Return Value**: The `bind` function itself must **synchronously** return the `Timeline` to wait for next, without waiting for the asynchronous operation to complete.
6871

6972
-----
7073

@@ -223,13 +226,16 @@ step0.define(Now, "Hello!");
223226
この`Timeline``bind`チェーンは、`Promise.then`と多くの点で似ています。
224227

225228
* **順次実行**: 前の処理が完了してから次の処理が開始されます。
226-
* **値の引き継ぎ**: 前のステップの結果が次のステップに渡されます。
229+
230+
* **値の引き継ぎ**: 前のステップの結果が次のステップに渡されます。
227231

228232
しかし、根本的なアプローチには重要な違いもあります。
229233

230234
* **リアクティブ**: `Timeline`は値の変化に反応して自動的に後続処理をトリガーする、リアクティブなシステムです。
231-
* **明示的な受信Timeline**: 各ステップの結果を受け取るための専用の`Timeline`を事前に定義する必要があります。
232-
* **同期的な戻り値**: `bind`関数自体は、非同期処理の完了を待たず、次に待機すべき`Timeline`**同期的**に返す必要があります。
235+
236+
* **明示的な受信Timeline**: 各ステップの結果を受け取るための専用の`Timeline`を事前に定義する必要があります。
237+
238+
* **同期的な戻り値**: `bind`関数自体は、非同期処理の完了を待たず、次に待機すべき`Timeline`**同期的**に返す必要があります。
233239

234240
-----
235241

_site/0-book/unit-7/section-1/2-monoidal-combinations.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -121,9 +121,9 @@ Chapter 1で学んだ`combineLatestWith`は、あらゆる2項演算を`Timeline
121121

122122
### 論理和: orOf
123123

124-
#### F\#**: `orOF: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
124+
##### F\#: `orOF: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
125125

126-
#### TS**: `orOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
126+
##### TS: `orOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
127127

128128
<!-- end list -->
129129

@@ -150,9 +150,9 @@ const orOf = (timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timel
150150

151151
### 論理積: andOf
152152

153-
#### F\#**: `andOf: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
153+
##### F\#: `andOf: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
154154

155-
#### TS**: `andOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
155+
##### TS: `andOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
156156

157157
2つの`Timeline<boolean>`を論理積(`&&`)で合成します。
158158

@@ -168,9 +168,9 @@ const orOf = (timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timel
168168

169169
### 加算: addOf
170170

171-
#### F\#**: (F\#版には直接のヘルパーなし。`combineLatestWith (+)` を使用)
171+
##### F\#: (F\#版には直接のヘルパーなし。`combineLatestWith (+)` を使用)
172172

173-
#### TS**: `addOf(timelineA: Timeline<number>, timelineB: Timeline<number>): Timeline<number>`
173+
##### TS: `addOf(timelineA: Timeline<number>, timelineB: Timeline<number>): Timeline<number>`
174174

175175
2つの`Timeline<number>`を加算(`+`)で合成します。
176176

@@ -186,9 +186,9 @@ const orOf = (timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timel
186186

187187
### 配列の結合: concatOf
188188

189-
**F\#**: `concatOf: Timeline<'a list> -> Timeline<'a> -> Timeline<'a list>`
189+
##### F\#: `concatOf: Timeline<'a list> -> Timeline<'a> -> Timeline<'a list>`
190190

191-
**TS**: `concatOf(timelineA: Timeline<any[]>, timelineB: Timeline<any>): Timeline<any[]>`
191+
##### TS: `concatOf(timelineA: Timeline<any[]>, timelineB: Timeline<any>): Timeline<any[]>`
192192

193193
`concat`は、2つの配列を結合して1つの新しい配列を作る操作です。この単純な操作もまた、極めて重要なMonoidを形成します。
194194

src/content/docs/en/book/unit-6/section-1/0-null.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ These examples illustrate that "absence," "emptiness," or "nullity" is not merel
3232

3333
## 2. The Theoretical Pillar: From Function Pipelines to Algebraic Structures (A Revisit)
3434

35-
Before diving into the core of the "absence" debate, we must return to the theoretical pillar of this book. This is the deliberate, logical flow, established in Unit 2, of how the definition of an **"algebraic structure"** is naturally derived from the idea of a **"function pipeline."
35+
Before diving into the core of the "absence" debate, we must return to the theoretical pillar of this book. This is the deliberate, logical flow, established in Unit 2, of how the definition of an **"algebraic structure"** is naturally derived from the idea of a **"function pipeline."**
3636

3737
First, our starting point is the fundamental concept in functional programming: the "pipeline," where data flows through a series of functions.
3838

src/content/docs/en/book/unit-6/section-2/0-bind-chain.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,16 @@ step0.define(Now, "Hello!");
6767
This `Timeline` `bind` chain is similar to `Promise.then` in many ways.
6868

6969
* **Sequential Execution**: The next operation starts after the previous one is complete.
70-
* **Value Passing**: The result of the previous step is passed to the next step.
70+
71+
* **Value Passing**: The result of the previous step is passed to the next step.
7172

7273
However, there are also important differences in the fundamental approach.
7374

7475
* **Reactive**: `Timeline` is a reactive system that automatically triggers subsequent operations in response to value changes.
75-
* **Explicit Receiving Timeline**: You need to pre-define a dedicated `Timeline` to receive the result of each step.
76-
* **Synchronous Return Value**: The `bind` function itself must **synchronously** return the `Timeline` to wait for next, without waiting for the asynchronous operation to complete.
76+
77+
* **Explicit Receiving Timeline**: You need to pre-define a dedicated `Timeline` to receive the result of each step.
78+
79+
* **Synchronous Return Value**: The `bind` function itself must **synchronously** return the `Timeline` to wait for next, without waiting for the asynchronous operation to complete.
7780

7881
-----
7982

src/content/docs/ja/book/unit-6/section-1/0-null.md

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,22 @@ description: >-
2525

2626
## 2. 理論的支柱:関数パイプラインから代数構造へ (再訪)
2727

28-
この「不在」を巡る議論の核心に迫る前に、我々は本書の理論的支柱となっている基本原則に立ち返る必要があります。それは、Unit 2で確立した、**「関数パイプライン」**の考え方から、いかにして**「代数構造」**の定義が自然に導かれるか、という丁寧な論理の流れです。
28+
この「不在」を巡る議論の核心に迫る前に、我々は本書の理論的支柱となっている基本原則に立ち返る必要があります。それは、Unit 2で確立した、**「関数パイプライン」** の考え方から、いかにして **「代数構造」** の定義が自然に導かれるか、という丁寧な論理の流れです。
2929

3030
まず、我々の出発点は、データが関数の連なりを流れていく「パイプライン」という、関数型プログラミングの基本的な考え方です。
3131

3232
![Pipeline Flow](https://raw.githubusercontent.com/ken-okabe/web-images5/main/img_1744449185892.png)
3333

34-
1. **パイプラインの構成要素**: * すべてのパイプラインは、特定の**型 (Type)** を持つデータを扱います。 * **関数 (Function)** が、このデータを明確に定義された方法で変換します。 * これにより、我々は自然と `(Type, Function)` というペアを扱うことになります。2. **二項演算子は関数である**: * `1 + 2`のような一般的な二項演算も、一種の**関数**である、という視点を取り入れます。例えば、`+` という演算子は、`(int, int) -> int` という型を持つ関数と見なせます。(カリー化)3. **型と集合の対応**: * プログラミングにおける **型 (Type)**は、数学における**集合 (Set)** と深く対応します。`int`型は整数の集合、`bool`型は`{true, false}`という集合、`string`型はあらゆる文字列の集合と考えることができます。
34+
1. **パイプラインの構成要素**:
35+
* すべてのパイプラインは、特定の**型 (Type)** を持つデータを扱います。
36+
* **関数 (Function)** が、このデータを明確に定義された方法で変換します。
37+
* これにより、我々は自然と `(Type, Function)` というペアを扱うことになります。
38+
39+
2. **二項演算子は関数である**:
40+
* `1 + 2`のような一般的な二項演算も、一種の**関数**である、という視点を取り入れます。例えば、`+` という演算子は、`(int, int) -> int` という型を持つ関数と見なせます。(カリー化)
41+
42+
3. **型と集合の対応**:
43+
* プログラミングにおける **型 (Type)**は、数学における**集合 (Set)** と深く対応します。`int`型は整数の集合、`bool`型は`{true, false}`という集合、`string`型はあらゆる文字列の集合と考えることができます。
3544

3645
これらの洞察を統合すると、我々の目の前に明確な対応関係が浮かび上がります。
3746

@@ -42,7 +51,7 @@ description: >-
4251

4352
パイプラインで扱っていた `(Type, Function)` のペアは、数学の世界で**代数構造**と呼ばれる `(Set, Operation)` のペアと、概念的に全く同じものだったのです。
4453

45-
結論として、代数構造とは、小難しい数学の話ではなく、**「あるデータ型(集合)と、そのデータ型上での構造を維持する一連の操作(関数)の組み合わせ」**という、我々にとって極めて身近な設計パターンのことに他なりません。
54+
結論として、代数構造とは、小難しい数学の話ではなく、**「あるデータ型(集合)と、そのデータ型上での構造を維持する一連の操作(関数)の組み合わせ」** という、我々にとって極めて身近な設計パターンのことに他なりません。
4655

4756
この後の議論は、すべてこの単純かつ強力な原則の上に成り立っています。
4857

src/content/docs/ja/book/unit-6/section-2/0-bind-chain.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,13 +61,16 @@ step0.define(Now, "Hello!");
6161
この`Timeline``bind`チェーンは、`Promise.then`と多くの点で似ています。
6262

6363
* **順次実行**: 前の処理が完了してから次の処理が開始されます。
64-
* **値の引き継ぎ**: 前のステップの結果が次のステップに渡されます。
64+
65+
* **値の引き継ぎ**: 前のステップの結果が次のステップに渡されます。
6566

6667
しかし、根本的なアプローチには重要な違いもあります。
6768

6869
* **リアクティブ**: `Timeline`は値の変化に反応して自動的に後続処理をトリガーする、リアクティブなシステムです。
69-
* **明示的な受信Timeline**: 各ステップの結果を受け取るための専用の`Timeline`を事前に定義する必要があります。
70-
* **同期的な戻り値**: `bind`関数自体は、非同期処理の完了を待たず、次に待機すべき`Timeline`**同期的**に返す必要があります。
70+
71+
* **明示的な受信Timeline**: 各ステップの結果を受け取るための専用の`Timeline`を事前に定義する必要があります。
72+
73+
* **同期的な戻り値**: `bind`関数自体は、非同期処理の完了を待たず、次に待機すべき`Timeline`**同期的**に返す必要があります。
7174

7275
-----
7376

src/content/docs/ja/book/unit-7/section-1/2-monoidal-combinations.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ Chapter 1で学んだ`combineLatestWith`は、あらゆる2項演算を`Timeline
1616

1717
### 論理和: orOf
1818

19-
#### F\#**: `orOF: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
19+
##### F\#: `orOF: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
2020

21-
#### TS**: `orOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
21+
##### TS: `orOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
2222

2323
<!-- end list -->
2424

@@ -45,9 +45,9 @@ const orOf = (timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timel
4545

4646
### 論理積: andOf
4747

48-
#### F\#**: `andOf: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
48+
##### F\#: `andOf: Timeline<bool> -> Timeline<bool> -> Timeline<bool>`
4949

50-
#### TS**: `andOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
50+
##### TS: `andOf(timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timeline<boolean>`
5151

5252
2つの`Timeline<boolean>`を論理積(`&&`)で合成します。
5353

@@ -63,9 +63,9 @@ const orOf = (timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timel
6363

6464
### 加算: addOf
6565

66-
#### F\#**: (F\#版には直接のヘルパーなし。`combineLatestWith (+)` を使用)
66+
##### F\#: (F\#版には直接のヘルパーなし。`combineLatestWith (+)` を使用)
6767

68-
#### TS**: `addOf(timelineA: Timeline<number>, timelineB: Timeline<number>): Timeline<number>`
68+
##### TS: `addOf(timelineA: Timeline<number>, timelineB: Timeline<number>): Timeline<number>`
6969

7070
2つの`Timeline<number>`を加算(`+`)で合成します。
7171

@@ -81,9 +81,9 @@ const orOf = (timelineA: Timeline<boolean>, timelineB: Timeline<boolean>): Timel
8181

8282
### 配列の結合: concatOf
8383

84-
**F\#**: `concatOf: Timeline<'a list> -> Timeline<'a> -> Timeline<'a list>`
84+
##### F\#: `concatOf: Timeline<'a list> -> Timeline<'a> -> Timeline<'a list>`
8585

86-
**TS**: `concatOf(timelineA: Timeline<any[]>, timelineB: Timeline<any>): Timeline<any[]>`
86+
##### TS: `concatOf(timelineA: Timeline<any[]>, timelineB: Timeline<any>): Timeline<any[]>`
8787

8888
`concat`は、2つの配列を結合して1つの新しい配列を作る操作です。この単純な操作もまた、極めて重要なMonoidを形成します。
8989

0 commit comments

Comments
 (0)