ProductsLogo
LogoStudy Documents
LogoAI Grader
LogoAI Answer
LogoAI Code Checker
LogoPlagiarism Checker
LogoAI Paraphraser
LogoAI Quiz
LogoAI Detector
PricingBlogAbout Us
logo

Computers, Data and Programming

Verified

Added on  2023/01/23

|10
|947
|41
AI Summary
This document provides answers to questions related to computers, data, and programming. It includes calculations for converting numbers to different bases, explanations of different number representations, and a MARIE program for calculating Fibonacci numbers. It also discusses interrupts in computer systems and the use of multiple bus architecture.

Contribute Materials

Your contribution can guide someone’s learning journey. Share your documents today.
Document Page
Running head: ASSESSMENT ITEM 2
Assignment 1: Computers, Data and Programming
Name of the Student
Name of the University
Author’s Note

Secure Best Marks with AI Grader

Need help grading? Try our AI Grader for instant feedback on your assignments.
Document Page
1
ASSESSMENT ITEM 2
Question 1 Answer
a. The value of base b if (152)b = 0x6A.
Demonstration of the calculation with the following steps:
0x6A = (6A) = 6 * 16¹₁₆ + A*16 = 96 + 10 = 106 (A = 10 in Hexadecimal)
(152)b = 1 * b² + 5 * b¹ + 2 * b
=> (152)b = b² + 5b + 2
Comparing both the equation we get:
=> b² + 5b + 2 = 106
=> b² + 5b - 104 = 0
=> b² + 13b - 8b - 104 = 0
=> b(b+13) - 8(b + 13) = 0
=> (b-8) (b+13) = 0
b = 8 ( b ≠ - 13 as base cannot be negative)
so b = 8
b. Conversion of the following
i. 0xBAD into 3-base representation
Step#1: Translating into decimal:
0xBAD16 = 11∙162+10∙161+13∙160 = 2816+160+13 = 298910
Result: 298910
Converting 298910 in 3-ary system here so:
Document Page
2
ASSESSMENT ITEM 2
The result is obtained by dividing the number with its base
2989 3
-
2988
996 3
1
-
996
332 3
0
-
330
110 3
2
-
108
36 3
2 -36 12 3
0 -12 4 3
0 -3 1
1
Conversion Result:
BAD16 = 110022013
ii. 3217 into 2-base (binary) representation
3217 = 3∙72+2∙71+1∙70 = 147+14+1 = 16210
Result: 16210
Converting 16210 in Binary system here so:
Document Page
3
ASSESSMENT ITEM 2
The result is obtained by dividing the number with its base
162 2
-
162
81 2
0 -80 40 2
1 -40 20 2
0 -20 10 2
0 -10 5 2
0 -4 2 2
1 -2 1
0
Result:16210 = 101000102
iii. 1235 into octal representation
3215 = 3∙52+2∙51+1∙50 = 75+10+1 = 8610
Result: 8610
8610 is converted into Octal system:
The result is obtained by dividing the number with its base

Paraphrase This Document

Need a fresh take? Get an instant paraphrase of this document with our AI Paraphraser
Document Page
4
ASSESSMENT ITEM 2
86 8
-80 10 8
6 -8 1
2
Result:8610 = 1268
iv. 21.218 into decimal representation
Step#1: It is converted into decimal representation:
21.218 = 2∙81+1∙80+2∙8-1+1∙8-2 = 16+1+0.25+0.015625 = 17.26562510
Result: 17.26562510
Result after the conversion:
21.218 = 17.26562510
c.
i. 1’s Complement –
Lowest Value (-ve Number): 1112 (-3)10
Highest Value (+ve Number): 0112 (+3)10
ii. 2’s Compliment –
Lowest Value (-ve Number): 1112 (-4)10
Highest Value (+ve Number): 0112 (+3)10
iii. Signed Magnitude –
Lowest Value (-ve Number): 1002 (-4). For the 3 bits, leftmost bit is represented
as the negative sign.
Highest Value (+ve Number): 0112 (+3). For the 3 bits the leftmost bit is
represented as the positive sign.
Document Page
5
ASSESSMENT ITEM 2
Question 2 Answer:
2.a.
MARIE program for calculating Fib(n) where the user can input n is given below:–
ORG 100
INPUT
STORE N
STORE Ctr
Loop1 CLEAR
LOAD Ctr
SUBT C1
STORE Ctr
LOAD F2
ADD F1
STORE F3
LOAD F1
STORE F2
LOAD F3
STORE F1
LOAD Ctr
SKIPCOND 400
Document Page
6
ASSESSMENT ITEM 2
JUMP Loop1
LOAD Ctr
OUTPUT
LOAD N
OUTPUT
LOAD F1
OUTPUT
HALT
N DEC 0
Ctr DEC 0
C1 DEC 1
F1 DEC 0
F2 DEC 1
F3 DEC 0

Secure Best Marks with AI Grader

Need help grading? Try our AI Grader for instant feedback on your assignments.
Document Page
7
ASSESSMENT ITEM 2
2.b.
For the value of n be greater than 24 the program cannot provide a correct result and
the flaw in the program is identified by increasing the value of n gradually and verifying the
output obtained from the program.
The main reason for getting the error in the output is the increase in threshold value
and exceeding the limit for storing the value.
Document Page
8
ASSESSMENT ITEM 2
Question 3 Answer:
a. In a computer system interrupt is defined as a function that is used by the operating
system for managing multiple tasks at a time.
The interrupt is a signal sent to the operating system as a prompt to stop the current
work that are in process and immediately start working on the process waiting in the
queue for a long time.
b. The use of multiple bus architecture can improve the speed and performance of the
processor for executing different instruction because in case of multiple bus
architecture a single bus is used for connecting a device than multiple device is
connected to a single bus in single bus architecture. Thus the delay would be less
since the instructions can be directly transferred from the bus to the processor and the
device does not have to wait for the bus to become free.
Document Page
9
ASSESSMENT ITEM 2
Bibliography
Null, L., & Lobur, J. (2014). The essentials of computer organization and architecture. Jones
& Bartlett Publishers.
Tanenbaum, A. S. (2016). Structured computer organization. Pearson Education India.
Wang, S., & ZHANG, C. (2016). Computer architecture.
1 out of 10
[object Object]

Your All-in-One AI-Powered Toolkit for Academic Success.

Available 24*7 on WhatsApp / Email

[object Object]