Contra vs covariant
The concept of covariant and contravariant quantities is very important in tensor calculus, but as far as I can tell, the concept usually isn't explained very well in most physics classes. I'll try to remedy that here. I will provide a vague conceptual motivation, then I'll illustrate the principle with a demonstration, define the two terms mathematically, and give explicit examples of covariant and contravariant vectors.
First, I should address a possible source of confusion caused by sloppy vocabulary. The word "covariant" has two meanings: (1) The mathematical meaning explained here, and (2) the physical idea of invariance under some transformation. When we say that we are formulating a covariant theory, we typically mean that the theory is Lorentz invariant. Also, the "covariant derivative" is an invariant derivative. This sloppy vocabulary can be rather confusing because it enables nonsensical phrases like "contravariant vectors and covariant vectors are both covariant." One way of clearing this up is to refer to quantities which transform covariantly as differential forms or "n-forms." For instance, a covariant vector is a rank-one covariant tensor and thus it is also referred to as a one-form. A covariant tensor of rank two is called a two-form, and so on. So, rather than saying "contravariant vectors and covariant vectors are both covariant," we can say "vectors and one-forms are both Lorentz invariant."
The motivating concept
I'll start with an imprecise (and somewhat misleading) illustration to motivate the difference between covariance and contravariance. Suppose you wish to compute the components of a vector, , in a coordinate system that is rotated with respect to your preferred coordinate system. Conceptually, you have two options:
Option 1: Maintain a single coordinate system, , and physically rotate the vector so that it has new components in . In this case, the vector changes because its orientation in space has changed; it becomes .
Option 2: Keep the vector fixed in space and transform the coordinate system from to . The components of in the basis are the same as the components of in the basis. The two situations are illustrated below.
The point is that the rotation occurs in opposite directions depending on whether the vector or the coordinate system (the basis) has been rotated. In a sense, the two cases are inverses of one another. The above discussion is misleading, since one of the operations actually changed the position vector by physically rotating it. It was only meant to illustrate a situation in which the components of a vector and the basis vectors of a coordinate system change in opposite ways.
Now we address the full concept. We use a non-orthogonal coordinate system because the difference between covariance and contravariance becomes much more obvious in this case. We show that a vector P can be represented using two different conventions. In the covariant convention, we use the coordinates . We draw lines from the tip of the vector to the axes such that the lines intersect the axes X1 and X2 perpendicularly. The value of X1 and X2 at the points of intersection give us and . In the contravariant convention, we use coordinates . We draw lines parallel to the coordinate axes. The points at which these parallel lines intersect X1 and X2 give us and .Thus, we have two representations for the same vector in which the components of the vector are different because they were found using different (parallel and perpendicular) conventions. In a Cartesian coordinate system, the two conventions are of course identical. If we now consider how these two different types of coordinates transform under a rotation, it should be obvious that the coordinates transform differently. The difference is analogous to the rotations discussed above. This discussion is still somewhat misleading because we have focussed on the coordinate systems. A more fundamental discussion can be found in section 2.5 of the book, Gravitation by Misner, Thorne, and Wheeler.
A comment on notation is in order here. By convention, contravariant coordinates are written with the upper index notation while the covariant coordinates are denoted by lowered indices
A DemonstrationIn order to demonstrate the concept, suppose there are two coordinate systems, and , with basis vectors given by and respectively. Note that the basis vectors have been written with the covariant (lower index) notation. Let the transformation between these two sets of basis vectors be given by
A vector in the unprimed basis is given by
Where the are the scaler components of the vector with respect to the unprimed basis. Notice that the components have been written with the contravariant (upper index) notation. The vector can also be written in the primed basis as
The two expressions for are equivalent, so
this can be written as
Since the basis vectors are linearly independent, the term in parentheses vanishes separately for each value of the index i, which implies
where is the inverse of . Therefore, the transformation rule for the coordinates is in a sense the opposite of the transformation rule for the basis vectors:
We say that the components transform contravariantly while the basis vectors transform covariantly. Next we will see how to find the transformation coefficients and .
DefinitionsSuppose that we know the explicit form of the change of coordinates from system to ,
and the inverse
A contravariant vector is defined by the transformation property:
A covariant vector is defined by
ExamplesExample 1: Contravariance
The tangent vector to a curve is a contravariant vector. Let the curve be given by the parameterization
The tangent vector to the curve is
Under a change of coordinates, the curve is
and the tangent vector is
By the chain rule,
which shows that the tangent vector transforms contravariantly and thus it is a contravariant vector. Example 2: Covariance
The gradient of a scalar field is a covariant vector field. Let be a scalar field. Let the gradient of be the vector field
In the primed coordinate system, the gradient is
By the chain rule,
which shows that the gradient is a covariant vector.
Concluding remarks and generalizations
In general, most things that we think of as vectors, such as a position or displacement, are contravariant vectors. These are represented as column vectors in linear algebra. Covariant vectors, or one-forms, are represented by row vectors in linear algebra. It may also be helpful to realize that contravariant vectors are associated with kets in the language of quantum mechanics while covariant vectors are associated with bras
The inner product of a vector with itself forms a scalar:
In order to change a contravariant vector into a one-form or vise-versa (so that we can compute the inner product), we use the metric tensor as a lowering or raising operator:
The definition of contravariant tensor of rank- is a simple generalization. For instance, a rank-2 contravariant tensor has the transformation property
and a two-form transforms as
Finally, a mixed tensor transforms as