Principal component analysis (PCA) is a statistical procedure that uses an orthogonal transformation to convert a set of observations of possibly correlated variables into a set of values of linearly uncorrelated variables called principal components. It's often used to make data easy to explore and visualize.
PCA is mathematically defined as an orthogonal linear transformation that transforms the data to a new coordinate system such that the greatest variance by some projection of the data comes to lie on the first coordinate (called the first principal component), the second greatest variance on the second coordinate, and so on.
Here is a very good source of PCA including presentation and source code Presentation Principal Component Analysis (PCA) : An Overview Article Principal component analysis - a tutorial Alaa