From 5be8c8533a71476c198f5157a77f6a7fe7463021 Mon Sep 17 00:00:00 2001 From: Guillaume Courrier Date: Tue, 26 Nov 2019 13:45:25 +0100 Subject: [PATCH] =?UTF-8?q?Impl=C3=A9mentation=20de=20la=20fonction=20coef?= =?UTF-8?q?2cont?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- presentation/presentation.tex | 0 rapport/rapport.tex | 0 tests/src/math.hpp | 21 ++++++++++++++++++--- 3 files changed, 18 insertions(+), 3 deletions(-) create mode 100644 presentation/presentation.tex create mode 100644 rapport/rapport.tex diff --git a/presentation/presentation.tex b/presentation/presentation.tex new file mode 100644 index 0000000..e69de29 diff --git a/rapport/rapport.tex b/rapport/rapport.tex new file mode 100644 index 0000000..e69de29 diff --git a/tests/src/math.hpp b/tests/src/math.hpp index fbfaf00..46bcb99 100644 --- a/tests/src/math.hpp +++ b/tests/src/math.hpp @@ -33,11 +33,17 @@ namespace math { return complex(res.real()/sig.size(), res.imag()/sig.size()); }; + //TODO: implémenter la fonction + csignal diff(const csignal& input, complex mean) { + return csignal(); + } + //TODO implémenter la fft csignal fft_rec(const csignal& input) { int size = input.size(); if (size == 1) { + //TODO: que faire dans ce cas ? return csignal(); } else { csignal odd; @@ -79,10 +85,18 @@ namespace math { contour cont; auto tf_it = tfd.begin(); auto cont_it = cont.begin(); + //TODO: trouver les bonnes valeurs + int kmin = 0; + int kmax = 2*cmax; - for (auto tf_it = tfd.begin(); tf_it != tfd.end(); ++tf_it) { - //TODO retrouver la formule - //*cont_it = mean + ...; + for (int m=0; m