| English | 意味 |
|---|---|
| carry/ˈkæri/ | Carry(進位) |
| half adder/hɑːf ˈædə/ | ハーフアダクター |
| full adder/fʊl ˈædə/ | フル加法器 |
| flip-flop/flɪp flɒp/ | フリップフロップ |
| ripple-carry adder/ˈrɪpl ˈkæri ˈædə/ | Ripple-carry 加法器(波伝送型加法器) |
| bistable/baɪˈsteɪbl/ | 双安定回路 |
| counters/ˈkaʊntəz/ | カウンタ |
| SRAM/ˈesræm/ | 静的RAM |
| SR flip-flop/ˌes ˈɑː flɪp flɒp/ | SRフリップフロップ |
| JK flip-flop/ˌdʒeɪ ˈkeɪ flɪp flɒp/ | JKフリップフロップ |
| toggle/ˈtɒɡl/ | トグル |
How a machine that only knows true and false does arithmetic
- A processor has no adder in the sense of a thing that knows numbers. It has gates that answer true or false, and nothing else.
- Yet $1 + 1 = 10$ falls out of two gates: an XOR gives the sum digit, an AND gives the carry. That is the entire arithmetic unit in miniature, and chaining copies of it adds numbers of any width.
- The other half of a computer is remembering, and one bit of memory is also just gates, wired so that their outputs feed back into their inputs and hold.
- This lesson is the half adder 半加器, the full adder 全加器, and the flip-flop 触发器 that stores a bit.
The half adder
- A half adder adds two single bits, $A$ and $B$, producing a sum $S$ and a carry 进位 $C$.
| A | B | S | C |
|---|---|---|---|
| 0 | 0 | 0 | 0 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 1 | 0 |
| 1 | 1 | 0 | 1 |
- Read the columns: $S$ is 1 when exactly one input is 1, which is XOR. $C$ is 1 only when both are 1, which is AND. So $S = A \oplus B$ and $C = A \cdot B$.
- It ignores any carry in, which is why it is only "half" an adder and cannot be chained on its own.

Two gates, and binary addition exists
加算器内部のゲート
ハーフ加算器の和 bit は XOR ゲート、 carry bit は AND ゲートです — A と B を切り替えて、真値表の行が点灯するか確認してください。
ハーフ加算器において、和出力 S はどのゲートによって生成されますか?
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
$S = A \text{ XOR } B$(入力が異なると 1)、carry は $A \text{ AND } B$ です。
ハーフ加算器において、carry 出力 C はどの単一のゲートによって生成されますか?
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
C は両方の入力が 1 のときにのみ 1 となり、これは AND です。和 S はちょうど一方の入力が 1 のときに 1 となり、これは XOR です。
The full adder
- A full adder adds three bits: $A$, $B$ and a carry-in, producing a sum and a carry-out. $S = A \oplus B \oplus C_{\text{in}}$.
- It can be built from two half adders plus an OR gate: the first half adder adds $A$ and $B$, the second adds that sum to the carry-in, and the OR combines the two carries.
- Chain full adders so that each carry-out feeds the next carry-in, and you have a multi-bit ripple-carry adder 行波进位加法器: four of them add two 4-bit numbers.

The carry is what has to travel, which is why it is called ripple
各構成要素与其功能进行匹配。
難易度 2/5 · 140 コイン + 今日初回完了時に小ボーナス付与
加算器はビットを加算する(多ビット加算にはフルアダーを連鎖させる)。フリップフロップはビットを格納する(JKフリップフロップはSRの禁止状態を回避する)。
フル加算器はハーフ加算器とどう異なりますか?
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
フル加法器はA、B、および carry-in を加算します(加法器の連鎖が可能)。2つの半加法器とORゲートから構成されます。
Worked example: why a full adder, not two half adders
- Explain why a 4-bit adder is built from full adders rather than half adders.
- Adding two 4-bit numbers column by column, every column except the rightmost may receive a carry from the column to its right, so it has three inputs to add, not two.
- A half adder has no carry-in, so it cannot take that third input, and the carry would simply be lost.
- Only the least significant column has no carry-in, so a half adder would do there; in practice all four are full adders, with the first carry-in tied to 0.
なぜ 4-bit 加算器はハーフ加算器ではなくフル加算器を使用しなければならないのか?
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
ハーフ加算器は carry を生成しますが、carry-in がないため、前の列から届いた carry を受け取ることができません。
4-bit リプルキャリー加算器の構成手順を正しい順番に並べ替えてください。
難易度 3/5 · 200 コイン + 今日初回完了時に小ボーナス付与
ゲートがハーフ加算器を作り、ハーフ加算器がフル加算器を作り、フル加算器がワード幅の加算器に連鎖されます。carry が伝播していくことが名前の由来です。
Flip-flops
- A flip-flop is a bistable 双稳态 circuit: it has two stable states, 0 and 1, and it remembers the one it is in. It stores exactly one bit.
- It is the basic element of registers, where $n$ bits means $n$ flip-flops, of counters, and of SRAM 静态RAM cells.
- Unlike an adder, whose output depends only on its inputs now, a flip-flop's output depends on its past inputs. That is what memory means at the circuit level.
フリップフロップは以下の目的で使用されます:
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
フリップフロップには2つの安定状態があり、1 bit を保持します — レジスタや SRAM の構成要素です。
フリップフロップは双安定であり、2つの安定状態を持ち、1 bit を記憶するため、レジスタや SRAM の構成要素となっています。
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
フリップフロップを連鎖させることでレジスタやカウンタが作られ、SRAM キャッシュもこれらから構成されます(DRAMとは異なりリフレッシュは不要です)。
SR and JK
- An SR flip-flop SR触发器 has inputs S (set) and R (reset) and outputs $Q$ and $\overline{Q}$, built from two cross-coupled NOR gates.
S=1, R=0sets $Q$ to 1.S=0, R=1resets $Q$ to 0.S=0, R=0holds the current state, which is the memory.S=1, R=1is invalid: it asks for set and reset at once.- A JK flip-flop JK触发器 removes that flaw by giving the
1,1input a meaning: toggle 翻转, so the output flips to its opposite. That makes it ideal for counters 计数器, since a chain of toggling flip-flops counts in binary. - A JK is usually clocked: the inputs act only on a clock edge, which keeps every flip-flop in the machine in step.

The invalid input turned into a useful one
SR フリップフロップについて、正しい文を全て選択してください。すべて選択してください。
難易度 2/5 · 140 コイン + 今日初回完了時に小ボーナス付与
1,1でトグルすることはJKフリップフロップの改良点です。SRでは、セットとリセットを同時に要求する入力であり、無効な状態になります。
JKフリップフロップのトグル動作は、カウンタを構築するのに適している理由です。
難易度 1/5 · 100 コイン + 今日初回完了時に小ボーナス付与
各が入力に追従してトグルするフリップフロップの鎖は、バイナリでカウントします。クロックをかけることで、すべてのステージが同期した状態を保ちます。
Worked example: trace an SR flip-flop
- $Q$ is currently 0. Give $Q$ after the inputs S=1 R=0, then S=0 R=0, then S=0 R=1.
- S=1, R=0 sets the output, so $Q$ becomes 1.
- S=0, R=0 holds, so $Q$ stays 1. This is the step that shows it is a memory: the inputs say nothing, and the output persists.
- S=0, R=1 resets, so $Q$ becomes 0. If S=1 and R=1 were applied, the answer is that the input is invalid, not a value.
Marks that slip away
- $S = A \oplus B$ and $C = A \cdot B$: XOR for the sum, AND for the carry. Swapping them loses both marks.
- "Half" means no carry-in, not "half the bits".
- A full adder is two half adders plus an OR, and the OR combines the two carries.
- On an SR flip-flop,
0,0holds and1,1is invalid. The JK's improvement is that1,1toggles.
You've got it
- half adder: two bits in, $S = A \oplus B$ from an XOR and $C = A \cdot B$ from an AND; no carry-in
- full adder: three bits in, built from two half adders plus an OR; chain them, carry-out to carry-in, for a ripple-carry adder
- a flip-flop is bistable and stores one bit; $n$ flip-flops make an $n$-bit register, and they are the cells of SRAM
- SR: set, reset,
0,0holds,1,1invalid · JK:1,1toggles, which is what makes counters, and it is clocked to stay synchronised