My Matlab FFT plot keeps showing the mirrored values of my frequency of interest. In this example I am looking for 250Hz with a 3200Hz sampling freq. The FFT plots my value at 266Hz as well as 1330 Hz. I assume my sampling freq is a little off which is why it isn't exactly at 250Hz. Matlab code is below, any help is appreciated.
% Tmax = (N-1)*Ts % largest freq = Fs/2 % smalles = -fs/2 fid = fopen('250Hz.bin'); AA = fread(fid, 'short'); length(AA); flenbytes = ftell(fid); flenshorts = floor(flenbytes/2); FF = floor(flenshorts/16)*16; fseek(fid,0, 'bof'); BB = fread(fid, [8 (FF/8)], 'short'); CC = BB'; DataSet = CC ./2^3; Z1Axis = DataSet(:,4); N = length(DataSet) Fs = 3200; ts = 1/Fs; tmax = (N-1)*ts; t = 0:ts:tmax; %start at 0 increment by ts up to tmax plot(t,Z1Axis) f = (0:N-1)*(Fs/N)/2; % start with -Fs/2, increment by Fs/(N-1), goes to Fs/2 z = fft(Z1Axis); %zreal = %plot(f,z) plot(f,abs(z));