Computer Science
Numeral Systems
Numeral systems are methods of representing numbers using symbols. In computer science, the most commonly used numeral systems are binary (base-2), decimal (base-10), and hexadecimal (base-16). Binary is fundamental in digital systems, representing data using only two symbols (0 and 1). Decimal is the standard system for human use, while hexadecimal is widely used in computing for its compact representation of binary data.
Written by Perlego with AI-assistance
Related key terms
1 of 5
12 Key excerpts on "Numeral Systems"
- eBook - PDF
- Parag K. Lala(Author)
- 2007(Publication Date)
- Wiley-Interscience(Publisher)
1 Number Systems and Binary Codes 1.1 INTRODUCTION In conventional arithmetic, a number system based on ten units (0 to 9) is used. However, arithmetic and logic circuits used in computers and other digital systems operate with only 0 ’ s and 1 ’ s because it is very dif fi cult to design circuits that require ten distinct states. The number system with the basic symbols 0 and 1 is called binary. Although digital systems use binary numbers for their internal operations, communication with the external world has to be done in decimal systems. In order to simplify the communication, every decimal number may be represented by a unique sequence of binary digits; this is known as binary encoding . In this chapter we discuss number systems in general and the binary system in particular. In addition, we consider the octal and hexadecimal number systems and fi xed-and fl oating-point representation of numbers. The chapter ends with a discussion on weighted and nonweighted binary encoding of decimal digits. 1.2 DECIMAL NUMBERS The invention of decimal number systems has been the most important factor in the devel-opment of science and technology. The term decimal comes from the Latin word for “ ten. ” The decimal number system uses positional number representation, which means that the value of each digit is determined by its position in a number. The base (also called radix) of a number system is the number of symbols that the system contains. The decimal system has ten symbols: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9; in other words it has a base of 10. Each position in the decimal system is 10 times more signi fi cant than the pre-vious position. For example, consider the four-digit number 2725: Notice that the 2 in the 10 3 position has a different value than the 2 in the 10 1 position. The value of a decimal number is determined by multiplying each digit of the number by the 1 Principles of Modern Digital Design , by Parag K. Lala Copyright © 2007 John Wiley & Sons, Inc. - eBook - PDF
- Svetlana N. Yanushkevich, Vlad P. Shmerko(Authors)
- 2008(Publication Date)
- CRC Press(Publisher)
2 Number Systems Computer Arithmetic Binary Octal Decimal Hexadecimal Binary arithmetic Sign and magnitude 1’s complement 2’s complement Addition and subtraction Residue arithmetics Modular adder Modular subtractor Modular multiplier Binary codes Gray code and Hamming distance Binary-coded decimal codes Weighted codes Advanced topics Number systems and cryptography Numbers and information Number Systems 21 2.1 Introduction The binary number system is the most important number system in digital design. This is because it is suited to the binary nature of the phenomena used in dominant microelectronic technology. Even in situations where the binary number system is not used as such, binary codes are employed to represent information at the signal level. For example, multi-valued logic values are often encoded using binary representations. However, humans prefer decimal numbers, – thus, that is, binary numbers must be converted into decimal numbers. In this chapter, various number systems are examined that are used in digital data structures. These number systems, such as octal and hexadecimal, are used to simplify the manipulation of binary numbers. 2.2 Positional numbers A number system is defined by Its basic symbols, called digits or numbers , and The ways in which the digits can be combined to represent the full range of numbers we need. 2.2.1 The decimal system The ten digits 0 , 1 , 2 , . . ., 9 can be combined in various ways to represent any number. The fundamental method of constructing a number is to form a sequence or string of digits or coefficients : d n − 1 · · · d 1 d 0 Integer part Decimal point ↓ • d − 1 d − 2 · · · d − m F ractional part String of digits or coef f icients where integer and fractional parts are represented by n and m digits to the left and to the right of the decimal point , respectively. The subscript i = − m, m − 1 , . . . , 0 , 1 , . . ., n gives the position of the digit. - eBook - PDF
- M. Lothaire(Author)
- 2002(Publication Date)
- Cambridge University Press(Publisher)
CHAPTER 7 Numeration Systems 7.0. Introduction This chapter deals with positional numeration systems. Numbers are seen as finite or infinite words over an alphabet of digits. A numeration system is defined by a pair composed of a base or a sequence of numbers, and of an alphabet of digits. In this chapter we study the representation of natural numbers, of real numbers and of complex numbers. We will present several generalizations of the usual notion of numeration system, which lead to interesting problems. Properties of words representing numbers are well studied in number theory: the concepts of period, digit frequency, normality give rise to important results. Cantor sets can be defined by digital expansions. In computer arithmetic, it is recognized that algorithmic possibilities depend on the representation of numbers. For instance, addition of two integers represented in the usual binary system, with digits 0 and 1, takes a time proportional to the size of the data. But if these numbers are represented with signed digits 0, 1, and -1, then addition can be realized in parallel in a time independent of the size of the data. Since numbers are words, finite state automata are relevant tools to describe sets of number representations, and also to characterize the complexity of arithmetic operations. For instance, addition in the usual binary system is a function computable by a finite automaton, but multiplication is not. The usual numeration systems, such as the binary and the decimal ones, are described in the first section. In fact, these systems are a particular case of all the various generalizations that will be presented in the next sections. The second section is devoted to the study of the so-called beta- expansions, introduced by Renyi; see Notes. They consist in taking for 230 7.1. Standard representation of numbers 231 base a real number p > 1. When p is actually an integer, we get the standard representation. - eBook - PDF
- R. Townsend(Author)
- 2014(Publication Date)
- Butterworth-Heinemann(Publisher)
Chapter 4 Number Representation in Computers Number Systems The number systems, with which we are most familiar, all use positional notation to represent a number. Although various number bases have been used by different races and nations throughout history, the base of 10 has been commonly accepted and is now universally established in the decimal system. It appears to have its origin in counting on the fingers, and the word 'digit' is derived from the Latin word for finger. The procedure of counting numbers greater than the base is to increase the digit which is one place to the left by one, each time the digit is increased by ten steps. One can therefore represent a decimal number: a n . . . α 3 α 2 αχα 0 M ^ e f orrn: N = a 0 10° +0X1O 1 + Λ ι 10 2 +0 3 1Ο 3 ...+0„1Ο The ordering of the coefficients is reversed in the polynomial in contrast to the number, which is a relic of the fact that our number system came to us from Arabia, in which writing is normally from right to left. The system can be generalised for a uniform system of any base as the polynomial N = a 0 b° +a x b l +a 2 b 2 +a 3 b 3 .. .+a n b n where b is the base, and the coefficients are a 0 . . .a n which are normally written down to represent the number. A step further in complication are the nonuniform based number systems which are now happily being outmoded, but some of which we still have with us for a time, such as tons, hundredweights, and quarters; seconds, minutes, hours and days; and these can be represented as the polynomial. N = a 0 b 0 +a 1 (b 0 )b 1 +a 2 (b 0 b 1 )b 2 +a 3 (b 0 b x b 2 )b 3 ... where b 0 = 1 Table 4.1 shows the numbers up to 16 represented in bases up to 10, 67 - eBook - PDF
- Aharon Yadin(Author)
- 2016(Publication Date)
- Chapman and Hall/CRC(Publisher)
Such a system that has already been mentioned was the Hollerith punched card, which used the holes in the card to represent data. The fast development of the Internet and the fact it is a global system required spe-cial attention to data representation standards. These standards provide the basic platform for data transfers between all connected devices. Furthermore, since all modern comput-ers use the binary system, the standards have to define the binary representation of data as well. This data may include numbers (integers, real and complex numbers), text, and special symbols. An important aspect of the representation system applicable to num-bers is its ability to support computations (as will be explained in the section “Computer’s Arithmetic” in this chapter). 48 ◾ Computer Systems Architecture Numerical Systems From the dawn of history, humans needed a mechanism that would allow the measurement of quantities. As such, basic verbal communication was developed to include a system to quantify size. Over the years, various civilizations have developed numerous such numeri-cal systems, used originally for counting and later for computations as well. Such numeri-cal systems are a prerequisite for data representation, since first the system has to be put in place and only later is its representation defined. Every numerical system has to use symbols (numerals) for representing quantities. A delicate balance regarding the number of the symbols used as the numeric system has to be maintained. On one hand, the number of symbols should be relatively small, so it will be easier for humans to remember and use the system. On the other hand, it should not be too small, as this would require long representation (or many numerals, as will be elaborated on and explained in the section “Binary System” in this chapter). The system, of course, should be able to cover the whole spectrum of numbers (i.e., be infinite). - eBook - ePub
- Pinaki Mazumder, Idongesit E. Ebong(Authors)
- 2023(Publication Date)
- River Publishers(Publisher)
The simplest numeral system is the unary numeral system ; this number system works by repeating characters for larger numbers. For example, the tally marks system still utilized today in many game settings is shown in Figure 2.1 a. Each character is represented by a forward slash, “/,” and the number of slashes indicates the value of the number represented. A more sophisticated unary numeral system, even though not commonly used today, is the Roman numeral system, as shown in Figure 2.1 b. Figure 2.1 (a) Tally mark counting to 7 and (b) Roman numeral counting to 7. Unary systems have been used throughout history, with some of its variants including the Egyptian and Chinese Numeral Systems. The problem with unary Numeral Systems is that they become very cumbersome when they deal with large numbers. For example, try computing the following arithmetic without converting to the decimal system you are used to: (XLII × MC) – (XXI × MMCC). Compare that to the following equivalent calculation: (42 × 1100) – (21 × 2200). The ease of working with the positional numeral system has contributed to its widespread use. 2.1.2 The positional numeral system, or the place-value system The positional numeral system 1 is the common number system used. For example, the number 1385.3 is interpreted as (1 × 1000) + (3 × 100) + (8 × 10) + (5 × 1) + (3 × 0.1). Each digit in the number 1385.3 is multiplied by a different place value and added together in order to obtain the value of the number. The given number 1385.3 is in decimal format because every place value is a power of 10. Hence, 1385.3 is therefore interpreted as 1 The Babylonian sexagesimal (base-60) system, which was supposedly inherited from Sumerian civilization (c. 4500c. 1900 BC) is credited as being the first positional numeral system (PNS). The Babylonian system (c. 2000 BC) used only two distinct symbols similar to I and < to count unit and ten, respectively - eBook - PDF
- Gideon Langholz, Abraham Kandel;Joe L Mott;;(Authors)
- 1998(Publication Date)
- WSPC(Publisher)
2 Number Systems, Arithmetic Operations and Codes 2.1 INTRODUCTION Digital systems are characterized by signals restricted to two possible values which are represented by an alphabet of only two characters, commonly denoted by 0 and 1. Binary data representations are therefore of fundamental importance to the analysis and design of digital systems. We begin this chapter by considering numerical data representations. Working with digital systems usually requires familiarity with several number systems: Decimal Binary Octal Hexadecimal Binary-coded decimal (BCD) The binary number system is the most natural to use in a digital system. Sometimes, however, it is more convenient to employ the other number systems, in particular the familiar decimal number system. In such cases, the numbers are manipulated within the number system in use but are, nevertheless, represented as binary numbers within the digital system. We will introduce arithmetic operations to provide a basis for understanding how digital systems handle numbers in arithmetic computations. We will discuss unsigned and signed binary number representations and consider the four basic arithmetic operations: 21 22 CHAPTER 2 NUMBER SYSTEMS addition, subtraction, multiplication, and division. Binary coding is another important issue. Numbers can be represented in a variety of codes, some of which are more useful than others in particular situations, and can be operated upon. Nevertheless, since arithmetic (numerical) data are not the only data type used, we also discuss codes for representing nonnumerical data, such as letters of the alphabet. Finally, we provide a brief introduction to the fundamentals of protecting against various transmission errors when data are transferred over communication links, and the principles of coding control instructions in a digital system. - eBook - PDF
Microelectronic Systems N2 Checkbook
The Checkbook Series
- R E Vears(Author)
- 2013(Publication Date)
- Butterworth-Heinemann(Publisher)
2 Numbering systems A MAIN POINTS CONCERNED WITH NUMBERING SYSTEMS 1 In everyday situations, a system of counting using a base of ten is employed. This is known as a decimal or denary system, and its main justification for use is often quoted as being that human beings have ten fingers/thumbs with which to count. The characteristics of a decimal numbering system are: (i) a set often distinct counting digits (0, 1, 2, 3, 4, 5, 6, 7, 8 & 9), and (ii) a place value (or weight) for each digit, organised in ascending powers of ten starting from the right. Thus, for example, the decimal number 2658 10 may be considered as follows: 2658 10 (decimal) = 2 X 10 3 + 6 X 10 2 + 5 X 10 1 + 8 X 10° = 2000 + 6 0 0 + 5 0 + 8 2 A decimal system is not particularly suitable for direct use in electronic circuits. Due to practical limitations imposed by electronic devices, only two conditions are consistently predictable. These conditions are obtained when a chosen elec-tronic device is made to act as a switch, and its two states are on and off, represented by the logic symbols 1 and 0. This is known as 'two state logic', and each 1 or 0 is called a bit (binary digit). A digital computer performs its tasks by manipulating information which is represented by patterns of bits. 3 One convenient method of representing numbers in terms of two-state logic is to make use of the binary (base two) system. The characteristics of a binary counting system are: (i) two counting digits (1 and 0), and (ii) a place value (or weight) for each digit, organised in ascending powers of two starting from the right (see column 2 of Table 1 ). Thus, a 1 in a particular position of a binary number contributes its place value towards the total, but a 0 contributes nothing. Therefore, the decimal equivalent of a binary number may be obtained by adding together all of the place values where a 1 occurs in that binary number. - eBook - PDF
Mathematical Practices, Mathematics for Teachers
Activities, Models, and Real-Life Examples
- Ron Larson, Robyn Silbey(Authors)
- 2014(Publication Date)
- Cengage Learning EMEA(Publisher)
Section 2.3 Number Lines and Numeral Systems 63 An Octal Numeral System Some Native American tribes used an octal 1 8 2 7 3 6 4 5 numeral system because they counted on the spaces between their fingers rather than on their fingers. What is the base for this system? SOLUTION The numeral system is base eight. Notice that there are 8 spaces between the digits of a person’s two hands. EXAMPLE 9 The Arabic-Hindu Numeral System The Arabic-Hindu numeral system is a base-ten positional system that was developed over many centuries. Its symbols have been traced to the Hindus of India as far back as 200 B.C. The system was adopted by Arab mathematicians around A.D. 800. Eventually, the symbols were transported to Spain, where a late 10th-century version looked like the numerals shown at the left. As books and printing become more standardized, the system spread throughout Europe and today it is the dominant system used throughout the world. Even so, the symbols used for the 10 digits in the system still vary. European Arabic-Indic Eastern Arabic-Indic (Persian and Urdu) Devanagari (Hindi) 0 1 2 3 4 5 6 7 8 9 Early versions of the Hindu numeral system did not have a symbol for zero. Explain why it is necessary to have a symbol for zero in a positional numeral system. SOLUTION A positional numeral system must have a symbol for zero to distinguish between base-ten numbers such as 15 = 1(10) + 5(1) and 105 = 1(100) + 0(10) + 5(1). The table shows the different representations among the Numeral Systems. EXAMPLE 10 Mayan Hexadecimal 0 1 2 3 4 5 6 7 8 9 A Egyptian Chinese Babylonian Roman I II III IV V VI VII VIII IX X European 0 1 2 3 4 5 6 7 8 9 10 Mathematical Practices Look for and Express Regularity in Repeated Reasoning MP8 Mathematically proficient students continually evaluate the reasonableness of intermediate results. iStockphoto.com/susaro Copyright 2014 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. - eBook - PDF
Digital Computer Design
Logic, Circuitry, and Synthesis
- Edward L. Braun(Author)
- 2014(Publication Date)
- Academic Press(Publisher)
1. Introduction 1.1. Uses of Number The subject matter of this book is the stored program digital computer. We will consider its fundamental nature, ways of describing its logical organization, various means of mechanization, and principles and tech-niques useful in its synthesis and utilization. Since these machines ac-complish their fimction by means of operations on numerically coded information, some preliminary discussion is in order on the subject of numbers. We will consider briefly the nature of numbers, certain symbols and notations used to represent them, and a description of mechanical and/or electronic means for representing numbers and operating on them. Numerical symbols may be used for various purposes. Sometimes they are used merely as labels to distinguish one of a set of objects from the others. In other words, they can be used as names or symbols for objects. They are convenient to use as names of persons or things because they provide an inexhaustible supply of such names. Ordinarily, one associates a deñnite order among numerals (or groups of numerals). Often, numerals are used for this characteristic alone, as in assigning them to houses on a street. The function of a street address is not to indicate how many houses there are on a street, but to indicate a particular house's position relative to other houses on the street, i.e., its order. The use of numerals to indicate the number of items in a set will be discussed in Section 1.2. 1.2. Counting Before considering how numbers came to be associated with the process of counting, it is well to emphasize the distinction between ordinal and cardinal numbers since, in common usage, the word number alone may refer to either. When numbers are used solely for an order property that has been deñned previously for them, they are called ordinal numbers (or ordinals)—^for example, numbers indicating relative locations or points in time. - eBook - PDF
- Israel Koren(Author)
- 2018(Publication Date)
- A K Peters/CRC Press(Publisher)
1 CONVENTIONAL NUMBER SYSTEMS . 1 THE BINARY NUMBER SYSTEM In conventional digital computers, integers are represented as binary numbers of fixed length. A binary number of length n is an ordered sequence ( x n -1 , x n-2 , N N N , x 1 , x o ) of binary digits where each digit x i (also known as a bit ) can assume one of the values 0 or 1. The length n of the sequence is of significance, since binary numbers in digital computers are stored in registers of a fixed length, n . The above sequence of n digits (or n -tuple) represents the integer value X ) x n-1 2 n-1 + x n-2 2 n-2 + N N N + x 1 2 + x o ) n -1 E x i 2 i . (1.1) i —o Upper case letters are used in this book to represent numerical values or se-quences of digits while lower case letters, usually indexed, represent individual digits. The weight of the digit x i in (1.1) is the i th power of 2, which is called the radix of the number system. The interpretation rule in Equation (1.1) is similar to the rule used for the ordinary decimal numbers. There are, however, two dif-ferences between these interpretation rules. First, the radix 10 is used instead of 2 in Equation (1.1) and consequently, the allowed digits in the decimal case are x i ; 0 , 1 , 2 , N N N , 9 i instead of x i ; 0 , 1 i . We call the decimal numbers radix-10 1 2 1. Conventional Number Systems numbers and the binary numbers radix-2 numbers. We indicate the radix to be used when interpreting a given sequence of digits by writing it as a subscript. Thus, the sequence (101) 10 represents the decimal value 101, while the sequence (101) 2 represents the decimal value 5. Since operands and results in an arithmetic unit are stored in registers of a fixed length, there is a finite number of distinct values that can be represented within an arithmetic unit. Let X E7z and X Ey? denote the smallest and largest representable values, respectively. We say that [ X E7z , X Ey? ] is the range of the representable numbers. - eBook - PDF
- Karl Smith(Author)
- 2016(Publication Date)
- Cengage Learning EMEA(Publisher)
. . The pattern continues: 22, 23, 24, 30, 31, 32, 33, 34, 40, . . . The pattern continues: 21, 22, 23, 24, 25, 30, 31, 32, 33, 34, 35, 40, . . . Copyright 2017 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s). Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require it. 146 CHAPTER 4 The Nature of Numeration Systems Different Numeration Systems 4.3 In the previous section, we discussed the Hindu-Arabic numeration system and grouping by tens. However, we could group by twos, fives, twelves, or any other counting num-ber. In this section, we summarize numeration systems with bases other than ten. This not only will help you understand our own numeration system, but will also give you insight into the numeration systems used with computers, namely, base 2 ( binary ), base 8 ( octal ), and base 16 ( hexadecimal ). Number of Symbols The number of symbols used in a particular base depends on the method of grouping for that base. For example, in base ten the grouping is by tens, and in base five the grouping is by fives. Suppose we wish to count in various bases. Let’s look for patterns in Table 4.5. Note the use of the subscript following the numeral to keep track of the base in which we are working.
Index pages curate the most relevant extracts from our library of academic textbooks. They’ve been created using an in-house natural language model (NLM), each adding context and meaning to key research topics.











