Truth Table will be as:
Input (Address lines) |
Output (Data) |
---|
I0 |
I1 |
I2 |
B0 |
B1 |
B2 |
B3 |
B4 |
B5 |
---|
0 |
0 |
0 |
0 |
0 |
0 |
0 |
0 |
0 |
0 |
0 |
1 |
0 |
0 |
0 |
0 |
0 |
1 |
0 |
1 |
0 |
0 |
0 |
0 |
1 |
0 |
0 |
0 |
1 |
1 |
0 |
0 |
1 |
0 |
0 |
1 |
1 |
0 |
0 |
0 |
1 |
0 |
0 |
0 |
0 |
1 |
0 |
1 |
0 |
1 |
1 |
0 |
0 |
1 |
1 |
1 |
0 |
1 |
0 |
0 |
1 |
0 |
0 |
1 |
1 |
1 |
1 |
1 |
0 |
0 |
0 |
1 |
example for 111 (7), square will 110001 (49)
so it will have 3 address line mean 8 address [000 to 111] and 6 bits [B0 to B5] at each address = 8 X 6 = 48 bits
but we do not need to store B4 and B5 [as B4 = 0 and B5 = I2 ]
so ROM will be of size 8 x 4 = 32bits.