Skip to content
Extraits de code Groupes Projets
mfft_real_ter.Rd 1,37 ko
Newer Older
  • Learn to ignore specific revisions
  • Michel Crucifix's avatar
    Michel Crucifix a validé
    % Generated by roxygen2: do not edit by hand
    % Please edit documentation in R/mfft_real_ter.R
    \name{mfft_real_ter}
    \alias{mfft_real_ter}
    \title{Modified Fourier transform  for real series (variant)}
    \usage{
    mfft_real_ter(xdata, nfreq = 5, correction = 1, fast = TRUE)
    }
    \arguments{
    \item{xdata}{The data provided either as a time series (advised), or as a vector.}
    
    \item{nfreq}{is the number of frequencies returned, must be smaller that the length of  xdata.}
    
    \item{fast}{(default = TRUE) uses analytical formulations for the crossproducts involving sines and cosines}
    
    \item{correction:}{0: no frequency correction (equivalent to Laskar); 1 : frequency correction using linear approximation ; 2: frequency correction using sythetic data}
    }
    \description{
    R-coded version of the Modified Fourier Transform
    with frequency  correction, adapted to R. 
    much slower than mfft (for complex numbers) as the latter is
    mainly written in C, but is physically
    more interpretable if signal is real, because
    it is designed to have no imaginary part in the residual
    A C-version should be supplied one day.
    }
    \examples{
    
    set.seed(12413)
    t = seq(1024)
    x_orig = cos(t*0.13423167+0.00) + 1.3 * cos(t*0.119432+2.314) + 0.134994 + 0.4*cos(t*0.653167) + 0.11 * cos(t*0.78913498) + rnorm(1024)*0.12
    OUT <- mfft_real(x_orig)
    print(OUT)
    
    }
    \references{
    \insertRef{sidlichovsky97aa}{gtseries}
    }
    \author{
    Michel Crucifix
    }