<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://qetlab.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Bell</id>
	<title>Bell - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://qetlab.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Bell"/>
	<link rel="alternate" type="text/html" href="https://qetlab.com/wiki/index.php?title=Bell&amp;action=history"/>
	<updated>2026-07-14T05:06:58Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.3</generator>
	<entry>
		<id>https://qetlab.com/wiki/index.php?title=Bell&amp;diff=404&amp;oldid=prev</id>
		<title>Nathaniel: Created page with &quot;{{Function |name=Bell |desc=Produces a Bell state |rel=MaxEntangled |cat=[[List of functions#Special_states,_vectors,_and_operators|Special states, vectors, and operators]...&quot;</title>
		<link rel="alternate" type="text/html" href="https://qetlab.com/wiki/index.php?title=Bell&amp;diff=404&amp;oldid=prev"/>
		<updated>2014-09-23T17:16:38Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{Function |name=Bell |desc=Produces a Bell state |rel=&lt;a href=&quot;/MaxEntangled&quot; title=&quot;MaxEntangled&quot;&gt;MaxEntangled&lt;/a&gt; |cat=[[List of functions#Special_states,_vectors,_and_operators|Special states, vectors, and operators]...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Function&lt;br /&gt;
|name=Bell&lt;br /&gt;
|desc=Produces a Bell state&lt;br /&gt;
|rel=[[MaxEntangled]]&lt;br /&gt;
|cat=[[List of functions#Special_states,_vectors,_and_operators|Special states, vectors, and operators]]&lt;br /&gt;
|upd=September 23, 2014&lt;br /&gt;
|v=0.50}}&lt;br /&gt;
&amp;lt;tt&amp;gt;&amp;#039;&amp;#039;&amp;#039;Bell&amp;#039;&amp;#039;&amp;#039;&amp;lt;/tt&amp;gt; is a [[List of functions|function]] that returns one of the four Bell states in 2-qubit space:&lt;br /&gt;
&amp;lt;center&amp;gt;&amp;lt;math&amp;gt;\displaystyle\begin{align*}|\phi_0\rangle = \frac{1}{\sqrt{2}}(|0\rangle\otimes|0\rangle + |1\rangle\otimes|1\rangle) &amp;amp; &amp;amp; &amp;amp; &amp;amp; |\phi_2\rangle = \frac{1}{\sqrt{2}}(|0\rangle\otimes|1\rangle + |1\rangle\otimes|0\rangle) \\ |\phi_1\rangle = \frac{1}{\sqrt{2}}(|0\rangle\otimes|0\rangle - |1\rangle\otimes|1\rangle) &amp;amp; &amp;amp; &amp;amp; &amp;amp; |\phi_3\rangle = \frac{1}{\sqrt{2}}(|0\rangle\otimes|1\rangle - |1\rangle\otimes|0\rangle) \\\end{align*}&amp;lt;/math&amp;gt;&amp;lt;/center&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Syntax==&lt;br /&gt;
* &amp;lt;tt&amp;gt;PHI = Bell()&amp;lt;/tt&amp;gt;&lt;br /&gt;
* &amp;lt;tt&amp;gt;PHI = Bell(IND)&amp;lt;/tt&amp;gt;&lt;br /&gt;
* &amp;lt;tt&amp;gt;PHI = Bell(IND,SP)&amp;lt;/tt&amp;gt;&lt;br /&gt;
* &amp;lt;tt&amp;gt;PHI = Bell(IND,SP,NRML)&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Argument descriptions==&lt;br /&gt;
* &amp;lt;tt&amp;gt;IND&amp;lt;/tt&amp;gt; (optional, default 0): The index of the Bell state (i.e., the subscript, from 0 to 3, of the Bell state that you would like, as indicated above).&lt;br /&gt;
* &amp;lt;tt&amp;gt;SP&amp;lt;/tt&amp;gt; (optional, default 0): A flag (either 1 or 0) indicating that &amp;lt;tt&amp;gt;PHI&amp;lt;/tt&amp;gt; should or should not be sparse.&lt;br /&gt;
* &amp;lt;tt&amp;gt;NRML&amp;lt;/tt&amp;gt; (optional, default 1): A flag (either 1 or 0) indicating that &amp;lt;tt&amp;gt;PHI&amp;lt;/tt&amp;gt; should or should not be scaled to have Euclidean norm 1. If &amp;lt;tt&amp;gt;NRML=0&amp;lt;/tt&amp;gt; then each entry of &amp;lt;tt&amp;gt;PHI&amp;lt;/tt&amp;gt; is 0 or 1, so it has norm $\sqrt{2}$.&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
The following code generates a matrix whose columns are the four different Bell states:&lt;br /&gt;
&amp;lt;syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;gt;&amp;gt; [Bell(0),Bell(1),Bell(2),Bell(3)]&lt;br /&gt;
&lt;br /&gt;
ans =&lt;br /&gt;
&lt;br /&gt;
    0.7071    0.7071         0         0&lt;br /&gt;
         0         0    0.7071    0.7071&lt;br /&gt;
         0         0    0.7071   -0.7071&lt;br /&gt;
    0.7071   -0.7071         0         0&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{SourceCode|name=Bell}}&lt;/div&gt;</summary>
		<author><name>Nathaniel</name></author>
	</entry>
</feed>