Computing Mixture Fraction and Progress Variable using UDF

How to access Mixture Fraction and Progress Variable using UDF?

The mean mixture fraction and progress variable can be accessed for UDF at the cell level using C_FMEAN(c,t) and C_PREMIXC(c,t)