Extending classical logic for reasoning about quantum...

48
Extending classical logic for reasoning about quantum systems R. Chadha * P. Mateus A. Sernadas C. Sernadas Department of Mathematics, IST, TU Lisbon SQIG,InstitutodeTelecomunica¸c˜oes {rchadha,pmat,acs,css}@math.ist.utl.pt February 26, 2008 Abstract A decidable logic extending classical reasoning and supporting quan- tum reasoning is presented. The quantum logic is obtained by applying the exogenous semantics approach to propositional logic. The design is guided by the postulates of quantum mechanics and inspired by applications in quantum computation and information. The models of the quantum logic are superpositions of classical valuations. In order to achieve decidability, the superpositions are taken in inner product spaces over algebraic closures of arbitrary real closed fields. 1 Introduction A new logic EQPL (exogenous quantum propositional logic) was proposed in [26, 27, 28] for modeling and reasoning about quantum systems, embodying all that is stated in the relevant Postulates of quantum physics (as presented, for instance, in [15, 31]). The logic was designed from the semantics upwards, starting with the key idea of adopting superpositions of classical models as the models of the proposed quantum logic. This novel approach to quantum reasoning is different from the mainstream approach [19, 14]. The latter, as initially proposed by Birkhoff and von Neu- mann [8], focuses on the lattice of closed subspaces of a Hilbert space and replaces the classical connectives by new connectives representing the lattice- theoretic operations. The former adopts superpositions of classical models as the models of the quantum logic, leading to a natural extension of the classi- cal language containing the classical connectives (just as modal languages are extensions of the classical language). Furthermore, EQPL allows quantitative reasoning about amplitudes and probabilities, being in this respect much closer to the possible worlds logics for probability reasoning than to the mainstream quantum logics. Finally, EQPL is designed to reason about finite collections of qubits and, therefore, it is suitable for applications in quantum computation * Now at University of Illinois at Urbana-Champaign. 1

Transcript of Extending classical logic for reasoning about quantum...

Page 1: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Extending classical logic for reasoning

about quantum systems

R. Chadha∗ P. Mateus A. Sernadas C. SernadasDepartment of Mathematics, IST, TU Lisbon

SQIG, Instituto de Telecomunicacoesrchadha,pmat,acs,[email protected]

February 26, 2008

Abstract

A decidable logic extending classical reasoning and supporting quan-tum reasoning is presented. The quantum logic is obtained by applying theexogenous semantics approach to propositional logic. The design is guidedby the postulates of quantum mechanics and inspired by applications inquantum computation and information. The models of the quantum logicare superpositions of classical valuations. In order to achieve decidability,the superpositions are taken in inner product spaces over algebraic closuresof arbitrary real closed fields.

1 Introduction

A new logic EQPL (exogenous quantum propositional logic) was proposed in[26, 27, 28] for modeling and reasoning about quantum systems, embodyingall that is stated in the relevant Postulates of quantum physics (as presented,for instance, in [15, 31]). The logic was designed from the semantics upwards,starting with the key idea of adopting superpositions of classical models as themodels of the proposed quantum logic.

This novel approach to quantum reasoning is different from the mainstreamapproach [19, 14]. The latter, as initially proposed by Birkhoff and von Neu-mann [8], focuses on the lattice of closed subspaces of a Hilbert space andreplaces the classical connectives by new connectives representing the lattice-theoretic operations. The former adopts superpositions of classical models asthe models of the quantum logic, leading to a natural extension of the classi-cal language containing the classical connectives (just as modal languages areextensions of the classical language). Furthermore, EQPL allows quantitativereasoning about amplitudes and probabilities, being in this respect much closerto the possible worlds logics for probability reasoning than to the mainstreamquantum logics. Finally, EQPL is designed to reason about finite collectionsof qubits and, therefore, it is suitable for applications in quantum computation

∗Now at University of Illinois at Urbana-Champaign.

1

Page 2: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

and information. The models of EQPL are superpositions of classical valua-tions that correspond to unit vectors expressed in the computational basis ofthe Hilbert space resulting from the tensor product of the independent qubitsystems.

Therefore, in EQPL we can express a wide range of properties of states ofsuch a finite collection of qubits. For example, we can impose that some qubitsare independent of (that is, not entangled with) other qubits; we can prescribethe amplitudes of a specific quantum state; we can assert the probability of aclassical outcome after a projective measurement over the computational basis;and, we can also impose classical constraints on the admissible quantum states.

Herein, we concentrate on presenting a decidable fragment of EQPL by suit-ably relaxing the semantic structures of EQPL. Instead of considering Hilbertspaces we work with inner product spaces over an arbitrary real closed fieldand its algebraic closure. The decidability results from the fact that the firstorder theory of such fields is decidable [24, 6]. This technique was inspired byrelated work on probabilistic logic [1]. Furthermore, the decidable fragment ofEQPL so established turns out to be strongly complete although we concen-trate on weak completeness. The price we have to pay for decidability is a weakarithmetic language – we loose the analytic aspects of complex numbers.

The exogenous approach to extending a given logic is discussed and illus-trated in Section 2. Section 3 presents dEQPL step by step: design options,models, language and its interpretation, sound axiomatization, and some use-ful metatheorems. In Section 4 we show that dEQPL is weakly complete anddecidable. The proof of weak completeness can easily be adapted to a proof ofstrong completeness but we refrained to do so since our primary interest is inapplications involving finitely presented theories. We illustrate the use of dE-QPL with two worked examples in Section 5. First we reason about a Bell state.Afterwards, we reason about the quantum teleportation protocol proposed in[7]. Finally, in Section 6 we assess what was achieved and provide an outlookof further developments of the proposed approach to quantum reasoning.

2 Exogenous approach

The exogenous semantics approach to enriching a given logic roughly consistsof taking as models of the new logic sets of models of the original logic, possiblytogether with some additional structure. This general mechanism for buildingnew logics is described in detail in [29, 9]. The first example of the approachappeared in the context of probabilistic logics [32, 33], although by then notyet recognized as a general construction.

The adjective “exogenous” is used as a counterpoint to “endogenous”. Forinstance, in order to enrich some given logic with probabilistic reasoning it maybe convenient to tinker with the models of the original logic. This endogenousapproach has been used extensively. For example, the domains of first-orderstructures are endowed with probability measures in [21]. Other examples in-clude labeling the accessibility pairs with probabilities in the case of Kripkestructures [22] for reasoning about probabilistic transition systems.

2

Page 3: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

By not tinkering with the original models and only adding some additionalstructure on collections of those models as they are, the exogenous approachhas the potential for providing general mechanisms for enriching a given logicwith some additional reasoning dimension. As we shall see, in our case theexogenous approach has the advantage of closely guiding the design of thelanguage around the underlying concepts of quantum physics while keeping theclassical connectives.

The exogenous approach of collecting the original models as proposed in[26, 27] is inspired by the possible worlds semantics of modal logic [25]. Itis also akin to the society semantics for many-valued logic [12] and to thepossible translations semantics for paraconsistent logic [11]. The possible worldsapproach also plays a role in probabilistic logic [32, 33, 5, 4, 18, 1, 13].

As an introductory example of the exogenous approach, we briefly explainhow a probabilistic logic can be obtained from classical propositional logic, fol-lowing closely [29]. Since quantum reasoning subsumes probabilistic reasoning,this example will also be useful for our purposes. However, before we proceed toexplain the probabilistic logic, we first concentrate on a fragment of the proba-bilistic logic called global propositional logic. Global logic is also a fragment ofthe quantum logic proposed in this paper.

We start by taking a set Π of propositional symbols. From a semantic pointof view, the models of global logic are sets of valuations over Π. The languageof global logic consists of:

• Classical propositional formulas constructed from Π using the classicalconnectives ⊥ and ⇒.

• Global formulas constructed from the classical propositional formulas bythe global connectives ⊥⊥ and A. The global connectives mimic the clas-sical connectives in a sense which we will make precise shortly.

The satisfaction relation between the semantic models and the formulas is asfollows. A model V (V is some set of “classical” valuations) of the global logicsatisfies a classical propositional formula α if every classical valuation v ∈ Vsatisfies α. Therefore, any classical tautology is a global tautology.

Analogous to the case of classical logic, a global valuation V satisfies theglobal formula γ1Aγ2 if either V satisfies γ2 or V does not satisfy γ1. The globalconnective ⊥⊥ is never satisfied. Clearly this is a copy of the classical propo-sitional logic and indeed, if we replace the classical connectives in a classicaltautology by their global counterparts we will get a global tautology.

As we just saw, there are two copies of the classical propositional logic in theglobal logic. A natural question to ask is whether the two copies are necessarilydistinct. The answer is yes and while the connectives ⊥ and ⊥⊥ collapse, it isnot the case with the two implications. However, there is a relation betweenthose two and if V satisfies α1 ⇒ α2 then V also satisfies α1 A α2. The reversedoes not hold in general.

There is a sound and strongly complete axiomatization for global logic whichcontains five axiom schemas and an inference rule. One axiom schema says thatevery classical tautology is a global tautology while the other says that replacing

3

Page 4: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

classical connectives by their global counterparts results in a global tautology.One axiom identifies ⊥ and ⊥⊥, a second one axiomatizes the relation betweenthe two implications that we mentioned above, and the last one says that theclassical and global conjunctions (global conjunction is introduced as usual)collapse. The inference rule is the global counterpart of modus ponens.

Global logic is the first step towards creating the exogenous probabilisticlogic. The probabilistic logic is obtained “exogenously” by assigning probabili-ties to each of the classical valuations in a global valuation V . This allows us toreason about the probability that a classical propositional formula is true in V :the probability of ϕ is the sum of the probabilities of the valuations that satisfyϕ. Given a set Π of propositional symbols, the language of the probabilisticlogic consists of:

• Classical propositional formulas constructed from Π using the classicalconnectives ⊥ and ⇒.

• A set of terms that include:

- real-valued variables and real computable numbers;

- probability terms denoting probabilities of classical formulas; and

- sum and product of terms.

• Comparison formulas of the form t1 ≤ t2 where t1 and t2 are terms.

• Formulas constructed from classical propositional formulas and compari-son formulas using the global connectives ⊥⊥ and A.

A model for the probabilistic logic, that is a probabilistic valuation, con-tains a global valuation along with a probability measure which assigns to eachclassical valuation a real value between 0 and 1. As explained, this gives usan interpretation of the probability terms in the language. The satisfaction ofclassical formulas is the same as in the global logic. Observe that if V satisfiesa classical formula α then the probability of α being true is 1 regardless of theprobability measure on V . Hence, the probability of a classical tautology inany model is always 1.

In order to interpret the variables, the model also contains an assignment ofvariables to real numbers. This helps to interpret the terms and the comparisonformulas in the natural way. The interpretation of the global connectives is thesame as before.

An axiomatization of probabilistic logic is obtained by extending the ax-iomatization for global logic as follows. The connection between the classicalconnectives and probability terms is obtained by three axioms:

1. The probability of any classical tautology is 1.

2. If the probability of the classical formula α1∧α2 is 0 then the probabilityof α1 ∨ α2 is the sum of the probabilities of α1 and α2. This is the finiteadditivity of probability measures.

4

Page 5: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

3. If the probability of the classical formula α1⇒α2 is 1 then the probabilityof α1 is less than the probability of α2. This is the monotonicity propertyof probability measures.

For the comparison formulas, an oracle is used which gives the valid com-parison formulas. The axiomatization is sound and weakly complete modulothe oracle. However, even with the oracle strong completeness fails as the logicis not compact.

The development of the exogenous quantum logic herein follows the samelines as the development of the probabilistic one. Instead of assigning probabil-ities, we assign amplitudes to the classical valuations in a global valuation. Theclassical valuations themselves represent the computational basis of the qubitsin a quantum system. In fact, we are only interested in quantum systems com-posed of a finite number of qubits since applications in quantum computationand information only deal with such systems. A superposition of these classicalvaluations will then give the state of the quantum system. We will explicitlyhave terms in the language to interpret these amplitudes and they will be atthe core of the design of our language. We postpone the detailed discussionof the language and the logic to Section 3. The resulting quantum logic is adecidable fragment of the logic in [28].

These quantum logics obtained using the exogenous approach are philosoph-ically closer to some probabilistic logics (like [18, 1]) than to the mainstreamquantum logics in the tradition of Birkhoff and von Neumann [8, 19, 14]. Bothtypes of quantum logic are motivated by semantic considerations, albeit verydifferent ones. The mainstream quantum logics are based on the idea of replac-ing the Boolean algebras of truth values by the more relaxed notion of ortho-modular lattices. Thus, they end up with non classical connectives reflectingthe properties of meets and joins of those lattices. The exogenous quantumlogics are based on the idea of replacing classical valuations by superpositionsof classical valuations while preserving the classical connectives. On the otherhand, in both types of quantum logic a formula and a propositional symbol inparticular denotes a subspace of the Hilbert space at hand. However, in theexogenous quantum logics a quantum system is assumed to be composed of nqubits and, hence, the underlying Hilbert space has dimension 2n.

Our semantics of quantum logic, although inspired by modal logic, is alsocompletely different from the alternative Kripke semantics given to mainstreamquantum logics (as first proposed in [16]). That Kripke semantics is based onorthomodular lattices.

The quantum logic proposed in [36, 35, 34] is also inspired by probabilisticlogics [18] and capitalizes on some techniques first proposed for those logics, butit has aspects of both mainstream quantum logics and exogenous quantum log-ics. In short, it is a classical logic of probabilistic measurements over a quantumsystem where quantum formulas denote projectors, quantum negation standsfor orthogonal complement and quantum conjunction stands for composition.Note also that no amplitude terms appear in [36, 35] contrarily to exogenousquantum logics where amplitudes replace probabilities as the central concept.

The tensor product plays a key role in the exogenous quantum logics as it

5

Page 6: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

does in the categorical semantics proposed in [2, 3]. However, in our logics westill use the concrete characterization of tensor product of qubits (representedin our language by the propositional symbols).

3 Decidable fragment of EQPL

We start by discussing design issues, and then proceed to introduce the logic.

3.1 Design issues

In this section, we shall discuss how the Postulates of quantum mechanics [15]guided the design of the proposed logic, and give a brief introduction to therelevant concepts and results. The first Postulate of quantum mechanics states:

Postulate 1: Every isolated quantum system is described by a Hilbert space.The states of the quantum system are the unit vectors of the correspondingHilbert space.

Please recall that a Hilbert space is a complete inner product space over C(the field of complex numbers). In quantum computation and information thequantum systems are composed of qubits. For example, the states of an isolatedqubit are vectors of the form z0|0〉+z1|1〉 where z0, z1 ∈ C and |z0|2 + |z1|2 = 1.In other words, they are unit vectors in the (unique up to isomorphism) Hilbertspace of dimension two. As pointed out in the introduction, instead of workingwith a Hilbert space we shall consider a “generalized” inner product spaceover the algebraic closure of an arbitrary real closed field. This design decisionhas the advantage that the resulting logic is decidable. It is possible to workwith Hilbert spaces and still get a weakly-complete calculus as was the casein EQPL [28], a previous version of the logic developed herein. Indeed, thelogic defined here identifies a decidable fragment of EQPL, and hence we shallcall it dEQPL. In addition to being decidable, dEQPL turns out to be stronglycomplete and, therefore, compact. In fact, the source of the non compactnessof EQPL mentioned in [28] was in its arithmetic component.

We shall now briefly review some definitions and results concerning realclosed fields and their algebraic closures.

Definition 3.1 (Real closed fields) An ordered field K = (K, +, ., 1, 0,≤) issaid to be a real closed field if the following hold:

• Every non-negative element of the K has a square root in K.

• Any polynomial of odd degree with coefficients in K has at least onesolution in K.

We shall use K1,K2, . . . to range over real closed fields and k1, k2, . . . torange over the elements of a real closed field. The set of real numbers with theusual multiplication, addition and order constitute a real closed field. The set

6

Page 7: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

of computable real numbers with the same operations is another example of areal closed field.

The algebraic closure of a real closed field K = (K,+,×, 1, 0,≤) is obtainedby adjoining an element δ to K such δ2 +1 = 0. The algebraic closure, denotedby K(δ), is a two-dimensional vector space over K. Each element in K(δ) isof the form k1 + k2δ where k1, k2 ∈ K. The addition and multiplication aredefined as:

(k1 + k2 δ) + (k′1 + k′2 δ) = (k1 + k′1 δ) + (k2 + k′2 δ)(k1 + k2 δ).(k′1 + k′2 δ) = (k1.k

′1 − k2.k

′2) + (k1.k

′2 + k′1.k2δ)

where −k2.k′2 is the additive inverse of k2.k

′2

We shall use c1, c2, . . . to range over the elements of K(δ). For example,the field of complex numbers is the algebraic closure of the set of real numberswith δ = i. The standard notion of conjugation, absolute value and real andimaginary parts from complex numbers can be generalized to K(δ) as follows:

Re(k1 + k2 δ) = k1

Im(k1 + k2 δ) = k2

|k1 + k2 δ| = k21 + k2

2

k1 + k2δ = k1 + (−k2)δ where −k2 is the additive inverse of k2

The conjugation allows us to generalize the notion of inner product andnormed vector space over C to an arbitrary K(δ) as follows:

Definition 3.2 (K(δ)-inner product space) A K(δ)-inner product space isa vector space W over the field K(δ) together with a map

〈·, ·〉 : W ×W → K(δ)

such that for all w, w1, w2 ∈ V and k ∈ K(δ), the following hold:

1. 〈w, w1 + w2〉 = 〈w, w1〉+ 〈w, w2〉.2. 〈w, w〉 ∈ K and 〈w, w〉 ≥ 0.

3. 〈w, w〉 = 0 if and only if w = 0.

4. 〈w1, w2〉 = 〈w2, w1〉.5. 〈w1, cw2〉 = c〈w1, w2〉.

Definition 3.3 (K(δ)-normed vector space) A K(δ)-normed space is a vec-tor space W over the field K(δ) together with a map

||.|| : W ×W → K

such that for all w, w1, w2 ∈ V and k ∈ K, the following hold

1. ||w|| ≥ 0.

7

Page 8: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

2. ||w|| = 0 if and only if w = 0.

3. ||cw|| = |c|||w|| where |c| is the absolute value of c.

4. ||w1 + w2|| ≤ ||w1||+ ||w2||.We shall say that a vector w is a unit vector if ||w|| = 1.

As in the case of inner product spaces over complex numbers, a K(δ)−innerproduct space (W, 〈·, ·〉) gives rise to a norm by letting:

||w|| =√〈w,w〉.

For example, the field K(δ) together with the map: 〈c1, c2〉 = c1.c2 is itselfa K(δ)−inner product space. In this case, the resulting norm ( ||c|| = √

c.c ) isthe absolute value function.

Any Hilbert space is a C-inner product space. However, we shall modelquantum systems as K(δ)−inner product spaces instead of Hilbert spaces, andthe field K(δ) will be a part of our semantic structure. Therefore, any theoremwe prove in the logic would remain valid if we had just used Hilbert spaces.

It is also worthwhile to point out that, unlike Hilbert spaces, K(δ)−innerproduct spaces in general may not have an analytical structure. So, we willnot be able to express properties that necessarily depend upon the analyticalstructure1.

Moreover, as the logic is intended to be applied for quantum computationand information, we shall work only with a special kind of K(δ)−inner productspaces that are defined by free construction from finite sets:

Definition 3.4 (Free K(δ)-inner product space) Given an arbitrary finiteset B, we can construct the free K(δ)-inner product space HK(δ)(B) as:

• Each element of HK(δ)(B) is a map |ψ〉 : B → K(δ).

• |ψ1〉+ |ψ2〉 is pointwise addition, i.e.,

(|ψ1〉+ |ψ2〉)(b) = |ψ1〉(b) + |ψ2〉(b).

• c|ψ〉 is pointwise scalar multiplication, i.e.,

(c|ψ〉)(b) = c (|ψ〉(b)).

• The inner product is given by2

〈ψ1|ψ2〉 =∑

b∈B|ψ1〉(b) |ψ2〉(b).

1For example, we cannot define the exponential function on an arbitrary K(δ).2We adopt here the Dirac notation, given its widespread use by the community of quantum

physics and computation.

8

Page 9: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

The dimension of the vector space HK(δ)(B) is the cardinality of the set B.Given b ∈ B, let |b〉 ∈ HK(δ)(B) be the vector defined as

|b〉(b) = 1 and |b〉(b1) = 0 for every b1 6= b.

It can be easily checked that the set |b〉 : b ∈ B forms a basis of the vectorspace HK(δ)(B). Furthermore, it is the case that 〈b|b〉 = 1 and 〈b|b1〉 = 0 forevery b 6= b1. For obvious reasons, we say that |b〉 : b ∈ B is an orthonormalbasis ofHK(δ)(B). This basis plays an important role in the semantics of dEQPLand for this reason we will henceforth refer to it as being the canonical basis ofHK(δ).

A natural question that arises in this context is how do we choose B. Theanswer lies in our interest in quantum systems composed of qubits. As men-tioned before, the states of an isolated qubit are vectors of the form z0|0〉+z1|1〉where z0, z1 ∈ C and |z0|2 + |z1|2 = 1. The set of states can be identified with(upto isomorphism) the unit vectors in the free C-inner product HC(B) whereB is an set of 2 elements. Keeping this is mind, it is natural to represent a qubitby a propositional symbol (henceforth called a qubit symbol) and take B in thiscase to be the set of two possible classical valuations of the qubit symbol: 0that assigns false to the qubit symbol and 1 that assigns true to it.

Similarly, the states of a isolated pair of qubits are of the form z00|00〉 +z01|01〉+z10|10〉+z11|11〉, where z00, z10, z01, z11 ∈ C and |z00|2+ |z01|2+ |z10|2+|z11|2 = 1. The set of states in this case can be identified with the unit vectors inthe free C-inner productHC(B) where B is the set of the four classical valuationsover the pair of qubit symbols representing the two qubits at hand.

The pattern becomes clear, and in general, we will fix a finite set of qubitsymbols 3:

qB = qbk : 0 < k ≤ n.These will represent the n qubits in our system. As we need to work with thealgebraic closure of arbitrary real closed fields, the states in our systems willbe unit vectors in the free K(δ)-inner product space HK(δ)(2qB), where 2qB isthe set of 2n possible classical valuations of the n qubit symbols. We shall callthese unit vectors K(δ)-quantum valuations over the set qB.

Another characteristic of quantum systems that we are likely to encounterin applications in computation and information is that they will be built fromindependent sub-systems. We shall model the sub-systems by partitioning theset qB, and a semantic structure will contain this partition. Each member ofthe partition, henceforth called a component, will then model the qubits of anindependent sub-system.

If A ⊆ qB is a component, then the states of the A sub-system will bequantum valuations over A, i.e., unit vectors in HK(δ)(2A). If S is the partition,then the semantic structure also includes a collection |ϕ〉A : A ∈ S, where|ϕ〉A is a quantum valuation over A. These represent the states of the sub-systems.

3In [28], the set of qubits was infinite. However, the set was restricted when judgmentswere considered.

9

Page 10: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

In addition to reasoning about component sub-systems, we also need toreason about bigger sub-systems. The sets of qubits of bigger sub-systems aregiven by union of qubits of the component sub-systems. Therefore, given apartition S of qB, we define Alg(S) = ∪iAi : Ai ∈ S. A member F ∈ Alg(S)models the qubits of the component systems. It is easy to see that Alg(S)satisfies the following properties4:

1. ∅, qB ∈ S.

2. G ∈ S implies that qB \G ∈ S.

3. G1, G2 ∈ S implies that G1 ∪G2 ∈ S

We also need a way to construct the states of sub-systems from smaller ones.For this, we take recourse to the second Postulate of quantum mechanics:

Postulate 2: The Hilbert space of a quantum system composed of a finitenumber of independent components is the tensor product of the componentHilbert spaces.

Therefore, for instance, the state of a sub-system composed of two inde-pendent sub-systems is the “tensor product” of the states of the sub-system.Of course, we remember that we are not working with Hilbert spaces. There-fore, we need a definition of a K(δ)-tensor product. For this, we will assumethat the reader is familiar with tensor products of vector spaces. Given twovector (K)(δ) vector spaces W1 and W2, we shall denote the tensor product byW1⊗W2. Please recall that the vector space W1⊗W2 is generated by vectors ofform w1⊗w2 where w1 ∈ W1 and w2 ∈ W2. We are ready to define K(δ)-tensorproducts:

Definition 3.5 (K(δ)-tensor product) The tensor product of two K(δ)-in-ner product spaces (W1, 〈·, ·〉1) and (W2, 〈·, ·〉2), is the pair (W1 ⊗ W2, 〈·, ·〉),where 〈·, ·〉 is defined as:

〈∑

i

ai vi ⊗ wi ,∑

j

bj v′j ⊗ w′j〉 =∑

i,j

aibj 〈vi, v′j〉〈wi, w

′j〉

Observe also that given w ∈ W1 ⊗ W2 it is not always possible to findw1 ∈ W1 and w2 ∈ W2 such that w = w1 ⊗ w2. Furthermore, when thatfactorization is possible it is not necessarily unique.

Please also observe that in our case, the K-vector spaces over the set ofqubits A are generated by vectors |v〉 where v is a classical valuation over A.Therefore, if S is the partition of qB in our model and A1, A2 ∈ S then thesub-system composed of A1 and A2 will be generated by vectors of the form|v1〉 ⊗ |v2〉 where vi ∈ H(2Ai). We will identify |v1〉 ⊗ |v2〉 with the vector|v1v2〉 ∈ H(2A1∪A2) where v1v2 is the unique valuation that extends v1 andv2. Furthermore, the state of sub-system composed of A1 and A2 is the tensor

4These properties define a structure often called an algebra in probability theory.

10

Page 11: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

product ψA1 ⊗ψA2 . (Please note that the tensor product of two unit vectors isagain a unit vector.)

When given a quantum state |ψ〉 ∈ HK(δ)(2qB) and non empty G ( qB, wesay that the qubits in G are not entangled with the other qubits if there are|ψ1〉 ∈ HK(δ)(2G) and |ψ2〉 ∈ HK(δ)(2qB\G) such that |ψ〉 = |ψ1〉 ⊗ |ψ2〉.

Therefore, given any G ∈ Alg(S), the qubits in G are not entangled withthe other qubits, thanks to the way we build the whole state of the system fromthe states of the components. Hence, qubits taken from any two independentcomponents of the system are not entangled in every possible quantum state.

Please note also that (contrarily to what was adopted in [28]) we do notrequire that each component state be non factorisable. This relaxation of thenotion of quantum structure had no impact on the entailment relation.

Another key concept in the design of our logic is the concept of logicalamplitudes. Given a K(δ)-quantum valuation |ψ〉 and a classical valuation v,the inner product 〈v|ψ〉 is said to be the logic amplitude of |ψ〉 for v. As weshall see, these logical amplitudes are at the core of dEQPL. These amplitudesappear in two ways in the structure which we discuss below.

It is also sometimes convenient to work with V ( 2qb, as we may want toimpose classical constraints on the quantum valuations. For example, we maywant to impose (qb1 ∨ qb2) requiring states to have (logical) amplitude zero forevery classical valuation not satisfying this classical formula. In our semanticsstructures, we shall therefore explicitly have a set V ⊆ 2qB and we shall call Vthe set of admissible classical valuations. Furthermore, for any v 6∈ V , we willrequire that the amplitude 〈v|ψ〉 = 0 where ψ is the quantum state of the fullsystem.

Note also that every subset A of qB can be identified with a classical valu-ation v over qB: v assigns true to qb if and only if qb ∈ A. This, of course, canbe generalized. Any set A ⊂ G ⊂ qB can be identified with a classical valuationvGA over G: vG

A assigns true to all elements of A and false to all elements ofG \A.

Finally, we also have a collection of K(δ) values ν = νGAG⊆qB, A⊆G inthe semantic structure. We impose that if G ⊂ Alg(S) then νGA = 〈vG

A |ψ〉Gwhere |ψ〉G is the state of the sub-system composed of qubits modeled by G.In other words, they are logic amplitudes when the qubits in G constitute anindependent sub-system.

It should be stressed that these values are not always physically meaningful.A term νGA is meaningful only if G ∈ Alg(S). The others are nevertheless usefulfor our purposes and help to avoid partial denotation maps. We are now readyto assemble the different pieces of our semantic structure:

Definition 3.6 (Quantum structure) A quantum structure over qB is a tu-ple

w = (K, δ, V,S, |ψ〉, ν)

where:

• K is a real closed field and K(δ) is its algebraic closure;

• V is a nonempty subset of 2qB;

11

Page 12: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

• S is a partition of qB;

• |ψ〉 = |ψ〉SS∈S where each |ψ〉S is a unit vector of HS . We extend |ψ〉to Alg(S) as follows:

1. |ψ〉∅ = 1;

2. |ψ〉S1∪···∪Sn= |ψ〉S1

⊗ · · · ⊗ |ψ〉Sn;

• 〈v|ψ〉qB = 0 if v 6∈ V ;

• ν : νGAG⊆qB,A⊆G where νGA = 〈vGA |ψ〉G if G ∈ Alg(S). In particular,

ν∅∅ = 1.

The proposed quantum logic will be interpreted over these quantum struc-tures. Obviously, we have some redundancy in the notion of quantum structure,namely, |ψ〉 can be reconstructed from ν. However, this redundancy pays off inease of use and in clarifying the connection to quantum physics.

The first two Postulates were sufficient to guide us in the task of settingup the notion of quantum structures over which we shall be able to define thesemantics of dEQPL. Now, we turn our attention to the Postulates concerningmeasurements of physical quantities.

Postulate 3: Every measurable physical quantity of an isolated quantum sys-tem is described by an observable acting on its Hilbert space.

Please recall that an observable is a Hermitian operator such that the directsum of its eigensubspaces coincides with the underlying Hilbert space. Alsorecall that the spectrum Ω of a Hermitian operator (set of its eigenvalues)is a subset of the set of real numbers, R. For each e ∈ Ω, we denote thecorresponding eigensubspace by He, and the projector onto the subspace Ee byPe.

It might seem at first that we need to extend the definition of Hermitianoperators to an arbitrary K(δ) as Hermitian operators are usually defined overHilbert spaces. However, as we shall see shortly, fortunately that is not re-quired. This is because we do not have constructs in the language for denotingsuch measurement operators. In order to use Postulate 3, we need to considerPostulate 4.

Postulate 4: The possible outcomes of the measurement of a physical quantityare the eigenvalues of the corresponding observable. When the physical quantityis measured using observable A on a system in a state |ψ〉, the resulting outcomesare ruled by the probability space PA

|ψ〉 = (Ω, E|Ω, µA|ψ〉) where (in the case A has

a countable spectrum)

- Ω is the spectrum of the observable A,

- E|Ω is ℘Ω the power-set of Ω , and

12

Page 13: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

- µA|ψ〉 : E|Ω → R is the probability measure defined as

µA|ψ〉(E) =

e∈E

||Pe|ψ〉||2 .

For the applications in quantum computation and information that we havein mind, only logic projective measurements are relevant. Given a quantumsystem with the set of qubits qB and a set of classical valuations V , these aremeasurements A such that:

- The spectrum of A is equipotent5 to V , i.e., there is a bijection betweenthe spectrum of A and V .

- If we identify V with the spectrum of A then for each v ∈ V , the corre-sponding eigenspace Hv is generated by the vector |v〉. The projector Pv

is the operator |v〉〈v|, i.e., Pv|ψ〉 = 〈v, ψ〉 |v〉 for each vector ψ ∈ HC(2qB).

Postulate 4 then tells us that the stochastic result of making a logic pro-jective measurement A given a quantum structure w = (K, δ, V,S, |ψ〉, ν) is de-scribed by the finite probability space Pw = (V, ℘V, µw) where for each U ⊆ V :

µw(U) =∑

v∈U

|〈v|ψ〉|2 . (1)

For example, if the quantum system is in the particular state

α00ω1 |00ω1〉+ α01ω2 |01ω2〉+ α01ω3 |01ω3〉+ α10ω4 |10ω4〉

then the probability of observing the first two qubits qb0, qb1 in the classicalvaluation 01 (here we take V as 00ω1, 00ω2, 00ω3, 00ω4) is given by |α01ω2 |2 +|α01ω3 |2.

We have probability terms in the language of the proposed logic and Equa-tion 1 is all that we need from Postulates 3 and 4 for interpreting them as weshall see in Section 3.2.

Once again, we recall that we are working with an arbitrary real closed field.Given a quantum structure w = (K, δ, V,S, |ψ〉, ν), we define the probability mapµw : ℘(V ) → K as:

µw(U) =∑

v∈U

|〈v|ψ〉|2 . (2)

The essential difference between Equation 1 and 2 is that summands in theformer are real numbers while the summands of the latter one are elements ofa real closed field given by the quantum structure. It is easy to check that µV

defined in Equation 2 satisfies the “usual” finite probability axioms:5The chosen bijection depends on how the qubits are physically implemented. For example,

when implementing a qubit using the spin of an electron, we may impose that spin + 12

corresponds to true and spin − 12

corresponds to false. But, as we shall see, the semantics ofEQPL does not depend on the choice of the bijection, as long as one exists. The same happensin the case of classical logic – its semantics does not depend on how bits are implemented.The details of which voltages correspond to which truth values are irrelevant.

13

Page 14: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

1. µV (∅) = 0 and µV (V ) = 1, and

2. µV (U1 ∪ U2) = µV (U1) + µV (U2) if U1 and U2 are disjoint sets.

Therefore, given a quantum structure w, we have the means for interpretingdEQPL terms of the form (

∫α) that denote probabilities.

Finally, although irrelevant to the design of dEQPL, we mention en passantPostulate 5 that rules how quantum systems evolve beyond measurements:

Postulate 5 : Excluding measurements, the evolution of a quantum systemis described by unitary transformations.

This last Postulate becomes relevant only when designing a dynamical ex-tension of the logic (see for instance [27]).

3.2 Language and semantics

There are two kinds of terms in dEQPL, one denoting elements of real closedfield in the quantum structure and the other denoting elements in its algebraicclosure. The formulas of dEQPL, henceforth called quantum formulas, are con-structed from classical propositional formulas, formulas denoting sub-systemsand comparison formulas (comparing terms denoting elements of real closedfields) using global connectives introduced in Section 2. We present language ofdEQPL in Table 1 using an abstract version of BNF notation [30] for a compactpresentation of inductive definitions. We discuss the language in detail below.

Classical formulasα := ⊥ 8 qb 8 (α⇒ α)

Term language (with the proviso A ⊆ G ⊆ qB)t := x 8 0 8 1 8 (t + t) 8 (t t) 8 Re(u) 8 Im(u) 8 |u| 8 (

∫α)

u := z 8 |>〉GA 8 t + it 8 u 8 (u + u) 8 (uu) 8 (α B u; u)

Quantum formulas (with the proviso F ⊆ qB):γ := α 8 (t ≤ t) 8 [F ]8 ⊥⊥ 8(γ A γ)

Table 1: Language of dEQPL

The first syntactic category is classical formulas. Please recall that we fixeda finite set of qubit symbols qB. Classical formulas are built from qubit symbolsin qB using the classical disjunctive connectives, falsum ⊥ and implication ⇒.As usual, other classical connectives like ¬, ∧,∨,⇔ and > are introduced asabbreviations. We denote the set of qubit symbols occurring in α by qB(α),and say that a classical formula α is over a set S of qubit symbols if qB(α) ⊆ S.

14

Page 15: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

For the term language, we pick two disjoint denumerable sets of variables.The first set of variables X = xk : k ∈ N is interpreted in the real closed fieldof the quantum structure, and the second set Z = zk : k ∈ N is interpretedin the closure of the real closed fields. As we shall see in Section 5, variablesare often useful for applications that we have in mind. There are two syntacticcategories t and u for terms, which are mutually defined. The syntactic categoryt denotes the elements of a real closed field and u denotes the elements of itsclosure respectively. We will often abuse the notation by saying that t is a realterm and u is a complex term.

Most of the term constructs are self-explanatory and already motivated inthe previous section. The term |>〉GA denotes the logical amplitude νGA in thequantum structure, and henceforth will be called an amplitude term. The term(∫

α) denotes the probability that classical formula α holds for an outcome ofa logical projective measurement, and will be called a probability term. Thedenotation of the alternative term (α B u1; u2) will be the value denoted by u1

if α is true, and the value denoted by u2 otherwise.As usual, we may define the notion of occurrence of a term t1 in a term t,

and the notion of replacing zero or more occurrences of terms t1 in t by t2. If~x, ~t, ~z and ~u are sequences of real variables, real terms, complex variables andcomplex terms respectively, we will write t|~x/~t, ~z/~u| to mean the real termobtained by substituting all occurrences of xi by ti and all occurrences of zj byuj . The complex term u|~x/~t, ~z/~u| is similarly defined.

The quantum formulas are built from classical formulas α, sub-system for-mulas [F ] and comparison formulas (t ≤ t) using the connectives ⊥⊥ and A.The formulas consisting of just the classical formulas, sub-system and compar-ison formulas are called quantum atoms, and the set of quantum atoms shallhenceforth be called qAtom. We shall use δ, δ′ to range over elements of qAtom.Please note that quantum bottom ⊥⊥ and quantum implication A are globalconnectives and should not be confused with their classical (local) counterparts.

The notion of occurrence of a term t in a quantum formula γ can be easilydefined. However, we have to be careful while defining the notion of occurrenceof a quantum formula γ in the quantum formula γ1. This is because we want γto occur as a quantum sub-formula of γ1 and rule out situations where γ occursas classical sub-formula. More precisely, we define γ1 q-occurs in γ inductivelyas:

• if γ is a classical formula, a comparison formula, a sub-system formula,or ⊥⊥, then γ1 q-occurs in γ if and only if γ1 is γ and;

• if γ is γ′ A γ′′ then γ1 q-occurs in γ if and only if one of the followingholds:

– γ1 is γ, or

– γ1 q-occurs in γ′, or

– γ1 q-occurs in γ′′.

The notion of replacing zero or more q-occurrences of a quantum formula γ1 inγ by γ′ can now be suitably defined.

15

Page 16: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

For example, the classical formula qb q-occurs in (qb A qb1) and replacingone q-occurrence of qb by qb2 will yield the quantum formula (qb2 A qb1). Onthe other hand qb does not q-occur in (qb⇒ qb1) (qb is a classical sub-formulaand not quantum sub-formula). The replacement qb by qb2 in (qb⇒ qb1) hasno effect. Similarly, qb does not q-occur in [qb].

For clarity sake, we shall often drop parenthesis in formulas and terms if itdoes not lead to ambiguity. As expected, other quantum connectives will beintroduced as abbreviations. However, before introducing a whole set of usefulabbreviations, we present the semantics of the language.

The language is interpreted in a quantum structure as defined in Section 3.1.Given a quantum structure w = (K, δ, V,S, |ψ〉, ν), recall that K is a real closedfield with K(δ) as its algebraic closure, V is a set of valuations over qB, S is apartition of qB, |ψ〉 is a collection of K(δ)-quantum states, and ν is a collectionof amplitude terms. We shall assume the semantics of classical propositionallogic, and say that v °c α if the classical valuation v satisfies the classicalformula α.

For interpreting the probability terms, we shall use the probability mapµw : ℘(V ) → K defined in Section 3.1 as:

µw(U) =∑

v∈U

||〈v|ψ〉||2 .

For the probability terms, we shall also need the extent at a set V of classicalformulas over S defined as:

|α|V = v ∈ V : v °c α.

For interpreting the variables, we need the concept of an assignment. Givena real closed field K, a K-assignment ρ is a map such that ρ(x) ∈ K for eachx ∈ X and ρ(z) ∈ K(δ) for each z ∈ Z. Please note that when K is clear fromthe context, we shall drop K.

Given a quantum structure w = (K, δ, V,S, |ψ〉, ν) and a K-assignment ρ.The denotation of terms and satisfaction of quantum formulas at w and ρ andis inductively defined in Table 2 (omitting the obvious ones).

Please observe that the set V is sufficient to interpret the classical formulas,and the partition S is sufficient to interpret the sub-system formulas. TheK-assignment ρ is sufficient to interpret a useful sub-language of the formulasdefined as:

κ := (a ≤ a)8 ⊥⊥ 8(κ A κ)a := x 8 0 8 1 8 (a + a) 8 (a a) 8 Re(b) 8 Im(b) 8 |b|b := z 8 a + ia 8 b 8 (b + b) 8 (b b)

Henceforth, the terms of this sub-language will be called arithmetical terms andthe formulas will be called arithmetical formulas.

We may use the satisfaction relation to define entailment as expected: wesay that a set of quantum formulas Γ entails a quantum formula η, writtenΓ ² η, if wρ ° η for every w and ρ satisfying every element of Γ. We say aquantum formula η is valid when it is entailed by the empty set of quantum

16

Page 17: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Denotation of terms[[x]]wρ = ρ(x)[[t1 + it2]]wρ = [[t1]]wρ + δ[[t2]]wρ

[[(∫

α)]]wρ = µw(|α|V )[[z]]wρ = ρ(z)[[|>〉GA]]wρ = νGA

[[(α B u1; u2)]]wρ =

[[u1]]wρ if |α|V = V[[u2]]wρ otherwise

Satisfaction of quantum formulaswρ ° α iff |α|V = Vwρ ° (t1 ≤ t2) iff [[t1]]wρ ≤ [[t2]]wρwρ ° [A] iff A ∈ Alg(S)wρ 6°⊥⊥wρ ° (γ1 A γ2) iff wρ 6° γ1 or wρ ° γ2

Table 2: Semantics of dEQPL

formulas. Please note also that the metatheorem of entailment holds: Γ, η1 ² η2

iff Γ ² (η1 A η2). That is, quantum implication internalizes the notion ofquantum entailment. The following are some examples of entailment:

² (¬α) A (¯α)² (α1 ∧ α2)≡ (α1 u α2)

[G1], [G2] ² [G1 ∩G2]α ² ((

∫α) = 1)

[G] ² ((∑

A⊆G ||>〉GA|2) = 1)

We shall now present some useful abbreviations, and give some small examples.

3.3 Abbreviations and examples

As anticipated, the proposed quantum language with the semantics above is richenough to express interesting properties of quantum systems. To this end, it isquite useful to introduce other operations, connectives and modalities throughabbreviations. We start with some additional quantum connectives:

• quantum negation: (¯ γ) for (γA ⊥⊥);

• quantum disjunction: (γ1 t γ2) for ((¯ γ1) A γ2);

• quantum conjunction: (γ1 u γ2) for (¯((¯ γ1) t (¯ γ2)));

• quantum equivalence: (γ1 ≡ γ2) for ((γ1 A γ2) u (γ2 A γ1)).

It is also useful to introduce some additional comparison formulas:

17

Page 18: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

• (t1 < t2) for ((t1 ≤ t2) u (¯(t2 ≤ t1)));

• (t1 = t2) for ((t1 ≤ t2) u (t2 ≤ t1));

• (u1 = u2) for ((Re(u1) = Re(u2)) u (Im(u1) = Im(u2)))

Please note that the only constants in our term language are 0 and 1. Asevery real closed field K has characteristic 0, we can embed a copy of rationalsin K. It is also possible to take square roots of positive numbers. Hence, it willbe useful to use the following abbreviations (with the proviso n > 0):

• (t = n) for t =((1 + (1 + . . . ...)))︸ ︷︷ ︸

n times;

• (t = mn ) for ((m.t) = n);

• (t1 =√

t2) for ((t2 ≥ 0) u (t12 = t2)).

Given A ⊆ G ⊆ qB, the following classical formula will also be useful:

• (∧GA) is ((∧qbk∈ Aqbk) ∧ (∧qbk∈ G\A(¬ qbk)).

The classical formula (∧GA) specifies the unique classical valuation that satisfiesall the qubit symbols in A and does not satisfy the qubit symbols in G \A. Wewill often need this classical formula in the case the set G is the full set of qubitsymbols qB. Therefore, we will often use the following abbreviation

• (∧A) for (∧qBA).

The logical amplitude terms, |>〉GA, are easily extendible to any classicalformula as (with the provisos qB(α) ⊆ G and A ⊆ G ⊆ qB):

• |α〉GA for (((∧GA)⇒ α) B |>〉GA; 0).

Intuitively, the amplitude term |α〉GA coincides with |>〉GA when the valuation∧GA satisfies with α and is 0 otherwise. We will often use this term in the caseG is the full set of qubit symbols qB. Therefore, the following abbreviation willalso be useful:

• |α〉A for |α〉qBA.

We introduce a couple of probability modalities as abbreviations:

• (♦α) for (0 < (∫

α));

• (¤α) for (1 = (∫

α)).

Finally, we can also define a quantum modality as an abbreviation:

• ([G]♦ α : u) for ([G] u (|u| > 0) u (tA⊆G(|α〉GA = u))).

18

Page 19: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Intuitively ([G]♦ α : u) is true iff G is a sub-system, there is a subset A ofG such that the classical valuation ∧GA satisfies α and the logical amplitude|>〉GA takes the non-zero value u.

We discuss a small example where we demonstrate the usefulness of dEQPLto specify properties of a quantum system. We postpone the discussion of moreinvolved examples to Section 5. Consider the following variant of Schrodinger’scat. The attributes of the cat that we consider are: being inside or outsidethe box, alive or dead, and moving or still. We choose three qubit symbolsqb0, qb1, qb2 to represent these attributes. For the sake of readability, we usecat-in-box, cat-alive and cat-moving instead of the symbols qb0, qb1 andqb2 respectively. The following dEQPL formulas constrain the state of the catat different levels of detail:

1. [cat-in-box, cat-alive, cat-moving];

2. (cat-moving⇒ cat-alive);

3. ((♦ cat-alive) u (♦ (¬ cat-alive)));

4. (¯[cat-alive]);

5. ((∫cat-alive) = 1

3);

6. ([cat-alive, cat-moving] u ((∫cat-alive ∧ cat-moving) = 1

6)u ((

∫cat-alive ∧ (¬ cat-moving)) = 1

6)u ((

∫(¬ cat-alive) ∧ (¬ cat-moving)) = 2

3)).

Please observe that all the above assertions are consistent with each other.Intuitively, the first assertion states that the qubits cat-in-box, cat-alive andcat-moving form a sub-system and therefore, are not entangled with the otherqubits of the cat system. The second is a classical constraint on the set ofadmissible valuations: if the cat is moving then it is alive. The third assertionis a consequence of the famous paradox: the cat can be in a state where it ispossible that the cat is alive and it is possible that the cat is dead. The fourthassertion states that the qubit cat-alive is necessarily entangled with otherqubits. The fifth assertion states that the cat is in a state where the probabilityof observing it alive (after collapsing the wave function) is 1

3 . Finally, the sixthassertion states that the qubits cat-alive, cat-moving are not entangled withother qubits, and that the cat is in quantum state where: the probability ofobserving it alive and moving is 1

6 , the probability of observing it alive and notmoving is 1

6 , and the probability of observing it dead (and, thus also not movingby second assertion)is 2

3 .

3.4 The axiomatization

We shall present a Hilbert-style axiomatization of the dEQPL. We need twonew concepts for the axiomatization, one of quantum tautology and the secondof a valid arithmetical formula.

19

Page 20: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Let P be a countable set of propositional symbols disjoint from qB. Given aclassical formula β over P, let βq be the syntactic entity obtained by replacingall occurrences of ⊥ by ⊥⊥ and ⇒ by A. A quantum formula σ is said tobe a quantum tautology if there is a classical tautology β over P and a mapσ : P → qAtom such that σ coincides with βqσ where βqσ is the quantumformula obtained from βq by replacing each p ∈ P by σ(p). For instance, thequantum formula ((x1 ≤ x2)A(x1 ≤ x2)) is tautological (obtained, for example,from the classical tautology p⇒ p).

Please recall that an arithmetical formula in the dEQPL is any formula thatdoes not have probability terms, amplitude terms, alternative terms, classicalformulas and sub-system formulas. As noted in Section 3.2, given an quantumstructure with K0 as the underlying real closed field, a K0-assignment is enoughto interpret all arithmetical formulas. We say that an arithmetical formula κ isa valid arithmetical formula if it holds for any assignment that maps variablesinto an arbitrary real closed field K. Clearly, a valid arithmetical formula holdsfor all semantic structures of dEQPL. It is a well-known fact from the theoryof quantifier elimination [24, 6] that the set of valid arithmetical formulas sodefined is decidable6. However, we shall not go into details of this result as wewant to focus our attention on reasoning about quantum aspects only.

The axioms and inference rules of dEQPL are listed in Table 3. In total,we have two inference rules and sixteen axioms. The two inference rules aremodus ponens for classical implication CMP and modus ponens for quantumimplication CMP7. The axioms are better understood in the following groups.

We have as axioms the classical tautologies and the quantum tautologies(CTaut and QTaut, respectively). Since the set of classical tautologies andthe set of quantum tautologies are both recursive, there is no need to spell outthe details of tautological reasoning.

The axioms Lift⇒, Eqv⊥ and Refu are sufficient to relate (local) classicalreasoning and (global) quantum tautological reasoning. These are exactly theaxioms that relate classical connectives and global connectives in global logic(see Section 2). We refer to [29] for more details.

The axioms Sub, Sub∪, and Sub\ are enough to reason about sub-systems.Together, they impose that sub-systems are closed under set-theoretic opera-tions (closure under intersection and set difference appear as theorems).

The axiom RCF says that if κ is a valid arithmetical formula, then anyformula obtained by replacing variables with the terms of dEQPL is a tautology.Since the set of valid arithmetical formulas is recursive, we refrain from spellingout the details.

The axioms If> and If⊥ are self-explanatory, and will be used in the com-pleteness proof to remove alternative terms.

The axioms Empty, NAdm, Unit and Mul rule logical amplitudes. Eachof them closely reflects a property of our semantic structures. The axiom emptysays that the logical amplitude |>〉∅∅ is always 1. The axiom Unit says that

6For the arithmetical sub-language, we may treat the global connectives as classical con-nectives

7Actually, CMP can be derived from QMP and Lift⇒.

20

Page 21: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Axioms[CTaut] ` α for each classical tautology α[QTaut] ` γ for each quantum tautology γ

[Lift⇒] ` ((α1 ⇒ α2) A (α1 A α2))[Eqv⊥] ` (⊥≡ ⊥⊥)[Refu] ` ((α1 u α2) A (α1 ∧ α2))

[Sub∅] ` [∅][Sub∪] ` ([G1] A ([G2] A [G1 ∪G2]))[Sub\] ` ([G]≡ [qB \G])

[RCF] ` κ|~x/~t , ~z/~u| where κ is a valid arithmetical formula,~x, ~z, ~t and ~u are sequences of real variables, complexvariables, real terms and complex terms respectively

[If>] ` (α A ((α B u1; u2) = u1))[If⊥] ` ((¯α) A ((α B u1; u2) = u2))

[Empty] ` (|>〉∅∅ = 1)[NAdm] ` ((¬(∧A)) A (|>〉qBA = 0))[Unit] ` ([G] A ((

∑A⊆G ||>〉GA|2) = 1))

[Mul] ` (([G1] u [G2]) A (|>〉G1∪G2A1∪A2= |>〉G1A1

|>〉G2A2))

where G1 ∩G2 = ∅, A1 ⊆ G1 and A2 ⊆ G2

[Prob] ` ((∫

α) = (∑

A ||α〉A|2))

Inference rules[CMP] α1, (α1 ⇒ α2) ` α2

[QMP] γ1, (γ1 A γ2) ` γ2

Table 3: Axioms for dEQPL

the state of each sub-system is a unit vector. The axiom NAdm says that theamplitude of a non-admissible classical valuation is 0. The axiom Mul saysthat the state of a system composed of two subs-systems is a tensor product ofthe two sub-systems.

Finally, the axiom Prob relates probabilities and amplitudes, closely fol-lowing Postulate 4 of quantum mechanics.

As expected, we say that a formula γ is a theorem, written ` γ, if we canbuild a derivation of γ from the axioms using the inference rules. We say thata (possibly infinite) set of formulas Γ derives γ, written Γ ` γ, if we can build

21

Page 22: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

a derivation of γ from axioms and the inference rules using formulas in Γ ashypothesis. As an illustration of the axiomatization, we establish the followingtheorems:

Proposition 3.7 For any classical formulas α1, α2, we have

[Lift∧] ` (α1 ∧ α2) A (α1 u α2).[PUnit] ` ((

∫>) = 1).

Proof: Derivation of [Lift∧]:

1 (α1 ∧ α2)⇒ α1 CTaut

2 ((α1 ∧ α2)⇒ α1) A ((α1 ∧ α2) A α1) Lift⇒

3 (α1 ∧ α2) A α1 QMP:1,2

4 (α1 ∧ α2)⇒ α2 CTaut

5 ((α1 ∧ α2)⇒ α2) A ((α1 ∧ α2) A α2) Lift⇒

6 (α1 ∧ α2) A α2 QMP:4,5

7 ((α1 ∧ α2) A α1) A (((α1 ∧ α2) A α2) A ((α1 ∧ α2) A (α1 u α2))) Qtaut

8 ((α1 ∧ α2) A α2) A ((α1 ∧ α2) A (α1 u α2)) QMP:3,8

9 (α1 ∧ α2) A (α1 u α2) QMP:6,8

Derivation of [PUnit]

1 [∅] Sub∅

2 [∅] A [qB] Sub\

3 [qB] QMP:1,2

4 ([qB] A ((∑

A⊆qB ||>〉qBA|2) = 1)) Unit

5 ((∑

A⊆qB ||>〉qBA|2) = 1) QMP:3,4

6 ((∫>) = (

∑A⊆qB ||>〉qBA|2)) Prob

7 (((∫>) = (

∑A⊆qB ||>〉qBA|2)) A (((

∑A⊆qB ||>〉qBA|2) = 1) A ((

∫>) = 1))) RCF

8 (((∑

A⊆qB ||>〉qBA|2) = 1) A ((∫>) = 1)) QMP:6,7

9 ((∫>) = 1) QMP:5,8

¦

We finish this section with a list of interesting theorems. The first threeshall be proved in Section 3.6 using the metatheorems of the logic. The firsttwo relate local equivalence and negation with their global counterparts, whilethe third one says sub-systems are closed under set intersection and the fourthone says that sub-systems are closed under set difference.

22

Page 23: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

[Lift⇔] ` (α1 ⇔ α2) A (α1 ≡ α2).[Lift¬] ` ¬α A ¯ α.[Sub∩] `F ([G1] A ([G2] A [G1 ∩G2])).[SubDiff] `F ([G1] A ([G2] A [G1 \G2])).

The following theorems give some insight on the major properties of logicalamplitudes.

[AAdd] ` ((|(α1 ∨ α2)〉G + |(α1 ∧ α2)〉G) = (|α1〉G + |α2〉G)).[AMon] ` ((α1 ⇒ α2) A (||α1〉G| ≤ ||α2〉G|)).[ASoE] ` ((α1 ⇔ α2) A (|α1〉G = |α2〉G)).[ANec] ` (α A (|α〉G = |>〉G)).[AMExc] ` ((|α〉G + |(¬α)〉G) = |>〉G) .

The first of the following theorems about probability after measurements juststates finite additivity. The second relates logical reasoning with probabil-ity reasoning (monotonicity). These two theorems and the theorem PUnitillustrated in Proposition 3.7 are axioms in the exogenous probabilistic logicdiscussed in Section 2.

[PAdd] ` (((∫(α1 ∨ α2)) + (

∫(α1 ∧ α2))) = ((

∫α1) + (

∫α2))).

[PMon] ` ((α1 ⇒ α2) A ((∫

α1) ≤ (∫

α2))).

The following theorems show that probability modalities behave as normalmodalities.

[PNec] ` (α A (¤α)).[PNorm] ` ((¤(α⇒ α′)) A ((¤α) A (¤α′))).

The quantum modalities also behave as normal modalities.

[QNorm] ` (([G]♦ (α ∨ α′) : u)≡ (([G]♦ α : u) t ([G]♦ α′ : u))) .[QMon] ` ((α⇒ α′) A (([G]♦ α : u) A ([G]♦ α′ : u))).[QCong] ` ((u = u′) A (([G]♦ α : u) A ([G]♦ α : u′))) .

3.5 Soundness

We now show that the calculus is strongly sound, i.e., if Γ ` γ then Γ ² γ. Itsuffices to show that each of the axioms is valid, i.e., if ` γ1 is an axiom, thenevery semantic structure satisfies γ1.

Lemma 3.8 The axiom QTaut is valid.

Proof: Assume that β is a classical tautology over the set of propositionalsymbols P and let σ : P → qAtom be a map from P into quantum atoms. Weshow that βqσ is valid in all models of dEQPL.

23

Page 24: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Take an arbitrary quantum structure w = (K, δ, V,S, |ψ〉, ν), and considerthe classical valuation v′ over P such that

v′(p) =

1 if wρ ° σ(p)0 otherwise

.

We show that for any classical formula β′ over P

v′ ° β′ iff wρ ° β′qσ

by induction on the structure of β′ as follows.If β′ is a propositional symbol then it follows from the definition of v′. The

case where β′ is the connective ⊥ is immediate.If β′ is (β1⇒ β2), then v′ satisfies β2 or v′ does not satisfy β1. If v′ satisfies

β2 then by induction hypothesis wρ ° (β2)q. If v′ does not satisfy β1, then byinduction hypothesis once again, v′ 6° (β1)q. Therefore, in either case, wρ °(β1)q A (β2)q. Now, note that β′q is (β1)q A (β2)q.

The lemma now follows by observing that v′ ° β. ¦

Lemma 3.9 The axioms are valid.

Proof: The axioms CTaut, Eqv⊥, RCF, If>, If⊥, Empty, Sub∅, Sub∪ andSub\ are easy to show. For the rest, let w = (K, δ, V,S, |ψ〉, ν) be a quantumstructure and ρ a K-assignment. We consider the other axioms one by one:

• Lift⇒. Assume that wρ ° (α1 ⇒ α2). Then, by definition, all classicalvaluations in V must satisfy (α1⇒α2). Therefore, if all classical valuationsin V satisfy α1 they must satisfy α2 also. Hence, either |α1|V 6= V or|α2|V = V . We conclude, by definition, w ° α1 A α2.

• Refu. Similar to the axiom Lift⇒.

• NAdm. Assume that wρ ° (¬(∧A)). This means that the classicalvaluation vqB

A that assigns 1 to the qubit symbols in A and 0 to all otherqubits is not an element of V . Therefore, νqBA = 〈vqB

A |ψ〉qB = 0 and hencewρ ° |>〉qBA = 0.

• Prob. Using the definition [[(∫

α)]]wρ = µw(|α|V ) =∑

v∈|α|V |〈v|ψ〉qB|2, itsuffices to show that

v∈|α|V|〈v|ψ〉qB|2 = [[

A

||α〉A|2]]wρ.

Please note that [[|α〉A]]wρ =

νqBA if vqBA ∈ |α|V

0 otherwise.

Also, by definition, νqBA = 〈vqBA |ψ〉qB. Therefore,

[[∑

A

||α〉A|2]]wρ =∑

vqBA ∈|α|V

|〈vqBA |ψ〉qB|2

We conclude by observing that every v is a vqBA for some unique A ⊆ qB.

24

Page 25: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

• Unit. Assume that wρ ° [G]. Then G ∈ Alg(S). Please note that|vG

A〉 : A ⊆ G forms an orthonormal basis of H(2G). Hence,

|ψ〉G =∑

A⊆G

〈vGA |ψ〉G |vG

A〉.

Again, by definition, 〈vGA |ψ〉G = νGA and so

|ψ〉G =∑

A⊆G

νGA |vGA〉.

Since |ψ〉G is a unit vector, we get∑

A⊆G

|νGA|2 = 1.

We conclude by noting that [[|>〉GA]]wρ = νGA by definition.

• Mul. Assume that wρ ° [G1] u [G2] where G1 ∩G2 = ∅. Then G1, G2 ∈Alg(S). The definition of quantum structure says that |ψ〉G1∪G2

= |ψ〉G1⊗

|ψ〉G2.

The definition of tensor product says that |vG1∪G2A1∪A2

〉 = |vG1A1〉 ⊗ |vG2

A2〉.

The definition of quantum structure gives

νG1∪G2A1∪A2 = 〈vG1∪G2A1∪A2

|ψ〉G1∪G2

.

The definition of tensor product then gives,

νG1∪G2A1∪A2 = 〈vG1A1⊗ vG2

A2| ψG1 ⊗ ψG2〉G1∪G2

= 〈vG1A1|ψ〉

G1〈vG2

A2|ψ〉

G2.

We conclude by observing that νG1A1 is 〈vG1A1|ψ〉

G1and νG2A2 is 〈vG2

A2|ψ〉

G2.

¦

Theorem 3.10 (Soundness) The proof system of dEQPL is sound.

Proof: The proof now follows by induction on the number of steps in thederivation. ¦

3.6 Metatheorems

We now prove some useful metatheorems for dEQPL. We start by showing thatthe inference rule Hypothetical Syllogism holds for dEQPL.

Lemma 3.11 (Hypothetical Syllogism) Let γ1, γ2, γ3 be quantum formu-las. Then,

[HypSyl] Γ ` γ1 A γ2 and Γ ` γ2 A γ3 imply Γ ` γ1 A γ3.

25

Page 26: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Proof: Observe that by QTaut,

` (γ1 A γ2) A ((γ2 A γ3) A (γ1 A γ3)).

The proposition follows by using two instances of QMP. ¦

The inference rule HypSyl is a useful rule as illustrated in the derivation ofthe theorem Lift¬ below:

Proposition 3.12 For any classical formula α, we have

[Lift¬] ` ¬α A ¯α.

Proof:

1 ((⊥A ⊥⊥) u (⊥⊥ A⊥)) Eqv⊥

2 ((⊥A ⊥⊥) u (⊥⊥ A⊥)) A (⊥A ⊥⊥) QTaut

3 (⊥A ⊥⊥) QMP: 1,2

4 (⊥A ⊥⊥) A ((α A⊥) A (αA ⊥⊥)) QTaut

5 (α A⊥) A (αA ⊥⊥) QMP: 3,4

6 (α⇒⊥) A (α A⊥) Lift⇒

7 (α⇒⊥) A (αA ⊥⊥) HypSyl: 5,6

¦

The axiomatization also enjoys the metatheorem of deduction :

Theorem 3.13 (Metatheorem of deduction) Let Γ be a set of quantumformulas and γ1, γ2 be quantum formulas. Then,

Γ ∪ γ1 ` γ2 iff Γ ` γ1 A γ2.

Proof: (←) Assume that Γ ` γ1 A γ2. Let Π be a proof of the derivationΓ ` γ1 A γ2 and assume that the length of Π is n. We can extend Π to obtainΓ ∪ γ1 ` γ2 as follows:

n γ1 A γ2 Πn+1 γ1 Hypn+2 γ2 QMP: n,n+1

(→) Assume that Γ∪ γ1 ` γ2. We will prove Γ ` γ1 A γ2 by induction onn, the length of proof of Γ ∪ γ1 ` γ2. The base step n = 1 will be subsumedby the inductive step. In the inductive step, we consider the last rule applied.There are three cases:

• γ2 is either an hypothesis or an axiom. In this case:

26

Page 27: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

1 γ2 axiom or hypothesis2 γ2 A (γ1 A γ2) QTaut3 γ1 A γ2 QMP: 1,2

• γ2 is obtained from γ and γ A γ2 by QMP where γ and γ A γ2 are alsoderived from Γ ∪ γ1. Then, by the induction hypothesis,

- Γ ` γ1 A γ;

- Γ ` γ1 A (γ A γ2)

Let Π1 and Π2 be the proofs of Γ ` γ1 Aγ and Γ ` γ1 A (γ Aγ2) of lengthsm1 and m2, respectively. Let m3 be m1 + m2. The proof of Γ ` γ1 A γ2

is as follows:

m1. γ1 A γ Π1

m3. γ1 A (γ A γ2) Π2

m3 + 1. (γ1 A (γ A γ2)) A ((γ1 A γ) A (γ1 A γ2)) QTautm3 + 2. (γ1 A γ) A (γ1 A γ2) QMP: m3,m3 + 1m3 + 3. γ1 A γ2 QMP: m1,m3 + 2

• γ2 is obtained from γ and γ ⇒ γ2 by CMP where γ and γ ⇒ γ2 are alsoderived from Γ ∪ γ1. Then, by the induction hypothesis,

- Γ ` γ1 A γ;

- Γ ` γ1 A (γ ⇒ γ2).

By the axiom Lift⇒ we also have Γ ` (γ ⇒ γ2) A (γ A γ2).

By hypothetical syllogism (Lemma 3.11) we also have Γ ` γ1 A (γ A γ2). Theproof now proceeds as in the previous case. ¦

We get as a corollary:

Corollary 3.14 (Metatheorem of reductio ad absurdum) Let Γ be a setof quantum formulas and γ be a quantum formula. Then,

If Γ ∪ γ `⊥⊥ then Γ ` ¯ γ.

We use the metatheorem of equivalence to derive the following theorems:

Proposition 3.15 For every classical formulas α1 and α2 and subsets G1, G2 ∈qB, we have

[Lift≡] ` (α1 ⇔ α2) A (α1 ≡ α2).[Sub∩] `F ([G1] A ([G2] A [G1 ∩G2])).

Proof: We shall use metatheorem of deduction to show each of the theorems:Lift≡. It suffices to show that (α1 ⇔ α2) ` (α1 ≡ α2)

27

Page 28: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

1 (α1 ⇒ α2) ∧ (α2 ⇒ α1) Hyp

2 ((α1 ⇒ α2) ∧ (α2 ⇒ α1))⇒ (α1 ⇒ α2) CTaut

3 (α1 ⇒ α2) CMP: 1,2

4 (α1 ⇒ α2) A (α1 A α2) Lift⇒

5 (α1 A α2) QMP: 3, 4

6 ((α1 ⇒ α2) ∧ (α2 ⇒ α1))⇒ (α2 ⇒ α1) CTaut

7 (α2 ⇒ α1) CMP: 1,2

8 (α2 ⇒ α1) A (α2 A α1) Lift⇒

9 (α2 A α1) QMP: 7, 8

10 (α1 A α2) A ((α2 A α1) A (α1 ≡ α2)) QTaut

11 (α2 A α1) A (α1 ≡ α2) QMP: 5,10

12 (α1 ≡ α2) QMP: 9,11

Sub∩. It suffices to show that [G1], [G2] ` [G1 ∩G2]

1 [G1] Hyp

2 [G1] A [qB \G1] Sub\

3 [qB \G1] QMP: 1,2

4 [G2] Hyp

5 [G2] A [qB \G2] Sub\

6 [qB \G2] QMP: 4,5

7 [qB \G1] A ([qB \G2] A [qb \ (G1 ∩G2)]) Sub∪

8 [qB \G2] A [qb \ (G1 ∩G2)] QMP: 3,7

9 [qb \ (G1 ∩G2)] QMP: 6,8

10 [qb \ (G1 ∩G2)] A [G1 ∩G2]) Sub\

11 [G1 ∩G2] QMP: 9,10

¦

We also have the principles of substitution of equal terms and equivalentformulas.

Theorem 3.16 (Principle of substitution of equal terms) Given a qua-ntum formula γ, two real terms t1 and t2, let γ′ be a quantum formula obtainedfrom γ by replacing zero or more occurrences of t1 in γ1 by t2. Then,

` t1 = t2 A (γ ≡ γ′).

28

Page 29: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Proof: The proof is by a straightforward induction on the structure of γ. Wenote that in the case where γ is t ≤ t′, we use the axiom RCF. The other casesare immediate. ¦

Substitution of equivalent terms preserves quantum equivalence:

Theorem 3.17 (Principle of substitution of equivalent formulas) Giv-en three quantum formulas γ, γ1 and γ2, let γ′ be obtained from γ by replacingzero or more q-occurrences of γ1 in γ by γ2. Then,

` (γ1 ≡ γ2) A (γ ≡ γ′).

Proof: The case γ1 does not q-occur in γ is trivial. We just consider the casein which γ1 has at least one q-occurrence in γ and γ′ is obtained by replacementof at least one such q-occurrence. The proof is carried out by induction on thestructure of γ. There are two cases:

1. γ is a quantum atom or ⊥⊥. Then γ1 is γ, γ1 q-occurs in γ exactly once,and replacement of q-occurrence of γ1 in γ by γ2 yields γ2. Hence, in thatcase γ′ is γ2. So the theorem holds trivially by the following assertion(justified by the axiom QTaut):

` (γ1 ≡ γ2) A (γ1 ≡ γ2).

2. γ is γa A γb. Then there are two cases.

• γ1 is γ. Then the theorem follows as in the previous case.

• γ1 q-occurs in γa or γb (it may occur in both). Let γ′ be γ′a A γ′bwhere γ′a and γ′b are obtained by replacing zero or more occurrencesof γa and γb respectively. Then, by the induction hypothesis we have

(γ1 ≡ γ2) ` (γa ≡ γ′a)

and(γ1 ≡ γ2) ` (γb ≡ γ′b).

We show that(γ1 ≡ γ2), γ ` γ′

as follows.1 γ1 ≡ γ2 Hyp2 γa A γb Hyp3 γb A γ′b 1, Induction Hypothesis4 γa A γ′b 2, 3, HypSyl5 γ′a A γa 1, Induction Hypothesis6 γ′a A γ′b 4,5, HypSyl

We can show similarly that

(γ1 ≡ γ2), γ′ ` γ.

The theorem now follows from metatheorem of deduction.

29

Page 30: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

¦

We get as a corollary that substitution of classically equivalent formulaspreserves quantum equivalence:

Corollary 3.18 Given a quantum formula γ, two classical formulas α1, α2, letγ′ be obtained from γ by replacing zero or more q-occurrences of α1 in γ by α2.Then

` (α1 ⇔ α2) A (γ ≡ γ′).

Proof: We observe that by Lift⇔, we have ` (α1 ⇔ α2) A (α1 ≡ α2). Theresult then follows from principle of substitution of equivalent formulas andhypothetical syllogism. ¦

Please note that we are only concerned with occurrence of classical formulasonly as quantum sub-formulas and not as classical formulas. Indeed, replace-ment of a classical formula by a quantum formula may not always yield valida quantum formula. Even in the case it yields a valid quantum formula, theprinciple of substitution does not hold. For example, let α1 be qb1, α2 be qb2

and γ be qb3. Now, consider the quantum formula:

(qb1 ≡ qb2) A ((qb1 ⇒ qb3)≡ (qb2 ⇒ qb3)).

Let V be the set of two valuations v1, v2 such that:

• v1(qb1) = v1(qb3) = 0, v1(qb2) = 1;

• v2(qb1) = v2(qb3) = 1, v2(qb2) = 0.

Any quantum structure with V as the set of valuations would then invalidatethe above quantum formula.

4 Completeness and decidability

We shall prove weak completeness of dEQPL – if Γ is a finite set of quantumformulas, then Γ ² γ implies that Γ ` γ. As our proof system enjoys principleof deduction, it suffices to demonstrate weak completeness when the set Γ isempty. The proof of weak completeness will go hand-in-hand with the proof ofdecidability, and can be adapted to a proof of strong completeness as we willsketch later.

The proof of weak completeness essentially follows the proof in [28], whichin turn was inspired by the Fagin-Megiddo-Halpern technique for probabilisticlogic [18]. The main difference is in the way the sub-system formulas are treatedhere. The other difference is that the proof is carried out in a manner so as tofacilitate the proof of decidability.

The central result in the proof is the Model Existence Lemma, namely, ifγ is consistent then there is a quantum structure w and an assignment ρ suchthat wρ ° γ. A quantum formula γ is said to be consistent if 6` (¯ γ). It

30

Page 31: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

will suffice to show that the model existence lemma holds for specials kinds ofquantum formula, namely quantum molecular formulas. A quantum molecularformula is a quantum disjunction of quantum literals (a quantum literal is eithera quantum atom or the quantum negation of a quantum atom). Please recallthat quantum atoms are classical formulas, comparison terms and sub-systemassertions.

The first steps in the proof of the Model Existence Lemma are to removethe probability and alternative terms using the axioms Prob, If> and If⊥.Next, we use the weak completeness of classical propositional logic to constructthe set of valuations V in the envisaged quantum structure. The partition Sis constructed by considering the sub-system literals in the quantum molecule,and the construction is guided by the fact that sub-systems are closed under setoperations (axioms Sub∅, Sub∪ and Sub\). The logical amplitudes νGA areconstructed by first adding all consistent equations using the axioms NAdm,Unit, Empty and Mul, and then “solving” for the (in)equations in the quan-tum molecule using RCF.

Before proceeding with carrying out the above outline, we start with a fewabbreviations and notations. We introduce the following abbreviation whereQ ⊂ qAtom and D ⊆ Q:

• (d

Q D) for ((d

µ∈D µ) u (d

µ∈(Q\D) (¯µ))).

We shall say that D is the positive part of the quantum molecule (d

Q D) andthat Q \D is its negative part. Given a molecule η, we denote by η+ and η−

the positive and negative parts respectively. We denote by ηc the conjunctionof the classical literals in η. In a similar way we define η≤ and ηs.

As is the case with classical propositional logic, every dEQPL formula has aquantum disjunctive normal form. A quantum formula is said to be in quantumdisjunctive normal form if it is a disjunction of quantum molecules.

Proposition 4.1 Every quantum formula is equivalent to a quantum disjunc-tive normal form. Furthermore, there is an algorithm that computes the quan-tum disjunctive normal form.

Proof: It is easier to prove a stronger result. That is, we show that anyquantum formula η has both a quantum disjunctive normal form and a quantumconjunctive normal form. We say that η is in quantum conjunctive normal formif it is a quantum conjunction of quantum disjunctions of literals. The proof isconstructive and follows by induction on the structure of the quantum formulaas in the case of classical logic. The construction also gives the algorithm forcomputing the normal forms. ¦

From now on we will assume that every quantum formula is in quantumdisjunctive normal form. The following proposition will ensure that to decideconsistency of a quantum formula we only need to check if one of its moleculesis consistent.

Proposition 4.2 A quantum formula is consistent iff one of its molecules isconsistent.

31

Page 32: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Proof: (⇒) It suffices to show that the quantum disjunction of two inconsistentquantum formulas γ1 and γ2 is inconsistent. If γ1 and γ2 are inconsistent then` (¯ γ1) and ` (¯ γ2). We can easily show that in this case ` ¯(γ1 t γ2) asfollows:

1 ` (¯ γ1) A ((¯ γ2) A ¯(γ1 t γ2)) QTaut

2 ` (¯ γ1) Hyp

3 ` (¯ γ2) Hyp

4 (¯ γ2) A ¯(γ1 t γ2) QMP: 1,2

5 ¯(γ1 t γ2) QMP: 3,4

Hence the formula, (γ1 t γ2) is inconsistent.(⇐) Assume that η is inconsistent. Then ` (¯ η). Let η be η1t . . .tηn. By

QTaut, ` (¯ η) ≡ (¯ η1 u . . . u ¯ ηn). Using QMP and QTaut we can easilyshow that ηi is inconsistent for i = 1, . . . , n. ¦

The first step in the proof is to remove the probability terms.

Proposition 4.3 Given a quantum molecule η, there is a η′ such that η′ hasno probability terms and ` η ≡ η′. Furthermore, there is an algorithm thatcomputes η′.

Proof: Let η be a molecule. For every probability term of the form (∫

α) replaceit by (

∑A ||α〉A|2)). Then by axiom Prob and the principle of substitution of

equal terms, the resulting formula is equivalent to η. ¦

The following proposition allows us to remove alternative terms in quantummolecules.

Proposition 4.4 A quantum molecule η is consistent iff there is a consistentquantum molecule η′ such that η′ has no alternative terms and ` (η′ A η).Moreover, if there is an algorithm for deciding the consistency of quantummolecules without alternative terms then there is an algorithm for deciding theconsistency of quantum molecules.

Proof: The existence of a consistent η′ such that ` (η′ A η) clearly implies theconsistency of η. For the other direction, consider an ordering α0, . . . , αm ofthe guards of alternative terms occurring in η. Let α0

i be αi and α1i be ¯αi for

i = 0, . . . , m.Given b0 . . . bm ∈ 0, 1m, let

ηb0...bm := η u αb00 u . . . u αbm

m .

Using QTaut we get,` η ≡

b0...bm∈0,1m

ηb0...bm .

32

Page 33: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Observe that, using the axioms If> and If⊥ and the principle of substitutionof equal terms, each ηb0...bm is equivalent to a formula in which the alternative(αi B u0

i ; u1i ) is replaced by ubi

i . Let ηb0...bmbe the resulting formula. Therefore,

` η ≡⊔

b0...bm∈0,1m

ηb0...bm.

With a reasoning similar to the one in Proposition 4.2, we conclude that ηis consistent iff ηb0...bm

is consistent for some b0 . . . bm ∈ 0, 1m. Please notethat ` ηb0...bm

A η for each b0 . . . bm ∈ 0, 1m.Finally, as the construction of each ηb0...bm

can be defined by an algorithm,we get the proposition. ¦

We shall now build the set of classical valuations V . Given a classicalformula α and a non-empty set of valuations V , we write V °c α if everyelement of V classically satisfies α. We say that V °c η if V °c α for everyα ∈ η+

c and V 6°c β for every β ∈ η−c .We will consider only a special kind of molecular formulas which will allow

us to deal with the restrictions imposed by the axiom NAdm. Please recallthat given A ⊆ qB, vA is the valuation that assigns true to qubit symbols inA and false to qubit symbols in qb \ A. A molecular formula η is said to bemaximal with respect to admissible classical valuations if for every subset A ofqB and set of valuations V such that V °c η, we have:

vA /∈ V iff (¬(∧A)) ∈ η+c .

The following proposition ensures that it suffices to consider molecular formulasmaximally consistent with classical valuations.

Proposition 4.5 A molecule η is consistent iff there is a consistent moleculeη′ such that η′ is maximal with respect to admissible classical valuations and` η′ A η. Moreover, if there is an algorithm for deciding the consistency ofquantum molecules maximal with respect to admissible valuations then thereis an algorithm for deciding consistency of quantum molecules.

Proof: Let A1, . . . , Am be an ordering of the subsets of qB. Let A0i be (¬(∧Ai))

and A1i be ¯(¬(∧Ai)) for i = 0, . . . ,m. Given b0 . . . bm ∈ 0, 1m, let

ηb0...bm := η uAb00 u . . . uAbm

m .

Using QTaut,` η ≡

b0...bm∈0,1m

ηb0...bm .

With a reasoning similar to the one in Proposition 4.2, we can conclude thatη is consistent iff ηb0...bm is consistent for some b0 . . . bm ∈ 0, 1m. Please notethat ` ηb0...bm A η for each b0 . . . bm ∈ 0, 1m. We claim that each ηb0...bm ismaximal with respect to admissible valuations. Fix one ηb0...bm .

33

Page 34: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Let V be a set of valuations such that V °c ηb0...bm . We will show that

vAi 6∈ V iff (¬(∧Ai)) ∈ (ηb0...bm)+c .

Clearly if (¬(∧Ai)) ∈ (ηb0...bm)+c then vAi 6∈ V .For the other part, if vAi 6∈ V it suffices to show that bi = 0. Suppose

that bi = 1. Then V 6°c (¬(∧Ai)). That means there is v ∈ V such thatv 6°c (¬(∧Ai)). This means that v °c ∧Ai which in turn implies that v is equalto vAi . Therefore vAi ∈ V contradicting the assumption bi = 1.

As the construction of ηb0...bm can be defined by an algorithm, we get theproposition. ¦

We will say that η is g-satisfiable if there is a set of valuations V such thatV °c η. Given a consistent molecule η, we now construct V such that V °c ηas follows.

Lemma 4.6 (g-satisfiability) If η is consistent then η is g-satisfiable. Fur-thermore, there is an algorithm to decide if η is g-satisfiable.

Proof: Let V be the set of valuations v such that v °c α for every α ∈ η+c .

This set can be computed since the set of qubit symbols is finite.If V is empty then η is not g-satisfiable. If V is not empty, then η is g-

satisfiable iff V 6°c β for every β ∈ η−c . As V and η−c are finite sets, this givesus an algorithm to check if η is g-satisfiable.

Assume that η is a consistent formula. Please note that using the theoremLift∧ and the principle of substitution, it is easy to show that if η is consistentthen (∧α∈η+

cα) is consistent as a classical propositional formula.

We show that η is g-satisfiable. As (∧α∈η+cα) is consistent (in propositional

logic), there is a classical valuation v that satisfies every α. As above, let V bethe set of valuations v such that v °c α for every α ∈ η+

c . It suffices to showthat V 6°c β for every β ∈ η−c .

We proceed by contradiction. Assume that there is β ∈ η−c such that V °c β.Fix one such β say β0. Therefore, by construction of V , we get:

°c

α∈η+c

α

⇒ β0

.

So, by CTaut we get:

`

α∈η+c

α

⇒ β0

.

Thus, by Lift⇒, we obtain

`

α∈η+c

α

A β0

.

34

Page 35: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Thus, by Refu and QTaut (transitivity of A) we get

`

l

α∈η+c

α

A β0

.

Therefore, by QTaut (right weakening of A)

`

l

α∈η+c

α

A

β∈η−c

β

leading to

l

α∈η+c

α

u

l

β∈η−c

(¯β)

by several obvious tautological steps. That is, we have ` (¯ η), contradictingthe consistency of η. ¦

Please observe that if η has neither probability nor alternative terms then η′

as constructed in the above proof also does not have probability and alternativeterms.

Given a sub-system formula [G] and a partition S of the set of qubits, wewrite S °s [G] if G ∈ Alg(S). We say that S °s η if S °s [G] for every [G] ∈ η+

s

and S 6°s [G] for every [G] ∈ η−s . We will say that η is s-satisfiable if there isa partition S such that S °s η. We construct the partition S in the proof ofModel Existence Lemma as follows.

Lemma 4.7 (s-satisfiability) If η is consistent then η is s-satisfiable. Thereis an algorithm to decide if η is s-satisfiable.

Proof:Assume that η is consistent. We will show that η is s-satisfiable. Please

recall that an algebra of sets on a domain X is a non-empty collection of subsetsof X closed under complements and unions. Let Alg(η+

s ) be the smallest algebraon qB containing η+

s .Find the minimal elements for Alg(η+

s ): a set G ∈ Alg(η+s ) is minimal if

G′ ⊆ G and G ∈ Alg(η+s ) implies that G′ is either the empty set or G itself.

Take S to be the set of minimal elements of Alg(η+s ) (it can be easily shown

that they form a partition). Therefore, by construction, S °s [G] for every[G] ∈ η+

s .If [H] ∈ η−s then we need to show [H] /∈ Alg(η+

s ). We proceed by contradic-tion and assume H ∈ Alg(η+

s ). Then H = H1 ∪ . . .∪Hm, where either Hi ∈ η+s

or qB \ Hi ∈ η+s for each 1 ≤ i ≤ m. Using the axioms QTaut, Sub\ and

Sub∪, we can show that` η ≡ η u [H].

Now as [H] ∈ η−s , we get

` η ≡ η u [H]≡ η u [H] u¯[H].

35

Page 36: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Now, by QTaut,` (η u [H] u¯[H])A ⊥⊥ .

Then, by principle of substitution of equivalent formulas, we get

` (¯ η).

This contradicts the consistency of η.The algorithm for checking the s-consistency is as follows. Take η+

s andgenerate the algebra Alg(η+

s ) with them. This algebra can be computed sincethe set of qubit symbols is finite. The formula η is s-satisfiable iff G /∈ Alg(η+

s )for every [G] ∈ η−s . This can be checked by an algorithm again as the set ofqubits is finite. ¦

We are now ready to construct the model (the amplitudes νGA will be con-structed in the proof). We need some auxiliary definitions. Recall that assign-ments are enough to interpret the arithmetical formulas. Let κ be a quantumconjunction of comparison literals. Let K be a real closed field with algebraicclosure K(δ) and ρ be a K-assignment. We say that K(δ), ρ °i κ if

• [[s]]ρ ≤ [[t]]ρ if s ≤ t ∈ κ+;

• [[s]]ρ 6≤ [[t]]ρ if s ≤ t ∈ κ−.

We say that ρ is a solution of κ in K(δ). We say that κ is ≤-consistent if thereis a real closed field K with algebraic closure K(δ), and a K-assignment ρ suchthat K(δ), ρ °i κ. Please note that the theory of elimination of quantifiersensures that there is an algorithm to decide the ≤-consistency [24, 6].

Theorem 4.8 (Model Existence Theorem) If the molecule η is consistentthen there is a quantum structure w = (K, δ, V,S, |ψ〉, ν) and a K-assignmentρ such that wρ ° η.

Proof: As a result of Propositions 4.3 and 4.4, we can assume that η does nothave any probability and alternative terms and is maximally consistent withrespect to admissible valuations.

Using Lemma 4.6 and Lemma 4.7, we find V and S such that V °c η andS °s η. We can show that ` η≡ (ηud[G]∈Alg(S)[G]) using axioms Sub∅, Sub∪and Sub\.

Please observe that the axiom Unit allows us to establish for every [G] ∈Alg(S):

` η A (∑

A⊆G

||>〉GA|2 = 1).

Let η1 be the formula

η ul

G∈Alg(S)

(∑

A⊆G

||>〉GA|2 = 1).

As a result we get that ` (η1 ≡ η).

36

Page 37: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

We also get as a result of the axiom NAdm, for every (¬(∧A)) occurringin η:

` η1 A (|>〉qBA = 0).

Let η2 be the formula

η1 ul

(¬(∧A)) in η+c

(|>〉qBA = 0).

As a result of axiom Mul, for every G1, G2, A1, A2 such that G1, G2 ∈Alg(S), A1 ⊆ G1 and A2 ⊆ G2, we get

` η2 A (|>〉G1∪G2A1∪A2= |>〉G1A1

|>〉G2A2).

Let η3 be the formula

η2 ul

G1,G2∈Alg(S)

A1⊆G1,A2⊆G2

(|>〉G1∪G2A1∪A2= |>〉G1A1

|>〉G2A2).

The axiom Empty gives us

` η3 A (|>〉∅∅ = 1).

Let η• be the formulaη3 u (|>〉∅∅ = 1).

Observe that we can show:` (η ≡ η•).

Please recall that η•≤ is the conjunction of the (in)equations in η•. Let ηR

be the formula obtained from η• by replacing each term of the form |>〉GA bya fresh variable z|>〉GA

. Please observe that η• is ηR|z|>〉GA/ |>〉GA|.

Now, either there is a real closed field K with K(δ) as its algebraic closure,and a K-assignment ρ such that K(δ), ρ °i (ηR)≤ or not. If there is no such Kand ρ then it must be the case that ¯(ηR)≤ is a valid arithmetic formula. So,by axiom RCF,

` (¯(ηR)≤)|z|>〉GA/ |>〉GA|.

However, the formula (¯(ηR)≤)|z|>〉GA/ |>〉GA| is (¯ η≤) and this will imply

that η is inconsistent.Therefore there are K(δ) and ρ such that K(δ), ρ °i (ηR)≤. We fix such a

K, K(δ) and ρ.We now construct |ψ〉 = |ψ〉SS∈S as follows:

• |ψ〉[∅] = 1;

• Let νSA = ρ(z|>〉SA) for every S ∈ S and A ⊆ S. Then,

|ψ〉[S] =∑

A⊆S

νSA|vSA〉.

37

Page 38: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

We construct ν = νGAG⊂qB,A⊆G as follows:

νGA =

ρ(z|>〉GA) if z|>〉GA

is a variable in ηR

0 otherwise.

Please note that, by construction νGA = 〈vGA |ψ〉[G] if G ∈ Alg(S). Let w

be (K, δ, V,S, |ψ〉, ν). We can easily show that w is a quantum structure andwρ ° η. ¦

The decidability of consistency of molecular formulas follows as a corollaryto the proof of the Model Existence Lemma.

Corollary 4.9 There is an algorithm to decide if a quantum molecule η isconsistent.

Proof: As a result of Propositions 4.3 and 4.4, we can assume that η doesnot have any probability and alternative terms and is maximally consistentwith respect to admissible valuations. Now as a result of the model existencelemma, all we need to do is to check if there is a quantum structure w suchthat w ° η. We refer to the proof of model existence lemma.

We first check if η is g-satisfiable and s-satisfiable which is algorithmic byLemmas 4.6 and 4.7. If not then η is not consistent. Otherwise, let V and Sbe as in the proof of the model existence lemma.

Now, we construct ηR as in the same proof. Note that the construction isalgorithmic. We check if (ηR)≤ is ≤-consistent or not. If it is not the case thenη is not consistent. If (ηR)≤ is ≤-consistent then we can construct w as in thatproof such that w ° η. Therefore η will be consistent if (ηR)≤ is ≤-consistent. ¦

Please note any formula γ is equivalent to a disjunction of quantum molec-ular formulas. Furthermore, if γ is consistent, so is one of its molecules, sayη. Theorem 4.8 gives a quantum structure w and an assignment ρ such thatwρ |= η. As η is a quantum molecule of Γ we get easily wρ |= γ. Hence, if anyquantum formula γ is consistent then γ has a model. We can now deduce theweak completeness of dEQPL in the standard way.

Theorem 4.10 (Completeness) The proof system of dEQPL is weakly com-plete, i.e., ² γ implies ` γ.

Proof:We prove completeness by contradiction. Assume that 6` γ. So by Qtaut

and QMP, we have 6` (¯(¯ γ)). Therefore, ¯ γ is consistent, and hence thereis a quantum structure w and an assignment ρ such that wρ |= ¯ γ. Therefore,wρ 6|= γ. ¦

Finally, we get the decidability of dEQPL.

Theorem 4.11 (Decidability) The set of theorems is decidable.

38

Page 39: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Proof: As a result of soundness and completeness we have, ` η iff ¯ η is incon-sistent. We can decide consistency of a formula by Corollary 4.9, Proposition 4.1and Proposition 4.2. ¦

We finish this section by observing two things. The first observation is thatthe proof of weak completeness can be adapted to a proof of strong completenessas follows. The key in the proof is again the Model Existence Lemma. Given apossibly infinite consistent set of quantum formulas Γ, we construct a maximallyconsistent set (the usual Henkin-Lindenbaum construction). Next, by lookingat the classical formulas in Γ, we construct V using the strong completeness ofpropositional logic. The construction of the partition S is by considering thesub-system literals in Γ and is similar to the one in the above proof. Finally,just as in the proof above, we replace the amplitude terms in comparison-literals by fresh variables and “solve” the resulting equations using the strongcompleteness of first-order logic (note that as Γ is maximal all the maximallyconsistent information about logical amplitudes is already in Γ).

The second observation is that in our semantic structures, if G is the set ofqubits of a sub-system then the qubits in G are necessarily not entangled withthe rest. That is, the following is a theorem in dEQPL:

` [G] Al

A1⊆G , A2⊆qB\G(|>〉qB(A1∪A2) = |>〉GA1

|>〉(qB\G)A2).

In EQPL [28], the reverse implication was also true. That is in [28], it was thecase that G is a sub-system if and only if the qubits in G are not entangled withthe rest. We can extend our results to such semantic structures by consideringthe (finite) set of formulas Γ = γG |G ⊆ qB where

γG := ([G]≡ (l

A1⊆G , A2⊆qB\G(|>〉qB(A1∪A2) = |>〉GA1

|>〉(qB\G)A2))).

Clearly Γ ² γ if and only γ holds in all the semantic structures where every setof qubits not entangled with the rest forms a sub-system. If were to augmentour axiom system with elements of Γ, then γ is a theorem in the augmentedaxiomatization if and only if Γ ` γ. The weak completeness and decidability inthe augmented system then follow from the results of this section.

5 Application examples

As it is, dEQPL is appropriate for reasoning about quantum states only. Forreasoning about the evolution of quantum systems through the application ofmeasurements and unitary transformations we will need to extend it towards adynamic logic, as already sketched in [26, 27].

Herein, we first illustrate how dEQPL can be used to reason about a Bellstate. Afterwards, we turn our attention to quantum teleportation and outlinethere some of the relevant constructs of the envisaged dynamic logic. In thefollowing examples, we write |F 〉 as an abbreviation for the vector (|>〉FA)A⊆F

assuming the lexicographic ordering of the subsets of F . We may also abbreviateqbk1

, . . . , qbkm by qbk1,...,km

in amplitude terms.

39

Page 40: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

5.1 Reasoning about Bell states

Bell states were first discussed by Einstein, Podolsky and Rosen [17] and havebeen very useful in designing quantum protocols. An independent sub-systemcomposed of a pair of qubits is said to be in a Bell state if they are maximallyentangled. For instance,

|ψ〉 =1√2(|10〉 − |01〉)

is a Bell state.In order to represent this pair in our logic, we choose two qubit symbols,

say qb0 and qb1. The fact that these qubits are independent from other qubitscan be written as

γind := [qb0, qb1].

We can express the state as the following formula

γEPR := (|qb01〉 =1√2(0,−1, 1, 0)).

We can use our logic to derive that these qubits are necessarily entangled,that is, neither qb0 nor qb1 form an independent sub-system. In other wordswe will show that

γind, γEPR ` ¯[qb0] u¯[qb1].

The proof will follow by applying the metatheorem theorem of deduction.In particular, we show

γind, γEPR, [qb0] `⊥⊥,

as follows:1 [qb0, qb1] Hyp

2 [qb0] Hyp

3 ([qb0, qb1] A ([qb0] A [qb1])) SubDiff

4 ([qb0] A [qb1])) QMP: 1,3

5 [qb1] QMP :2,4

6 (|>〉qb01∅ = 0) u ((|>〉qb01qb0= − 1√

2) u (|>〉qb01qb1

= 1√2) u (|>〉qb01qb01

= 0)) Hyp

7 (γ1 u γ2) A γ2 QTaut

8 (|>〉qb01qb0= − 1√

2) u (|>〉qb01qb1

= 1√2) u (|>〉qb01qb01

= 0) QMP: 6,7

9 |>〉qb01qb0= |>〉qb0qb0

|>〉qb1∅ Mul: 2,5

10 |>〉qb01qb1= |>〉qb0∅|>〉qb1qb1

Mul: 2,5

11 |>〉qb01qb1= |>〉qb0qb0

|>〉qb1qb1Mul: 2,5

12 ⊥ RCF: 8–11

13 ⊥⊥ Eqv⊥: 12

40

Page 41: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Therefore, by metatheorem of deduction, we get

γind, γEPR ` ¯[qb0].

In a similar way, we can derive

γind, γEPR ` ¯[qb1],

and consequently, we get

γind, γEPR ` ¯[qb0] u¯[qb1].

In the next section, we consider a protocol which uses this Bell state toachieve teleportation.

5.2 Reasoning about quantum teleportation

A protocol for quantum teleportation was first proposed in [7]. The idea is tomove a qubit from one agent to another who share an entangled pair of qubitswhile exchanging only classical information.

Before describing and verifying the protocol we need to extend dEQPL withsome features from dynamic logic. Namely, we shall use formulas, called Hoaretriples for historical reasons [23], of the form

γ1P γ2

where γ1 and γ2 are dEQPL formulas and P is a quantum program denotingsome composition of unitary transformations and measurements. It is oftenuseful to reserve some qubits that are always in a classical state. Let us call themclassical bits and use the symbols cb1, . . . , cbm to range over them. We shallavoid going into the details of the quantum program language and semantics,better left to a specific paper on a dynamic extension of dEQPL. However, weshall provide the needed intuitions. Namely, The Hoare triple above means thatif the system is in a quantum state satisfying γ1 then after running P it reachesa state satisfying γ2.

The protocol in [7] uses three qubits, say qb0, qb1 and qb2 plus two classicalbits cb0 and cb2. The purpose is to transfer the quantum state of qb0 toqb1, using qb2 and the classical bits as auxiliary variables. Initially, qb1 andqb2 will be prepared in a Bell state not entangled with qb0. Afterwards, ameasurement of qb0 and qb2 is made (by Alice). Note that this measurementwill also affect qubit 1 because it is entangled with qubit 2. The classical bitsare used to store the result of measuring the corresponding qubits. The classicalinformation to be exchanged is precisely the contents of the classical bits afterthe measurement. Finally, this information is used (by Bob) to decide whichunitary transformation to apply on qb1 in order to achieve the required state.

41

Page 42: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

In short, the protocol QTP is as follows:

Mqb02;

IF|cb02〉 = (1, 0, 0, 0) → −Iqb1

|cb02〉 = (0, 1, 0, 0) → −Zqb1

|cb02〉 = (0, 0, 1, 0) → Xqb1

|cb02〉 = (0, 0, 0, 1) → −Xqb1Zqb1

FI

where I is the identity operator and X and Z are the standard Pauli operators(not and phase flip, respectively).

The initial state of the system (after preparing the qubits 1 and 2) is assumedto comply with:

γinit := [qb0] u (|qb12〉 =1√2(0, 1,−1, 0)) u (|qb0〉 = (z0, z1)) .

Observe that we are not constraining the state of qubit 0. We just need torefer to it which we achieve by using the (rigid) variables z0 and z1. Note alsothat in such a state the qubits 1 and 2 are entangled. Actually, they are in aBell state as discussed in the previous example.

We want the final state of the system (after running the protocol) to complywith:

γfin := [qb1] u (|qb1〉 = (z0, z1)) .

In other words, we want to establish:

Spec := γinitQTP γfin .

To this end, it is enough to assume that the measurement operator Mqb02

complies with the following non probabilistic specification:

γinitMqb02t4

k=1γk

where

γ1 := (|cb02〉 = (1, 0, 0, 0)) u (|qb02〉 = 1√2(1, 0, 0, 1)) u (|qb1〉 = −(z0, z1));

γ2 := (|cb02〉 = (0, 1, 0, 0)) u (|qb02〉 = 1√2(−1, 0, 0, 1)) u (|qb1〉 = (−z0, z1));

γ3 := (|cb02〉 = (0, 0, 1, 0)) u (|qb02〉 = 1√2(0, 1, 1, 0)) u (|qb1〉 = (z1, z0));

γ4 := (|cb02〉 = (0, 0, 0, 1)) u (|qb02〉 = 1√2(0,−1, 1, 0)) u (|qb1〉 = (z1,−z0)).

Observe that the IF part of the protocol QTP complies with:

γk IF γfin

for k = 1, . . . , 4. Therefore, we can derive Spec using the traditional compositionrules of dynamic logic.

42

Page 43: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

6 Concluding remarks

A decidable quantum logic allowing us to reason about amplitudes of quantumstates and probabilities of classical outcomes was obtained as a fragment ofEQPL. Decidability was achieved by relaxing the semantics, replacing Hilbertspaces by inner product spaces over arbitrary real closed fields and their alge-braic closures. The proof of decidability was carried out hand in hand with theproof of weak completeness and follows the Fagin-Halpern-Megiddo technique(originally proposed for probabilistic logics [18, 1]).

We envision to use this decidable quantum logic in the specification andverification of quantum procedures and protocols, either via model checking ortheorem proving. To this end, the hardness of the proposed decision algorithmneeds to be analyzed. We also intend to enrich this decidable quantum logic withHoare triples as outlined in Section 5 and in [26, 27]. Temporal extensions ofdEQPL should also be explored to reason about liveness and progress propertiesof quantum computations. Another interesting line of research would be todevelop a first-order quantum logic based on the exogenous semantics approach.

Both EQPL and dEQPL allow us to express amplitudes of pure quantumstates of collections of qubits. Therefore, these logics are not insensitive to theglobal phase of the quantum state. One may argue that it should be insensitivesince no physical measurement will ever be able to distinguish two quantumstates that are equivalent up to global phase. We decided to leave dEQPL asit is (that is, sensitive to global phase) for two reasons. In practice, physicistsand quantum computer scientists need to work with both levels of abstraction.Sometimes they want to work with states as unit vectors and other times theywant to abstract away the global phase. Therefore, a calculus supporting theformer level of abstraction is also useful. The second reason is a consequence ofthe fact that forgetting global phase requires a major semantic shift. Indeed, itis better solved by identifying a quantum state with a density operator work-ing on the underlying inner product space, that is, working with probabilisticensembles or mixed quantum states in general.

Such a shift toward a semantics based on density operators will lead to aquite different quantum logic (but still extending classical logic by applyingthe exogenous approach) that will also be useful for reasoning about quantumsystems evolving under partial tracing, besides unitary transformations andmeasurements. Clearly, this is yet another line of research that will deserveattention.

The relationship between the exogenous quantum logics and the more tra-ditional quantum logics (based on the original Birkhoff and von Neumann pro-posal) should be further explored. At the preliminary stage of work in thisdirection, it seems that most of the qualitative assertions possible in the lattercan be made in the former and that the latter can be easily extended withquantitative aspects of the former. In other words, it seems feasible to combinethe two quantum logics into a single logic by using fibring techniques [20, 10].

43

Page 44: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Acknowledgments

The authors wish to express their gratitude to the regular participants in theQCI Seminar at SQIG-IT (formerly at CLC), and also to Dave Marker andAnand Pillay for their help on real closed fields and their algebraic comple-tion. This work was partially supported by FCT and FEDER through POCTI,namely via the QuantLog POCTI/MAT/55796/2004 (Quantum Logic), KLogPTDC/MAT/68723/2006 (Kleistic Logic) and QSec PTDC/EIA/67661/2006(Quantum Security) projects.

References

[1] M. Abadi and J. Y. Halpern. Decidability and expressiveness for first-orderlogics of probability. Information and Computation, 112(1):1–36, 1994.

[2] S. Abramsky and B. Coecke. A categorical semantics of quantum protocols.In Proceedings of the 19th Annual IEEE Symposium on Logic in ComputerScience (LICS 2004), pages 415–425. IEEE Computer Science Press, 2004.Extended version at arXiv:quant-ph/0402130).

[3] S. Abramsky and R. Duncan. A categorical quantum logic. MathematicalStructures in Computer Science, 16(3):469–489, 2006.

[4] F. Bacchus. On probability distributions over possible worlds. In Uncer-tainty in Artificial Intelligence, 4, volume 9 of Machine Intelligence andPattern Recognition, pages 217–226. North-Holland, 1990.

[5] F. Bacchus. Representing and Reasoning with Probabilistic Knowledge.MIT Press Series in Artificial Intelligence. MIT Press, 1990.

[6] S. Basu, R. Pollack, and R. Marie-Francoise. Algorithms in Real AlgebraicGeometry. Springer, 2003.

[7] C. H. Bennett, G. Brassard, C. Crepeau, R. Jozsa, A. Peres, and W. K.Wootters. Teleporting an unkown quantum state via dual classical andeinstein-podolsky-rosen channels. Physical Review Letters, 70(13):1895–1899, 1993.

[8] G. Birkhoff and J. von Neumann. The logic of quantum mechanics. Annalsof Mathematics, 37(4):823–843, 1936.

[9] C. Caleiro, P. Mateus, A. Sernadas, and C. Sernadas. Quantum institu-tions. In K. Futatsugi, J.-P. Jouannaud, and J. Meseguer, editors, Algebra,Meaning, and Computation – Essays Dedicated to Joseph A. Goguen on theOccasion of His 65th Birthday, volume 4060 of Lecture Notes in ComputerScience, pages 50–64. Springer-Verlag, 2006.

[10] C. Caleiro, A. Sernadas, and C. Sernadas. Fibring logics: Past, present andfuture. In S. Artemov, H. Barringer, A. S. d’Avila Garcez, L. C. Lamb,and J. Woods, editors, We Will Show Them: Essays in Honour of DovGabbay, Volume One, pages 363–388. College Publications, 2005.

44

Page 45: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

[11] W. A. Carnielli. Possible-translations semantics for paraconsistent logics.In Frontiers of Paraconsistent Logic (Ghent, 1997), volume 8 of Studies inLogic and Computation, pages 149–163. Research Studies Press, 2000.

[12] W. A. Carnielli and M. Lima-Marques. Society semantics and multiple-valued logics. In Advances in Contemporary Logic and Computer Science(Salvador, 1996), volume 235 of Contemporary Mathematics, pages 33–52.AMS, 1999.

[13] R. Chadha, L. Cruz-Filipe, P. Mateus, and A. Sernadas. Reasoning aboutprobabilistic sequential programs. Theoretical Computer Science, 379(1-2):142–165, 2007.

[14] M. L. D. Chiara, R. Giuntini, and R. Greechie. Reasoning in QuantumTheory. Kluwer Academic Publishers, 2004.

[15] C. Cohen-Tannoudji, B. Diu, and F. Laloe. Quantum Mechanics. JohnWiley, 1977.

[16] H. Dishkant. Semantics of the minimal logic of quantum mechanics. StudiaLogica, 30:23–32, 1972.

[17] A. Einstein, B. Podolsky, and N. Rosen. Can quantum-mechanical de-scription of physical reality be considered complete? Physical Review,47:777–780, 1935.

[18] R. Fagin, J. Y. Halpern, and N. Megiddo. A logic for reasoning aboutprobabilities. Information and Computation, 87(1-2):78–128, 1990.

[19] D. J. Foulis. A half-century of quantum logic. What have we learned? InQuantum Structures and the Nature of Reality, volume 7 of Einstein MeetsMagritte, pages 1–36. Kluwer Acad. Publ., 1999.

[20] D. M. Gabbay. Fibred semantics and the weaving of logics: Part 1. Journalof Symbolic Logic, 61(4):1057–1120, 1996.

[21] J. Y. Halpern. An analysis of first-order logics of probability. ArtificialIntelligence, 46:311–350, 1990.

[22] H. Hansson and B. Jonsson. A logic for reasoning about time and reliability.Formal Aspects of Computing, 6:512–535, 1995.

[23] C. Hoare. An axiomatic basis for computer programming. Communicationsof the ACM, 12:576–583, 1969.

[24] W. Hodges. Model Theory. Cambridge University Press, 1993.

[25] S. A. Kripke. Semantical analysis of modal logic. I. Normal modal propo-sitional calculi. Zeitschrift fur Mathematische Logik und Grundlagen derMathematik, 9:67–96, 1963.

45

Page 46: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

[26] P. Mateus and A. Sernadas. Exogenous quantum logic. In W. A. Carnielli,F. M. Dionısio, and P. Mateus, editors, Proceedings of CombLog’04, Work-shop on Combination of Logics: Theory and Applications, pages 141–149,1049-001 Lisboa, Portugal, 2004. Departamento de Matematica, InstitutoSuperior Tecnico. Extended abstract.

[27] P. Mateus and A. Sernadas. Reasoning about quantum systems. InJ. Alferes and J. Leite, editors, Logics in Artificial Intelligence, Ninth Eu-ropean Conference, JELIA’04, volume 3229 of Lecture Notes in ArtificialIntelligence, pages 239–251. Springer-Verlag, 2004.

[28] P. Mateus and A. Sernadas. Weakly complete axiomatization of exogenousquantum propositional logic. Information and Computation, 204(5):771–794, 2006.

[29] P. Mateus, A. Sernadas, and C. Sernadas. Exogenous semantics approachto enriching logics. In G. Sica, editor, Essays on the Foundations of Mathe-matics and Logic, volume 1 of Advanced Studies in Mathematics and Logic,pages 165–194. Polimetrica, 2005.

[30] P. Naur. Revised report on the algorithmic language Algol 60. The Com-puter Journal, 5:349–367, 1963.

[31] M. A. Nielsen and I. L. Chuang. Quantum Computation and QuantumInformation. Cambridge University Press, 2000.

[32] N. J. Nilsson. Probabilistic logic. Artificial Intelligence, 28(1):71–87, 1986.

[33] N. J. Nilsson. Probabilistic logic revisited. Artificial Intelligence, 59(1-2):39–42, 1993.

[34] M. Patra. A logic for quantum computation and classical simulation ofquantum algorithms. International Journal of Quantum Information, 6(2),2008. In print.

[35] R. van der Meyden and M. Patra. Knowledge in quantum systems. InM. Tennenholtz, editor, Theoretical Aspects of Rationality and Knowledge,pages 104–117. ACM, 2003.

[36] R. van der Meyden and M. Patra. A logic for probability in quantumsystems. In M. Baaz and J. A. Makowsky, editors, Computer ScienceLogic, volume 2803 of Lecture Notes in Computer Science, pages 427–440.Springer-Verlag, 2003.

46

Page 47: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

Index

Bell states, 40

Classicallogic, 3tautology, 20valuation, 9

CompletenessdEQPL, 38

DecidabilitydEQPL, 38

dEQPLaxioms, 20decidability, 38dynamic extension, 41language, 14logic amplitude, 11metatheorem of deduction, 26model existence theorem, 36semantics, 16soundness, 25weak completeness, 38

EntailmentdEQPL, 16

Exogenous approach, 3, 5Exogenous quantum propositional logic

axioms, 20decidability, 38language, 14metatheorem of deduction, 26model existence theorem, 36semantics, 16soundness, 25weak completeness, 38

Formula of dEQPLg-satisfiable, 34s-satisfiable, 35arithmetical, 16classical, 14comparison, 15consistent, 30extent, 16global, 3

molecule, 31quantum, 15quantum atom, 15quantum sub-, 15satisfaction of quantum, 16sub-system, 15

Globallogic, 3valuation, 3

Hilbert space, 5Hoare triple, 41

Inner product space, 7free, 8

Logicclassical, 3global, 3modal, 5probabilistic, 3–5quantum, 5

Modalityprobability, 18quantum, 18

Normed space, 7

Probabilisticlogic, 3–5valuation, 4

Probabilitymodality, 18

Quantumabbreviations, 17atom, 15connectives, 15consistent formula, 30disjunctive normal form, 31formula, 15literal, 31logic, 5modality, 18

47

Page 48: Extending classical logic for reasoning about quantum systemssqig.math.ist.utl.pt/pub/SernadasA/05-CMSS-quantlog07.pdf · Extending classical logic for reasoning about quantum systems

molecular formula, 31structure, 11sub-formula, 15tautology, 20valuation, 9

Quantum mechanicspostulates, 6, 10, 12, 14

Quantum propositional logicaxioms, 20decidability, 38language, 14metatheorem of deduction, 26model existence theorem, 36semantics, 16soundness, 25weak completeness, 38

Quantum teleportation, 41

Real closed field, 6algebraic closure, 7

SoundnessdEQPL, 25

Tautologyclassical, 20quantum, 20

Tensor product, 10Term of dEQPL

alternative, 15amplitude, 15arithmetical, 16denotation of, 16probability, 15

Valuationclassical, 9global, 3probabilistic, 4quantum, 9

Weak completenessdEQPL, 38

48