Hexadecimal Multiplication using 2's complement

Click For Summary

Discussion Overview

The discussion revolves around performing hexadecimal multiplication using the 2's complement method, specifically calculating ##FFFD_{16} * FFF1_{16}##. Participants explore the conversion of hexadecimal values to decimal and back, as well as the implications of sign in the multiplication result.

Discussion Character

  • Homework-related
  • Mathematical reasoning
  • Debate/contested

Main Points Raised

  • One participant presents their solution, converting ##FFFD_{16}## and ##FFF1_{16}## to their 2's complement forms and claims the product is ##0D2_{16}##.
  • Several participants question the correctness of the conversion and the final answer, particularly whether ##D2_{16}## corresponds to the expected decimal result of ##3 * 15##.
  • Another participant recalculates and asserts that the correct product should be ##2D_{16}##, based on their interpretation of the multiplication.
  • There is a discussion about performing the multiplication directly in hexadecimal versus converting to decimal, with some expressing frustration about the complexity of the arithmetic in hexadecimal.
  • One participant acknowledges a previous mistake in notation, confusing ##D2## with ##2D##.

Areas of Agreement / Disagreement

Participants do not reach a consensus on the correct answer to the multiplication problem. Multiple competing views exist regarding the correct interpretation of the hexadecimal multiplication and the resulting values.

Contextual Notes

There are unresolved issues regarding the assumptions made in the calculations, particularly concerning the handling of negative values in 2's complement and the arithmetic process in hexadecimal.

Fatima Hasan
Messages
315
Reaction score
14

Homework Statement


Perform the following operations using 2's complement method.
##FFFD_{16} * FFF1_{16}##

Homework Equations


-

The Attempt at a Solution


##FFFD_{16}## ----> (1's comp.) = ##0002_{16}## -----> (2's comp.) = ##0003_{16}##
##FFF1_{16}## ----> (1's comp.) = ##000E_{16}## -----> (2's comp.) = ##000F_{16}##
##0003_{16} * 000F_{16} = D2_{16} ##

But ##FFFD_{16} ## ( negative ) * ##FFF1_{16}## ( negative ) , so the answer should be positive .
The answer is ## = 0D2_{16}## (positive ) .
Could anyone check my answer please ?
 
Physics news on Phys.org
what is D2 base 16 in decimal? Does it sound like the right answer for 3x15?
 
phinds said:
what is D2 base 16 in decimal? Does it sound like the right answer for 3x15?
##2D_{16}##
 
Fatima Hasan said:
##2D_{16}##
Did you not understand my question? What is that in DECIMAL base?
 
phinds said:
Did you not understand my question? What is that in DECIMAL base?
##D2_{16} = 13 * 16 + 2 * 16^0 ##
## = 210 ##
It's not the right answer for 3*15 .
I tried to solve the problem again and this is my work :
## 3 * 15 = 45## in decimal which is equal to ##2D_{16} ##
So, ##FFFD_{16} ## ( negative ) * ##FFF1 ## (negative) = ##02D_{16}##
 
Fatima Hasan said:
##D2_{16} = 13 * 16 + 2 * 16^0 ##
## = 210 ##
It's not the right answer for 3*15 .
I tried to solve the problem again and this is my work :
## 3 * 15 = 45## in decimal which is equal to ##2D_{16} ##
So, ##FFFD_{16} ## ( negative ) * ##FFF1 ## (negative) = ##02D_{16}##
Yes, and can you do the actual arithmetic in base 16? (I wouldn't bother but I'm not sure if that's part of what you are supposed to do)
 
Fatima Hasan said:
I solved it again and I got ##2D_{16}## not ##D2_{16}##.
Yes, I deleted the post where I mistakenly said it 2D was wrong. I got the 2D confused with the D2
 
phinds said:
Yes, and can you do the actual arithmetic in base 16? (I wouldn't bother but I'm not sure if that's part of what you are supposed to do)
3 * F (15 in decimal) = 45 in decimal.
45 / 16 = 2.8125 ( 2 is the first digit , subtract 2 from 2.8125 and multiply the answer by 16 to get the second digit which is 13 in decimal ( D in base 16 ).
 
Fatima Hasan said:
3 * F (15 in decimal) = 45 in decimal.
45 / 16 = 2.8125 ( 2 is the first digit , subtract 2 from 2.8125 and multiply the answer by 16 to get the second digit which is 13 in decimal ( D in base 16 ).
No, I mean can you do the original problem FFFD*FFF1 IN HEX not in decimal. I don't know that it's a requirement of the problem, I'm just asking if you CAN do it. Anyway, I think I've given you what help I can with this problem so I'll bow out now.
 
  • #10
phinds said:
No, I mean can you do the original problem FFFD*FFF1 IN HEX

yes, but it's annoying and requires twice the register space and use of a rubber chicken to do it flat out instead of as complements.
 
  • Like
Likes   Reactions: phinds
  • #11
Fatima Hasan said:
But ##FFFD_{16} ## ( negative ) * ##FFF1_{16}## ( negative ) , so the answer should be positive .
The answer is ## = 0D2_{16}## (positive ) .
Could anyone check my answer please ?
Is this all solved now, Fatima Hasan? The only problem being that you have been writing D2 where you meant to write 2D?
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
11K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 17 ·
Replies
17
Views
3K
  • · Replies 4 ·
Replies
4
Views
5K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 3 ·
Replies
3
Views
16K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 4 ·
Replies
4
Views
2K
Replies
8
Views
2K