Monday, May 12, 2008

Assignment 2

(1)
0000=xAND(NOTx)
1000=NOT(xORy)
0100=yAND(NOTx)
0010=xAND(NOTy)
0001=xANDy
1100=NOTx
1010=NOTy
1001=((NOTx)ORy)AND((NOTy)ORx)
0110=(xAND(NOTy))OR(yAND(NOTx))
0101=y
0011=x
1110=NOT(xANDy)
1101=(NOTx)ORy
1011=(NOTy)ORx
0111=xORy
1111=xOR(NOTx)
(2)
0000=xXORx
1000=xXOR(yIMPLx)
0100=xXOR(yXOR((xIMPLy)XOR((xXORx)IMPL(xXORy))))
0010=(xIMPLy)XOR((xXORx)IMPL(xXORy))
0001=xXOR((xIMPLy)XOR((xXORx)IMPL(xXORy)))
1100=xIMPL(xXORx)
1010=yIMPL(xXORx)
1001=(xXORy)IMPL(xXORx)
0110=xXORy
0101=y
0011=x
1110=xIMPL(xXORy)
1101=xIMPLy
1011=yIMPLx
0111=yXOR((xIMPLy)XOR((xXORx)IMPL(xXORy)))
1111=(xXORx)IMPL(xXORy)
Therefore all 16 functions can be written using only complositions of XOR and IMPL.
(3)
(a) Comutative functions: 0000, 1000, 0001, 1001, 0110, 1110, 0111, 1111

(4)
Working in ternary we have 3x3=9 possible combinations (x,y). Our functions will then be columns of 9 digits 0-2, which means 3^9=19683 possibilities. Therefore, there are possible 19,683 bynary operations.
(5)
For binary inputs , there are necessary three operations: AND, OR, NOT to represent all the possible functions.
From my research through the internet, I found out that for ternary inputs, in order to represent all 19,683 possible functions there are necessary four operations: AND, OR, NOT, IMPL .
(6)
(b)

pic1ANDpic2 pic1ORpic2 pic1IMPLpic2


pic1IMPLpic2=(NOTpic1)OR(pic2)
black=1, white=0
black or black =black
white or white =white
black or white =black
white or black =black
For finding pic1IMPLpic2 we imagine overlaping the two original pictures. In the area where the first picture was black and the second one white we will obtain white. The rest of the picture will be black.
(7)
Let:
a=Poison caused the victim's death.
b=There was a change in the blood chemistry.
c=There was a residue of poison in the stomach.
d=There were puncture marks on the body.
e=Poison was injected by a needle.
a IFF (b OR c)
(NOT b) AND (NOTc) AND d
e IMPL d
a XOR (NOT d)
(8)
1)
64K=2^6K
1GB=2^10MB=2^20K
2^20/2^6=2^14 times more memory
2)
1floppy=800K
1DVD=4.7GB=(4.7)x (2^20)KB.
(4.7)x(2^20)/800=6160.384
Therefore we would need 6161 floppy disks to save all the data on a single DVD.
3)
Processor clock rates of early computers:
The clock rate is the fundamental rate in cycles per second (measured in hertz) at which a computer performs its most basic operations such as adding two numbers or transferring a value from one processor register to another. Usually when referring to a computer, the term "clock rate" is used to refer to the speed of the CPU.
The first commercial PC, the Altair 8800 (by MITS), used an Intel 8080 CPU with a clock rate of 2 MHz (2 million cycles/second). The original IBM PC (c. 1981) had a clock rate of 4.77 MHz. In 1995, Intel's Pentium chip ran at 100 MHz , and in 2002, an Intel Pentium 4 model was introduced as the first CPU with a clock rate of 3 GHz.

No comments: