How do we solve $x^2 + \{x\}^2 = 33$ without computer

algebra-precalculusceiling-and-floor-functionsfractional-part

This is a problem taken from a group on Facebook. I wonder how to solve this without numerical process.

$x^2 + \{x\}^2 = 33\tag{1}$

My unfinished attempt:

$$\begin{align}
x^2 + \{x\}^2 &= 33\\
x^2 + \left(x – \lfloor x \rfloor\right)^2 &= 33\\
x^2 + x^2 – 2x \lfloor x \rfloor + \lfloor x \rfloor^2 &= 33\\
2x\left(x – \lfloor x \rfloor\right) + \lfloor x \rfloor^2 &= 33\\
2x\{x\} + \lfloor x \rfloor^2 = 33
\end{align}$$

I'm stuck at there. Also we know that the fractional part of $x$ is bounded i.e.:

$$0\leq\{x\}<1$$

From that, I can predict where the two solutions are placed at:

$$\begin{align}
0&\leq \{x\} < 1\\
0 &\leq \{x\}^2 < 1\\
x^2 &\leq x^2 + \{x\}^2 < x^2 + 1\\
x^2 &\leq 33 < x^2 + 1 \tag{$x^2 + \{x\}^2 = 33$}\\
S &= -\sqrt{33}\leq x \leq \sqrt{33} \quad \bigcap \quad x< -\sqrt{32} \lor x > \sqrt{32}\\
\therefore S &= -\sqrt{33}\leq x < -4\sqrt2 \quad \bigcup \quad 4\sqrt{2} < x \leq \sqrt{33}\\
S &\approx -5.74456 \leq x < -5.65685 \quad \bigcup \quad 5.65685 < x \leq 5.74456
\end{align}$$

I don't know if that's even going to help. Anyway, here are the two solutions (to the original problem) that's given by Wolfram Alpha:

$$\begin{align}
x_1 &= \frac12 \left(3\sqrt{17} – 1\right) \approx -5.815\\
x_2 &= \frac12 \left(-1 – 3\sqrt{113}\right) \approx 5.685
\end{align}$$

You see $x_1$ isn't at the interval. I'm confused.

Best Answer

ADDED EDIT BELOW.

First note roughly we know $5\le x \le 6$ or $-6\le x \le -5$.

So we have $\{x\}=x-5$ when $x>0$ and $\{x\}=x-(-6)=x+6$ when $x<0$, using the fact that $\{x\} = x - \lfloor x \rfloor$, where $\lfloor x \rfloor$ is the greatest integer less than or equal to $x$.

Now you solve each case separately.

When $x>0$, solve $x^2 +(x-5)^2=33$, noting we want the positive solution to this. With quadratic formula we get $\frac{5}{2} + \frac{\sqrt{41}}{2}$

And when $x<0$ solve $x^2 + (x+6)^2=33$, noting we want the negative solution between -6 and -5 to this. We get $-3 - \sqrt{15/2}$.

This matches what Wolfram give: https://www.wolframalpha.com/input/?i=x%5E2+%2B+%28x-floor%28x%29%29%5E2+%3D+33%2C+solve+for+x

(Which didn't match what you quoted above.)


Edit.

As it turns out $\{x\} = frac(x)$ is not universally agreed when $x$ is negative. According to Wikipedia: "However, in case of negative numbers, there are various conflicting ways to extend the fractional part function to them" https://en.wikipedia.org/wiki/Fractional_part.

So one might also consider the alternate definition, when $x<0$, take $\{x\} = x - \lceil x \rceil$ instead, and resolve it.