For questions concerning finite precision arithmetic in computers and other related concepts.
Questions tagged [computer-arithmetic]
111 questions
4
votes
3 answers
Differences between signed and unsigned decimal values
What are examples of signed and unsigned decimal values? What are the differences between them?
Bilis
- 125
2
votes
1 answer
IEEE754 32-bit single precision format
I have a question like this:
Show how the number $-12.75$D is stored in the computer's storage using IEEE754 32-bit single precision format. You are required to show your conversion steps clearly.
My answer…
Bilis
- 125
1
vote
1 answer
Logic Circuits And Equations Issue - Multiply Binary Number By 3
I am trying to build a logic circuit that multiplies any 4 digit binary number by 3.
I know that if I multiply/divide number by 2 it moves left/right the digits, but what I'm
doing with multiply by 3?
How to extract the equations that multiply…
Ofir Attia
- 3,136
1
vote
1 answer
Why do some results for two's complement subtraction requires another conversion of two's complement again while some don't?
Currently a student studying computer arithmetic, came across two's complement subtraction and some of the questions that I did, their answers does not another conversion of two's complement again while some have to.
This example requires a…
Han
- 23
1
vote
3 answers
Possible combinations of binary digits
Why do we say 2 raised to a "n" ,where n is the number of digits = the possible combinations for that binary number
For example:
(00000000)2 Has 2 raised to 8 = 256
Why?
user_
- 253
0
votes
1 answer
Algorithms on converting hex to IEEE-754 single-precision floating point number
I need help with finding algorithm converting hex to IEEE-754 single-precision floating point number (without coding). I couldn't find any on the internet :(
For example, given input string 0xB9CD542, we need to return string 0x1.39aa84p-104 where…
regina
- 27
- 3
0
votes
0 answers
summation result
I have an array A = [1,2,3] I need to find the array B[i] with the below statement. calculation i did:
B[0] = A[1] + F[0]
1 + F[0] = 1+0=2 hence B=[1]
1 + F[1] = 1+2=3 hence B=[1,2]
1 + F[2] = 1+3=4 hence B=[1,3,4] but the…
0
votes
0 answers
Modified ceiling and floor calculations that take into account binary digit sums
If we define $\nu(n)$ as the binary digit sum of the natural number $n$. I want to quickly calculate a strange floor and ceiling of a rational $x$:
$\lceil x\rceil_b=\min(\{m\in N|m\ge x,\nu(m)\le b\})$
$\lfloor x\rfloor_b=\max(\{m\in N|m\le…
Neill Clift
- 11
0
votes
0 answers
Tens Compliment Arithmetic.
For the following pairs of 4 digit decimal numbers, A and B, show the ten's complement of each, compute A + B and A – B using ten's complement arithmetic, indicate which of the 4 numbers (A, B, A + B, and A – B) are negative (and give their ten's…
0
votes
1 answer
Adder delay model in a ripple carry adder.
In section 5.3. of the following book an analysis of carry propagation in the ripple carry adder is performed. However the statistical analysis doesn't particularly convince me. Specifically at the beginning of page 81 it is stated that "The…
user8469759
- 5,285
0
votes
1 answer
Implementing a (5,5;4) counter with FA and HA
I am trying to implement a (5,5;4)-counter using only FA's and HA's as building blocks. I tried using both Wallace and Dadda tree structures, but I was never able to end up with a 4-bit number as a result. I keep on obtaining 5-bit outputs.
The…
H. Doerr
- 1
0
votes
1 answer
How can I get the average of two numbers represented as bytes?
I'm dealing with numbers, each one represented by two bytes (a short value, in the programming sense).
I want to compute the average of these two numbers, and get once again two bytes back.
Can I just do the following?
result_byte_A =…
Aviv Cohn
- 449