22 views

Uploaded by Amiruless Aminzz

kkgfjh

- digi_com
- Digital Conversiona using FPGA
- Mathematical Concepts and their Applications - Number System
- 18
- 2 IT201 Digital System Design - Supple - July 2017 1
- Experiment 9 10
- 71252592-Algebra-1
- CM105.20
- 8085 Microprocessor_ Flag Register & Instruction Organization
- Chapter7 Arithmetic
- C Program to Convert Binary Number to Octal and Octal to Binary
- Lc Meter 007
- Operations in Intel 8086
- CCP105
- LZQJ-DLMS-E-1.25
- Compute's Beginners Guide to C64 Sound
- number system
- Assembler Language Programming
- cifrarenwav3
- MX620MX630MX640E

You are on page 1of 35

system

a. Sign and magnitude

b. 1s Complement and 2s Complement

c. Binary Coded Decimal (BCD system)

d. ASCII and EBCDIC

Sign and Magnitude

Positive sign, ( 0 )

or

Negative sign ( 1 )

Magnitude =

Size

Or value

Sign and Magnitude

Example 1 : Represent -9 in sign

and magnitude.

-9

sign

magnitude

1

1001

11001

-9 in sign &magnitude value is 11001

Sign and Magnitude

Example 2 : Represent 25 in sign

and magnitude.

+25

sign

magnitude

0

11001

011001

25 in sign & magnitude value is 011001

Twos Complements

Ones Complements

The ones complement of a binary number is

obtained by changing each 0 to 1 and 1 to a 0.

Only change negative number

In other words, change each bit in the number to

its complement.

Exp:

form 1s complement

Thus, we say that the 1s complement of

10011001 is 01100110.

Exp:

a) -2710 = 001002

-------------

Twos Complement

taking the 1s complement of the number and

adding 1 to the least-significant-bit (LSB)

position.

Exp:

101101 binary equivalent of 45

010010 complement each bit to form 1s complement

+

1 add 1

010011 2s complement of original binary

number

Twos complement = Ones Complement + 1

Exercise

1.

1s complement 2s complement

-101110012

0100 0111

-5768

01000 0001

-124516

-4510

01000 0010

Addition in 1s complement

+

1000

1100

10100

1

0101

-3 change to 1s complement

add carry to LSB

----------------

Addition in 2s complement

1100

+

1

1101

+ 1000

10101

-3 change to 1s complement

-3 change to 2s complement

8 change to binary number

This carry is disregarded, the result is 0101 (sum=5)

+

+

0111

-8 change to 1s complement

1

1000

0011

1011

-8 change to 2s complement

3 change to binary number

negative sign bit

Subtraction in 1s

complement

change to 1s complement. If the number is decimal

number, change the number to binary number.

complement, means that the number already

change to +ve. So that, the subtraction process

have change to addition process.

and add with the number.

2510 = 110012

1310 = 11012

1310 = 11012 change to 1s complement = 10010

+

+

11001

10010

101011

1

01100

-13 change to 1s complement

add 1

total=12

Subtraction in 2s

complement

Change the number are given to binary

number.

to 1s complement (change 0 to 1 and 1 to 0).

Step 1 : Convert 2510 and -1310 to binary number.

2510 = 110012

1310 = 11012

-1310 = 011012 change to 1s complement = 10010

10010 change to 2s complement = 10011

11001

+ 10011

101100

25 change to binary

-13 change to 2s complement

total=12

Carry disregard

Exercise

i.

428 158

ii.

101110 - 56910

Signed Number

Exp:

+4 + (+8) = +12

+4

00000100

+8

00001000

+12 00001100

Exp 1:

(-4) + (+8) = +4

-4

11111100

+ (+8)

00001000

+4

1 00000100

00000100

11111011

+4

1s complements

+

1

11111100

2s complements

Exp 1:

(-12) + (+5) = -7

-12

11110100

+ +5

00000101

-7

11111001

00001100

11110011

+12

1s complements

+

1

11110100

2s complements

Positive Number (-) Negative Number

Exp:

+10 (-5) = +10 + (+5)

= + 15

+10

+ 5

+15

00001010

00000101

00001111

Exp:

-10 (+5) = - 15

- 10

- (+5

-15

11110110

11110110

00000101 +11111011

111110001

00001010

11110101

complements

+

1

11110110

complements

00000101

11110010

complements

+

1

11111011

complements

This carry is disregarded

+10

1s

2s

+5

1s

2s

Exp:

-10 (-5)

-10

- (- 5)

- 5

= -10 + (5)

=-5

11110110

00000101

11111011

00001010

11110101

complements

+

1

11110110

complements

+10

1s

2s

BCD Code

4221 and etc.

Desimal

5421

5311

4221

3321

2421

8421

7421

0000

0000

0000

0000

0000

0000

0000

0001

0001

0001

0001

0001

0001

0001

0010

0011

0010

0010

0010

0010

0010

0011

0100

0011

0011

0011

0011

0011

0100

0101

1000

0101

0100

0100

0100

1000

1000

0111

1010

1011

0101

0101

1001

1001

1100

1100

1100

0110

0110

1010

1011

1101

1101

1101

0111

1000

1011

1100

1110

1110

1110

1000

1001

1100

1101

1111

1111

1111

1001

1010

Binary-Coded-Decimal Code

its binary equivalent, the result is a code called

binary-coded-decimal.

required to code each digit (the binary code for 9 is

1001)

Exp: 87410

8

(decimal)

1000

0111

0100

(BCD)

Number

Exp:

Convert 1001 0110BCD 8421 to binary number.

number.

1001

0110

9

6

Step 2 : Change decimal number to binary

number.

1001 0110BCD 8421 = 11000002

8421 Code

Exp:

Convert 10010102 to BCD 8421

code.

Step 1: Change binary number to decimal

number.

10010102 = 7410

Step 2: Change decimal number to BCD

8421 code.

ASCII Code

American Standard Code for Information

Interchange (ASCII).

= 128 possible code groups.

ASCII code

MSB

LSB

Binary

000

001

010

011

100

101

110

111

Binary

Hex

0000

Nul

Del

sp

0001

Soh

Dc1

0010

Stx

Dc2

0011

Etx

Dc3

0100

Eot

Dc4

0101

End

Nak

0110

Ack

Syn

&

0111

Bel

Etb

1000

Bs

Can

1001

HT

Em

1010

LF

Sub

1011

VT

Esc

1100

FF

FS

<

1101

CR

GS

1110

SO

RS

>

1111

SI

US

Exp:

An operator is typing in a BASIC program

at the keyboard of a certain

microcomputer. The computer converts

each keystroke into its ASCII code and

stores the code as a byte in memory.

Determine the binary strings that will be

entered into memory when operator types

in the following BASIC statement:

GOTO 25

Solution:

Locate each character (including the

space) and record ASCII code.

G

O

T

O

(space)

2

5

01000111

01001111

01010100

01001111

00100000

00110010

00110101

*0wasaddedtotheleftmostbitofeachASCIIcodebecausethe

Codesmustbestoredasbytes(eightbits).

Exercise :

1.The following message encode in ASCII

code. What the meaning of this code ?

a) 54 4F 4C 4F 45 47

b) 48 45 4C 4C 4F

c) 41 50 41 4B 48 41 42 41 52

EBCDIC

Interchange Code.

was first used on the IBM 360 computer,

which was presented to the market in 1964.

Used with large computer such as

mainframe.

- digi_comUploaded byvigneshraja20
- Digital Conversiona using FPGAUploaded byPraveen Kumar Kuttuva
- Mathematical Concepts and their Applications - Number SystemUploaded byJesstern Rays
- 18Uploaded byapi-3812413
- 2 IT201 Digital System Design - Supple - July 2017 1Uploaded byGayatri Sharma
- Experiment 9 10Uploaded byManoj Kavedia
- 71252592-Algebra-1Uploaded byRoyston Lim
- CM105.20Uploaded byapi-3849444
- 8085 Microprocessor_ Flag Register & Instruction OrganizationUploaded byPartha Saha
- Chapter7 ArithmeticUploaded byRaghu Kanchiraju
- C Program to Convert Binary Number to Octal and Octal to BinaryUploaded byAnonymous sMqylH
- Lc Meter 007Uploaded byyooo2011
- Operations in Intel 8086Uploaded byAmr Alshareef
- CCP105Uploaded byapi-3849444
- LZQJ-DLMS-E-1.25Uploaded byvietbkfet
- Compute's Beginners Guide to C64 SoundUploaded byCubemanPDX
- number systemUploaded bysarvarrasheed
- Assembler Language ProgrammingUploaded byhnsmksm
- cifrarenwav3Uploaded bycapitanez
- MX620MX630MX640EUploaded bychuvihi
- Working With the 555Uploaded byanurag_d_cool_guy
- CNC Part ProgrammingUploaded bySathish Kumar Rajendiran
- 16454_Digital Conversions (1)Uploaded byGourang Paul
- RocUploaded byJosé Luis Aros Rivera
- 11_7ke_ueUploaded byIrfan Gani
- Module 10Uploaded byerdvk

- CHAPTER 1.1.pdfUploaded byAmiruless Aminzz
- Lab Activity 3Uploaded byAmiruless Aminzz
- Doc2Uploaded byAmiruless Aminzz
- CHAPTER 1.2.pdfUploaded byAmiruless Aminzz
- CHAPTER 1.3.pdfUploaded byAmiruless Aminzz
- Presentation Assessment1Uploaded byAmiruless Aminzz
- Cover - Copy - CopyUploaded byAmiruless Aminzz
- Mpu 3012- Ko-kurikulum 2Uploaded byAmiruless Aminzz
- CHAPTER 5 (1).pptxUploaded byAmiruless Aminzz
- CHAPTER 5 (1).pptxUploaded byAmiruless Aminzz
- Book1jUploaded byAmiruless Aminzz
- sejarahUploaded byAmiruless Aminzz
- Doc2Uploaded byAmiruless Aminzz
- attribUploaded byAmiruless Aminzz
- Peta Minda Sejarah T5.pdfUploaded byCikgu Faizal
- nota pendekUploaded byBeevy GB
- Sejarah Smk Sungai BesiUploaded byAmiruless Aminzz
- sej debabUploaded byfifi5020
- SejarahUploaded byAmiruless Aminzz
- SejarahUploaded byAmiruless Aminzz
- FOLIO GEOUploaded byAmiruless Aminzz

- Rational ExpressionUploaded byCassandra Jea Perez
- Math g6 m2 Topic d Lesson 19 TeacherUploaded byOgnjen Popovic
- Min TermUploaded byAli
- Elements of Algebra (1910)Uploaded byBob Vines
- 14029270028Uploaded byShubham
- 11+ Maths Worksheets -Uploaded bymadhujayan
- Maths Project CrypteritmUploaded byramperiannan
- Class 7Uploaded byKunal Sonwane
- Contract Maths Yrs 5Uploaded byTW Sean
- Progressions QnsUploaded byLokesh Kumar
- JuliaUploaded bydavidauxskis
- Unit 1 NotesUploaded byanon-605611
- Chapter4 FractionsUploaded byismael63322
- NumbersUploaded byOmer Ali
- mathUploaded byWencil Bentulan Gequillo
- Lecture07_IE321_DrAtifShahzad.pdfUploaded byatifshahzad
- Significant FiguresUploaded byJnn Katemb
- Football Betting SecretsUploaded byFloat Kgb
- Decimal Binary c programming Using SwitchUploaded byTanmoy Onoitik Ganguly
- Unit 1Uploaded byumaa6
- Sample.problem.3.QAUploaded byvivekltp120
- 01-BasicConceptsUploaded bySaif khawaja
- Grade-5 MathUploaded bymamun31
- comp c1Uploaded byAditya Chadha
- Rational and Irrational Numbers.docUploaded bySha Mercs
- Dividing PolynomialsUploaded byMyPc Services
- VLSI Implementation of a Low Power Single Precision Floating Point Fused Multiply-Add UnitUploaded byTejashree
- QuantProblemSet IIIUploaded byapi-27239845
- 503 33 Powerpoint-slides Chapter-3Uploaded byssrkm gupta
- A First Course in Mathematics for Technical Students 1000017015Uploaded byRené Wester