2014-05-31 19:12:21 +02:00
|
|
|
#include <triqs/gfs.hpp>
|
|
|
|
using namespace triqs::gfs;
|
|
|
|
int main() {
|
|
|
|
double beta = 1, a = 1;
|
|
|
|
int N = 10000;
|
2014-07-03 19:47:48 +02:00
|
|
|
auto gw = gf<imfreq>{{beta, Fermion, N/2}, {1, 1}};
|
2014-05-31 19:12:21 +02:00
|
|
|
auto gt = gf<imtime>{{beta, Fermion, N}, {1, 1}};
|
|
|
|
|
|
|
|
triqs::clef::placeholder<0> om_;
|
|
|
|
gw(om_) << 1 / (om_ - a);
|
|
|
|
|
|
|
|
// fills a full *view* of gt with the contents of the FFT
|
|
|
|
gt() = inverse_fourier(gw);
|
|
|
|
|
2014-07-03 19:47:48 +02:00
|
|
|
// make a new fresh gf from the FFT of gt with a mesh of size N/2
|
|
|
|
auto gw2 = make_gf_from_fourier(gt, N/2);
|
2014-05-31 19:12:21 +02:00
|
|
|
}
|
|
|
|
|