Số nhị phân
Đã giới thiệu| English | Ý nghĩa |
|---|---|
| bit/bɪt/ | bit |
| binary/ˈbaɪnəri/ | nhị phân |
| decimal/ˈdesɪml/ | thập phân |
| power of two/ˈpaʊə ɒv tuː/ | lũy thừa của hai |
| fixed number of bits/fɪkst ˈnʌmbə ɒv bɪts/ | số bit cố định |
| overflow error/ˌəʊvəˈfləʊ ˈerə/ | lỗi tràn dữ liệu |
| Analog/ˈænəlɒɡ/ | tương tự |
| digital/ˈdɪdʒɪtl/ | chữ số |
| sample/ˈsæmpl/ | mẫu |
| byte/baɪt/ | byte: byte |
Everything is bits
- Deep down, a computer knows only two states: on and off, written 1 and 0.
- A bit 位 is a single 0 or 1 — the smallest piece of data.
- Two states are easy to build from a wire (voltage or none) and hard to confuse.
- Counting with two digits is binary 二进制 (base 2); everyday decimal 十进制 (base 10) uses ten.
Một số 0 hoặc 1 đơn lẻ, mảnh dữ liệu nhỏ nhất, được gọi là ______.
Độ khó 1/5 · 100 xu + một phần thưởng nhỏ cho lần hoàn thành đầu tiên trong ngày
Tám bit nhóm thành một byte.
Place values and conversion
- In binary, each position is a power of two 2 的幂, doubling leftward: $\dots, 8, 4, 2, 1$.
- To read binary → decimal, add the position values where there is a 1.
- To go decimal → binary, keep subtracting the largest power of two that fits.
Binary to decimal: $1011$ lines up with $8, 4, 2, 1$. The 1-bits are at $8, 2, 1$, so $8 + 0 + 2 + 1 = 11$. Decimal to binary: for $13$, take $8$ (leaves 5), then $4$ (leaves 1), skip $2$, take $1$ → $1101$.

An 8-bit place-value chart: the 1s sit under the values that add to the number
Giá trị vị trí nhị phân
value = Σ giá trị vị trí nơi bit bằng 1
Xem cách một mẫu 8-bit ánh xạ sang số thập phân bằng cách cộng các giá trị vị trí (128, 64, 32, 16, 8, 4, 2, 1) tại mọi vị trí có số 1.
Số nhị phân 1011 là bao nhiêu trong hệ thập phân?
Độ khó 2/5 · 140 xu + một phần thưởng nhỏ cho lần hoàn thành đầu tiên trong ngày
Giá trị vị trí 8,4,2,1 với các bit 1 ở vị trí 8,2,1: 8+2+1 = 11.
Số thập phân 13 là bao nhiêu trong hệ nhị phân?
Độ khó 1/5 · 100 xu + một phần thưởng nhỏ cho lần hoàn thành đầu tiên trong ngày
8 + 4 + 1 = 13, vì vậy các bit 8,4,1 được bật: 1101.
Với 4 bit, giá trị lớn nhất bạn có thể lưu trữ là gì (2^4 − 1)?
Độ khó 2/5 · 140 xu + một phần thưởng nhỏ cho lần hoàn thành đầu tiên trong ngày
2^4 = 16 mẫu, từ 0 đến 15. Cộng thêm 15+1 gây tràn.
Fixed bits and overflow
- Computers store numbers in a fixed number of bits 固定位数, such as 8 or 16.
- With $n$ bits you can make $2^n$ patterns, from $0$ up to $2^n - 1$.
- If a result is too big to fit, the extra bits are lost — an overflow error 溢出错误.
- Worked idea. With 4 bits the largest value is $2^4 - 1 = 15$; adding $15 + 1$ needs a 5th bit that does not exist, so it overflows.
Biến đổi sóng âm liên tục thành các bit bằng cách lấy nhiều phép đo lường được gọi là:
Độ khó 1/5 · 100 xu + một phần thưởng nhỏ cho lần hoàn thành đầu tiên trong ngày
Mỗi phép đo là một mẫu; kết quả được lưu trữ là dữ liệu kỹ thuật số.
Analog to digital
- Analog 模拟 data is smooth and continuous, like a real sound wave.
- To store it, a computer takes many quick measurements; each is a sample 采样.
- Each sample is rounded to the nearest storable value, so the copy only approximates the original.
- More samples and more bits per sample give a closer copy — the result is digital 数字 data.
Một byte có bao nhiêu bit?
Độ khó 2/5 · 140 xu + một phần thưởng nhỏ cho lần hoàn thành đầu tiên trong ngày
Tám bit tạo thành một byte.
Bytes
- Bits are tiny, so we group them: eight bits make one byte 字节.
- A byte is the common unit of data size — enough for one letter of English text.
- Bigger units build on it: ~1000 bytes is a kilobyte, ~a million is a megabyte.
- Worked idea. A 200-letter message at 1 byte each is 200 bytes, or $200 \times 8 = 1600$ bits.
A bit is one 0/1; binary (base 2) uses place values that are powers of two, so $1011_2 = 8+2+1 = 11$. A fixed number of bits limits the range to $2^n-1$; exceeding it is an overflow error. Analog signals become digital by sampling, and eight bits group into one byte.