Hi folks. I'm new to using C and the math functions, and am having some trouble with the exp() function. I have a statement in my arduino program like this:

K = 1 - exp(-2*pi*C/S);

where K is a double, and pi, C, and S are defined elsewhere and are floats. Unfortunately no matter what values I use for C and S for some reason K always comes out as 0. Even when I do something like:

double stuff = -2*pi*C/S;

K = 1 - exp(stuff);

I still have the same problem. Does anyone have any ideas? Thanks in advance!