A.
Fractional binary numbers:
If each binary digit or bit bi ranges between “0” and “1”, then the notation represented by the below equation
Round-to-even rule:
- This rule rounding can be used even when user are not rounding to a entire number. The rounding can be calculated by using whether the least significant digit is even or odd.
- To binary fractional number, the round-to-even can be used by considering least significant value “0” to be even and “1” to be odd.
Example:
The example for round-to-even is shown below:
Consider a binary number is “10.000112” that is fractional
- From the above binary number, the decimal for “10” is “2”.
- Here the rounding the values nearest to 2 bits to the right of the binary point.
- Hence, the result after rounding is “10.002”.
B.
Fractional binary numbers:
If each binary digit or bit bi ranges between “0” and “1”, then the notation represented by the below equation
Round-to-even rule:
- This rule rounding can be used even when user are not rounding to a entire number. The rounding can be calculated by using whether the least significant digit is even or odd.
- To binary fractional number, the round-to-even can be used by considering least significant value “0” to be even and “1” to be odd.
Example:
The example for round-to-even is shown below:
Consider a binary number is “10.000112” that is
- From the above binary number, the decimal for “10” is “2”.
- Here the rounding the values nearest to 2 bits to the right of the binary point.
- Hence, the result after rounding is “10.002”.
C.
Fractional binary numbers:
If each binary digit or bit
Round-to-even rule:
- This rule rounding can be used even when user are not rounding to a entire number. The rounding can be calculated by using whether the least significant digit is even or odd.
- To binary fractional number, the round-to-even can be used by considering least significant value “0” to be even and “1” to be odd.
Example:
The example for round-to-even is shown below:
Consider a binary number is “10.000112” that is
- From the above binary number, the decimal for “10” is “2”.
- Here the rounding the values nearest to 2 bits to the right of the binary point.
- Hence, the result after rounding is “10.002”.
D.
Fractional binary numbers:
If each binary digit or bit bi ranges between “0” and “1”, then the notation represented by the below equation
Round-to-even rule:
- This rule rounding can be used even when user are not rounding to a entire number. The rounding can be calculated by using whether the least significant digit is even or odd.
- To binary fractional number, the round-to-even can be used by considering least significant value “0” to be even and “1” to be odd.
Example:
The example for round-to-even is shown below:
Consider a binary number is “10.000112” that is
- From the above binary number, the decimal for “10” is “2”.
- Here the rounding the values nearest to 2 bits to the right of the binary point.
- Hence, the result after rounding is “10.002”.
Want to see the full answer?
Check out a sample textbook solutionChapter 2 Solutions
Computer Systems: A Programmer's Perspective (3rd Edition)
- Chapter 3: Practice Problems VIII. You are given the following C code to compute integer absolute value: int abs(int x) { } return x > (sizeof(int)*8-1); int comp = x mask; return comp; } A. What bit pattern does mask have, as a function of x? B. What numerical value does mask have, as a function of x? C. For what values of x do functions abs and opt abs return identical results? D. For the cases where they produce different results, how are the two results related? E. Show that with the addition of just one single arithmetic operation (any C operation is allowed) that you can fix opt abs. Show your modifications on the original code. (You can just provide the line that you will add). F. Are there any values of x such that abs returns a value that is not greater than 0? Which value(s)?arrow_forwardH.W:- Used Cramer's Rule to find the value of the variables in the following equations: G. 3x1 + 2x2x3 = 4, x1 + x25x3 = -3, (1) - (2) -2x1x2 + 4x3 = 0. (3)arrow_forward(c) A third expression is due to Wallis (1656): ㅠ 2 2 4 4 6 6 ² = ( ² × ²3 ) × ( ² × ¦ ) × ( ÷ × ;) 2 1 3 5 5 7 X... X 2i 2i X 2i 1 2i + 1 :) X... Write a function pi_wallis (n) which takes an integer n as input and returns an approximation of by evaluating the Wallis formlua with n brackets in the formula. (For example, pi_wallis (3) should return 2.9257142857....)arrow_forward
- H.W:- Used Cramer's Rule to find the value of the variables in the following equations 3x1 + 2x2 - x3 = 4, (1) x1 + x2 - 5x3 = -3, (2) -2x1 - x2 + 4x3 = 0. (3)arrow_forward5-Find the solution of the following LP problem using simplex method. Min F =12x, +5x, St. 4x, +2x, 2 80 2.x, + 3x, 2 90 Ans.[0,40]arrow_forwardProblem #2: [35 pts] Parity Bit CheckerThe parity bit of a sequence of bits is 0 if the number of 1’s in the sequence is even and 1otherwise.Example: if the sequence of bits is 1 1 0 1, the parity bit should be 1 (total number of 1-bits is 3 whichis odd) if the sequence of bits is 1 0 1 0, the parity bit should be 0 (total number of 1-bits is 2 whichis even)Write a Java program that asks the user to enter the number of bits he has. The program thenreads the bits as separate integers. In the end, the program prints the parity bit on the screen. Ifthe use enters a bit value that is neither 0 nor 1, the entry should be discarded and a messagedisplayed as shown in the sample run.Sample run 1:How many bits do you have? 6Enter 6 bits: 1 1 0 0 1 0The parity bit is 1Sample run 2:How many bits do you have? 8Enter 8 bits: 1 1 1 0 0 0 0 1The parity bit is 0Sample run 3:How many bits do you have? 5Enter 5 bits: 1 1 3 0 1Incorrect bit value 3 is discarded.The parity bit is 1 java brogramarrow_forward
- Problem#2: - Implement the following function with 8x1 line multiplexer? F(A, B, C ,D) = E m( 1, 3, 4, 11, 12, 13, 14, 15) A B D F 8X1 MUX So 0. A 1 S, 1 1 C S 2 1 1 1 F 1 1 1 1 1 1 1 1.arrow_forward1. (a) What is the machine representation of 3/7 in double precision format (M = 11, N = 52)? (b) Suppose you use double precision floating point arithmetic with round to even rule. What is x – fl(x) for x = 234 + 2-8+2-16 + 2-24? %3Darrow_forwardProblem 2 Assume your computer is capable of solving a 10³ × 10³ system (of 64-bit numbers) in 1 second using Gauss elimination. Solve the following: a) How many floating-point operations per second (FLOPS) is your computer capable of? b) How long will it take to solve a 105 × 10° system using Gauss elimination? c) How long will it take to solve a 10% × 10° system with a banded structure of p = q = 5 using banded Gauss elimination? d) How long will it take to solve a 10³ × 10³ system using Gauss-Seidel with 100 iterations?arrow_forward
- Problem_#09] Determine the value of the IEEE single precision floating-point number. (a) 1 10000001 01001001110001000000000 (b) 0 11001100 10000111110100100000000 Problem_#10] Perform the addition in 2's complement form. (a) 33 and 15 (b) 56 and -27 (c) -46 and 25 (d) -110 and -84arrow_forwardPROBLEMS FOR PRACTICE REPRESENT THE FOLLOWING NUMBERS IN SIGN MAGNITUDE, RADIX AND DIMINISHED RADIX FORM (i) +96 (ii) -50 (iii) 2 REPRESENT THE FOLLOWING NUMBERS IN SCIENTIFIC AND FLOATING POINT NOTATIONS (i) 325680000000 (ii) 0.00001568900 (iii) 1.25698000000 (iv)-568923000000 (v)-0.000001589654arrow_forward3. Express the other canonical form of the following boolean functions: a. F(x,y,z) = (0, 4, 5,7) b. F(w,x,y,z)=(1, 5, 6, 7, 9,10,11) 4. Obtain the complement of the following boolean functions: a. F(x,y,z) = (x+y+z)(x'+z')(x+y) b. F(x,y,z) = (1,3,7), to be in sum of minterms.arrow_forward
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education