Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
---
title: "Rapport Math"
author: [Troller Fabian, Rivier Nicolas]
date: "2022-04-25"
keywords: [Math, Intégrales]
...
# Introduction Génerale
# Introduction théorique
## Intégration numérique
On définit une fonction **f(x)**,
\begin{equation}
f(x)=-\frac{2x-1}{\exp(x^2-x+2)},
\end{equation}
Ou l'on veut calculer son intégration entre un intervalle de **[a,b]** a un certain **N** d'approximation.
\begin{equation}
I(a,b,N,f(x))=\sum_{i=0}^{N-1} f(a+i\delta x)\delta x,\quad \delta x=\frac{b-a}{N}.
\end{equation}
Afin de pouvoir faire une comparaison d'erreur entre la solution numerique et analytique nous allons prendre la meme intervalle **[a,b]** $=$ **[1,5]**
## Intégration analytique
Afin de valider notre intégration analytique et étudié l'erreur en fonction du **N** nombre d'intervalle.
Nous allons calculer la solution analytique de notre fonction.
\begin{equation}
f(x)=-\frac{2x-1}{\exp(x^2-x+2)},
\end{equation}
\begin{equation}
I=\int_a^b f(x)*dx = -\frac{2x-1}{\exp(x^2-x+2)}\mathrm{d}x.
\end{equation}
pour un intervalle [1,5].
\begin{equation}
\int_1^5 -\frac{2x-1}{e^{(-x^2+x-2)}}
\end{equation}
\begin{equation}
\int_1^5 -(2x-1) * \frac{1}{e^{(-x^2+x-2)}}
\end{equation}
\begin{equation}
\int_1^5 (-2x+1) * e^{(-x^2+x-2)^{-1}}
\end{equation}
\begin{equation}
\int_1^5 (-2x+1) * e^{(-x^2+x-2)}
\end{equation}
Déterminer la transformée en u
\begin{equation}
\int_1^5 du * e^u
\end{equation}
\begin{equation}
u = f(x) = -x^2+x-2
\end{equation}
\begin{equation}
du = F{(x)}'= -2x+1
\end{equation}
\begin{equation}
\int_1^5 e^u * du = \mid_1^5 e^{(-x^2+x-2)}
\end{equation}
selon
\begin{equation}
\mid_a^b f(x) = f(b) - f(a)
\end{equation}
on obtient
\begin{equation}
\mid_1^5 e^{(-x^2+x-2)} = e^{-5^2+5-2} - e^{-1^2+1-2}
\end{equation}
\begin{equation}
e^{-25+5-2} - e^{-1+1-2} = e^{-22} - e^{-2}
\end{equation}
finalement
\begin{equation}
I = \frac {1}{e^{22}} - \frac {1}{e^{2}} = -0,135335283
\end{equation}
## Validation
Afin de comparer nos résultats nous allons varier **N** de 5,10,50,100,500,1000 pour une même intervalle a b $=$ **[1,5]** et calculer l'erreur de notre résultat numérique par rapport à la solution analytique.
\begin{equation}
E(N)=\left|\frac{I-I(a,b,N,f(x))}{I}\right|
\end{equation}
")
# Convolutions et filtrage
Afin de se familiariser avec les convolutions, nous allons filtrer des signaux à 1 dimension.
Pour cela nous définition un signal composé de deux signaux avec chacun une fréquence différents w1 et w2.
\begin{equation}
s(x)=\sin(2\pi\omega_1 x)+\sin(2\pi\omega_2 x).
\end{equation}
et un certain filtre
\begin{equation}
f(x)=\left\{\begin{array}{ll}
\frac{1}{\psi},&\mbox{ si }x\in[-\psi/2,\psi/2]\\
0,&\mbox{ sinon.}
\end{array}\right.
\end{equation}
Le but est de déterminer l'intervalle du filtre
\begin{equation}
[-\psi/2,\psi/2]
\end{equation}
afin que la convolution de ces deux fonctions (f*s)(x) annule une des deux composantes sinusoïdales du signal.
## Solution analytique
### Délimitation
La convolution de deux fonctions est définie de la sorte:
\begin{equation}
\int_{-\infty }^{\infty} S(x - t)*f(x)dt
\end{equation}
On va développer dans les intervalles que nous recherchons.
\begin{equation}
\int_{-\infty }^{-\psi/2} S(x - t)*f(x)dt + \int_{-\psi/2 }^{\psi/2} S(x - t)*f(x)dt + \int_{\psi/2 }^{\infty} S(x - t)*f(x)dt
\end{equation}
En observant f(x) on constate que dans l'intervalle [-psi/2, psi/2] f(x) vaut 1/psi sinon 0 :
\begin{equation}
f(x)=\left\{\begin{array}{ll}
\frac{1}{\psi},&\mbox{ si }x\in[-\psi/2,\psi/2]\\
0,&\mbox{ sinon.}
\end{array}\right.
\end{equation}
donc notre domaine de convolution recherché s’étant a
\begin{equation}
\int_{-\psi/2 }^{\psi/2} S(x - t)*f(x)dt = \int_{-\psi/2 }^{\psi/2} (\sin(2\pi\omega_1 (x - t))+\sin(2\pi\omega_2 (x - t))) * \frac{1}{\psi} dt
\end{equation}
### Transformée primaire
On cherche à déterminer la dérivée primaire du sinus et de sa composante par la factorisation de primitive en fonction de t :
\begin{equation}
f(g(t))' = f'(g(t))*g'(t)
\end{equation}
pour :
\begin{equation}
\int \sin(2\pi\omega(x-t)dt
\end{equation}
\begin{equation}
f(t) = sin(x) \quad étant \quad f'(t) = -cos(x)
\end{equation}
\begin{equation}
g(t) = 2\pi\omega(x-t) \quad étant \quad g'(t) = 2\pi\omega*0 - 2\pi\omega*1 = - 2\pi\omega
\end{equation}
Ce qui nous donne:
\begin{equation}
\int \sin(2\pi\omega(x-t)dt \neq -\cos(2\pi\omega(x-t) * -2\pi\omega
\end{equation}
Donc pour y remédier on multiplie par 1 l’intégrale:
\begin{equation}
\frac{-2\pi\omega}{-2\pi\omega} = 1
\end{equation}
\begin{equation}
\frac{-2\pi\omega}{-2\pi\omega} * \int \sin(2\pi\omega(x-t)dt = \frac{-2\pi\omega}{-2\pi\omega} * -\cos(2\pi\omega(x-t) * -2\pi\omega
\end{equation}
Ce qui nous donne finalement comme résultat:
\begin{equation}
\int \sin(2\pi\omega(x-t)dt = \frac{-\cos(2\pi\omega(x-t)}{-2\pi\omega} = \frac{\cos(2\pi\omega(x-t)}{2\pi\omega}
\end{equation}
#### Transformée primaire de l’intégral au complet
\begin{equation}
\int_{-\psi/2 }^{\psi/2} (\sin(2\pi\omega_1 (x - t))+\sin(2\pi\omega_2 (x - t))) * \frac{1}{\psi} dt
\end{equation}
\begin{equation}
\mid_{-\psi/2 }^{\psi/2} (\frac{\cos(2\pi\omega_1(x-t))}{2\pi\omega_1} + \frac{\cos(2\pi\omega_2(x-t))}{2\pi\omega_2}) * \frac{1}{\psi}
\end{equation}
Distribution des constante et factoriser au mème dénominateur commun:
\begin{equation}
\mid_{-\psi/2 }^{\psi/2} \frac{\cos(2\pi\omega_1(x-t))}{2\pi\omega_1\psi} + \frac{\cos(2\pi\omega_2(x-t))}{2\pi\omega_2\psi}
\end{equation}
\begin{equation}
\mid_{-\psi/2 }^{\psi/2} \frac{\cos(2\pi\omega_1(x-t))}{2\pi\omega_1\psi}*\frac{\omega_2}{\omega_2} + \frac{\cos(2\pi\omega_2(x-t))}{2\pi\omega_2\psi}*\frac{\omega_1}{\omega_1}
\end{equation}
\begin{equation}
\mid_{-\psi/2 }^{\psi/2} \frac{\cos(2\pi\omega_1(x-t))\omega_2 + \cos(2\pi\omega_2(x-t))\omega_1}{2\pi\omega_1\omega_2\psi}
\end{equation}
### Distribution de la constante de temps
Selon la règle:
\begin{equation}
\mid_{\pi}^{-\pi} f(x-t) = f(x-\pi) - f(x+\pi)
\end{equation}
Notre convolution devient:
\begin{equation}
\mid_{-\psi/2 }^{\psi/2} \frac{\cos(2\pi\omega_1(x-t))\omega_2 + \cos(2\pi\omega_2(x-t))\omega_1}{2\pi\omega_1\omega_2\psi}
\end{equation}
\begin{equation}
= \frac{\cos(2\pi\omega_1(x-\psi/2))\omega_2 + \cos(2\pi\omega_2(x-\psi/2))\omega_1}{2\pi\omega_1\omega_2\psi} - \frac{\cos(2\pi\omega_1(x+\psi/2))\omega_2 + \cos(2\pi\omega_2(x + \psi/2))\omega_1}{2\pi\omega_1\omega_2\psi}
\end{equation}
\begin{equation}
= \frac{\cos(2\pi\omega_1(x-\psi/2))\omega_2 + \cos(2\pi\omega_2(x-\psi/2))\omega_1 - \cos(2\pi\omega_1(x+\psi/2))\omega_2 - \cos(2\pi\omega_2(x + \psi/2))\omega_1}{2\pi\omega_1\omega_2\psi}
\end{equation}
### Regroupement des variables communes
Pour simplifier, je regroupe la formule en différentes parties :
\begin{equation}
\frac{A + B}{C}
\end{equation}
\begin{equation}
A = \cos(2\pi\omega_1(x-\psi/2))\omega_2 - \cos(2\pi\omega_1(x+\psi/2))\omega_2
\end{equation}
\begin{equation}
B = \cos(2\pi\omega_2(x-\psi/2))\omega_1 - \cos(2\pi\omega_2(x + \psi/2))\omega_1
\end{equation}
\begin{equation}
C = 2\pi\omega_1\omega_2\psi
\end{equation}
### Règles de transformation sinusoïdal
Selon une des régles de transformation de somme en produit du sinus:
\begin{equation}
cos(p) - cos(q) = - 2 sin(\frac{p+q}{2}) sin(\frac{p-q}{2})
\end{equation}
Nous allons appliquer cette régle sur A et B
\begin{equation}
A = \cos(2\pi\omega_1(x-\psi/2))\omega_2 - \cos(2\pi\omega_1(x+\psi/2))*\omega_2
\end{equation}
\begin{equation}
(\cos(2\pi\omega_1(x-\psi/2)) - \cos(2\pi\omega_1(x+\psi/2)))*\omega_2
\end{equation}
\begin{equation}
- 2 sin(\frac{2\pi\omega_1(x-\psi/2) + 2\pi\omega_1(x+\psi/2))}{2}) sin(\frac{2\pi\omega_1(x-\psi/2) - 2\pi\omega_1(x+\psi/2)}{2})*\omega_2
\end{equation}
\begin{equation}
- 2 sin(\frac{2\pi\omega_1((x-\psi/2)+(x+\psi/2))}{2}) sin(\frac{2\pi\omega_1((x-\psi/2) - (x+\psi/2))}{2})*\omega_2
\end{equation}
\begin{equation}
- 2 sin(\frac{2\pi\omega_1(2x)}{2}) sin(\frac{2\pi\omega_1(-2*\psi/2) )}{2})*\omega_2
\end{equation}
\begin{equation}
- 2 sin(\pi\omega_1(2x)) sin(\pi\omega_1(-\psi)))*\omega_2
\end{equation}
\begin{equation}
- 2 sin(2\pi\omega_1x) sin(-\pi\omega_1\psi)*\omega_2
\end{equation}
Puis sur B de la même façon.
\begin{equation}
B = \cos(2\pi\omega_2(x-\psi/2))\omega_1 - \cos(2\pi\omega_2(x + \psi/2))\omega_1
\end{equation}
\begin{equation}
(\cos(2\pi\omega_2(x-\psi/2)) - \cos(2\pi\omega_2(x + \psi/2)))*\omega_1
\end{equation}
\begin{equation}
...
\end{equation}
\begin{equation}
- 2 sin(2\pi\omega_2x) sin(-\pi\omega_2\psi)*\omega_1
\end{equation}
### Finalement en rassemblant A,B et C nous obtenont
\begin{equation}
\frac{- 2 sin(2\pi\omega_1x) sin(-\pi\omega_1\psi)*\omega_2 - 2 sin(2\pi\omega_2x) sin(-\pi\omega_2\psi)*\omega_1}{2\pi\omega_1\omega_2\psi}
\end{equation}
\begin{equation}
\frac{- sin(2\pi\omega_1x) sin(-\pi\omega_1\psi)*\omega_2 - sin(2\pi\omega_2x) sin(-\pi\omega_2\psi)*\omega_1}{\pi\omega_1\omega_2\psi}
\end{equation}
\begin{equation}
\frac{sin(2\pi\omega_1x) sin(\pi\omega_1\psi)*\omega_2 + sin(2\pi\omega_2x) sin(\pi\omega_2\psi)*\omega_1}{\pi\omega_1\omega_2\psi}
\end{equation}
On peut alors observer que les deux composent du signal (les deux signaux sinusoïdaux) dépende d'un sinus(w * x) et sinus(w * phi).
On notera alors que si phi équivaut à la période d'un des deux composant 1/w. phi annule la composent visé.
Démonstration:
\begin{equation}
\psi = \frac{1}{\omega_1}
\end{equation}
\begin{equation}
\frac{- 2 sin(2\pi\omega_1x) sin(-\pi\omega_1\frac{1}{\omega_1})*\omega_2 - 2 sin(2\pi\omega_2x) sin(-\pi\omega_2\frac{1}{\omega_1})*\omega_1}{2\pi\omega_1\omega_2\frac{1}{\omega_1}}
\end{equation}
\begin{equation}
\frac{- 2 sin(2\pi\omega_1x) sin(-\pi)*\omega_2 - 2 sin(2\pi\omega_2x) sin(-\pi\frac{\omega_2}{\omega_1})*\omega_1}{2\pi\omega_2}
\end{equation}
Vu que sinus(PI) équivaut a 0. (calcule en radiant) cela revient a faire:
\begin{equation}
\frac{- 2 sin(2\pi\omega_2x) sin(-\pi\frac{\omega_2}{\omega_1})*\omega_1}{2\pi\omega_2}
\end{equation}
On a belle est bien annulé la premier composant (signal sinusoïdal) composent le signal de base S(x)
## Solution Numérique
Voici les résultats par rapport à **N** pour $E(N)$