Error is simple.....the variables Ro2, Rn2 are scalars i.e. they are constants and they have sinlge value. In the line:
C(i) = ((0.21)*(Cpo2(i)) + (0.79)*(Cpn2(i)))./((0.2*Ro2(i))+(0.79*Rn2(i)));
You tried accessing Ro2, Rn2 as an array. So, when loop takes i = 2, Ro2(2) do not exist, thus error pops. You need to think of your code.