how?

The Gateway to Computer Science Excellence

First time here? Checkout the FAQ!

x

+20 votes

When two $4-bit$ numbers $A = a_3a_2a_1a_0$ and $B=b_3b_2b_1b_0$ are multiplied, the bit $c_1$ of the product $C$ is given by ________

+30 votes

Best answer

$\begin{matrix}

& & & &a_3 & a_2 & a_1&a_0 \\

& & &\times & b_3 &b_2 &b_1 &b_0 \\

\hline

& & & & a_3b_0 &a_2b_0 &a_1b_0 & a_0b_0&\\

& & &a_3b_1 &a_2b_1 &a_1b_1 & a_0b_1 &- &\\

& &a_3b_2 &a_2b_2 &a_1b_2 &a_0b_2 &- &- &\\

& a_3b_3 &a_2b_3 &a_1b_3 &a_0b_3 &- &- &- \\

\hline

c_7&c_6&c_5 &c_4 &c_3 &c_2 &c_1 &c_0 \\ \hline

\end{matrix}$

$c_1=b_1 a_0 \oplus a_1 b_0$

& & & &a_3 & a_2 & a_1&a_0 \\

& & &\times & b_3 &b_2 &b_1 &b_0 \\

\hline

& & & & a_3b_0 &a_2b_0 &a_1b_0 & a_0b_0&\\

& & &a_3b_1 &a_2b_1 &a_1b_1 & a_0b_1 &- &\\

& &a_3b_2 &a_2b_2 &a_1b_2 &a_0b_2 &- &- &\\

& a_3b_3 &a_2b_3 &a_1b_3 &a_0b_3 &- &- &- \\

\hline

c_7&c_6&c_5 &c_4 &c_3 &c_2 &c_1 &c_0 \\ \hline

\end{matrix}$

$c_1=b_1 a_0 \oplus a_1 b_0$

+25

When we consider 2 bits, ADD and XOR works the same except when both inputs are 1. In this case, ADD gives 10, while XOR gives 0. Since, we are asked only about the bit c1, our answer should be 0 which is given by XOR.

+3

@ sid1221 We need to add these two bits,so we can use same expression of sum of half adder which is exor

0

@VS

I think expression for C2 will not be same ..value of C2 depend on carry if generated while calculating C1,

Hence C2 => C1 $\bigoplus$ Carry out of First adder

- All categories
- General Aptitude 1.5k
- Engineering Mathematics 7.1k
- Digital Logic 2.7k
- Programming & DS 4.9k
- Algorithms 4.2k
- Theory of Computation 5.3k
- Compiler Design 2.1k
- Databases 4k
- CO & Architecture 3.5k
- Computer Networks 4k
- Non GATE 1.4k
- Others 1.5k
- Admissions 556
- Exam Queries 553
- Tier 1 Placement Questions 23
- Job Queries 69
- Projects 18

47,903 questions

52,285 answers

182,209 comments

67,715 users