1

How to integrate:

$$1) \int_{0}^{2}[x^{2}+[x^{2}]]dx$$

$$2) \int_{0}^{2}[x+[x^{2}+x+2]]dx$$

Here the two questions are different. And also $[.]$ denotes Greatest Integer Function.

Now my way of Approach:

For the $2^{nd}$ integral, I am trying this by writing

$$\int_{0}^{2}[x+[x^{2}+x+2]]dx=\int_{0}^{2}[x]dx+\int_{0}^{2}[x^{2}+x+2]dx$$

Now $$\int_{0}^{2}[x]dx$$ is easy.

But I am unable to integrate $$\int_{0}^{2}[x^{2}+x+2]dx$$

Though I thought of writing $x^{2}+x+2=(x+\frac{1}{2})^{2}+\frac{7}{4}$

But after this step I am unable to understand what to do.

Kindly help me out with these 2 integrals.

  • I had asked a similar question once, maybe the answers would help, see - https://math.stackexchange.com/q/4690200/1157207 – Amrut Ayan Sep 11 '24 at 11:53
  • You recieved 4 answers to your question. Is any of them what you needed? If so, consider accepting the best answer and upvoting all useful answers you got. That's how the site works. – 5xum Sep 13 '24 at 10:50
  • @5xum accepting an answer isn't mandatory? – Integreek Oct 22 '24 at 11:57
  • 1
    @MathGuy I didn't say it is. But some sort of feedback, while not obligatory, is certainly customary and helpful to the workings of the site. – 5xum Oct 22 '24 at 18:17

4 Answers4

2

$1) $ $$ \begin{aligned} \int_0^2\left[x^2+\left[x^2\right]\right] d x = & \int_0^2\left(\left[x^2\right]+\left[x^2\right]\right) d x \\ = & 2 \int_0^2\left[x^2\right] d x \\ = & 2\left[\int_1^{\sqrt{2}}\left[x^2\right] d x+\int_{\sqrt{2}}^{\sqrt{3}}\left[x^2\right] d x+\int_{\sqrt{3}}^2\left[x^2\right] d x\right] \\ = & 2\left[\int_1^{\sqrt{2}} 1 d x+\int_{\sqrt{2}}^{\sqrt{3}} 2 d x+\int_{\sqrt{3}}^2 3 d x\right] \\ = & 2[\sqrt{2}-1+2(\sqrt{3}-\sqrt{2})+3(2-\sqrt{3})] \\ = & 2(5-\sqrt{2}-\sqrt{3}) \end{aligned} $$ $2)$ $$ \int_0^2\left[x+\left[x^2+x+2\right]\right] d x = \int_0^2[x] d x+\int_0^2\left[x^2+x+2\right] d x = 3+\int_0^2\left[x^2+x+2\right] d x $$ To divide the interval $[0,2)$ into intervals by finding the ranges of $x$ for which $$ k-1 \leqslant x^2+x+2<k $$$$ \begin{aligned} 2\le x^2+x+2<3 & \Rightarrow \quad 0\le x<\frac{1}{2}(\sqrt{5}-1) \\ x^2+x+2<4 &\Rightarrow \quad x<1 \\ x^2+x+2<5 &\Rightarrow \quad x<\frac{1}{2}(\sqrt{13}-1) \\ x^2+x+2<6 &\Rightarrow \quad x<\frac{1}{2}(\sqrt{17}-1) \\ x^2+x+2<7 &\Rightarrow \quad x<\frac{1}{2}(\sqrt{21}-1) \\ x^2+x+2<8 &\Rightarrow \quad x<2 \end{aligned} $$ $$\begin{aligned} & \int_0^2\left[x^2+x+2\right] d x \\ = & \int_0^{\frac{1}{2}(\sqrt{5}-1)}\left[x^2+x+2\right] d x+\int_{\frac{1}{2}(\sqrt{5}-1)}^1\left[x^2+x+2\right] d x +\int_1^{\frac{1}{2}(\sqrt{13}-1)}\left[x^2+x+2\right] d x \\&+\int_{\frac{1}{2}(\sqrt{13}-1)}^{\frac{1}{2}(\sqrt{17}-1)}\left[x^2+x+2\right] d x +\int_{\frac{1}{2}(\sqrt{17}-1)}^{\frac{1}{2}(\sqrt{21}-1)}\left[x^2+x+2\right] d x+\int_{\frac{1}{2}(\sqrt{21}-1)}^2\left[x^2+x+2\right] d x \\=& 2\left[\frac{1}{2}(\sqrt{5}-1)\right]+3\left[1-\frac{1}{2}(\sqrt{5}-1)\right]+4\left[\frac{1}{2}(\sqrt{13}-1)-1\right] + 5\left[\frac{1}{2}(\sqrt{17}-\sqrt{13})\right]\\ &+6\left[\frac{1}{2}(\sqrt{21}-\sqrt{17}) \right]+7\left[2-\frac{1}{2}(\sqrt{2} 1-1)\right]\\=& \frac{1}{2}(23-\sqrt{5}-\sqrt{13}-\sqrt{17}-\sqrt{21}) \end{aligned}$$ $$\int_0^2\left[x+\left[x^2+x+2\right]\right] d x= \frac{1}{2}(29-\sqrt{5}-\sqrt{13}-\sqrt{17}-\sqrt{21})$$

Wish it helps.

Lai
  • 31,615
1

Hint:

First, think about what happens if you integrate something like

$$\int_0^1 [x^2] dx.$$

This should be a very simple integral to calculate.

Then, think about $$\int_1^2[x^2]dx$$

This one is a little trickier, but can you find some $a$ such that $$\int_1^a [x^2]dx$$ is again very simple (i.e., simple for the same reason that the first integral is simple)? Once you do that, find some $b$ such that $$\int_a^b [x^2]$$ is again simple, and continue the process until you cover the whole interval $[1,2]$.

5xum
  • 126,227
  • 6
  • 135
  • 211
  • Yes you are right. But for integral of $[x^{2}]$, the intervals are known to me. But for the integral of $[x^{2}+[x^{2}]]$ how can we consider the lower and upper limits of the integral? –  Sep 11 '24 at 09:39
  • For $[x^{2}]$ we generally assume the limits like $[0,1];[1,\sqrt{2}];[\sqrt{2},\sqrt{3}]$ and so on. But will the assumption be same for $[x^{2}+[x^{2}]]$ ? –  Sep 11 '24 at 09:41
  • 1
    @SyamaprasadChakrabarti Well, $[x^2 + [x^2]] = [x^2] + [x^2]$... – 5xum Sep 11 '24 at 09:46
1

I think it is hard to integrate it directly, so you can use the idea of the definition of integral.

That is, You can find the minimum and maximum of the function in the interval, and for each integers between the min and max, find the area under it.

For example, let $f=[x^2+[x^2]]$, then min is $0$, max is $8$. Consider $f=0\implies 0\leq x^2+[x^2]<1$, let $x^2=[x^2]+c$ for some $0\leq c<1$, thus we get $0\leq 2x^2-c<1\implies c\leq 2x^2<1+c$, since it is possible for $c=0$ or infinitely close to $1$, thus we get $0\leq 2x^2<2\implies 0\leq x<1$.

Hence there is a "rectangle" under $f=0$ at $0\leq x<1$, so the integral restricted to that range is $0\times(1-0)=0$, so $\int_0^1f(x)\,dx=0$. For the remaining, it is similar.

Note: you can plot the function for easier understanding

1

To evaluate the integral

$$ \int_{0}^{2} \left( x^2 + [x^2] \right) \, dx, $$

we need to understand the function involved, particularly the floor function $[x^2].$

  1. Evaluate the floor function $([x^2])$ for the interval from $(0)$ to $(2)$:

    • For $(0 \leq x < 1):$
      • $(x^2)$ ranges from $(0)$ to $(1)$ (not inclusive). Thus, $([x^2] = 0)$.
    • For $(1 \leq x < \sqrt{2})$ (i.e., $(1 \leq x < 1.4142))$:
      • $(x^2)$ ranges from $(1)$ to $(2)$ (not inclusive). Thus, $([x^2] = 1)$.
    • For $(\sqrt{2} \leq x < 2)$ (i.e., $(1.4142 \leq x < 2))$:
      • $(x^2)$ ranges from $(2)$ to $(4)$, so $([x^2] = 2)$.

Now, we can split the integral into pieces based on these intervals:

$$[ \int_{0}^{2} \left( x^2 + [x^2] \right) \, dx = \int_{0}^{1} \left( x^2 + 0 \right) \, dx + \int_{1}^{\sqrt{2}} \left( x^2 + 1 \right) \, dx + \int_{\sqrt{2}}^{2} \left( x^2 + 2 \right) \, dx. ]$$

  1. Calculate each integral separately:

    • For the first integral: $$[ \int_{0}^{1} x^2 \, dx = \left[ \frac{x^3}{3} \right]_{0}^{1} = \frac{1}{3}. ]$$

    • For the second integral: $$[ \int_{1}^{\sqrt{2}} (x^2 + 1) \, dx = \int_{1}^{\sqrt{2}} x^2 \, dx + \int_{1}^{\sqrt{2}} 1 \, dx. ]$$

    • The first part: $$[ \int_{1}^{\sqrt{2}} x^2 \, dx = \left[ \frac{x^3}{3} \right]_{1}^{\sqrt{2}} = \frac{(\sqrt{2})^3}{3} - \frac{1^3}{3} = \frac{2\sqrt{2}}{3} - \frac{1}{3} = \frac{2\sqrt{2} - 1}{3}. ]$$

    • The second part: $$[ \int_{1}^{\sqrt{2}} 1 \, dx = \sqrt{2} - 1. ]$$

    • Thus, for the second integral: $$[ \int_{1}^{\sqrt{2}} (x^2 + 1) \, dx = \frac{2\sqrt{2} - 1}{3} + (\sqrt{2} - 1) = \frac{2\sqrt{2} - 1 + 3(\sqrt{2} - 1)}{3} = \frac{5\sqrt{2} - 4}{3}. ]$$

    • For the third integral: $$[ \int_{\sqrt{2}}^{2} (x^2 + 2) \, dx = \int_{\sqrt{2}}^{2} x^2 \, dx + \int_{\sqrt{2}}^{2} 2 \, dx. ]$$

    • The first part: $$[ \int_{\sqrt{2}}^{2} x^2 \, dx = \left[ \frac{x^3}{3} \right]_{\sqrt{2}}^{2} = \frac{2^3}{3} - \frac{(\sqrt{2})^3}{3} = \frac{8}{3} - \frac{2\sqrt{2}}{3} = \frac{8 - 2\sqrt{2}}{3}. ]$$

    • The second part: $$[ \int_{\sqrt{2}}^{2} 2 \, dx = 2 \cdot (2 - \sqrt{2}) = 4 - 2\sqrt{2}. ]$$

    • Thus, for the third integral: $$[ \int_{\sqrt{2}}^{2} (x^2 + 2) \, dx = \frac{8 - 2\sqrt{2}}{3} + (4 - 2\sqrt{2}) = \frac{8 - 2\sqrt{2} + 12 - 6\sqrt{2}}{3} = \frac{20 - 8\sqrt{2}}{3}. ]$$

  2. Combine all the results: $$[ \int_{0}^{2} (x^2 + [x^2]) \, dx = \frac{1}{3} + \frac{5\sqrt{2} - 4}{3} + \frac{20 - 8\sqrt{2}}{3}. ]$$

Combining together:

$$[ = \frac{1 + (5\sqrt{2} - 4) + (20 - 8\sqrt{2})}{3} = \frac{1 - 4 + 20 + 5\sqrt{2} - 8\sqrt{2}}{3} = \frac{17 - 3\sqrt{2}}{3}. ]$$

Thus the final answer is:

$$[ \int_{0}^{2} (x^2 + [x^2]) \, dx = \frac{17 - 3\sqrt{2}}{3}. ]$$

Now for the second one. I don't know...but it's like the first one ..we must Evaluate the function in the range $0$ to $2$

Mostafa
  • 111