2
$\begingroup$

The Toffoli gate takes in three inputs and gives out three outputs, and is often referred to as the quantum AND gate.

It takes in a,b,c and gives out a, b, c XOR (a AND b).

Why does it do that, instead of just giving out a,b,b AND c? or a,b,(a AND b)?

$\endgroup$
  • 2
    $\begingroup$ in a word, reversibility! $\endgroup$ – vzn Oct 21 '15 at 15:08
  • 1
    $\begingroup$ That's approximately the 7th question you ask about quantum computation in the span of the last two week. there's no magic to understanding it but spending a lot of time, reading about it (maybe using a textbook) until you get the basics. Try to use this site for asking questions after you exhausted all your other immediate resources. $\endgroup$ – Ran G. Oct 21 '15 at 20:34
  • $\begingroup$ Are you sure that's the intent of the site? Isn't it to have good answers to questions that people are likely to ask about? If everyone exhausted all resources before coming here, there would be no site. (Perhaps a better meta post, if this hasn't already been chatted about before) $\endgroup$ – Alan Wolfe Oct 21 '15 at 21:02
  • $\begingroup$ @AlanWolfe, feel free to ask that question on meta -- I suspect you'll get some informative answers. You might like to take a look at cs.stackexchange.com/help/how-to-ask and meta.stackoverflow.com/q/261592/781723, to get some background. $\endgroup$ – D.W. Oct 22 '15 at 23:19
0
$\begingroup$

As the comments said, if it worked like i asked, it would neither be reversible, nor a unitary matrix.

Both things are required for quantum computing!

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.