
Number System in Computer
Numbers inside a computer are represented using different types of number systems. Some important number systems are:
1. Binary Number System
-
Base: 2
-
Digits Used: 0 and 1
-
This is the most fundamental number system for computers because computers process data only in binary form.
-
Example: (1010)2
The binary number (1010)2 is equal to decimal 10.
2. Octal Number System
-
Base: 8
-
Digits Used: 0 to 7
-
Used to represent binary numbers in a shorter form.
-
Example: (237)8
3. Decimal Number System
-
Base: 10
-
Digits Used: 0 to 9
-
This is the standard number system used by humans.
-
Example: (123)10
4. Hexadecimal Number System
-
Base: 16
-
Digits Used: 0 to 9 and A to F
-
A = 10
-
B = 11
-
C = 12
-
D = 13
-
E = 14
-
F = 15
-
Used in memory addressing, programming, and color coding.
-
Example: (A2F)16
Number System Conversions
Different number systems can be converted into one another.
Decimal to Binary
1010=10102
Binary to Hexadecimal
10102=A16
Examples
1. Binary Number System (Base 2)
Digits used: 0 and 1
Example:
10102
Binary to Decimal Conversion
1×23+0×22+1×21+0×20
=8+0+2+0
=1010
2. Decimal Number System (Base 10)
Digits used: 0 to 9
Example:
4510
Decimal to Binary Conversion
4510=1011012
3. Octal Number System (Base 8)
Digits used: 0 to 7
Example:
258
Octal to Decimal Conversion
2×81+5×80
=16+5
=2110
4. Hexadecimal Number System (Base 16)
Digits used: 0-9 and A-F
Example:
1A316
Hexadecimal to Decimal Conversion
1×162+A×161+3×160
=1×256+10×16+3×1
=256+160+3
=41910
Representation of the Same Number in Different Number Systems
| Number System | Representation |
|---|
| Decimal | 2910 |
| Binary | 111012 |
| Octal | 358 |
| Hexadecimal | 1D16 |
Importance of Number Systems in Computers
All types of data inside a computer, including text, images, audio, and videos, are stored and processed in binary form. Therefore, understanding number systems is very important in computer science and programming.
Hindi Version:
कंप्यूटर के अंदर संख्याओं को विभिन्न प्रकार के नंबर सिस्टम का उपयोग करके दर्शाया जाता है। इनमें से कुछ प्रमुख नंबर सिस्टम हैं:
-
बाइनरी नंबर सिस्टम (Binary Number System):
- कंप्यूटर के लिए सबसे मूलभूत नंबर सिस्टम है।
- इसमें केवल दो अंकों का उपयोग होता है: 0 और 1.
- आधार (Base) 2 होता है।
- उदाहरण: (101)2
-
ऑक्टल नंबर सिस्टम (Octal Number System):
- आठ अंकों का उपयोग होता है: 0 से 7 तक।
- आधार (Base) 8 होता है।
- उदाहरण: (237)8
-
डेसिमल नंबर सिस्टम (Decimal Number System):
- दस अंकों का उपयोग होता है: 0 से 9 तक।
- आधार (Base) 10 होता है।
- उदाहरण: (123)10
-
हेक्साडेसिमल नंबर सिस्टम (Hexadecimal Number System):
- सोलह अंकों का उपयोग होता है: 0 से 9 तक और A से F तक।
- आधार (Base) 16 होता है।
- उदाहरण: (A2F)16
इन नंबर सिस्टमों के बीच रूपांतरण (Conversion) किया जा सकता है। उदाहरण के लिए, एक बाइनरी संख्या को डेसिमल संख्या में या एक डेसिमल संख्या को हेक्साडेसिमल संख्या में बदला जा सकता है।
कंप्यूटर के अंदर सभी डेटा, चाहे वह टेक्स्ट हो, इमेज हो या वीडियो, बाइनरी संख्याओं के रूप में संग्रहित किया जाता है। इसलिए, कंप्यूटर नंबर सिस्टम का अध्ययन कंप्यूटर विज्ञान में महत्वपूर्ण है।
1. बाइनरी नंबर सिस्टम (Binary Number System)
- बेस (Base): 2
- डिजिट्स: 0 और 1
- यह कंप्यूटर का मूलभूत नंबर सिस्टम है क्योंकि कंप्यूटर केवल बाइनरी में डेटा प्रोसेस करता है।
- उदाहरण: 10102
(यह बाइनरी संख्या 10 के बराबर होती है।)
2. दशमलव नंबर सिस्टम (Decimal Number System)
- बेस (Base): 10
- डिजिट्स: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
- यह मनुष्यों द्वारा उपयोग किया जाने वाला सामान्य नंबर सिस्टम है।
- उदाहरण: 2510
3. ऑक्टल नंबर सिस्टम (Octal Number System)
- बेस (Base): 8
- डिजिट्स: 0, 1, 2, 3, 4, 5, 6, 7
- बाइनरी को छोटा करने के लिए इस नंबर सिस्टम का उपयोग किया जाता है।
- उदाहरण: 178
(यह दशमलव में 15 के बराबर है।)
4. हैक्साडेसिमल नंबर सिस्टम (Hexadecimal Number System)
- बेस (Base): 16
- डिजिट्स: 0-9 और A-F (जहां A=10, B=11, ..., F=15)
- इसका उपयोग मेमोरी एड्रेसिंग और कलर कोडिंग में किया जाता है।
- उदाहरण: 1F16
(यह दशमलव में 31 के बराबर है।)
बदलाव (Conversions)
कंप्यूटर में नंबर सिस्टम के बीच परिवर्तन करना आवश्यक होता है।
उदाहरण:
- दशमलव से बाइनरी
10 (Decimal) → 10102 (Binary) - बाइनरी से हैक्साडेसिमल
10102 (Binary) → A16 (Hexadecimal)
Example:-
1. बाइनरी नंबर सिस्टम (Base 2)
- संख्या: केवल 0 और 1 का उपयोग।
- उदाहरण:
- 10102
- बाइनरी से दशमलव: 1×23+0×22+1×21+0×20=8+0+2+0=1010
2. दशमलव नंबर सिस्टम (Base 10)
- संख्या: 0 से 9 तक।
- उदाहरण:
- 4510
- दशमलव से बाइनरी: 4510→1011012
3. ऑक्टल नंबर सिस्टम (Base 8)
- संख्या: 0 से 7 तक।
- उदाहरण:
- 258
- ऑक्टल से दशमलव: 2×81+5×80=16+5=2110
4. हैक्साडेसिमल नंबर सिस्टम (Base 16)
- संख्या: 0-9 और A-F (जहां A=10, B=11, ..., F=15)।
- उदाहरण:
- 1A316
- हैक्साडेसिमल से दशमलव:
1×162+A×161+3×160
=1×256+10×16+3×1=256+160+3=41910
विभिन्न नंबर सिस्टम में एक ही संख्या का प्रदर्शन
- दशमलव (Decimal): 2910
- बाइनरी (Binary): 111012
- ऑक्टल (Octal): 358
- हैक्साडेसिमल (Hexadecimal): 1D16
0 Comments
Please comment any query