Linear Algebra Methods for Data Mining with Applications to Materials Science