Fourier3 function in star basic

Hello,
I defined la function “Fourier3” but I don’t understand becouse the results ( in yellow) is costant for each value of x (light blue): this is not correct

Can You Help me?

Thank you

Fourier3.ods

Please set the number of decimal places in cells’ format to 4 or more to see the difference.