Quantum state
In quantum physics, a quantum state is a mathematical object that fully describes a quantum system. One typically imagines some experimental apparatus and procedure which "prepares" this quantum state; the mathematical object then reflects the setup of the apparatus. Quantum states can be statistically mixed, corresponding to an experiment involving a random change of the parameters. States obtained in this way are called mixed states, as opposed to pure states which cannot be described as a mixture of others. When performing a certain measurement on a quantum state, the result is in general described by a probability distribution, and the form that this distribution takes is completely determined by the quantum state and the observable describing the measurement. However, unlike in classical mechanics, the result of a measurement on even a pure quantum state is only determined probabilistically. This reflects a core difference between classical and quantum physics.
Mathematically, a pure quantum state is typically represented by a vector in a Hilbert space. In physics, bra-ket notation is often used to denote such vectors. Linear combinations (superpositions) of vectors can describe interference phenomena. Mixed quantum states are described by density matrices.
In a more general mathematical context, quantum states can be understood as positive normalized linear functionals on a C- algebra; see GNS construction.

# Conceptual description

## The state of a physical system
The state of a physical system is a complete description of the parameters of the experiment.
To understand this rather abstract notion, it is useful to first explore it in an example from classical mechanics.
Consider an experiment with a (non-quantum) particle of mass m=1 which moves freely, and without friction,
in one spatial direction.
We start the experiment at time t=0 by pushing the particle with some speed into some direction.
Doing this, we determine the initial position q and the initial momentum
p
-f the particle. These initial conditions are what characterizes the state 
\sigma of the system, 
formally denoted as  \sigma = (p,q) . We say that we prepare the state of the system
by fixing its initial conditions.
At a later time t>0, we conduct measurements on the particle. 
The measurements we can perform on this simple
system are essentially its position Q(t) at time t, its momentum P(t),
and combinations of these.
Here P(t) and Q(t) refer to the measurable quantities (observables)
-f the system as such, not the specific results they produce in a certain run of the experiment.
However, knowing the state \sigma of the system, we can compute the
value of the observables in the specific state, i.e., the results that our measurements will produce,
depending on p and q.
We denote these values as \langle P(t) \rangle _\sigma and \langle Q(t) \rangle _\sigma. 
In our simple example, it is well known that the particle moves with constant velocity; therefore,
\langle P(t) \rangle _\sigma = p, \quad
\langle Q(t) \rangle _\sigma = pt+q.
Now suppose that we start the particle with a random initial position and momentum.
(For argument's sake, we may suppose that the particle is pushed away at t=0
by some apparatus which is controlled by a random number generator.)
The state \sigma of the system is now not described by two numbers 
p and q, but rather by two probability distributions.
The observables P(t) and Q(t) will produce random results now;
they become random variables, and their values in a single measurement cannot be predicted.
However, if we repeat the experiment sufficiently often,
always preparing the same state \sigma, we can predict the expectation value
-f the observables (their statistical mean) in the state \sigma. The expectation
value of P(t) is again denoted by \langle P(t) \rangle _\sigma, etc.
These "statistical" states of the system are called mixed states, 
as opposed to the pure states \sigma=(p,q) discussed further above.
Abstractly, mixed states arise as a statistical mixture of pure states.

## Quantum states
In quantum systems, the conceptual distinction between observables and states persists just as described above.
The state \sigma of the system is fixed by the way the physicist prepares his experiment
(e.g., how he adjusts his particle source). As above, there is a distinction between pure states and
mixed states, the latter being statistical mixtures of the former. 
However, some important differences arise in comparison with classical mechanics.
In quantum theory, even pure states show statistical behaviour. 
Regardless of how carefully we prepare the state \rho of the system,
measurement results are not repeatable in general, and we must understand the expectation value
\langle A \rangle _\sigma of an observable A as a statistical mean.
It is this mean that is predicted by physical theories.
For any fixed observable A, it is generally
possible to prepare a pure state \sigma_A such that A has a fixed 
value in this state: If we repeat the experiment several times, each time
measuring A, we will always obtain the same measurement result,
without any random behaviour.
Such pure states \sigma_A are called eigenstates of A.
However, it is  impossible to prepare a simultaneous eigenstate 
for all observables. For example, we cannot prepare a state 
such that both the position measurement Q(t) 
and the momentum measurement P(t) 
(at the same time t) produce "sharp" results;
at least one of them will exhibit random behaviour.
This is the content of the Heisenberg uncertainty relation.
Moreover, in contrast to classical mechanics, it is unavoidable that
performing a measurement on the system generally changes its state.
More precisely: After measuring an observable A, 
the system will be in an eigenstate of A; thus the state has changed, unless the system was already in that eigenstate.
This expresses a kind of logical consistency: If we measure A twice in the same 
run of the experiment, the measurements being directly consecutive in time, then they will 
produce the same results. This has some strange consequences however:
Consider two observables, A and B, where A corresponds
to a measurement earlier in time than B. 
Suppose that the system is in an eigenstate of B.
If we measure only B, we will not notice statistical behaviour.
If we measure first A and then B in the same run of the experiment,
the system will transfer to an eigenstate of A after the first measurement,
and we will generally notice that the results of B are statistical.
Thus, quantum mechanical measurements influence one another, and it is important
in which order they are performed.
Another feature of quantum states becomes relevant if we consider a physical system that
consists of multiple subsystems; for example, an experiment with two particles rather than one.
Quantum physics allows for certain states, called entangled states,
that show certain statistical correlations between measurements on the two particles
which cannot be explained by classical theory. For details, see entanglement.
These entangled states lead to experimentally testable properties (Bell's theorem)
that allow to distinguish between quantum theory and alternative classical (non-quantum) models.

## Schrodinger picture vs. Heisenberg picture
In the discussion above, we have taken the observables P(t), Q(t)
to be dependent on time, while the state \sigma was fixed once at the beginning of the experiment.
This approach is called the Heisenberg picture. One can, equivalently, treat the observables as fixed,
while the state of the system depends on time; that is known as the Schrodinger picture.
Conceptually (and mathematically), both approaches are equivalent; choosing one of them is a matter of convention.
Both viewpoints are used in quantum theory. While non-relativistic quantum mechanics is usually formulated
in terms of the Schrodinger picture, the Heisenberg picture is often preferred in a relativistic context,
that is, for quantum field theory.

# Formalism in quantum physics

## Pure states as rays in a Hilbert space
Quantum physics is most commonly formulated in terms of linear algebra, as follows. Any given system is identified with some Hilbert space, such that each vector in the Hilbert space (apart from the origin) corresponds to a pure quantum state. In addition, two vectors that differ only by a nonzero complex scalar correspond to the same state (in other words, each pure state is a ray in the Hilbert space).
Alternatively, many authors choose to only consider normalized vectors (vectors of norm 1) as corresponding to quantum states. In this case, the set of all pure states corresponds to the unit sphere of a Hilbert space, with the proviso that two normalized vectors correspond to the same state if they differ only by a complex scalar of absolute value 1 (called a phase factor).

## Bra-ket notation
Calculations in quantum mechanics make frequent use of linear operators, inner products, dual spaces, and Hermitian conjugation. In order to make such calculations more straightforward, and to obviate the need (in some contexts) to fully understand the underlying linear algebra, Paul Dirac invented a notation to describe quantum states, known as bra-ket notation. Although the details of this are beyond the scope of this article (see the article Bra-ket notation), some consequences of this are:
- The variable name used to denote a vector (which corresponds to a pure quantum state) is chosen to be of the form |\psi\rangle (where the "\psi" can be replaced by any other symbols, letters, numbers, or even words). This can be contrasted with the usual mathematical notation, where vectors are usually bold, lower-case letters, or letters with arrows on top.
- Instead of vector, the term ket is used synonymously.
- Each ket |\psi\rangle is uniquely associated with a so-called bra, denoted \langle\psi|, which is also said to correspond to the same physical quantum state. Technically, the bra is an element of the dual space, and related to the ket by the Riesz representation theorem.
- Inner products (also called brackets) are written so as to look like a bra and ket next to each other: \lang \psi_1|\psi_2\rang. (Note that the phrase "bra-ket" is supposed to resemble "bracket".)

## Spin, Many-body states
It is important to note that in quantum mechanics besides, e.g., the usual position variable \mathbf r, a discrete variable m exists, corresponding to the value of the z-component of the spin vector. This is some kind of intrinsic angular momentum, which does, however, not appear at all in classical mechanics and is in fact a legacy from Dirac's relativistic generalization of the theory. As a consequence, the quantum state of a system of N particles is described by a function with four variables per particle, e.g.
|\psi (\mathbf r_1,m_1;\dots ;\mathbf r_N,m_N)\rangle. Here, the variables m assume values from the set {-S_\nu, -S_\nu +1, ..., +S_\nu -1,+S_\nu}, where S_\nu  (in units of Planck's reduced constant \hbar), is either a non-negative integer (0,1,2...; bosons), or semi-integer (1/2,3/2,5/2,...; fermions). Moreover, in the case of identical particles, the above N-particle function must either be symmetrized (in the bosonic case) or anti-symmetrized (in the fermionic case) w.r.t. the particle numbers.
Electrons are fermions with S=1/2, photons (quanta of light) are bosons with S=1.
Apart from the symmetrization or anti-symmetrization,  N-particle states can thus simply be obtained by tensor products of one-particle states, to which we return herewith.

## Basis states of one-particle systems
As with any vector space, if a basis is chosen for the Hilbert space of a system, then any ket can be expanded as a linear combination of those basis elements. Symbolically, given basis kets |k_i\rang, any ket |\psi\rang can be written
where ci are complex numbers. In physical terms, this is described by saying that |\psi\rang has been expressed as a quantum superposition of the states |k_i\rang. If the basis kets are chosen to be orthonormal (as is often the case), then c_i=\lang k_i|\psi\rang.
One property worth noting is that the normalized states |\psi\rang are characterized by
Expansions of this sort play an important role in measurement in quantum mechanics. In particular, If the |k_i\rang are eigenstates (with eigenvalues k_i) of an observable, and that observable is measured on the normalized state |\psi\rang, then the probability that the result of the measurement is ki is |ci|2. (The normalization condition above mandates that the total sum of probabilities is equal to one.)
A particularly important example is the position basis, which is the basis consisting of eigenstates of the observable which corresponds to measuring position. If these eigenstates are nondegenerate (for example, if the system is a single, spinless particle), then any ket |\psi\rang is associated with a complex-valued function of three-dimensional space:
This function is called the wavefunction corresponding to |\psi\rang.

## Superposition of pure states
One aspect of quantum states, mentioned above, is that superpositions of them can be formed. If |\alpha\rangle and |\beta\rangle are two kets corresponding to quantum states, the ket
is a different quantum state (possibly not normalized). Note that which quantum state it is depends on both the amplitudes and phases (arguments) of c_\alpha and c_\beta. In other words, for example, even though |\psi\rang and e^{i\theta}|\psi\rang (for real ) correspond to the same physical quantum state, they are not interchangeable, since for example |\phi\rang+|\psi\rang and |\phi\rang+e^{i\theta}|\psi\rang do not (in general) correspond to the same physical state. However, |\phi\rang+|\psi\rang and e^{i\theta}(|\phi\rang+|\psi\rang) do correspond to the same physical state. This is sometimes described by saying that "global" phase factors are unphysical, but "relative" phase factors are physical and important.
One example of a quantum interference phenomenon that arises from superposition is the double-slit experiment. The photon state is a superposition of two different states, one of which corresponds to the photon having passed through the left slit, and the other corresponding to passage through the right slit. The relative phase of those two states has a value which depends on the distance from each of the two slits. Depending on what that phase is, the interference is constructive at some locations and destructive in others, creating the interference pattern.
Another example of the importance of relative phase in quantum superposition is Rabi oscillations, where the relative phase of two states varies in time due to the Schrodinger equation. The resulting superposition ends up oscillating back and forth between two different states.

## Mixed states
A pure quantum state is a state which can be described by a single ket vector, as described above.  A mixed quantum state is a statistical ensemble of pure states (see quantum statistical mechanics).
A mixed state cannot be described as a ket vector. Instead, it is described by its associated density matrix (or density operator), usually denoted \rho. Note that density matrices can describe both mixed and pure states, treating them on the same footing.
The density matrix is defined as
where p_s is the fraction of the ensemble in each pure state |\psi_s\rangle. Here, one typically uses a one-particle formalism to describe the average behaviour of a N-particle system.
A simple criterion for checking whether a density matrix is describing a pure or mixed state is that the trace of 2 is equal to 1 if the state is pure, and less than 1 if the state is mixed. Another, equivalent, criterion is that the von Neumann entropy is 0 for a pure state, and strictly positive for a mixed state.
The rules for measurement in quantum mechanics are particularly simple to state in terms of density matrices. For example, the ensemble average (expectation value) of a measurement corresponding to an observable A is given by
where |\alpha_i\rangle, \; a_i are eigenkets and eigenvalues, respectively, for the operator A, and tr denotes trace. It is important to note that two types of averaging are occurring, one being a quantum average over the basis kets |\psi_s\rangle  of the pure states, and the other being a statistical average with the probabilities p_s  of those states.
W.r.t. these different types of averaging, i.e. to distinguish pure and/or mixed states, one   often uses the expressions 'coherent' and/or 'incoherent superposition' of quantum states.

# Mathematical formulation
For a mathematical discussion on states as functionals, see Gelfand-Naimark-Segal construction. There, the same objects are described in a Calgebraic context.

# Notes
-  If you are not familiar with the concept of momentum, think of it as being the velocity of the particle. That is fully justified in this context.
-  To avoid misunderstandings: Here we mean that Q(t) and P(t) are measured in the same state, but not in the  same run of the experiment.)
-  For concreteness' sake, you may suppose that A=Q(t_1) and B=P(t_2) in the above example, with t_2>t_1>0.