1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Ainat [17]
3 years ago
8

Convert +41.50 in a IEEE 754 single precision format.

Computers and Technology
1 answer:
mrs_skeptik [129]3 years ago
8 0
<h2>Answer:</h2>

+41.50 = 0 10000100 01001100000000000000000  [single precision]

-72.125 = 1 10000000101 0010000010000000000000000000000000000000000000000000 [double precision]

<h2>Explanation:</h2>

(I) +41.50 using single precision

Follow the following steps:

(a) Single precision has 32 bits in total and is divided into three groups: <em>sign</em> (has 1 bit), an <em>exponent </em>(has 8 bits) and a <em>mantissa </em>(also called fraction, has 23 bits)

(b) Divide the number (41.50) into its whole and decimal parts:

Whole = 41

Decimal = 0.50

(c) Convert the whole part to binary:

<u>2    |    41</u>

<u>2    |    20 r 1</u>

<u>2    |    10 r 0</u>

<u>2    |    5 r 0</u>

<u>2    |    2 r 1</u>

<u>2    |    1 r 0</u>

<u>      |    0 r 1</u>

<u />

Reading upwards gives 41 = 101001₂

(d) Convert the decimal part to binary:

0.50 x 2 = 1.0  = 1 [number in front of decimal]

0.0 x 2 = 0.0 = 0  [number in front of decimal]

Reading downwards gives 0.5 = 10₂

(e) Put the two parts together as follows;

    101001.10₂

(f) Convert the result in (e) to its base 2 scientific notation:

Move the decimal to just before the leftmost bit as follows;

1.0100110

In doing so, we have moved over 5 numbers to the left. Therefore, the exponent is 5. Moving to the left gives a positive exponent while moving to the right gives a negative exponent.

Altogether we have;

1.0100110 x 2⁵

(g) Determine the sign bit of the number and display in binary: Since the number +41.50 is positive, the sign bit is 0.

(h) Determine the exponent bits.

Since this is a single precision conversion, the exponent bias is 127.

To get the exponent we add the exponent value from (e) to the exponent bias and get;

5 + 127 = 132

(i) Convert the exponent to binary:

<u>2    |    132</u>

<u>2    |    66 r 0</u>

<u>2    |    33 r 0</u>

<u>2    |    16 r 1</u>

<u>2    |    8 r 0</u>

<u>2    |    4 r 0</u>

<u>2    |    2 r 0</u>

<u>2    |    1 r 0</u>

<u>      |    0 r 1</u>

Reading upwards gives 132 = 10000100₂

(j) Determine the mantissa bits:

The mantissa is the rest of the number after the decimal of the base 2 scientific notation found in (f) above.

0100110 from 1.0100110 x 2⁵                  [<em>Just remove the leftmost 1 and the decimal point</em>]

(k) Combine the three parts: sign bit (1 bit), exponent bits (8 bits) and mantissa bits (23 bits)

sign bit = 0                [1 bit]

exponent bits = 10000100        [8 bits]

mantissa bits = 0100110        [7 out of 23 bits]

Then fill out the remaining part of the mantissa with zeros to make it 23 bits.

mantissa bits = 01001100000000000000000        

Putting all together we have

0 10000100 01001100000000000000000 as +41.50 in  a IEEE 754 single precision format.

(II) -72.125 using double precision

Follow the following steps:

(a) Double precision has 32 bits in total and is divided into three groups: <em>sign</em> (has 1 bit), an <em>exponent </em>(has 11 bits) and a <em>mantissa </em>(also called fraction, has 52 bits)

(b) Divide the number (72.125) into its whole and decimal parts:

Whole = 72

Decimal = 0.125

(c) Convert the whole part to binary:

<u>2    |    72</u>

<u>2    |    36 r 0</u>

<u>2    |    18 r 0</u>

<u>2    |    9 r 0</u>

<u>2    |    4 r 1</u>

<u>2    |    2 r 0</u>

<u>2    |    1 r 0</u>

<u>      |    0 r 1</u>

<u />

Reading upwards gives 72 = 1001000₂

(d) Convert the decimal part to binary:

0.125 x 2 = 0.25  = 0 [number in front of decimal]

0.25 x 2 = 0.50 = 0  [number in front of decimal]

0.50 x 2 = 1.00 = 1  [number in front of decimal]

0.00 x 2 = 0.00 = 0  [number in front of decimal]

Reading downwards gives 0.125 = 0010₂

(e) Put the two parts together as follows;

    1001000.0010₂

(f) Convert the result in (e) to its base 2 scientific notation:

Move the decimal to just before the leftmost bit as follows;

1.0010000010

In doing so, we have moved over 6 numbers to the left. Therefore, the exponent is 6. Moving to the left gives a positive exponent while moving to the right gives a negative exponent.

Altogether we have;

1.0010000010 x 2⁶

(g) Determine the sign bit of the number and display in binary: Since the number -72.125 is negative, the sign bit is 1.

(h) Determine the exponent bits.

Since this is a double precision conversion, the exponent bias is 1023.

To get the exponent we add the exponent value from (e) to the exponent bias and get;

6 + 1023 = 1029

(i) Convert the exponent to binary:

<u>2    |    1029</u>

<u>2    |    514 r 1</u>

<u>2    |    257 r 0</u>

<u>2    |    128 r 1</u>

<u>2    |    64 r 0</u>

<u>2    |    32 r 0</u>

<u>2    |    16 r 0</u>

<u>2    |    8 r 0</u>

<u>2    |    4 r 0</u>

<u>2    |    2 r 0</u>

<u>2    |    1 r 0</u>

<u>      |    0 r 1</u>

Reading upwards gives 1029 = 10000000101₂

(j) Determine the mantissa bits:

The mantissa is the rest of the number after the decimal of the base 2 scientific notation found in (f) above.

0010000010 from 1.0010000010 x 2⁶                  [<em>Just remove the leftmost 1 and the decimal point</em>]

(k) Combine the three parts: sign bit (1 bit), exponent bits (11 bits) and mantissa bits (52 bits)

sign bit = 1                [1 bit]

exponent bits = 10000000101    [11 bits]

mantissa bits = 0010000010        [10 out of 52 bits]

Then fill out the remaining part of the mantissa with zeros to make it 52 bits.

mantissa bits = 0010000010000000000000000000000000000000000000000000

Putting all together we have

1 10000000101 0010000010000000000000000000000000000000000000000000 as -72.125 in  a IEEE 754 double precision format.

You might be interested in
Easy way of communication with people is one disadvantage of a network. *<br><br> 1.True<br> 2.False
Maksim231197 [3]

Answer:

false

because we are able to connect with people easily..

without have to wait for long time in the case of letters..

4 0
2 years ago
Read 2 more answers
The operating systems, and utility programs that perform system
Phantasy [73]

Answer:

System softwares.

Explanation:

A software can be defined as a set of executable instructions (codes) or collection of data that is used typically to instruct a computer how to perform a specific task and to solve a particular problem.

Basically, softwares are categorized into two (2) main categories and these are;

I. Utility software.

II. System software.

The operating systems, and utility programs that perform system maintenance and protection tasks such as error correction and backup are called system softwares.

An operating system is a system software pre-installed on a computing device to manage or control software application, computer hardware and user processes.

This ultimately implies that, an operating system acts as an interface or intermediary between the computer end user and the hardware portion of the computer system (computer hardware) in the processing and execution of instructions.

Some examples of an operating system on computers are QNX, Linux, OpenVMS, MacOS, Microsoft windows, IBM, Solaris, VM etc.

On the other hand, a utility software can be defined as a software application or program designed to add more functionality to a computer system, as well as to improve its performance efficiently. Some examples of commonly used utility tools in computer are file and folder backup tools, file management, antivirus, hard disk diagnostics, registry cleaner, network performance monitor, screensavers etc.

4 0
2 years ago
Look at the following structure declaration.
myrzilka [38]

Answer:

B. a tag

Explanation:

In the structure definition given below:

struct Employee

{

string name;

int idNum;  

};

Employee corresponds to the tag of the structure. The tag is used to create additional instances of the structure. For example:

struct Employee e1;

struct Employee e2;

name and idNum are members of the Employee structure and are referenced using the dot notation. e.g.,

struct Employee e1;

e1.idNum=1;

7 0
3 years ago
Freeeeeeee brainliest!!!
kondaur [170]

Answer:

Oh Thanks :)

Explanation:

7 0
3 years ago
Q1). Write a python program to pass a list to a function and double the odd values and half even values of a list and display li
zepelin [54]

Answer:

\textsf{\large{\underline{Solution}:}}

The given problem is solved using language - Python.

def f(x):

   new_list=[]

   for i in x:

       if i%2==0:

           new_list.append(i//2)

       else:

           new_list.append(i*2)

   return new_list

   

my_list=list(range(1,6))

print('Original List:',my_list)

my_list=f(my_list)

print('Modified List:',my_list)

\textsf{\large{\underline{Logic}:}}

  1. Create a new list.
  2. Iterate over the list passed into the function.
  3. Check if the element is even or not. If true, append half the value of element in the list.
  4. If false, append twice the value of the element in the list.
  5. At last, return the new list.

There is another way of doing this - By using map() function.

—————————————————————————————

def f(x):

   return list(map(lambda x:x//2 if x%2==0 else 2*x,x))

   

my_list=list(range(1,6))

print('Original List:',my_list)

my_list=f(2my_list)

print('Modified List:',my_list)

—————————————————————————————

\textsf{\large{\underline{O{u}tput}:}}

Original List: [1, 2, 3, 4, 5]

Modified List: [2, 1, 6, 2, 10]

8 0
3 years ago
Other questions:
  • The Internet and World Wide Web allow almost any business to be global. What are two important results of this process?
    8·1 answer
  • Compose a program to examine the string "Hello, world!\n", and calculate the total decimal numeric value of all the characters i
    7·1 answer
  • PLEASE help me RIGHT NOW!!!!!!!!! I will give a Brainly to anyone who helps me!
    15·1 answer
  • Vector testGrades contains NUM_VALS test scores. Write a for loop that sets sumExtra to the total extra credit received. Full cr
    7·1 answer
  • Which of the following is part of Connections Academy's AUP regarding the use of the school'supplied technology
    7·2 answers
  • Where ....................... the books that you borrowed? *
    5·1 answer
  • 4. Give four reasons why a laptop computer is more expensive than a desktop computer of the
    10·1 answer
  • Commercial technical data and commercial software:_________.
    11·1 answer
  • THis took FOREVER! please go check it out, if you have seen my demo to this game, you will like the full version! https://scratc
    9·2 answers
  • Carl is beginning a digital forensic investigation. he has been sent into the field to collect a machine. when he arrives, he se
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!