Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. a) Describe the features and an example of Lossy and Lossless Compression. b)

ID: 3591506 • Letter: 1

Question

1.

a)        Describe the features and an example of Lossy and Lossless Compression.

b)        Describe the relationship between MAR, Address Decoder and MDR    


2. Analyze the following program. When run, what does this program do? Your friend reviews the code and telling you there is a bug in the code. Can you identify the bug? What can you do to fix it?   

PC: 35

Memory Location

Value

35

901 (INPUT)

36

381 (STORE 81)

37

901 (INPUT)

38

382 (STORE 82)

39

581 (LDA 81)

39

282 (SUB 82)

40

383 (STORE 83)

41

747 (BRZ 47)

42

845 (BRP 45)

43

582 (LDA 82)

44

902 (OUTPUT A)

45

581 (LDA 81)

46

902 (OUTPUT A)

47

549 (LDA 49)

48

902 (OUTPUT A)

49

HALT

81

000

82

000

83

000

Memory Location

Value

35

901 (INPUT)

36

381 (STORE 81)

37

901 (INPUT)

38

382 (STORE 82)

39

581 (LDA 81)

39

282 (SUB 82)

40

383 (STORE 83)

41

747 (BRZ 47)

42

845 (BRP 45)

43

582 (LDA 82)

44

902 (OUTPUT A)

45

581 (LDA 81)

46

902 (OUTPUT A)

47

549 (LDA 49)

48

902 (OUTPUT A)

49

HALT

81

000

82

000

83

000

Explanation / Answer

.Que1

a)

Whenever we have a file that is too large to transmit or store we normally compress it. and we recover it at the reciever end or after some time .two things can happen doing this.

1) Lossless features:

Example:

In case of Compressing Binary File we use lossless . because change in any of the bit in a file will corrupt the whole file . so loss in binary file in intolerable.

111100 -------> 110100(Corrupted data)

can check by parity bit that data is lost / corrupted.

2)Lossy Features:

Example:

In case of storing or transmitting any kind of image or MP3 or MP4 files we can use lossy if any kind of loss in data occures in these files its tolerable.

b)

MAR Stands for memory address register.This is connected to the address bus using 32 bit tri state buffer,

.It can have two kind of addresses -- Address of instruction -- address of the data. its work is to place the address stored in it into address bus.

MDR Stands for Memory data register . this is connected to the data bus. it stores the data to be used.

it can either read data from data bus into itself -- loading or

it can store its data from mdr into data bus or any part of cpu -- storing

they both can be used in reading and writing operations. if u want to read or write any data then you can store its address in MAR then place value stored at that location into mdr now you can read or write data.

Address decoder:

It is a binary decoder having n-input and 2n outputs . it is used for selecting the devices . N-input are address of devices which are applied to address decoder and it tells by selection process that which set of devices to use.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Chat Now And Get Quote