Quantum Computing. Hafiz Md. Hasan Babu
Чтение книги онлайн.

Читать онлайн книгу Quantum Computing - Hafiz Md. Hasan Babu страница 15

Название: Quantum Computing

Автор: Hafiz Md. Hasan Babu

Издательство: Ingram

Жанр: Программы

Серия:

isbn: 9780750327473

isbn:

СКАЧАТЬ output equations of the half-adder can be mapped with a quantum Peres gate, as shown in figure 4.1, and the quantum half-adder can be obtained by putting C = 0, which is illustrated in figure 4.2. The quantum cost of the quantum half-adder is 4 and the delay is 4Δ.

image

      Figure 4.1. The quantum Peres gate.

image

      Figure 4.2. The quantum Peres gate as a quantum half-adder.

      Table 4.2 is the truth table of a full-adder. From this table we can obtain the output of the full-adder circuit:

      Sum=A⊕B⊕CinCarry=(A⊕B)Cin⊕AB.

A B C in Carry Sum
0 0 0 0 0
0 0 1 0 1
0 1 0 0 1
0 1 1 1 0
1 0 0 0 1
1 0 1 1 0
1 1 0 1 0
1 1 1 1 1

      The output equations of the full-adder can be mapped with the quantum modified Thapliyal Srinivas gate (MTSG), as shown in figure 4.3, and the quantum full-adder can be obtained by putting D = 0, which is shown in figure 4.4. The quantum cost of the quantum full-adder is 6 and the delay is 5Δ.

image

      Figure 4.3. The quantum MTSG gate.

image

      Figure 4.4. The quantum MTSG gate as a quantum full-adder.

      A subtractor is also an important logic component in circuit design. Subtractors are classified into two types: half-subtractors and full-subtractors. The half-subtractor circuit has two inputs A and B where the half-subtractor performs the AB operation.

      Table 4.3 is the truth table of a half-subtractor. From this table we can obtain the half-subtractor circuit:

      Difference=A⊕BBorrow=A¯B.

A B Borrow Difference
0 0 0 0
0 1 1 1
1 0 0 1
1 1 0 0

      The output equations of the half-subtractor can be mapped with a quantum Thapliyal Ranganathan (TR) gate, as shown in figure 4.5, and the quantum half-subtractor can be obtained by putting C = 0, which is shown in figure 4.6. The quantum cost of the quantum half-subtractor is 4 and the delay is 4Δ.

image

      Figure 4.5. The quantum TR gate.

image

      Figure 4.6. The quantum half-subtractor.

      The full-subtractor circuit has three inputs A, B, and Cin, which realize the operation Y = ABC. Table 4.4 is the truth table of a full-subtractor. From this table we can obtain the output of the full-subtractor circuit:

      Difference=A⊕B⊕CinBorrow=(A⊕B¯)Cin⊕AB.

A B C in Borrow Difference
0 0 0 0 0
0 0 1 1 1
0 1 СКАЧАТЬ