0

So my function is $y(x)=x^{3} - x\pi^{2}$ for $|x|\le\pi$.

I found out the Fourier coefficients, and now I am asked to compute a specific sum with Parseval's formula.

The issue for me lies on when computing $\frac{1}{2\pi}\int_{-\pi}^{\pi} |x^{3} - x\pi^{2}|^{2} dx$.

How do I handle the absolute value?

Jean Marie
  • 81,803
fejz1234
  • 542

2 Answers2

1

As user JeanMarie said in the comments, if $a \in \Bbb{R}$ then $$ |a|^2 = a^2 \tag{1} $$ Indeed, if $a\geq0$ then $|a|=a$ so certainly $(1)$ holds. If $a<0$ then $|a|=-a$ so $|a|^2=(-a)^2=a^2$ and $(1)$ holds also. So we conclude that $(1)$ holds for all $a \in \Bbb{R}$.

Now, as for your integral, making use of $(1)$, we get \begin{align} \| y\|_2^2 &= \frac{1}{2\pi} \int_{-\pi}^{\pi} |x^{3} - x\pi^{2}|^{2} \,dx \\ &= \frac{1}{2\pi}\int_{-\pi}^{\pi} (x^{3} - x\pi^{2})^{2} dx \\ &= \frac{1}{\pi}\int_{0}^{\pi}(x^6-2x^4\pi^2+x^2\pi^4) dx \quad \text{(even integrand)} \\ &= \frac{1}{\pi} \left[\frac{x^7}{7}-\frac{2\pi^2 x^5}{5} + \frac{\pi^4x^3}{3}\right]_{0}^{\pi} \\ &= \frac{1}{\pi} \left(\frac{\pi^7}{7}-\frac{2\pi^7}{5}+ \frac{\pi^7}{3}\right) \\ &= \frac{8 \pi^6}{105} \end{align}

  • Could you help me with this one? How do I think here : $y(x)=x^{2}$ for $|x|\le\pi$ What choice of $a_{0}$ minimises this integral $\int_{-\pi}^{\pi} |y(x)-a_{0}| dx $ – fejz1234 Feb 16 '17 at 23:20
  • @fejz1234 Well, you could tackle that problem with simple calculus. Just consider the cases $a_0 \leq 0$, $0 < a_0 \leq \pi^2$ and $a_0 > \pi^2$. Note that your problem is equivalent to minimizing $\displaystyle\int_0^{\pi} |x^2-a_0|,dx$ – NeedForHelp Feb 16 '17 at 23:45
1

Answer to the added question:

By symmetry, it is equivalent to minimize $I(a):=\int_{0}^{\pi} |y(x)-a| dx$ (I have dropped index $0$)

$I(a)=\int_0^{\sqrt{a}}(a-x^2)dx+\int_{\sqrt{a}}^{\pi}(x^2-a)dx$

$I(a)=[ax-x^3/3]_0^{\sqrt{a}}+[x^3/3-ax]_{\sqrt{a}}^{\pi}$

$I(a)=4a\sqrt{a}/3-a\pi+\pi^3/3$

whose minimum is obtained for a value of $a$ such that $I'(a)=0$ giving

$2\sqrt{a}=\pi \ \iff a=(\pi/2)^2$

Jean Marie
  • 81,803
  • I think your argument works for $0\leq a \leq \pi^2$. The value of your integral when $a=(\pi/2)^2$ is $\pi^3/4$. If $a\leq0$ then the integral equals $\pi^3/3-a\pi$ which is minimized when $a=0$ with value $\pi^3/3$. Finally if $a\geq\pi^2$ then the integral equals $\pi a-\pi^3/3$ which is minimized when $a=\pi^2$ with value $2\pi^3/3$. In the end $\pi^3/4$ wins. – NeedForHelp Feb 17 '17 at 00:03
  • @NeedForhelp It is almost evident that the value of $a$ that minimizes the integral is in the range of values of $x^2$, for $x \in[0,\pi]$, i.e., $[0,\pi^2]$. – Jean Marie Feb 17 '17 at 00:11
  • @NeedForHelp Thus I maintain that the value of $a$ that minimizes the integral is the one I have given. – Jean Marie Feb 17 '17 at 00:21
  • It's OK. You are correct. If it is evident you should at least say so at the beginning of your argument. Also what is evident for someone maybe isn't for another one. Saying "it is almost evident that..." rarely constitutes a proof... – NeedForHelp Feb 17 '17 at 00:24
  • @NeedForHelp I agree with your sense of rigor ; but for me, it can be a burden to over-explain, for example in such a case that $a$ cannot be negative, etc. – Jean Marie Feb 17 '17 at 00:31
  • Why is it by symmetry that is the same thing as ingegrating from 0 to pi? – fejz1234 Feb 17 '17 at 07:44
  • The consideration of symmetry is before beginning the minimisation process: whatever the value of $a$, $x\mapsto |x^2-a|$ is an even function thus $\int_{-\pi}^{\pi}....=2\int_0^{\pi}...$ – Jean Marie Feb 17 '17 at 13:19
  • Ah true...and if i want to find $a$ so that I can minimize $max_{x\in[-\pi,\pi]} |x^{2}-a| $ ? This should be equivalent with minimizing $max_{x\in[0,\pi]} |x^{2}-a| $? But im stuck here..the correct answer is $\frac{\pi^2}{2}$ – fejz1234 Feb 18 '17 at 13:24