Homogeneity Quantification Method and its Application to Microstructure Assessment