fftphase-func
Calculate phase from FFT complex result.
vector fftphase(vector<complex> cx, int side = 1, int unwrap = 1, int unit = 1)
cx
side
unwrap
unit
Return the phase
// Import the signal data string fname$ = system.path.program$ + "Samples\Signal Processing\fftfilter1.DAT"; impASC fname:=fname$; // Define a range variable for input signal range rSignal = col(2); // Add two new columns to store the amplitude results (one-sided, two-sided) worksheet -a 2; // Set column labels to distinguish col(C)[L]$ = "Phase"; col(C)[C]$ = "One-Sided"; col(D)[L]$ = "Phase"; col(D)[C]$ = "Two-Sided"; // First use fftc to get FFT complex result // Then use fftphase to get magnitude in column C and D col(C) = fftphase(fftc(rSignal));// One-Sided col(D) = fftphase(fftc(rSignal), 2, 0, 0);// Two-Sided, not unwrapped and with radian unit
fftamp