Page MenuHomec4science

fftw_engine_c2c.hh
No OneTemporary

File Metadata

Created
Mon, Sep 9, 20:57

fftw_engine_c2c.hh

/**
* file fftw_engine_c2c.hh
*
* @author Till Junge <till.junge@epfl.ch>
*
* @date 11 May 2017
*
* @brief implementaion of fft_engine using redundant c2c fftw transform
*
* @section LICENCE
*
* Copyright (C) 2017 Till Junge
*
* µSpectre is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation, either version 3, or (at
* your option) any later version.
*
* µSpectre is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GNU Emacs; see the file COPYING. If not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#include "system/fft_engine.hh"
#include <fftw3.h>
#ifndef FFTW_ENGINE_C2C_H
#define FFTW_ENGINE_C2C_H
namespace muSpectre {
template <Dim_t DimS, Dim_t DimM>
class FFTW_EngineC2C: public FFT_Engine<DimS, DimM> {
public:
using Index = Index_t<DimS>;
FFTW_EngineC2C(Index nb_pixels);
virtual ~FFTW_EngineC2C();
virtual void init(FFT_PlanFlags flags) override;
virtual Real * convolve(const Real * const Ghat, const Real * const arr) override;
protected:
fftw_complex * i_work_space, * o_work_space;
fftw_plan plan_fft;
fftw_plan plan_ifft;
};
} // muSpectre
#endif /* FFTW_ENGINE_C2C_H */

Event Timeline