Question

In: Computer Science

1. Suppose an average page of a Unicode text document holds roughly 1500 characters. Using appropriate...

1. Suppose an average page of a Unicode text document holds roughly 1500 characters. Using appropriate units of measure, estimate how many such pages a CD storage media with 600 MB capacity can store. Show your work.

2. Perform the following using 10-bit floating-point notation having the format SEEEMMMMMM: (A) Decode 1101110110 to decimal integer and/or fraction. (B) Decode 0001100000 to decimal integer and/or fraction. (C) Encode -5/32 (D) Encode: +6 and 5/8

3. Please read carefully. Using the minimum number of digits in 2’s complement notation, perform 25 – 18 (subtraction by preserving addition). Show all the significant steps in your work by indicating the starting values, sign conversion, and the addition operation aligning all numbers, including the carry values in each position using the Courier New font. Indicate the final value as decimal.

4. How many bits are required to represent all the elements currently in the Periodic Table? Explain.

Solutions

Expert Solution

1.

By using UTF ecoding mechanism in which each character takes 1 byte size.

So, One page would take 1500 byte size.

We have a CD, whose storage capacity is = 600MB = 600000000 Bytes.

Total pages, we can store = 600000000/1500 = 400000 pages

2.

(A) -0.017578125

(B) 1

(D) 0.110000000 | 000010

sign=0(positive)

mantissa=0.110000000

exponent=000010

3.

to represent 25, or -18 we need 6 bits.
so, using 6 bits for calculations..

Number: 25
Let's convert this to two's complement binary
25
Since this is a positive number. we can directly convert this into binary
Divide 25 successively by 2 until the quotient is 0
   > 25/2 = 12, remainder is 1
   > 12/2 = 6, remainder is 0
   > 6/2 = 3, remainder is 0
   > 3/2 = 1, remainder is 1
   > 1/2 = 0, remainder is 1
Read remainders from the bottom to top as 11001
So, 25 of decimal is 11001 in binary
so, 25 in 2's complement binary is 011001

Number: -18
Let's convert this to two's complement binary
-18
This is negative. so, follow these steps to convert this into a 2's complement binary
Step 1:
Divide 18 successively by 2 until the quotient is 0
   > 18/2 = 9, remainder is 0
   > 9/2 = 4, remainder is 1
   > 4/2 = 2, remainder is 0
   > 2/2 = 1, remainder is 0
   > 1/2 = 0, remainder is 1
Read remainders from the bottom to top as 10010
So, 18 of decimal is 10010 in binary
So, 18 in normal binary is 010010
Step 2: flip all the bits. Flip all 0's to 1 and all 1's to 0.
   010010 is flipped to 101101
Step 3:. Add 1 to above result
101101 + 1 = 101110
so, -18 in 2's complement binary is 101110

Adding 011001 and 101110 in binary
(c)1110000  <-  these are carry bits for the calculation. 
    011001
    101110
-----------
 (1)000111
-----------
Sum produces a carry of 1. We can ignore that carry.
So, sum of these numbers in binary is 000111

Verification:
---------------
sum = 000111
since left most bit is 0, this number is positive
so, we can directly convert this into a decimal value
Converting 111 to decimal
111
=> 1x2^2+1x2^1+1x2^0
=> 1x4+1x2+1x1
=> 4+2+1
=> 7
Answer: 7

This is correct since we can verify that 25+-18 = 7
So, there was no overflow.

4. 7

Explanation:- There are currently 118 elements in the periodic table. n bits can represent maximum value of (2^n) -1. So, maximum value can be represent by 7 bits is (2^7)-1= 128-1= 127.


Related Solutions

A book page contains on average 50 lines and each line contains on average 60 characters....
A book page contains on average 50 lines and each line contains on average 60 characters. The probability that there is character typo is 0.0001. A line or a page contains a random amount of character typos and we want to use the laws or probability to study them. We designate by X, the random variable related to the number of character typos in a line and Y is the random variable related to the number of character typos in...
#3 – Suppose a random sample of text-message lengths (in characters) resulted in the following observations:...
#3 – Suppose a random sample of text-message lengths (in characters) resulted in the following observations: 59,60,52,66,73. What was the sample’s standard deviation? ANSWER: #5 – In a marketing study participant were measured as to: 1) the number of mobile devices registered to their wireless plan; and 2) the amount of data (in average GB per month) they use. The first measurement would result in _____ data and the second measurement would result in _____ data. ANSWER: #6 – Pat...
This assignment includes the creation of a text document using Vi Editor and changing permissions to...
This assignment includes the creation of a text document using Vi Editor and changing permissions to access the new file. Use Vi Editor to create a text document Add data to your text file Save your text file Exit Vi Editor Display the contents of your file using the following tools: cat head tail Set file permissions as listed below User – RWX Group – RWX Other – RWX Use a GUI tool to display the new file in your...
Using Javascript Create a page places an order for a Calzone: Using Text box to get...
Using Javascript Create a page places an order for a Calzone: Using Text box to get customers Name Radio Buttons for sizes: small, medium, large list for type of crust: crispy, soft, hard check boxes for toppings, with at least 3 to be selected Submit button that displays the order information.
(2.) 2 pages text and 1 page graphs/equations maximum for your answer. Suppose Denver Metro is...
(2.) 2 pages text and 1 page graphs/equations maximum for your answer. Suppose Denver Metro is a government agency responsible for supplying drinking water to the city of Denver, Colorado. Use Course Concepts to address the following questions. (A) Denver is a large metropolitan city anticipating continuous future growth. What categories of costs must Denver Metro cover to provide residents with adequate quantities of water? Identify 4 (number them) and explain thoroughly. (B) Due to the use patterns by the...
Using JAVA Resource: "Analyze and Document JDBC API Calls" text file ** PASTED BELOW** For this...
Using JAVA Resource: "Analyze and Document JDBC API Calls" text file ** PASTED BELOW** For this assignment, you will analyze code that uses the JDBC API to access a database, retrieve data, and compose output based on that data. You will then comment the code to reflect the purpose and expected results of the code. Download the linked TXT file, and read through the Java™ code carefully. Add your name, instructor's name, and today's date to the header comment. Replace...
1) As a browser load a web page, it creates a model of that namely Document...
1) As a browser load a web page, it creates a model of that namely Document Object Model (DOM) Tree. True False 2) Document Object Model (DOM) Tree consists of ________________ main types of nodes. 3 4 5 6 3) Which is not a type of Document Object Model (DOM) node? Document Node Element Node Style Node Attribute Node 4) Which Document Object Model (DOM) node represents the entire page? Document Node Element Node Style Node Attribute Node 5) The...
1) As a browser load a web page, it creates a model of that namely Document...
1) As a browser load a web page, it creates a model of that namely Document Object Model (DOM) Tree. True False 2) Document Object Model (DOM) Tree consists of ________________ main types of nodes. 3 4 5 6 3) Which is not a type of Document Object Model (DOM) node? Document Node Element Node Style Node Attribute Node 4) Which Document Object Model (DOM) node represents the entire page? Document Node Element Node Style Node Attribute Node 5) The...
in c++ (Sum, average and product of numbers in a file) Suppose that a text file...
in c++ (Sum, average and product of numbers in a file) Suppose that a text file Exercise13_3.txt contains six integers. Write a program that reads integers from the file and displays their sum, average and product. Integers are separated by blanks. Instead of displaying the results on the screen, send the results to an output named using your last name. Example:       Contents of Exercise13_3.txt: 100 95 88 97 71 67 80 81 82             Contents of YourLastName.txt: Your...
Suppose the CAPM holds. You know that the average investor has a degree of risk aversion...
Suppose the CAPM holds. You know that the average investor has a degree of risk aversion of 2.9. The current risk free rate is 0.017, the inflation is estimated at 0.027, and the volatility of the market is 0.162. What is the market risk premium?
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT