Digital Refractive Index Measurement Principle and