Averaged variables giving NaN?? Plz help

NaN means not a number, basically you are trying to use a number that is not acceptable, not a legal number.