Getting frequencies out of a FFT
At this moment i'm not hos i can't check my answer...
You say


  In the output array I get amplitudes of sin and cos functions.


Well that is you frequency array. Probably not the way want it. I suspect youre looking for the magnitude and maybe the phase.

the magnitude is quite easy.. it is the $abs(array (real + imag)$.
the phase $ \phi = \arctan \frac{imag}{real} $

in this way it is common to show the half the frequency array because of it's symmetry.
if you plot $array[0]$ to $array[N/2]$ you shoult get your frequecy array from $ \frac{1}{N}$ to $\frac{F_s}{2}$