1 #define f1(i) ((i)*(i))
2 #define I2(f, n) f(n) + f(n+1)
3 #define I3(f, n) I2(f, n) + f(n+2)
5 #define FL_f1(i) ((i)*(i))
6 #define FL_I2(f, n) f(n) + f(n+0.2)
7 #define FL_I3(f, n) FL_I2(f, n) + f(n+0.5)
17 highp float fl_f5 = FL_I3(FL_f1, 0.1);
21 // = I2(f1, 0) + f1(0 + 2)
22 // = f1(0) + f1(0+1) + f1(0+2)
26 // fl_f5 = FL_I3(FL_f1, 0.1)
27 // = FL_I2(FL_f1, 0.1) + FL_f1(0.1 + 0.5)
28 // = FL_f1(0.1) + FL_f1(0.1 + 0.2) + FL_f1(0.1 + 0.5)
29 // = 0.1*0.1 + 0.3*0.3 + 0.6*0.6